{"action":"opened","issue":{"url":"https://api.github.com/repos/johnpapa/angular-ngrx-data/issues/182","repository_url":"https://api.github.com/repos/johnpapa/angular-ngrx-data","labels_url":"https://api.github.com/repos/johnpapa/angular-ngrx-data/issues/182/labels{/name}","comments_url":"https://api.github.com/repos/johnpapa/angular-ngrx-data/issues/182/comments","events_url":"https://api.github.com/repos/johnpapa/angular-ngrx-data/issues/182/events","html_url":"https://github.com/johnpapa/angular-ngrx-data/issues/182","id":357326431,"node_id":"MDU6SXNzdWUzNTczMjY0MzE=","number":182,"title":"factory function don't work well when in production","user":{"login":"jberall","id":13126777,"node_id":"MDQ6VXNlcjEzMTI2Nzc3","avatar_url":"https://avatars3.githubusercontent.com/u/13126777?v=4","gravatar_id":"","url":"https://api.github.com/users/jberall","html_url":"https://github.com/jberall","followers_url":"https://api.github.com/users/jberall/followers","following_url":"https://api.github.com/users/jberall/following{/other_user}","gists_url":"https://api.github.com/users/jberall/gists{/gist_id}","starred_url":"https://api.github.com/users/jberall/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jberall/subscriptions","organizations_url":"https://api.github.com/users/jberall/orgs","repos_url":"https://api.github.com/users/jberall/repos","events_url":"https://api.github.com/users/jberall/events{/privacy}","received_events_url":"https://api.github.com/users/jberall/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-09-05T17:20:14Z","updated_at":"2018-09-05T17:20:14Z","closed_at":null,"author_association":"NONE","body":"<!--\r\nIF SUFFICIENT INFORMATION IS NOT PROVIDED VIA THE FOLLOWING TEMPLATE THE ISSUE MIGHT BE CLOSED WITHOUT FURTHER CONSIDERATION OR INVESTIGATION\r\n-->\r\n> Please provide us with the following information:\r\n> ---------------------------------------------------------------\r\n\r\n### This issue is for a: (mark with an `x`)\r\n```\r\n- [x ] bug report -> please search issues before submitting\r\n- [ ] feature request\r\n- [ ] documentation issue or request\r\n- [ ] regression (a behavior that used to work and stopped in a new release)\r\n```\r\n\r\n### Minimal steps to reproduce\r\nI have a factory function to create a service.  While in development everything works fine.\r\nWhen compiled in production the entityHttpResourceUrls  overwrite the entityUrl/entitiesUrl  to the default of ngrx-data.\r\nIn development the url is http://localhost:3000/api/super-heroes and in production it turns to http://localhost:3000/api/heroes\r\nThe DefaultDataServiceConfig seems to  overwrite the entityUrl/entitiesUrl in the service.  \r\n\r\nexport const urlConfig: DefaultDataServiceConfig = {\r\n  root:  environment.API_URL + '/api',\r\n  timeout: 2000,\r\n  getDelay: environment.API_URL === 'http://localhost:3000' ? 500 : 0,\r\n  saveDelay: environment.API_URL === 'http://localhost:3000' ? 500 : 0\r\n   entityHttpResourceUrls: {\r\n     Villain: {\r\n       entityResourceUrl: urlRoot + '/super-villain/',\r\n       collectionResourceUrl: urlRoot + '/super-villains/'\r\n      },\r\n\r\n }\r\n};\r\n\r\n### Any log messages given by the failure\r\n>\r\n\r\n### Expected/desired behavior\r\n>\r\n\r\n### OS and Version?\r\n> Windows 7, 8 or 10. Linux (which distribution). macOS (Yosemite? El Capitan? Sierra?)\r\nmacOS High Sierra\r\n### Versions\r\n> 10.13.16\r\n\r\n### Mention any other details that might be useful\r\n\r\n> ---------------------------------------------------------------\r\n> Thanks! We'll be in touch soon.\r\n"}}
{"actor":{"display_login":"jberall"}}