Advertisement
michussj07

config.service.ts

Feb 13th, 2020
198
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.35 KB | None | 0 0
  1. import { Injectable } from '@angular/core';
  2.  
  3. @Injectable({
  4. providedIn: 'root'
  5. })
  6. export class ConfigService {
  7.  
  8. public _api_url = '/api';
  9. private _user_url = this._api_url + '/user';
  10.  
  11. private _refresh_token_url = this._api_url + '/refresh';
  12.  
  13. get refresh_token_url(): string {
  14. return this._refresh_token_url;
  15. }
  16.  
  17. private _login_url = this._api_url + '/login';
  18.  
  19. get login_url(): string {
  20. return this._login_url;
  21. }
  22.  
  23. private _logout_url = this._api_url + '/logout';
  24. get logout_url(): string {
  25. return this._logout_url;
  26. }
  27.  
  28. private _change_password_url = this._api_url + '/changePassword';
  29.  
  30. get change_password_url(): string {
  31. return this._change_password_url;
  32. }
  33.  
  34. private _change_email_url = this._api_url;
  35.  
  36. get change_email_url(): string {
  37. return this._change_email_url;
  38. }
  39.  
  40. private _whoami_url = this._api_url + '/whoami';
  41.  
  42. get whoami_url(): string {
  43. return this._whoami_url;
  44. }
  45.  
  46. private _users_url = this._user_url + '/all';
  47.  
  48. get users_url(): string {
  49. return this._users_url;
  50. }
  51.  
  52. private _reset_credentials_url = this._user_url + '/reset-credentials';
  53.  
  54. get reset_credentials_url(): string {
  55. return this._reset_credentials_url;
  56. }
  57.  
  58. private _signup_url = this._api_url + '/signup';
  59.  
  60. get signup_url(): string {
  61. return this._signup_url;
  62. }
  63. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement