@abp/ng.identity 4.4.1 → 5.0.0-beta.1-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (160) hide show
  1. package/abp-ng.identity.d.ts +1 -11
  2. package/bundles/abp-ng.identity-config.umd.js +30 -7
  3. package/bundles/abp-ng.identity-config.umd.js.map +1 -1
  4. package/bundles/abp-ng.identity-proxy.umd.js +213 -0
  5. package/bundles/abp-ng.identity-proxy.umd.js.map +1 -0
  6. package/bundles/abp-ng.identity.umd.js +652 -1185
  7. package/bundles/abp-ng.identity.umd.js.map +1 -1
  8. package/config/abp-ng.identity-config.d.ts +1 -1
  9. package/config/identity-config.module.d.ts +4 -0
  10. package/config/package.json +0 -1
  11. package/config/providers/route.provider.d.ts +1 -1
  12. package/esm2015/abp-ng.identity.js +1 -10
  13. package/esm2015/abp-ng.identity.js.map +1 -0
  14. package/esm2015/config/abp-ng.identity-config.js +1 -2
  15. package/esm2015/config/abp-ng.identity-config.js.map +1 -0
  16. package/esm2015/config/enums/index.js +1 -1
  17. package/esm2015/config/enums/index.js.map +1 -0
  18. package/esm2015/config/enums/policy-names.js +1 -1
  19. package/esm2015/config/enums/policy-names.js.map +1 -0
  20. package/esm2015/config/enums/route-names.js +1 -1
  21. package/esm2015/config/enums/route-names.js.map +1 -0
  22. package/esm2015/config/identity-config.module.js +8 -4
  23. package/esm2015/config/identity-config.module.js.map +1 -0
  24. package/esm2015/config/providers/index.js +1 -1
  25. package/esm2015/config/providers/index.js.map +1 -0
  26. package/esm2015/config/providers/route.provider.js +1 -1
  27. package/esm2015/config/providers/route.provider.js.map +1 -0
  28. package/esm2015/config/public-api.js +1 -1
  29. package/esm2015/config/public-api.js.map +1 -0
  30. package/esm2015/lib/components/index.js +1 -1
  31. package/esm2015/lib/components/index.js.map +1 -0
  32. package/esm2015/lib/components/roles/roles.component.js +44 -46
  33. package/esm2015/lib/components/roles/roles.component.js.map +1 -0
  34. package/esm2015/lib/components/users/users.component.js +69 -67
  35. package/esm2015/lib/components/users/users.component.js.map +1 -0
  36. package/esm2015/lib/defaults/default-roles-entity-actions.js +14 -16
  37. package/esm2015/lib/defaults/default-roles-entity-actions.js.map +1 -0
  38. package/esm2015/lib/defaults/default-roles-entity-props.js +13 -15
  39. package/esm2015/lib/defaults/default-roles-entity-props.js.map +1 -0
  40. package/esm2015/lib/defaults/default-roles-form-props.js +3 -5
  41. package/esm2015/lib/defaults/default-roles-form-props.js.map +1 -0
  42. package/esm2015/lib/defaults/default-roles-toolbar-actions.js +5 -7
  43. package/esm2015/lib/defaults/default-roles-toolbar-actions.js.map +1 -0
  44. package/esm2015/lib/defaults/default-users-entity-actions.js +13 -15
  45. package/esm2015/lib/defaults/default-users-entity-actions.js.map +1 -0
  46. package/esm2015/lib/defaults/default-users-entity-props.js +1 -1
  47. package/esm2015/lib/defaults/default-users-entity-props.js.map +1 -0
  48. package/esm2015/lib/defaults/default-users-form-props.js +8 -11
  49. package/esm2015/lib/defaults/default-users-form-props.js.map +1 -0
  50. package/esm2015/lib/defaults/default-users-toolbar-actions.js +5 -7
  51. package/esm2015/lib/defaults/default-users-toolbar-actions.js.map +1 -0
  52. package/esm2015/lib/enums/components.js +1 -1
  53. package/esm2015/lib/enums/components.js.map +1 -0
  54. package/esm2015/lib/enums/index.js +1 -1
  55. package/esm2015/lib/enums/index.js.map +1 -0
  56. package/esm2015/lib/guards/extensions.guard.js +7 -7
  57. package/esm2015/lib/guards/extensions.guard.js.map +1 -0
  58. package/esm2015/lib/guards/index.js +1 -1
  59. package/esm2015/lib/guards/index.js.map +1 -0
  60. package/esm2015/lib/identity-routing.module.js +27 -23
  61. package/esm2015/lib/identity-routing.module.js.map +1 -0
  62. package/esm2015/lib/identity.module.js +38 -20
  63. package/esm2015/lib/identity.module.js.map +1 -0
  64. package/esm2015/lib/models/config-options.js +1 -1
  65. package/esm2015/lib/models/config-options.js.map +1 -0
  66. package/esm2015/lib/models/index.js +1 -2
  67. package/esm2015/lib/models/index.js.map +1 -0
  68. package/esm2015/lib/tokens/extensions.token.js +1 -1
  69. package/esm2015/lib/tokens/extensions.token.js.map +1 -0
  70. package/esm2015/lib/tokens/index.js +1 -1
  71. package/esm2015/lib/tokens/index.js.map +1 -0
  72. package/esm2015/proxy/abp-ng.identity-proxy.js +5 -0
  73. package/esm2015/proxy/abp-ng.identity-proxy.js.map +1 -0
  74. package/esm2015/proxy/lib/index.js +3 -0
  75. package/esm2015/proxy/lib/index.js.map +1 -0
  76. package/esm2015/proxy/lib/proxy/identity/identity-role.service.js +46 -0
  77. package/esm2015/proxy/lib/proxy/identity/identity-role.service.js.map +1 -0
  78. package/esm2015/proxy/lib/proxy/identity/identity-user-lookup.service.js +37 -0
  79. package/esm2015/proxy/lib/proxy/identity/identity-user-lookup.service.js.map +1 -0
  80. package/esm2015/proxy/lib/proxy/identity/identity-user.service.js +63 -0
  81. package/esm2015/proxy/lib/proxy/identity/identity-user.service.js.map +1 -0
  82. package/esm2015/proxy/lib/proxy/identity/index.js +6 -0
  83. package/esm2015/proxy/lib/proxy/identity/index.js.map +1 -0
  84. package/esm2015/proxy/lib/proxy/identity/models.js +2 -0
  85. package/esm2015/proxy/lib/proxy/identity/models.js.map +1 -0
  86. package/esm2015/proxy/lib/proxy/identity/profile.service.js +33 -0
  87. package/esm2015/proxy/lib/proxy/identity/profile.service.js.map +1 -0
  88. package/esm2015/proxy/lib/proxy/users/index.js +2 -0
  89. package/esm2015/proxy/lib/proxy/users/index.js.map +1 -0
  90. package/esm2015/proxy/lib/proxy/users/models.js +2 -0
  91. package/esm2015/proxy/lib/proxy/users/models.js.map +1 -0
  92. package/esm2015/proxy/public-api.js +2 -0
  93. package/esm2015/proxy/public-api.js.map +1 -0
  94. package/esm2015/public-api.js +1 -6
  95. package/esm2015/public-api.js.map +1 -0
  96. package/fesm2015/abp-ng.identity-config.js +8 -4
  97. package/fesm2015/abp-ng.identity-config.js.map +1 -1
  98. package/fesm2015/abp-ng.identity-proxy.js +173 -0
  99. package/fesm2015/abp-ng.identity-proxy.js.map +1 -0
  100. package/fesm2015/abp-ng.identity.js +224 -628
  101. package/fesm2015/abp-ng.identity.js.map +1 -1
  102. package/lib/components/roles/roles.component.d.ts +8 -8
  103. package/lib/components/users/users.component.d.ts +8 -10
  104. package/lib/defaults/default-roles-entity-actions.d.ts +1 -1
  105. package/lib/defaults/default-roles-entity-props.d.ts +1 -1
  106. package/lib/defaults/default-roles-form-props.d.ts +1 -1
  107. package/lib/defaults/default-roles-toolbar-actions.d.ts +1 -1
  108. package/lib/defaults/default-users-entity-actions.d.ts +1 -1
  109. package/lib/defaults/default-users-entity-props.d.ts +1 -1
  110. package/lib/defaults/default-users-form-props.d.ts +1 -1
  111. package/lib/defaults/default-users-toolbar-actions.d.ts +1 -1
  112. package/lib/guards/extensions.guard.d.ts +3 -0
  113. package/lib/identity-routing.module.d.ts +5 -0
  114. package/lib/identity.module.d.ts +13 -0
  115. package/lib/models/config-options.d.ts +1 -1
  116. package/lib/models/index.d.ts +0 -1
  117. package/lib/tokens/extensions.token.d.ts +1 -2
  118. package/package.json +7 -5
  119. package/proxy/abp-ng.identity-proxy.d.ts +5 -0
  120. package/proxy/lib/index.d.ts +2 -0
  121. package/{lib → proxy/lib}/proxy/identity/identity-role.service.d.ts +6 -3
  122. package/{lib → proxy/lib}/proxy/identity/identity-user-lookup.service.d.ts +3 -0
  123. package/{lib → proxy/lib}/proxy/identity/identity-user.service.d.ts +4 -1
  124. package/{lib → proxy/lib}/proxy/identity/index.d.ts +0 -0
  125. package/{lib → proxy/lib}/proxy/identity/models.d.ts +33 -28
  126. package/{lib → proxy/lib}/proxy/identity/profile.service.d.ts +3 -0
  127. package/{lib → proxy/lib}/proxy/users/index.d.ts +0 -0
  128. package/proxy/lib/proxy/users/models.d.ts +11 -0
  129. package/proxy/package.json +10 -0
  130. package/proxy/public-api.d.ts +1 -0
  131. package/public-api.d.ts +0 -5
  132. package/abp-ng.identity.metadata.json +0 -1
  133. package/bundles/abp-ng.identity-config.umd.min.js +0 -2
  134. package/bundles/abp-ng.identity-config.umd.min.js.map +0 -1
  135. package/bundles/abp-ng.identity.umd.min.js +0 -2
  136. package/bundles/abp-ng.identity.umd.min.js.map +0 -1
  137. package/config/abp-ng.identity-config.metadata.json +0 -1
  138. package/esm2015/lib/actions/identity.actions.js +0 -67
  139. package/esm2015/lib/actions/index.js +0 -2
  140. package/esm2015/lib/models/identity.js +0 -2
  141. package/esm2015/lib/proxy/identity/identity-role.service.js +0 -47
  142. package/esm2015/lib/proxy/identity/identity-user-lookup.service.js +0 -38
  143. package/esm2015/lib/proxy/identity/identity-user.service.js +0 -64
  144. package/esm2015/lib/proxy/identity/index.js +0 -6
  145. package/esm2015/lib/proxy/identity/models.js +0 -2
  146. package/esm2015/lib/proxy/identity/profile.service.js +0 -34
  147. package/esm2015/lib/proxy/users/index.js +0 -2
  148. package/esm2015/lib/proxy/users/models.js +0 -2
  149. package/esm2015/lib/services/identity-state.service.js +0 -66
  150. package/esm2015/lib/services/index.js +0 -2
  151. package/esm2015/lib/states/identity.state.js +0 -128
  152. package/esm2015/lib/states/index.js +0 -2
  153. package/lib/actions/identity.actions.d.ts +0 -65
  154. package/lib/actions/index.d.ts +0 -1
  155. package/lib/models/identity.d.ts +0 -11
  156. package/lib/proxy/users/models.d.ts +0 -11
  157. package/lib/services/identity-state.service.d.ts +0 -21
  158. package/lib/services/index.d.ts +0 -1
  159. package/lib/states/identity.state.d.ts +0 -26
  160. package/lib/states/index.d.ts +0 -1
