@openziti/ziti-console-lib 0.9.2 → 0.9.3

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.
@@ -20645,6 +20645,15 @@ class TerminatorsPageService extends ListPageServiceClass {
20645
20645
  super(settings, filterService, csvDownloadService, extService, router);
20646
20646
  this.schemaSvc = schemaSvc;
20647
20647
  this.router = router;
20648
+ this.DEFAULT_PAGING = {
20649
+ filter: "",
20650
+ noSearch: false,
20651
+ order: "asc",
20652
+ page: 1,
20653
+ searchOn: "address",
20654
+ sort: "address",
20655
+ total: 50
20656
+ };
20648
20657
  this.paging = this.DEFAULT_PAGING;
20649
20658
  this.resourceType = 'terminators';
20650
20659
  this.selectedConfig = {};
@@ -20747,8 +20756,9 @@ class TerminatorsPageService extends ListPageServiceClass {
20747
20756
  ];
20748
20757
  }
20749
20758
  getData(filters, sort) {
20750
- sort.sortBy = 'address';
20751
- // we can customize filters or sorting here before moving on...
20759
+ if (sort.sortBy === 'name') {
20760
+ sort.sortBy = 'address';
20761
+ }
20752
20762
  return super.getTableData('terminators', this.paging, filters, sort)
20753
20763
  .then((results) => {
20754
20764
  return this.processData(results);
@@ -21791,7 +21801,7 @@ class JwtSignerFormComponent extends ProjectableForm {
21791
21801
  return isEmpty(this.errors);
21792
21802
  }
21793
21803
  get showTokenType() {
21794
- return !isEmpty(this.settingsService?.zitiSemver) && semver.gte(this.settingsService?.zitiSemver, '1.3.4');
21804
+ return !isEmpty(this.settingsService?.zitiSemver) && semver.gte(this.settingsService?.zitiSemver, '1.4.0');
21795
21805
  }
21796
21806
  get targetToken() {
21797
21807
  if (this.formData && !this.formData.targetToken) {
@@ -24778,7 +24788,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "16.2.12", ngImpo
24778
24788
  }] });
24779
24789
 
24780
24790
  const VERSION = {
24781
- "version": "3.9.1"
24791
+ "version": "3.9.2"
24782
24792
  };
24783
24793
 
24784
24794
  /*
@@ -25227,11 +25237,34 @@ class ZacWrapperService extends ZacWrapperServiceClass {
25227
25237
  this.handleServiceResult(data, returnTo);
25228
25238
  });
25229
25239
  break;
25240
+ case 'reset':
25241
+ this.resetIdentityPassword(params, returnTo);
25242
+ break;
25230
25243
  case 'tags':
25231
25244
  // For no this is a no-op
25232
25245
  break;
25233
25246
  }
25234
25247
  }
25248
+ resetIdentityPassword(params, returnTo) {
25249
+ const controllerDomain = this.settingsService?.settings?.selectedEdgeController || '';
25250
+ this.callZitiEdge(`${controllerDomain}/edge/management/v1/current-identity/authenticators?filter=method="updb"`, { rejectUnauthorized: false }, 'GET', 'application/json').then((identResp) => {
25251
+ const ident = identResp.data[0];
25252
+ var id = ident.id;
25253
+ var body = {
25254
+ currentPassword: params.password,
25255
+ password: params.newpassword,
25256
+ username: ident.username
25257
+ };
25258
+ this.callZitiEdge(`${controllerDomain}/edge/management/v1/current-identity/authenticators/${id}`, body, 'PATCH', 'application/json').then((authResp) => {
25259
+ if (authResp.error) {
25260
+ returnTo({ error: "Failed to update password" });
25261
+ }
25262
+ else {
25263
+ returnTo({ success: "Password Updated" });
25264
+ }
25265
+ });
25266
+ });
25267
+ }
25235
25268
  handleServiceResult(result, returnTo) {
25236
25269
  if (result?.error) {
25237
25270
  result = this.handleError(result);