@@ -1,318 +1,33 @@
1
- import { __decorate } from 'tslib';
2
1
  import * as i1 from '@abp/ng.core';
3
- import { RestService, ListService, LocalizationService, ConfigStateService, DynamicLayoutComponent, AuthGuard, PermissionGuard, ReplaceableRouteContainerComponent, LazyModuleFactory, CoreModule } from '@abp/ng.core';
4
- import { Confirmation, ConfirmationService, getPasswordValidators, ThemeSharedModule } from '@abp/ng.theme.shared';
2
+ import { ListService, LocalizationService, ConfigStateService, DynamicLayoutComponent, AuthGuard, PermissionGuard, ReplaceableRouteContainerComponent, LazyModuleFactory, CoreModule } from '@abp/ng.core';
3
+ import * as i3 from '@abp/ng.identity/proxy';
4
+ import * as i2 from '@abp/ng.theme.shared';
5
+ import { Confirmation, getPasswordValidators, ThemeSharedModule } from '@abp/ng.theme.shared';
6
+ import * as i4 from '@abp/ng.theme.shared/extensions';
5
7
  import { FormPropData, generateFormFromProps, EXTENSIONS_IDENTIFIER, EntityAction, EntityProp, FormProp, ToolbarAction, ExtensionsService, getObjectExtensionEntitiesFromStore, mapEntitiesToContributors, mergeWithDefaultActions, mergeWithDefaultProps, UiExtensionsModule } from '@abp/ng.theme.shared/extensions';
6
8
  import * as i0 from '@angular/core';
7
- import { Injectable, Component, Injector, ViewChild, InjectionToken, NgModule } from '@angular/core';
8
- import * as i1$1 from '@ngxs/store';
9
- import { Action, Selector, State, Store, Select, NgxsModule } from '@ngxs/store';
10
- import { tap, pluck, finalize, switchMap, take, map, mapTo } from 'rxjs/operators';
11
- import { FormBuilder, Validators } from '@angular/forms';
12
- import snq from 'snq';
13
- import { of } from 'rxjs';
9
+ import { Component, ViewChild, InjectionToken, Injectable, NgModule } from '@angular/core';
10
+ import { finalize, tap, switchMap, map, mapTo } from 'rxjs/operators';
11
+ import * as i5 from '@abp/ng.permission-management';
14
12
  import { PermissionManagementModule } from '@abp/ng.permission-management';
15
- import { NgbNavModule, NgbDropdownModule } from '@ng-bootstrap/ng-bootstrap';
13
+ import * as i4$1 from '@angular/forms';
14
+ import { Validators } from '@angular/forms';
15
+ import * as i9 from '@ngx-validate/core';
16
16
  import { NgxValidateCoreModule } from '@ngx-validate/core';
17
+ import * as i6 from '@ng-bootstrap/ng-bootstrap';
18
+ import { NgbNavModule, NgbDropdownModule } from '@ng-bootstrap/ng-bootstrap';
19
+ import * as i8 from '@angular/common';
20
+ import { of } from 'rxjs';
21
+ import * as i1$1 from '@angular/router';
17
22
  import { RouterModule } from '@angular/router';
18
23
 
19
- class GetRoles {
20
- constructor(payload) {
21
- this.payload = payload;
22
- }
23
- }
24
- GetRoles.type = '[Identity] Get Roles';
25
- class GetRoleById {
26
- constructor(payload) {
27
- this.payload = payload;
28
- }
29
- }
30
- GetRoleById.type = '[Identity] Get Role By Id';
31
- class DeleteRole {
32
- constructor(payload) {
33
- this.payload = payload;
34
- }
35
- }
36
- DeleteRole.type = '[Identity] Delete Role';
37
- class CreateRole {
38
- constructor(payload) {
39
- this.payload = payload;
40
- }
41
- }
42
- CreateRole.type = '[Identity] Create Role';
43
- class UpdateRole {
44
- constructor(payload) {
45
- this.payload = payload;
46
- }
47
- }
48
- UpdateRole.type = '[Identity] Update Role';
49
- class GetUsers {
50
- constructor(payload) {
51
- this.payload = payload;
52
- }
53
- }
54
- GetUsers.type = '[Identity] Get Users';
55
- class GetUserById {
56
- constructor(payload) {
57
- this.payload = payload;
58
- }
59
- }
60
- GetUserById.type = '[Identity] Get User By Id';
61
- class DeleteUser {
62
- constructor(payload) {
63
- this.payload = payload;
64
- }
65
- }
66
- DeleteUser.type = '[Identity] Delete User';
67
- class CreateUser {
68
- constructor(payload) {
69
- this.payload = payload;
70
- }
71
- }
72
- CreateUser.type = '[Identity] Create User';
73
- class UpdateUser {
74
- constructor(payload) {
75
- this.payload = payload;
76
- }
77
- }
78
- UpdateUser.type = '[Identity] Update User';
79
- class GetUserRoles {
80
- constructor(payload) {
81
- this.payload = payload;
82
- }
83
- }
84
- GetUserRoles.type = '[Identity] Get User Roles';
85
-
86
- class IdentityRoleService {
87
- constructor(restService) {
88
- this.restService = restService;
89
- this.apiName = 'AbpIdentity';
90
- this.create = (input) => this.restService.request({
91
- method: 'POST',
92
- url: '/api/identity/roles',
93
- body: input,
94
- }, { apiName: this.apiName });
95
- this.delete = (id) => this.restService.request({
96
- method: 'DELETE',
97
- url: `/api/identity/roles/${id}`,
98
- }, { apiName: this.apiName });
99
- this.get = (id) => this.restService.request({
100
- method: 'GET',
101
- url: `/api/identity/roles/${id}`,
102
- }, { apiName: this.apiName });
103
- this.getAllList = () => this.restService.request({
104
- method: 'GET',
105
- url: '/api/identity/roles/all',
106
- }, { apiName: this.apiName });
107
- this.getList = (input) => this.restService.request({
108
- method: 'GET',
109
- url: '/api/identity/roles',
110
- params: { sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },
111
- }, { apiName: this.apiName });
112
- this.update = (id, input) => this.restService.request({
113
- method: 'PUT',
114
- url: `/api/identity/roles/${id}`,
115
- body: input,
116
- }, { apiName: this.apiName });
117
- }
118
- }
119
- IdentityRoleService.ɵprov = i0.ɵɵdefineInjectable({ factory: function IdentityRoleService_Factory() { return new IdentityRoleService(i0.ɵɵinject(i1.RestService)); }, token: IdentityRoleService, providedIn: "root" });
120
- IdentityRoleService.decorators = [
121
- { type: Injectable, args: [{
122
- providedIn: 'root',
123
- },] }
124
- ];
125
- IdentityRoleService.ctorParameters = () => [
126
- { type: RestService }
127
- ];
128
-
129
- class IdentityUserService {
130
- constructor(restService) {
131
- this.restService = restService;
132
- this.apiName = 'AbpIdentity';
133
- this.create = (input) => this.restService.request({
134
- method: 'POST',
135
- url: '/api/identity/users',
136
- body: input,
137
- }, { apiName: this.apiName });
138
- this.delete = (id) => this.restService.request({
139
- method: 'DELETE',
140
- url: `/api/identity/users/${id}`,
141
- }, { apiName: this.apiName });
142
- this.findByEmail = (email) => this.restService.request({
143
- method: 'GET',
144
- url: `/api/identity/users/by-email/${email}`,
145
- }, { apiName: this.apiName });
146
- this.findByUsername = (username) => this.restService.request({
147
- method: 'GET',
148
- url: '/api/identity/users/by-username/{userName}',
149
- }, { apiName: this.apiName });
150
- this.get = (id) => this.restService.request({
151
- method: 'GET',
152
- url: `/api/identity/users/${id}`,
153
- }, { apiName: this.apiName });
154
- this.getAssignableRoles = () => this.restService.request({
155
- method: 'GET',
156
- url: '/api/identity/users/assignable-roles',
157
- }, { apiName: this.apiName });
158
- this.getList = (input) => this.restService.request({
159
- method: 'GET',
160
- url: '/api/identity/users',
161
- params: { filter: input.filter, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },
162
- }, { apiName: this.apiName });
163
- this.getRoles = (id) => this.restService.request({
164
- method: 'GET',
165
- url: `/api/identity/users/${id}/roles`,
166
- }, { apiName: this.apiName });
167
- this.update = (id, input) => this.restService.request({
168
- method: 'PUT',
169
- url: `/api/identity/users/${id}`,
170
- body: input,
171
- }, { apiName: this.apiName });
172
- this.updateRoles = (id, input) => this.restService.request({
173
- method: 'PUT',
174
- url: `/api/identity/users/${id}/roles`,
175
- body: input,
176
- }, { apiName: this.apiName });
177
- }
178
- }
179
- IdentityUserService.ɵprov = i0.ɵɵdefineInjectable({ factory: function IdentityUserService_Factory() { return new IdentityUserService(i0.ɵɵinject(i1.RestService)); }, token: IdentityUserService, providedIn: "root" });
180
- IdentityUserService.decorators = [
181
- { type: Injectable, args: [{
182
- providedIn: 'root',
183
- },] }
184
- ];
185
- IdentityUserService.ctorParameters = () => [
186
- { type: RestService }
187
- ];
188
-
189
- let IdentityState = class IdentityState {
190
- constructor(identityUserService, identityRoleService) {
191
- this.identityUserService = identityUserService;
192
- this.identityRoleService = identityRoleService;
193
- }
194
- static getRoles({ roles }) {
195
- return roles.items || [];
196
- }
197
- static getRolesTotalCount({ roles }) {
198
- return roles.totalCount || 0;
199
- }
200
- static getUsers({ users }) {
201
- return users.items || [];
202
- }
203
- static getUsersTotalCount({ users }) {
204
- return users.totalCount || 0;
205
- }
206
- getRoles({ patchState }, { payload }) {
207
- return this.identityRoleService.getList(payload).pipe(tap(roles => patchState({
208
- roles,
209
- })));
210
- }
211
- getRole({ patchState }, { payload }) {
212
- return this.identityRoleService.get(payload).pipe(tap(selectedRole => patchState({
213
- selectedRole,
214
- })));
215
- }
216
- deleteRole(_, { payload }) {
217
- return this.identityRoleService.delete(payload);
218
- }
219
- addRole(_, { payload }) {
220
- return this.identityRoleService.create(payload);
221
- }
222
- updateRole({ getState }, { payload }) {
223
- return this.identityRoleService.update(payload.id, Object.assign(Object.assign({}, getState().selectedRole), payload));
224
- }
225
- getUsers({ patchState }, { payload }) {
226
- return this.identityUserService.getList(payload).pipe(tap(users => patchState({
227
- users,
228
- })));
229
- }
230
- getUser({ patchState }, { payload }) {
231
- return this.identityUserService.get(payload).pipe(tap(selectedUser => patchState({
232
- selectedUser,
233
- })));
234
- }
235
- deleteUser(_, { payload }) {
236
- return this.identityUserService.delete(payload);
237
- }
238
- addUser(_, { payload }) {
239
- return this.identityUserService.create(payload);
240
- }
241
- updateUser({ getState }, { payload }) {
242
- return this.identityUserService.update(payload.id, Object.assign(Object.assign({}, getState().selectedUser), payload));
243
- }
244
- getUserRoles({ patchState }, { payload }) {
245
- return this.identityUserService.getRoles(payload).pipe(pluck('items'), tap(selectedUserRoles => patchState({
246
- selectedUserRoles,
247
- })));
248
- }
249
- };
250
- IdentityState.decorators = [
251
- { type: Injectable }
252
- ];
253
- IdentityState.ctorParameters = () => [
254
- { type: IdentityUserService },
255
- { type: IdentityRoleService }
256
- ];
257
- __decorate([
258
- Action(GetRoles)
259
- ], IdentityState.prototype, "getRoles", null);
260
- __decorate([
261
- Action(GetRoleById)
262
- ], IdentityState.prototype, "getRole", null);
263
- __decorate([
264
- Action(DeleteRole)
265
- ], IdentityState.prototype, "deleteRole", null);
266
- __decorate([
267
- Action(CreateRole)
268
- ], IdentityState.prototype, "addRole", null);
269
- __decorate([
270
- Action(UpdateRole)
271
- ], IdentityState.prototype, "updateRole", null);
272
- __decorate([
273
- Action(GetUsers)
274
- ], IdentityState.prototype, "getUsers", null);
275
- __decorate([
276
- Action(GetUserById)
277
- ], IdentityState.prototype, "getUser", null);
278
- __decorate([
279
- Action(DeleteUser)
280
- ], IdentityState.prototype, "deleteUser", null);
281
- __decorate([
282
- Action(CreateUser)
283
- ], IdentityState.prototype, "addUser", null);
284
- __decorate([
285
- Action(UpdateUser)
286
- ], IdentityState.prototype, "updateUser", null);
287
- __decorate([
288
- Action(GetUserRoles)
289
- ], IdentityState.prototype, "getUserRoles", null);
290
- __decorate([
291
- Selector()
292
- ], IdentityState, "getRoles", null);
293
- __decorate([
294
- Selector()
295
- ], IdentityState, "getRolesTotalCount", null);
296
- __decorate([
297
- Selector()
298
- ], IdentityState, "getUsers", null);
299
- __decorate([
300
- Selector()
301
- ], IdentityState, "getUsersTotalCount", null);
302
- IdentityState = __decorate([
303
- State({
304
- name: 'IdentityState',
305
- defaults: { roles: {}, selectedRole: {}, users: {}, selectedUser: {} },
306
- })
307
- ], IdentityState);
308
-
309
- const ɵ0$9 = "Identity.RolesComponent" /* Roles */;
310
24
  class RolesComponent {
311
- constructor(list, confirmationService, store, injector) {
25
+ constructor(list, confirmationService, injector, service) {
312
26
  this.list = list;
313
27
  this.confirmationService = confirmationService;
314
- this.store = store;
315
28
  this.injector = injector;
29
+ this.service = service;
30
+ this.data = { items: [], totalCount: 0 };
316
31
  this.visiblePermissions = false;
317
32
  this.modalBusy = false;
318
33
  this.permissionManagementKey = "PermissionManagement.PermissionManagementComponent" /* PermissionManagement */;
@@ -336,11 +51,8 @@ class RolesComponent {
336
51
  this.openModal();
337
52
  }
338
53
  edit(id) {
339
- this.store
340
- .dispatch(new GetRoleById(id))
341
- .pipe(pluck('IdentityState', 'selectedRole'))
342
- .subscribe(selectedRole => {
343
- this.selected = selectedRole;
54
+ this.service.get(id).subscribe(res => {
55
+ this.selected = res;
344
56
  this.openModal();
345
57
  });
346
58
  }
@@ -348,10 +60,10 @@ class RolesComponent {
348
60
  if (!this.form.valid)
349
61
  return;
350
62
  this.modalBusy = true;
351
- this.store
352
- .dispatch(this.selected.id
353
- ? new UpdateRole(Object.assign(Object.assign(Object.assign({}, this.selected), this.form.value), { id: this.selected.id }))
354
- : new CreateRole(this.form.value))
63
+ const { id } = this.selected;
64
+ (id
65
+ ? this.service.update(id, Object.assign(Object.assign({}, this.selected), this.form.value))
66
+ : this.service.create(this.form.value))
355
67
  .pipe(finalize(() => (this.modalBusy = false)))
356
68
  .subscribe(() => {
357
69
  this.isModalVisible = false;
@@ -365,12 +77,12 @@ class RolesComponent {
365
77
  })
366
78
  .subscribe((status) => {
367
79
  if (status === Confirmation.Status.confirm) {
368
- this.store.dispatch(new DeleteRole(id)).subscribe(() => this.list.get());
80
+ this.service.delete(id).subscribe(() => this.list.get());
369
81
  }
370
82
  });
371
83
  }
372
84
  hookToQuery() {
373
- this.list.hookToQuery(query => this.store.dispatch(new GetRoles(query))).subscribe();
85
+ this.list.hookToQuery(query => this.service.getList(query)).subscribe(res => (this.data = res));
374
86
  }
375
87
  openPermissionsModal(providerKey) {
376
88
  this.providerKey = providerKey;
@@ -384,41 +96,37 @@ class RolesComponent {
384
96
  this.list.sortOrder = dir;
385
97
  }
386
98
  }
387
- RolesComponent.decorators = [
388
- { type: Component, args: [{
389
- selector: 'abp-roles',
390
- template: "<div id=\"identity-roles-wrapper\" class=\"card\">\n <div class=\"card-header\">\n <div class=\"row\">\n <div class=\"col col-md-6\">\n <h5 class=\"card-title\">{{ 'AbpIdentity::Roles' | abpLocalization }}</h5>\n </div>\n <div class=\"text-right col col-md-6\">\n <abp-page-toolbar [record]=\"data$ | async\"></abp-page-toolbar>\n </div>\n </div>\n </div>\n\n <div class=\"card-body\">\n <abp-extensible-table\n [data]=\"data$ | async\"\n [recordsTotal]=\"totalCount$ | async\"\n [list]=\"list\"\n ></abp-extensible-table>\n </div>\n</div>\n\n<abp-modal size=\"md\" [(visible)]=\"isModalVisible\" [busy]=\"modalBusy\">\n <ng-template #abpHeader>\n <h3>{{ (selected?.id ? 'AbpIdentity::Edit' : 'AbpIdentity::NewRole') | abpLocalization }}</h3>\n </ng-template>\n\n <ng-template #abpBody>\n <form [formGroup]=\"form\" (ngSubmit)=\"save()\" validateOnSubmit>\n <abp-extensible-form [selectedRecord]=\"selected\"></abp-extensible-form>\n </form>\n </ng-template>\n\n <ng-template #abpFooter>\n <button type=\"button\" class=\"btn btn-secondary\" abpClose>\n {{ 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <abp-button iconClass=\"fa fa-check\" [disabled]=\"form?.invalid\" (click)=\"save()\">{{\n 'AbpIdentity::Save' | abpLocalization\n }}</abp-button>\n </ng-template>\n</abp-modal>\n\n<abp-permission-management\n #abpPermissionManagement=\"abpPermissionManagement\"\n *abpReplaceableTemplate=\"\n {\n inputs: {\n providerName: { value: 'R' },\n providerKey: { value: providerKey },\n visible: { value: visiblePermissions, twoWay: true },\n hideBadges: { value: true }\n },\n outputs: { visibleChange: onVisiblePermissionChange },\n componentKey: permissionManagementKey\n };\n let init = initTemplate\n \"\n (abpInit)=\"init(abpPermissionManagement)\"\n>\n</abp-permission-management>\n",
391
- providers: [
392
- ListService,
393
- {
394
- provide: EXTENSIONS_IDENTIFIER,
395
- useValue: ɵ0$9,
396
- },
397
- ]
398
- },] }
399
- ];
400
- RolesComponent.ctorParameters = () => [
401
- { type: ListService },
402
- { type: ConfirmationService },
403
- { type: Store },
404
- { type: Injector }
405
- ];
406
- __decorate([
407
- Select(IdentityState.getRoles)
408
- ], RolesComponent.prototype, "data$", void 0);
409
- __decorate([
410
- Select(IdentityState.getRolesTotalCount)
411
- ], RolesComponent.prototype, "totalCount$", void 0);
99
+ RolesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: RolesComponent, deps: [{ token: i1.ListService }, { token: i2.ConfirmationService }, { token: i0.Injector }, { token: i3.IdentityRoleService }], target: i0.ɵɵFactoryTarget.Component });
100
+ RolesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.6", type: RolesComponent, selector: "abp-roles", providers: [
101
+ ListService,
102
+ {
103
+ provide: EXTENSIONS_IDENTIFIER,
104
+ useValue: "Identity.RolesComponent" /* Roles */,
105
+ },
106
+ ], ngImport: i0, template: "<div id=\"identity-roles-wrapper\" class=\"card\">\n <div class=\"card-header\">\n <div class=\"row\">\n <div class=\"col col-md-6\">\n <h5 class=\"card-title\">{{ 'AbpIdentity::Roles' | abpLocalization }}</h5>\n </div>\n <div class=\"text-right col col-md-6\">\n <abp-page-toolbar [record]=\"data.items\"></abp-page-toolbar>\n </div>\n </div>\n </div>\n\n <div class=\"card-body\">\n <abp-extensible-table\n [data]=\"data.items\"\n [recordsTotal]=\"data.totalCount\"\n [list]=\"list\"\n ></abp-extensible-table>\n </div>\n</div>\n\n<abp-modal [(visible)]=\"isModalVisible\" [busy]=\"modalBusy\">\n <ng-template #abpHeader>\n <h3>{{ (selected?.id ? 'AbpIdentity::Edit' : 'AbpIdentity::NewRole') | abpLocalization }}</h3>\n </ng-template>\n\n <ng-template #abpBody>\n <form [formGroup]=\"form\" (ngSubmit)=\"save()\" validateOnSubmit>\n <abp-extensible-form [selectedRecord]=\"selected\"></abp-extensible-form>\n </form>\n </ng-template>\n\n <ng-template #abpFooter>\n <button type=\"button\" class=\"btn btn-secondary\" abpClose>\n {{ 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <abp-button iconClass=\"fa fa-check\" [disabled]=\"form?.invalid\" (click)=\"save()\">{{\n 'AbpIdentity::Save' | abpLocalization\n }}</abp-button>\n </ng-template>\n</abp-modal>\n\n<abp-permission-management\n #abpPermissionManagement=\"abpPermissionManagement\"\n *abpReplaceableTemplate=\"\n {\n inputs: {\n providerName: { value: 'R' },\n providerKey: { value: providerKey },\n visible: { value: visiblePermissions, twoWay: true },\n hideBadges: { value: true }\n },\n outputs: { visibleChange: onVisiblePermissionChange },\n componentKey: permissionManagementKey\n };\n let init = initTemplate\n \"\n (abpInit)=\"init(abpPermissionManagement)\"\n>\n</abp-permission-management>\n", components: [{ type: i4.PageToolbarComponent, selector: "abp-page-toolbar", exportAs: ["abpPageToolbar"] }, { type: i4.ExtensibleTableComponent, selector: "abp-extensible-table", inputs: ["actionsText", "data", "list", "recordsTotal", "actionsColumnWidth", "actionsTemplate"], exportAs: ["abpExtensibleTable"] }, { type: i2.ModalComponent, selector: "abp-modal", inputs: ["visible", "busy", "options", "suppressUnsavedChangesWarning"], outputs: ["visibleChange", "init", "appear", "disappear"] }, { type: i4.ExtensibleFormComponent, selector: "abp-extensible-form", inputs: ["selectedRecord"], exportAs: ["abpExtensibleForm"] }, { type: i2.ButtonComponent, selector: "abp-button", inputs: ["buttonId", "buttonClass", "buttonType", "iconClass", "loading", "disabled", "attributes"], outputs: ["click", "focus", "blur", "abpClick", "abpFocus", "abpBlur"] }, { type: i5.PermissionManagementComponent, selector: "abp-permission-management", inputs: ["providerName", "providerKey", "hideBadges", "visible"], outputs: ["visibleChange"], exportAs: ["abpPermissionManagement"] }], directives: [{ type: i4$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i4$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i1.FormSubmitDirective, selector: "form[ngSubmit][formGroup]", inputs: ["debounce", "notValidateOnSubmit"], outputs: ["ngSubmit"] }, { type: i4$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i9.ValidationGroupDirective, selector: "[formGroup],[formGroupName]", inputs: ["blueprints", "errorTemplate", "invalidClasses", "mapErrorsFn", "skipValidation", "targetSelector", "validateOnSubmit"] }, { type: i2.ModalCloseDirective, selector: "[abpClose]" }, { type: i1.ReplaceableTemplateDirective, selector: "[abpReplaceableTemplate]", inputs: ["abpReplaceableTemplate"] }, { type: i1.InitDirective, selector: "[abpInit]", outputs: ["abpInit"] }], pipes: { "abpLocalization": i1.LocalizationPipe } });
107
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: RolesComponent, decorators: [{
108
+ type: Component,
109
+ args: [{
110
+ selector: 'abp-roles',
111
+ templateUrl: './roles.component.html',
112
+ providers: [
113
+ ListService,
114
+ {
115
+ provide: EXTENSIONS_IDENTIFIER,
116
+ useValue: "Identity.RolesComponent" /* Roles */,
117
+ },
118
+ ],
119
+ }]
120
+ }], ctorParameters: function () { return [{ type: i1.ListService }, { type: i2.ConfirmationService }, { type: i0.Injector }, { type: i3.IdentityRoleService }]; } });
412
121
 
413
- const ɵ0$8 = "Identity.UsersComponent" /* Users */;
414
122
  class UsersComponent {
415
- constructor(list, confirmationService, userService, fb, store, injector) {
123
+ constructor(list, confirmationService, service, fb, injector) {
416
124
  this.list = list;
417
125
  this.confirmationService = confirmationService;
418
- this.userService = userService;
126
+ this.service = service;
419
127
  this.fb = fb;
420
- this.store = store;
421
128
  this.injector = injector;
129
+ this.data = { items: [], totalCount: 0 };
422
130
  this.visiblePermissions = false;
423
131
  this.modalBusy = false;
424
132
  this.permissionManagementKey = "PermissionManagement.PermissionManagementComponent" /* PermissionManagement */;
@@ -428,7 +136,8 @@ class UsersComponent {
428
136
  };
429
137
  }
430
138
  get roleGroups() {
431
- return snq(() => this.form.get('roleNames').controls, []);
139
+ var _a;
140
+ return ((_a = this.form.get('roleNames')) === null || _a === void 0 ? void 0 : _a.controls) || [];
432
141
  }
433
142
  ngOnInit() {
434
143
  this.hookToQuery();
@@ -436,15 +145,18 @@ class UsersComponent {
436
145
  buildForm() {
437
146
  const data = new FormPropData(this.injector, this.selected);
438
147
  this.form = generateFormFromProps(data);
439
- this.userService.getAssignableRoles().subscribe(({ items }) => {
148
+ this.service.getAssignableRoles().subscribe(({ items }) => {
440
149
  this.roles = items;
441
- this.form.addControl('roleNames', this.fb.array(this.roles.map(role => this.fb.group({
442
- [role.name]: [
443
- this.selected.id
444
- ? !!snq(() => this.selectedUserRoles.find(userRole => userRole.id === role.id))
445
- : role.isDefault,
446
- ],
447
- }))));
150
+ this.form.addControl('roleNames', this.fb.array(this.roles.map(role => {
151
+ var _a;
152
+ return this.fb.group({
153
+ [role.name]: [
154
+ this.selected.id
155
+ ? !!((_a = this.selectedUserRoles) === null || _a === void 0 ? void 0 : _a.find(userRole => userRole.id === role.id))
156
+ : role.isDefault,
157
+ ],
158
+ });
159
+ })));
448
160
  });
449
161
  }
450
162
  openModal() {
@@ -457,12 +169,11 @@ class UsersComponent {
457
169
  this.openModal();
458
170
  }
459
171
  edit(id) {
460
- this.store
461
- .dispatch(new GetUserById(id))
462
- .pipe(switchMap(() => this.store.dispatch(new GetUserRoles(id))), pluck('IdentityState'), take(1))
463
- .subscribe((state) => {
464
- this.selected = state.selectedUser;
465
- this.selectedUserRoles = state.selectedUserRoles || [];
172
+ this.service
173
+ .get(id)
174
+ .pipe(tap(user => (this.selected = user)), switchMap(() => this.service.getRoles(id)))
175
+ .subscribe(userRole => {
176
+ this.selectedUserRoles = userRole.items || [];
466
177
  this.openModal();
467
178
  });
468
179
  }
@@ -470,12 +181,13 @@ class UsersComponent {
470
181
  if (!this.form.valid || this.modalBusy)
471
182
  return;
472
183
  this.modalBusy = true;
473
- const { roleNames } = this.form.value;
474
- const mappedRoleNames = snq(() => roleNames.filter(role => !!role[Object.keys(role)[0]]).map(role => Object.keys(role)[0]), []);
475
- this.store
476
- .dispatch(this.selected.id
477
- ? new UpdateUser(Object.assign(Object.assign(Object.assign({}, this.selected), this.form.value), { id: this.selected.id, roleNames: mappedRoleNames }))
478
- : new CreateUser(Object.assign(Object.assign({}, this.form.value), { roleNames: mappedRoleNames })))
184
+ const { roleNames = [] } = this.form.value;
185
+ const mappedRoleNames = roleNames.filter(role => !!role[Object.keys(role)[0]]).map(role => Object.keys(role)[0]) ||
186
+ [];
187
+ const { id } = this.selected;
188
+ (id
189
+ ? this.service.update(id, Object.assign(Object.assign(Object.assign({}, this.selected), this.form.value), { roleNames: mappedRoleNames }))
190
+ : this.service.create(Object.assign(Object.assign({}, this.form.value), { roleNames: mappedRoleNames })))
479
191
  .pipe(finalize(() => (this.modalBusy = false)))
480
192
  .subscribe(() => {
481
193
  this.isModalVisible = false;
@@ -489,7 +201,7 @@ class UsersComponent {
489
201
  })
490
202
  .subscribe((status) => {
491
203
  if (status === Confirmation.Status.confirm) {
492
- this.store.dispatch(new DeleteUser(id)).subscribe(() => this.list.get());
204
+ this.service.delete(id).subscribe(() => this.list.get());
493
205
  }
494
206
  });
495
207
  }
@@ -499,7 +211,7 @@ class UsersComponent {
499
211
  this.list.sortOrder = dir;
500
212
  }
501
213
  hookToQuery() {
502
- this.list.hookToQuery(query => this.store.dispatch(new GetUsers(query))).subscribe();
214
+ this.list.hookToQuery(query => this.service.getList(query)).subscribe(res => (this.data = res));
503
215
  }
504
216
  openPermissionsModal(providerKey) {
505
217
  this.providerKey = providerKey;
@@ -508,97 +220,89 @@ class UsersComponent {
508
220
  }, 0);
509
221
  }
510
222
  }
511
- UsersComponent.decorators = [
512
- { type: Component, args: [{
513
- selector: 'abp-users',
514
- template: "<div id=\"identity-roles-wrapper\" class=\"card\">\n <div class=\"card-header\">\n <div class=\"row\">\n <div class=\"col col-md-6\">\n <h5 class=\"card-title\">{{ 'AbpIdentity::Users' | abpLocalization }}</h5>\n </div>\n <div class=\"text-right col col-md-6\">\n <abp-page-toolbar [record]=\"data$ | async\"></abp-page-toolbar>\n </div>\n </div>\n </div>\n <div class=\"card-body\">\n <div id=\"data-tables-table-filter\" class=\"data-tables-filter\">\n <div class=\"input-group\">\n <input\n type=\"search\"\n class=\"form-control\"\n [placeholder]=\"'AbpUi::PagerSearch' | abpLocalization\"\n [(ngModel)]=\"list.filter\"\n />\n </div>\n </div>\n\n <abp-extensible-table\n [data]=\"data$ | async\"\n [recordsTotal]=\"totalCount$ | async\"\n [list]=\"list\"\n ></abp-extensible-table>\n </div>\n</div>\n\n<abp-modal size=\"md\" [(visible)]=\"isModalVisible\" [busy]=\"modalBusy\">\n <ng-template #abpHeader>\n <h3>{{ (selected?.id ? 'AbpIdentity::Edit' : 'AbpIdentity::NewUser') | abpLocalization }}</h3>\n </ng-template>\n\n <ng-template #abpBody>\n <ng-template #loaderRef\n ><div class=\"text-center\"><i class=\"fa fa-pulse fa-spinner\"></i></div\n ></ng-template>\n\n <form *ngIf=\"form; else loaderRef\" [formGroup]=\"form\" (ngSubmit)=\"save()\">\n <ul ngbNav #nav=\"ngbNav\" class=\"nav-tabs\">\n <li ngbNavItem>\n <a ngbNavLink>{{ 'AbpIdentity::UserInformations' | abpLocalization }}</a>\n <ng-template ngbNavContent>\n <abp-extensible-form [selectedRecord]=\"selected\"></abp-extensible-form>\n </ng-template>\n </li>\n\n <li ngbNavItem>\n <a ngbNavLink>{{ 'AbpIdentity::Roles' | abpLocalization }}</a>\n <ng-template ngbNavContent>\n <div\n *ngFor=\"let roleGroup of roleGroups; let i = index; trackBy: trackByFn\"\n class=\"custom-checkbox custom-control mb-2\"\n >\n <input\n type=\"checkbox\"\n class=\"custom-control-input\"\n [attr.id]=\"'roles-' + i\"\n [formControl]=\"roleGroup.controls[roles[i].name]\"\n />\n <label class=\"custom-control-label\" [attr.for]=\"'roles-' + i\">{{\n roles[i].name\n }}</label>\n </div>\n </ng-template>\n </li>\n </ul>\n\n <div class=\"mt-2 fade-in-top\" [ngbNavOutlet]=\"nav\"></div>\n </form>\n </ng-template>\n\n <ng-template #abpFooter>\n <button type=\"button\" class=\"btn btn-secondary\" abpClose>\n {{ 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <abp-button iconClass=\"fa fa-check\" [disabled]=\"form?.invalid\" (click)=\"save()\">{{\n 'AbpIdentity::Save' | abpLocalization\n }}</abp-button>\n </ng-template>\n</abp-modal>\n\n<abp-permission-management\n #abpPermissionManagement=\"abpPermissionManagement\"\n *abpReplaceableTemplate=\"\n {\n inputs: {\n providerName: { value: 'U' },\n providerKey: { value: providerKey },\n visible: { value: visiblePermissions, twoWay: true }\n },\n outputs: { visibleChange: onVisiblePermissionChange },\n componentKey: permissionManagementKey\n };\n let init = initTemplate\n \"\n (abpInit)=\"init(abpPermissionManagement)\"\n>\n</abp-permission-management>\n",
515
- providers: [
516
- ListService,
517
- {
518
- provide: EXTENSIONS_IDENTIFIER,
519
- useValue: ɵ0$8,
520
- },
521
- ]
522
- },] }
523
- ];
524
- UsersComponent.ctorParameters = () => [
525
- { type: ListService },
526
- { type: ConfirmationService },
527
- { type: IdentityUserService },
528
- { type: FormBuilder },
529
- { type: Store },
530
- { type: Injector }
531
- ];
532
- UsersComponent.propDecorators = {
533
- modalContent: [{ type: ViewChild, args: ['modalContent', { static: false },] }]
534
- };
535
- __decorate([
536
- Select(IdentityState.getUsers)
537
- ], UsersComponent.prototype, "data$", void 0);
538
- __decorate([
539
- Select(IdentityState.getUsersTotalCount)
540
- ], UsersComponent.prototype, "totalCount$", void 0);
223
+ UsersComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: UsersComponent, deps: [{ token: i1.ListService }, { token: i2.ConfirmationService }, { token: i3.IdentityUserService }, { token: i4$1.FormBuilder }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
224
+ UsersComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.6", type: UsersComponent, selector: "abp-users", providers: [
225
+ ListService,
226
+ {
227
+ provide: EXTENSIONS_IDENTIFIER,
228
+ useValue: "Identity.UsersComponent" /* Users */,
229
+ },
230
+ ], viewQueries: [{ propertyName: "modalContent", first: true, predicate: ["modalContent"], descendants: true }], ngImport: i0, template: "<div id=\"identity-roles-wrapper\" class=\"card\">\n <div class=\"card-header\">\n <div class=\"row\">\n <div class=\"col col-md-6\">\n <h5 class=\"card-title\">{{ 'AbpIdentity::Users' | abpLocalization }}</h5>\n </div>\n <div class=\"text-right col col-md-6\">\n <abp-page-toolbar [record]=\"data.items\"></abp-page-toolbar>\n </div>\n </div>\n </div>\n <div class=\"card-body\">\n <div id=\"data-tables-table-filter\" class=\"data-tables-filter\">\n <div class=\"input-group\">\n <input\n type=\"search\"\n class=\"form-control\"\n [placeholder]=\"'AbpUi::PagerSearch' | abpLocalization\"\n [(ngModel)]=\"list.filter\"\n />\n </div>\n </div>\n\n <abp-extensible-table\n [data]=\"data.items\"\n [recordsTotal]=\"data.totalCount\"\n [list]=\"list\"\n ></abp-extensible-table>\n </div>\n</div>\n\n<abp-modal [(visible)]=\"isModalVisible\" [busy]=\"modalBusy\">\n <ng-template #abpHeader>\n <h3>{{ (selected?.id ? 'AbpIdentity::Edit' : 'AbpIdentity::NewUser') | abpLocalization }}</h3>\n </ng-template>\n\n <ng-template #abpBody>\n <ng-template #loaderRef\n ><div class=\"text-center\"><i class=\"fa fa-pulse fa-spinner\"></i></div\n ></ng-template>\n\n <form *ngIf=\"form; else loaderRef\" [formGroup]=\"form\" (ngSubmit)=\"save()\">\n <ul ngbNav #nav=\"ngbNav\" class=\"nav-tabs\">\n <li ngbNavItem>\n <a ngbNavLink>{{ 'AbpIdentity::UserInformations' | abpLocalization }}</a>\n <ng-template ngbNavContent>\n <abp-extensible-form [selectedRecord]=\"selected\"></abp-extensible-form>\n </ng-template>\n </li>\n\n <li ngbNavItem>\n <a ngbNavLink>{{ 'AbpIdentity::Roles' | abpLocalization }}</a>\n <ng-template ngbNavContent>\n <div\n *ngFor=\"let roleGroup of roleGroups; let i = index; trackBy: trackByFn\"\n class=\"custom-checkbox custom-control mb-2\"\n >\n <input\n type=\"checkbox\"\n class=\"custom-control-input\"\n [attr.id]=\"'roles-' + i\"\n [formControl]=\"roleGroup.controls[roles[i].name]\"\n />\n <label class=\"custom-control-label\" [attr.for]=\"'roles-' + i\">{{\n roles[i].name\n }}</label>\n </div>\n </ng-template>\n </li>\n </ul>\n\n <div class=\"mt-2 fade-in-top\" [ngbNavOutlet]=\"nav\"></div>\n </form>\n </ng-template>\n\n <ng-template #abpFooter>\n <button type=\"button\" class=\"btn btn-secondary\" abpClose>\n {{ 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <abp-button iconClass=\"fa fa-check\" [disabled]=\"form?.invalid\" (click)=\"save()\">{{\n 'AbpIdentity::Save' | abpLocalization\n }}</abp-button>\n </ng-template>\n</abp-modal>\n\n<abp-permission-management\n #abpPermissionManagement=\"abpPermissionManagement\"\n *abpReplaceableTemplate=\"\n {\n inputs: {\n providerName: { value: 'U' },\n providerKey: { value: providerKey },\n visible: { value: visiblePermissions, twoWay: true }\n },\n outputs: { visibleChange: onVisiblePermissionChange },\n componentKey: permissionManagementKey\n };\n let init = initTemplate\n \"\n (abpInit)=\"init(abpPermissionManagement)\"\n>\n</abp-permission-management>\n", components: [{ type: i4.PageToolbarComponent, selector: "abp-page-toolbar", exportAs: ["abpPageToolbar"] }, { type: i4.ExtensibleTableComponent, selector: "abp-extensible-table", inputs: ["actionsText", "data", "list", "recordsTotal", "actionsColumnWidth", "actionsTemplate"], exportAs: ["abpExtensibleTable"] }, { type: i2.ModalComponent, selector: "abp-modal", inputs: ["visible", "busy", "options", "suppressUnsavedChangesWarning"], outputs: ["visibleChange", "init", "appear", "disappear"] }, { type: i4.ExtensibleFormComponent, selector: "abp-extensible-form", inputs: ["selectedRecord"], exportAs: ["abpExtensibleForm"] }, { type: i6.NgbNavOutlet, selector: "[ngbNavOutlet]", inputs: ["paneRole", "ngbNavOutlet"] }, { type: i2.ButtonComponent, selector: "abp-button", inputs: ["buttonId", "buttonClass", "buttonType", "iconClass", "loading", "disabled", "attributes"], outputs: ["click", "focus", "blur", "abpClick", "abpFocus", "abpBlur"] }, { type: i5.PermissionManagementComponent, selector: "abp-permission-management", inputs: ["providerName", "providerKey", "hideBadges", "visible"], outputs: ["visibleChange"], exportAs: ["abpPermissionManagement"] }], directives: [{ type: i4$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i4$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i8.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i4$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i1.FormSubmitDirective, selector: "form[ngSubmit][formGroup]", inputs: ["debounce", "notValidateOnSubmit"], outputs: ["ngSubmit"] }, { type: i4$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i9.ValidationGroupDirective, selector: "[formGroup],[formGroupName]", inputs: ["blueprints", "errorTemplate", "invalidClasses", "mapErrorsFn", "skipValidation", "targetSelector", "validateOnSubmit"] }, { type: i6.NgbNav, selector: "[ngbNav]", inputs: ["destroyOnHide", "orientation", "roles", "keyboard", "activeId"], outputs: ["activeIdChange", "navChange"], exportAs: ["ngbNav"] }, { type: i6.NgbNavItem, selector: "[ngbNavItem]", inputs: ["disabled", "domId", "destroyOnHide", "ngbNavItem"], exportAs: ["ngbNavItem"] }, { type: i6.NgbNavLink, selector: "a[ngbNavLink]" }, { type: i6.NgbNavContent, selector: "ng-template[ngbNavContent]" }, { type: i8.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i4$1.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { type: i4$1.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i9.ValidationDirective, selector: "[formControl],[formControlName]", inputs: ["blueprints", "errorTemplate", "invalidClasses", "mapErrorsFn", "skipValidation", "targetSelector", "validateOnSubmit"] }, { type: i2.ModalCloseDirective, selector: "[abpClose]" }, { type: i1.ReplaceableTemplateDirective, selector: "[abpReplaceableTemplate]", inputs: ["abpReplaceableTemplate"] }, { type: i1.InitDirective, selector: "[abpInit]", outputs: ["abpInit"] }], pipes: { "abpLocalization": i1.LocalizationPipe } });
231
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: UsersComponent, decorators: [{
232
+ type: Component,
233
+ args: [{
234
+ selector: 'abp-users',
235
+ templateUrl: './users.component.html',
236
+ providers: [
237
+ ListService,
238
+ {
239
+ provide: EXTENSIONS_IDENTIFIER,
240
+ useValue: "Identity.UsersComponent" /* Users */,
241
+ },
242
+ ],
243
+ }]
244
+ }], ctorParameters: function () { return [{ type: i1.ListService }, { type: i2.ConfirmationService }, { type: i3.IdentityUserService }, { type: i4$1.FormBuilder }, { type: i0.Injector }]; }, propDecorators: { modalContent: [{
245
+ type: ViewChild,
246
+ args: ['modalContent', { static: false }]
247
+ }] } });
541
248
 
542
- const ɵ0$7 = data => {
543
- const component = data.getInjected(RolesComponent);
544
- component.edit(data.record.id);
545
- }, ɵ1$4 = data => {
546
- const component = data.getInjected(RolesComponent);
547
- component.openPermissionsModal(data.record.name);
548
- }, ɵ2$2 = data => {
549
- const component = data.getInjected(RolesComponent);
550
- component.delete(data.record.id, data.record.name);
551
- }, ɵ3$1 = data => !data.record.isStatic;
552
249
  const DEFAULT_ROLES_ENTITY_ACTIONS = EntityAction.createMany([
553
250
  {
554
251
  text: 'AbpIdentity::Edit',
555
- action: ɵ0$7,
252
+ action: data => {
253
+ const component = data.getInjected(RolesComponent);
254
+ component.edit(data.record.id);
255
+ },
556
256
  permission: 'AbpIdentity.Roles.Update',
557
257
  },
558
258
  {
559
259
  text: 'AbpIdentity::Permissions',
560
- action: ɵ1$4,
260
+ action: data => {
261
+ const component = data.getInjected(RolesComponent);
262
+ component.openPermissionsModal(data.record.name);
263
+ },
561
264
  permission: 'AbpIdentity.Roles.ManagePermissions',
562
265
  },
563
266
  {
564
267
  text: 'AbpIdentity::Delete',
565
- action: ɵ2$2,
268
+ action: data => {
269
+ const component = data.getInjected(RolesComponent);
270
+ component.delete(data.record.id, data.record.name);
271
+ },
566
272
  permission: 'AbpIdentity.Roles.Delete',
567
- visible: ɵ3$1,
273
+ visible: data => !data.record.isStatic,
568
274
  },
569
275
  ]);
570
276
 
571
- const ɵ0$6 = data => {
572
- const l10n = data.getInjected(LocalizationService);
573
- const t = l10n.instant.bind(l10n);
574
- const { isDefault, isPublic, name } = data.record;
575
- return of(name +
576
- (isDefault
577
- ? `<span class="badge badge-pill badge-success ml-1">${t('AbpIdentity::DisplayName:IsDefault')}</span>`
578
- : '') +
579
- (isPublic
580
- ? `<span class="badge badge-pill badge-info ml-1">${t('AbpIdentity::DisplayName:IsPublic')}</span>`
581
- : ''));
582
- };
583
277
  const DEFAULT_ROLES_ENTITY_PROPS = EntityProp.createMany([
584
278
  {
585
279
  type: "string" /* String */,
586
280
  name: 'name',
587
281
  displayName: 'AbpIdentity::RoleName',
588
282
  sortable: true,
589
- valueResolver: ɵ0$6,
283
+ valueResolver: data => {
284
+ const l10n = data.getInjected(LocalizationService);
285
+ const t = l10n.instant.bind(l10n);
286
+ const { isDefault, isPublic, name } = data.record;
287
+ return of(name +
288
+ (isDefault
289
+ ? `<span class="badge badge-pill badge-success ml-1">${t('AbpIdentity::DisplayName:IsDefault')}</span>`
290
+ : '') +
291
+ (isPublic
292
+ ? `<span class="badge badge-pill badge-info ml-1">${t('AbpIdentity::DisplayName:IsPublic')}</span>`
293
+ : ''));
294
+ },
590
295
  },
591
296
  ]);
592
297
 
593
- const ɵ0$5 = (data) => data.record && data.record.isStatic, ɵ1$3 = () => [Validators.required];
594
298
  const DEFAULT_ROLES_CREATE_FORM_PROPS = FormProp.createMany([
595
299
  {
596
300
  type: "string" /* String */,
597
301
  name: 'name',
598
302
  displayName: 'AbpIdentity::RoleName',
599
303
  id: 'role-name',
600
- disabled: ɵ0$5,
601
- validators: ɵ1$3,
304
+ disabled: (data) => data.record && data.record.isStatic,
305
+ validators: () => [Validators.required],
602
306
  },
603
307
  {
604
308
  type: "boolean" /* Boolean */,
@@ -617,43 +321,41 @@ const DEFAULT_ROLES_CREATE_FORM_PROPS = FormProp.createMany([
617
321
  ]);
618
322
  const DEFAULT_ROLES_EDIT_FORM_PROPS = DEFAULT_ROLES_CREATE_FORM_PROPS;
619
323
 
620
- const ɵ0$4 = data => {
621
- const component = data.getInjected(RolesComponent);
622
- component.add();
623
- };
624
324
  const DEFAULT_ROLES_TOOLBAR_ACTIONS = ToolbarAction.createMany([
625
325
  {
626
326
  text: 'AbpIdentity::NewRole',
627
- action: ɵ0$4,
327
+ action: data => {
328
+ const component = data.getInjected(RolesComponent);
329
+ component.add();
330
+ },
628
331
  permission: 'AbpIdentity.Roles.Create',
629
332
  icon: 'fa fa-plus',
630
333
  },
631
334
  ]);
632
335
 
633
- const ɵ0$3 = data => {
634
- const component = data.getInjected(UsersComponent);
635
- component.edit(data.record.id);
636
- }, ɵ1$2 = data => {
637
- const component = data.getInjected(UsersComponent);
638
- component.openPermissionsModal(data.record.id);
639
- }, ɵ2$1 = data => {
640
- const component = data.getInjected(UsersComponent);
641
- component.delete(data.record.id, data.record.name || data.record.userName);
642
- };
643
336
  const DEFAULT_USERS_ENTITY_ACTIONS = EntityAction.createMany([
644
337
  {
645
338
  text: 'AbpIdentity::Edit',
646
- action: ɵ0$3,
339
+ action: data => {
340
+ const component = data.getInjected(UsersComponent);
341
+ component.edit(data.record.id);
342
+ },
647
343
  permission: 'AbpIdentity.Users.Update',
648
344
  },
649
345
  {
650
346
  text: 'AbpIdentity::Permissions',
651
- action: ɵ1$2,
347
+ action: data => {
348
+ const component = data.getInjected(UsersComponent);
349
+ component.openPermissionsModal(data.record.id);
350
+ },
652
351
  permission: 'AbpIdentity.Users.ManagePermissions',
653
352
  },
654
353
  {
655
354
  text: 'AbpIdentity::Delete',
656
- action: ɵ2$1,
355
+ action: data => {
356
+ const component = data.getInjected(UsersComponent);
357
+ component.delete(data.record.id, data.record.name || data.record.userName);
358
+ },
657
359
  permission: 'AbpIdentity.Users.Delete',
658
360
  },
659
361
  ]);
@@ -682,14 +384,13 @@ const DEFAULT_USERS_ENTITY_PROPS = EntityProp.createMany([
682
384
  },
683
385
  ]);
684
386
 
685
- const ɵ0$2 = () => [Validators.required, Validators.maxLength(256)], ɵ1$1 = data => [Validators.required, ...getPasswordValidators({ get: data.getInjected })], ɵ2 = () => [Validators.maxLength(64)], ɵ3 = () => [Validators.maxLength(64)], ɵ4 = () => [Validators.required, Validators.maxLength(256), Validators.email], ɵ5 = () => [Validators.maxLength(16)];
686
387
  const DEFAULT_USERS_CREATE_FORM_PROPS = FormProp.createMany([
687
388
  {
688
389
  type: "string" /* String */,
689
390
  name: 'userName',
690
391
  displayName: 'AbpIdentity::UserName',
691
392
  id: 'user-name',
692
- validators: ɵ0$2,
393
+ validators: () => [Validators.required, Validators.maxLength(256)],
693
394
  },
694
395
  {
695
396
  type: "password" /* Password */,
@@ -697,35 +398,35 @@ const DEFAULT_USERS_CREATE_FORM_PROPS = FormProp.createMany([
697
398
  displayName: 'AbpIdentity::Password',
698
399
  id: 'password',
699
400
  autocomplete: 'new-password',
700
- validators: ɵ1$1,
401
+ validators: data => [Validators.required, ...getPasswordValidators({ get: data.getInjected })],
701
402
  },
702
403
  {
703
404
  type: "string" /* String */,
704
405
  name: 'name',
705
406
  displayName: 'AbpIdentity::DisplayName:Name',
706
407
  id: 'name',
707
- validators: ɵ2,
408
+ validators: () => [Validators.maxLength(64)],
708
409
  },
709
410
  {
710
411
  type: "string" /* String */,
711
412
  name: 'surname',
712
413
  displayName: 'AbpIdentity::DisplayName:Surname',
713
414
  id: 'surname',
714
- validators: ɵ3,
415
+ validators: () => [Validators.maxLength(64)],
715
416
  },
716
417
  {
717
418
  type: "email" /* Email */,
718
419
  name: 'email',
719
420
  displayName: 'AbpIdentity::EmailAddress',
720
421
  id: 'email',
721
- validators: ɵ4,
422
+ validators: () => [Validators.required, Validators.maxLength(256), Validators.email],
722
423
  },
723
424
  {
724
425
  type: "string" /* String */,
725
426
  name: 'phoneNumber',
726
427
  displayName: 'AbpIdentity::PhoneNumber',
727
428
  id: 'phone-number',
728
- validators: ɵ5,
429
+ validators: () => [Validators.maxLength(16)],
729
430
  },
730
431
  {
731
432
  type: "boolean" /* Boolean */,
@@ -735,17 +436,15 @@ const DEFAULT_USERS_CREATE_FORM_PROPS = FormProp.createMany([
735
436
  defaultValue: true,
736
437
  },
737
438
  ]);
738
- const ɵ6 = prop => prop.name !== 'password';
739
- const DEFAULT_USERS_EDIT_FORM_PROPS = DEFAULT_USERS_CREATE_FORM_PROPS.filter(ɵ6);
439
+ const DEFAULT_USERS_EDIT_FORM_PROPS = DEFAULT_USERS_CREATE_FORM_PROPS.filter(prop => prop.name !== 'password');
740
440
 
741
- const ɵ0$1 = data => {
742
- const component = data.getInjected(UsersComponent);
743
- component.add();
744
- };
745
441
  const DEFAULT_USERS_TOOLBAR_ACTIONS = ToolbarAction.createMany([
746
442
  {
747
443
  text: 'AbpIdentity::NewUser',
748
- action: ɵ0$1,
444
+ action: data => {
445
+ const component = data.getInjected(UsersComponent);
446
+ component.add();
447
+ },
749
448
  permission: 'AbpIdentity.Users.Create',
750
449
  icon: 'fa fa-plus',
751
450
  },
@@ -801,26 +500,12 @@ class IdentityExtensionsGuard {
801
500
  }), mapTo(true));
802
501
  }
803
502
  }
804
- IdentityExtensionsGuard.decorators = [
805
- { type: Injectable }
806
- ];
807
- IdentityExtensionsGuard.ctorParameters = () => [
808
- { type: Injector }
809
- ];
503
+ IdentityExtensionsGuard.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityExtensionsGuard, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Injectable });
504
+ IdentityExtensionsGuard.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityExtensionsGuard });
505
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityExtensionsGuard, decorators: [{
506
+ type: Injectable
507
+ }], ctorParameters: function () { return [{ type: i0.Injector }]; } });
810
508
 
811
- const ɵ0 = {
812
- requiredPolicy: 'AbpIdentity.Roles',
813
- replaceableComponent: {
814
- key: "Identity.RolesComponent" /* Roles */,
815
- defaultComponent: RolesComponent,
816
- },
817
- }, ɵ1 = {
818
- requiredPolicy: 'AbpIdentity.Users',
819
- replaceableComponent: {
820
- key: "Identity.UsersComponent" /* Users */,
821
- defaultComponent: UsersComponent,
822
- },
823
- };
824
509
  const routes = [
825
510
  { path: '', redirectTo: 'roles', pathMatch: 'full' },
826
511
  {
@@ -831,24 +516,40 @@ const routes = [
831
516
  {
832
517
  path: 'roles',
833
518
  component: ReplaceableRouteContainerComponent,
834
- data: ɵ0,
519
+ data: {
520
+ requiredPolicy: 'AbpIdentity.Roles',
521
+ replaceableComponent: {
522
+ key: "Identity.RolesComponent" /* Roles */,
523
+ defaultComponent: RolesComponent,
524
+ },
525
+ },
835
526
  },
836
527
  {
837
528
  path: 'users',
838
529
  component: ReplaceableRouteContainerComponent,
839
- data: ɵ1,
530
+ data: {
531
+ requiredPolicy: 'AbpIdentity.Users',
532
+ replaceableComponent: {
533
+ key: "Identity.UsersComponent" /* Users */,
534
+ defaultComponent: UsersComponent,
535
+ },
536
+ },
840
537
  },
841
538
  ],
842
539
  },
843
540
  ];
844
541
  class IdentityRoutingModule {
845
542
  }
846
- IdentityRoutingModule.decorators = [
847
- { type: NgModule, args: [{
848
- imports: [RouterModule.forChild(routes)],
849
- exports: [RouterModule],
850
- },] }
851
- ];
543
+ IdentityRoutingModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityRoutingModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
544
+ IdentityRoutingModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityRoutingModule, imports: [i1$1.RouterModule], exports: [RouterModule] });
545
+ IdentityRoutingModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityRoutingModule, imports: [[RouterModule.forChild(routes)], RouterModule] });
546
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityRoutingModule, decorators: [{
547
+ type: NgModule,
548
+ args: [{
549
+ imports: [RouterModule.forChild(routes)],
550
+ exports: [RouterModule],
551
+ }]
552
+ }] });
852
553
 
853
554
  class IdentityModule {
854
555
  static forChild(options = {}) {
@@ -883,151 +584,46 @@ class IdentityModule {
883
584
  return new LazyModuleFactory(IdentityModule.forChild(options));
884
585
  }
885
586
  }
886
- IdentityModule.decorators = [
887
- { type: NgModule, args: [{
888
- declarations: [RolesComponent, UsersComponent],
889
- exports: [RolesComponent, UsersComponent],
890
- imports: [
891
- NgxsModule.forFeature([IdentityState]),
892
- CoreModule,
893
- IdentityRoutingModule,
894
- NgbNavModule,
895
- ThemeSharedModule,
896
- UiExtensionsModule,
897
- NgbDropdownModule,
898
- PermissionManagementModule,
899
- NgxValidateCoreModule,
900
- ],
901
- },] }
902
- ];
903
-
904
- class IdentityUserLookupService {
905
- constructor(restService) {
906
- this.restService = restService;
907
- this.apiName = 'AbpIdentity';
908
- this.findById = (id) => this.restService.request({
909
- method: 'GET',
910
- url: `/api/identity/users/lookup/${id}`,
911
- }, { apiName: this.apiName });
912
- this.findByUserName = (userName) => this.restService.request({
913
- method: 'GET',
914
- url: `/api/identity/users/lookup/by-username/${userName}`,
915
- }, { apiName: this.apiName });
916
- this.getCount = (input) => this.restService.request({
917
- method: 'GET',
918
- url: '/api/identity/users/lookup/count',
919
- params: { filter: input.filter },
920
- }, { apiName: this.apiName });
921
- this.search = (input) => this.restService.request({
922
- method: 'GET',
923
- url: '/api/identity/users/lookup/search',
924
- params: { filter: input.filter, sorting: input.sorting, skipCount: input.skipCount, maxResultCount: input.maxResultCount },
925
- }, { apiName: this.apiName });
926
- }
927
- }
928
- IdentityUserLookupService.ɵprov = i0.ɵɵdefineInjectable({ factory: function IdentityUserLookupService_Factory() { return new IdentityUserLookupService(i0.ɵɵinject(i1.RestService)); }, token: IdentityUserLookupService, providedIn: "root" });
929
- IdentityUserLookupService.decorators = [
930
- { type: Injectable, args: [{
931
- providedIn: 'root',
932
- },] }
933
- ];
934
- IdentityUserLookupService.ctorParameters = () => [
935
- { type: RestService }
936
- ];
937
-
938
- class ProfileService {
939
- constructor(restService) {
940
- this.restService = restService;
941
- this.apiName = 'AbpIdentity';
942
- this.changePassword = (input) => this.restService.request({
943
- method: 'POST',
944
- url: '/api/identity/my-profile/change-password',
945
- body: input,
946
- }, { apiName: this.apiName });
947
- this.get = () => this.restService.request({
948
- method: 'GET',
949
- url: '/api/identity/my-profile',
950
- }, { apiName: this.apiName });
951
- this.update = (input) => this.restService.request({
952
- method: 'PUT',
953
- url: '/api/identity/my-profile',
954
- body: input,
955
- }, { apiName: this.apiName });
956
- }
957
- }
958
- ProfileService.ɵprov = i0.ɵɵdefineInjectable({ factory: function ProfileService_Factory() { return new ProfileService(i0.ɵɵinject(i1.RestService)); }, token: ProfileService, providedIn: "root" });
959
- ProfileService.decorators = [
960
- { type: Injectable, args: [{
961
- providedIn: 'root',
962
- },] }
963
- ];
964
- ProfileService.ctorParameters = () => [
965
- { type: RestService }
966
- ];
967
-
968
- class IdentityStateService {
969
- constructor(store) {
970
- this.store = store;
971
- }
972
- getRoles() {
973
- return this.store.selectSnapshot(IdentityState.getRoles);
974
- }
975
- getRolesTotalCount() {
976
- return this.store.selectSnapshot(IdentityState.getRolesTotalCount);
977
- }
978
- getUsers() {
979
- return this.store.selectSnapshot(IdentityState.getUsers);
980
- }
981
- getUsersTotalCount() {
982
- return this.store.selectSnapshot(IdentityState.getUsersTotalCount);
983
- }
984
- dispatchGetRoles(...args) {
985
- return this.store.dispatch(new GetRoles(...args));
986
- }
987
- dispatchGetRoleById(...args) {
988
- return this.store.dispatch(new GetRoleById(...args));
989
- }
990
- dispatchDeleteRole(...args) {
991
- return this.store.dispatch(new DeleteRole(...args));
992
- }
993
- dispatchCreateRole(...args) {
994
- return this.store.dispatch(new CreateRole(...args));
995
- }
996
- dispatchUpdateRole(...args) {
997
- return this.store.dispatch(new UpdateRole(...args));
998
- }
999
- dispatchGetUsers(...args) {
1000
- return this.store.dispatch(new GetUsers(...args));
1001
- }
1002
- dispatchGetUserById(...args) {
1003
- return this.store.dispatch(new GetUserById(...args));
1004
- }
1005
- dispatchDeleteUser(...args) {
1006
- return this.store.dispatch(new DeleteUser(...args));
1007
- }
1008
- dispatchCreateUser(...args) {
1009
- return this.store.dispatch(new CreateUser(...args));
1010
- }
1011
- dispatchUpdateUser(...args) {
1012
- return this.store.dispatch(new UpdateUser(...args));
1013
- }
1014
- dispatchGetUserRoles(...args) {
1015
- return this.store.dispatch(new GetUserRoles(...args));
1016
- }
1017
- }
1018
- IdentityStateService.ɵprov = i0.ɵɵdefineInjectable({ factory: function IdentityStateService_Factory() { return new IdentityStateService(i0.ɵɵinject(i1$1.Store)); }, token: IdentityStateService, providedIn: "root" });
1019
- IdentityStateService.decorators = [
1020
- { type: Injectable, args: [{
1021
- providedIn: 'root',
1022
- },] }
1023
- ];
1024
- IdentityStateService.ctorParameters = () => [
1025
- { type: Store }
1026
- ];
587
+ IdentityModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
588
+ IdentityModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityModule, declarations: [RolesComponent, UsersComponent], imports: [CoreModule,
589
+ IdentityRoutingModule,
590
+ NgbNavModule,
591
+ ThemeSharedModule,
592
+ UiExtensionsModule,
593
+ NgbDropdownModule,
594
+ PermissionManagementModule,
595
+ NgxValidateCoreModule], exports: [RolesComponent, UsersComponent] });
596
+ IdentityModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityModule, imports: [[
597
+ CoreModule,
598
+ IdentityRoutingModule,
599
+ NgbNavModule,
600
+ ThemeSharedModule,
601
+ UiExtensionsModule,
602
+ NgbDropdownModule,
603
+ PermissionManagementModule,
604
+ NgxValidateCoreModule,
605
+ ]] });
606
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.6", ngImport: i0, type: IdentityModule, decorators: [{
607
+ type: NgModule,
608
+ args: [{
609
+ declarations: [RolesComponent, UsersComponent],
610
+ exports: [RolesComponent, UsersComponent],
611
+ imports: [
612
+ CoreModule,
613
+ IdentityRoutingModule,
614
+ NgbNavModule,
615
+ ThemeSharedModule,
616
+ UiExtensionsModule,
617
+ NgbDropdownModule,
618
+ PermissionManagementModule,
619
+ NgxValidateCoreModule,
620
+ ],
621
+ }]
622
+ }] });
1027
623
 
1028
624
  /**
1029
625
  * Generated bundle index. Do not edit.
1030
626
  */
1031
627
 
1032
- export { CreateRole, CreateUser, DEFAULT_IDENTITY_CREATE_FORM_PROPS, DEFAULT_IDENTITY_EDIT_FORM_PROPS, DEFAULT_IDENTITY_ENTITY_ACTIONS, DEFAULT_IDENTITY_ENTITY_PROPS, DEFAULT_IDENTITY_TOOLBAR_ACTIONS, DeleteRole, DeleteUser, GetRoleById, GetRoles, GetUserById, GetUserRoles, GetUsers, IDENTITY_CREATE_FORM_PROP_CONTRIBUTORS, IDENTITY_EDIT_FORM_PROP_CONTRIBUTORS, IDENTITY_ENTITY_ACTION_CONTRIBUTORS, IDENTITY_ENTITY_PROP_CONTRIBUTORS, IDENTITY_TOOLBAR_ACTION_CONTRIBUTORS, IdentityExtensionsGuard, IdentityModule, IdentityRoleService, IdentityState, IdentityStateService, IdentityUserLookupService, IdentityUserService, ProfileService, RolesComponent, UpdateRole, UpdateUser, UsersComponent, RolesComponent as ɵa, IDENTITY_EDIT_FORM_PROP_CONTRIBUTORS as ɵba, IdentityState as ɵc, IdentityUserService as ɵd, IdentityRoleService as ɵe, GetRoles as ɵf, GetRoleById as ɵg, DeleteRole as ɵh, CreateRole as ɵi, UpdateRole as ɵj, GetUsers as ɵk, GetUserById as ɵl, DeleteUser as ɵm, CreateUser as ɵn, UpdateUser as ɵo, GetUserRoles as ɵp, UsersComponent as ɵt, IdentityRoutingModule as ɵu, IdentityExtensionsGuard as ɵv, IDENTITY_ENTITY_ACTION_CONTRIBUTORS as ɵw, IDENTITY_TOOLBAR_ACTION_CONTRIBUTORS as ɵx, IDENTITY_ENTITY_PROP_CONTRIBUTORS as ɵy, IDENTITY_CREATE_FORM_PROP_CONTRIBUTORS as ɵz };
628
+ export { DEFAULT_IDENTITY_CREATE_FORM_PROPS, DEFAULT_IDENTITY_EDIT_FORM_PROPS, DEFAULT_IDENTITY_ENTITY_ACTIONS, DEFAULT_IDENTITY_ENTITY_PROPS, DEFAULT_IDENTITY_TOOLBAR_ACTIONS, IDENTITY_CREATE_FORM_PROP_CONTRIBUTORS, IDENTITY_EDIT_FORM_PROP_CONTRIBUTORS, IDENTITY_ENTITY_ACTION_CONTRIBUTORS, IDENTITY_ENTITY_PROP_CONTRIBUTORS, IDENTITY_TOOLBAR_ACTION_CONTRIBUTORS, IdentityExtensionsGuard, IdentityModule, RolesComponent, UsersComponent };
1033
629
  //# sourceMappingURL=abp-ng.identity.js.map