@genesislcap/foundation-entity-management 14.150.1 → 14.151.0

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.
@@ -69,10 +69,6 @@ declare const EntityManagement_base: (new (...args: any[]) => {
69
69
  readonly attributes: NamedNodeMap;
70
70
  readonly classList: DOMTokenList;
71
71
  className: string;
72
- /**
73
- * The name of the resource in the backend to interact with when dispatching actions from the update/create modal
74
- * @internal
75
- */
76
72
  readonly clientHeight: number;
77
73
  readonly clientLeft: number;
78
74
  readonly clientTop: number;
@@ -534,6 +530,10 @@ export declare class EntityManagement extends EntityManagement_base {
534
530
  enableFilterBar: boolean;
535
531
  hideEdit: boolean;
536
532
  hideDelete: boolean;
533
+ /**
534
+ * This attribute controls whether to enable the search-bar.
535
+ * @public
536
+ */
537
537
  enableSearchBar: boolean;
538
538
  /**
539
539
  * The case type to use for the header names. If not set, the default CONSTANT_CASE will be used.
@@ -552,6 +552,11 @@ export declare class EntityManagement extends EntityManagement_base {
552
552
  * @internal
553
553
  */
554
554
  connectedCallback(): Promise<void>;
555
+ /**
556
+ * Gets the default searchBarConfig if the user has not created their own.
557
+ * @internal
558
+ */
559
+ private getDefaultSearchBarConfig;
555
560
  /**
556
561
  * Override the deepClone method to ensure that observable attributes are cloned
557
562
  * @public
@@ -1 +1 @@
1
- {"version":3,"file":"entities.d.ts","sourceRoot":"","sources":["../../../src/entities/entities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EAAE,OAAO,EAAE,iBAAiB,EAAE,MAAM,+BAA+B,CAAC;AAC3E,OAAO,EAAa,aAAa,EAAE,MAAM,+BAA+B,CAAC;AAEzE,OAAO,EAAE,eAAe,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAE7E,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAC7D,OAAO,EAAuB,WAAW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,CAAC,OAAO,KAAA;CAkB3B"}
@@ -84,6 +84,10 @@ declare const Users_base: (new (...args: any[]) => {
84
84
  outerHTML: string;
85
85
  readonly ownerDocument: Document;
86
86
  readonly part: DOMTokenList;
87
+ /**
88
+ * entityID used to control the definition of an optional entity column which is created with the {@link Users.entityColumn} function.
89
+ * @internal
90
+ */
87
91
  readonly prefix: string;
88
92
  readonly scrollHeight: number;
89
93
  scrollLeft: number;
@@ -123,6 +127,10 @@ declare const Users_base: (new (...args: any[]) => {
123
127
  removeAttributeNS(namespace: string, localName: string): void;
124
128
  removeAttributeNode(attr: Attr): Attr;
125
129
  requestFullscreen(options?: FullscreenOptions): Promise<void>;
130
+ /**
131
+ * Used as the callback function in {@link Users.statusColumn}
132
+ * @internal
133
+ */
126
134
  requestPointerLock(): void;
127
135
  scroll(options?: ScrollToOptions): void;
128
136
  scroll(x: number, y: number): void;
@@ -442,6 +450,11 @@ export declare class Users extends Users_base {
442
450
  * @public
443
451
  */
444
452
  persistColumnStateKey: string;
453
+ /**
454
+ * This attribute controls whether to enable the search-bar.
455
+ * @public
456
+ */
457
+ enableSearchBar: boolean;
445
458
  /**
446
459
  * GridOptions to be passed down from application
447
460
  * @public
@@ -1 +1 @@
1
- {"version":3,"file":"users.d.ts","sourceRoot":"","sources":["../../../src/users/users.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAItD,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAC7E,OAAO,EAA4B,WAAW,EAAc,MAAM,yBAAyB,CAAC;AAC5F,OAAO,EAAE,uBAAuB,EAAE,MAAM,aAAa,CAAC;AAWtD;;;;;;;GAOG;AACH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;IAoC7B,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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uBAAuB,CAAC;IAEtD;;;OAGG;IACG,YAAY,SAAe;IAEjC;;;;;;;;;OASG;IAC8C,qBAAqB,EAAE,MAAM,CAClD;IAE5B;;;OAGG;IACwD,eAAe,EAAE,OAAO,CAAS;IAE5F;;;OAGG;IACS,WAAW,EAAE,WAAW,CAAC;IAErC;;;;;OAKG;IACI,YAAY;;;;;;;;;;;;IAYnB;;;;;OAKG;IACI,YAAY;;;;;;;;IAYnB;;OAEG;IACS,OAAO,EAAE,GAAG,CAAqB;IAEjC,sBAAsB,EAAE,GAAG,CAAM;IACjC,sBAAsB,EAAE,GAAG,CAAM;IAEjC,aAAa,EAAE,OAAO,CAAC;IACnC,OAAO,CAAC,aAAa,CAAS;IAE9B;;OAEG;IACS,WAAW,EAAE,MAAM,CAAC;IAEhC;;OAEG;IACS,WAAW,EAAE,MAAM,CAAC;IAEhC;;OAEG;IACS,WAAW,EAAE,MAAM,CAAC;IAEhC;;;OAGG;IACG,QAAQ,EAAE,MAAM,CAAqB;IAE3C;;;OAGG;IACG,cAAc,EAAE,MAAM,CAAU;IAEtC;;;OAGG;IACG,WAAW,EAAE,MAAM,CAAkB;IAE3C;;;OAGG;IACG,yBAAyB,EAAE,MAAM,CAAuB;IAE9D;;OAEG;;IAaG,iBAAiB;IAcd,SAAS,IAAI,IAAI;IAe1B;;;OAGG;IACH,sBAAsB,CAAC,MAAM,KAAA;;;;;;;;IAW7B;;;;;;;;OAQG;IACG,YAAY,CAAC,MAAM,KAAA;IAoCzB;;OAEG;IACG,YAAY,CAAC,IAAI,KAAA;;;;;;;;;;;;;;;CAwBxB"}
@@ -2,6 +2,7 @@ import { __awaiter, __decorate, __rest } from "tslib";
2
2
  import { Connect } from '@genesislcap/foundation-comms';
3
3
  import { renderers } from '@genesislcap/foundation-forms';
4
4
  import { showNotification, showNotificationDialog } from '@genesislcap/foundation-notifications';
5
+ import { getCriteriaBuilder, INPUT_MIN_LENGTH, } from '@genesislcap/foundation-ui';
5
6
  import { LifecycleMixin } from '@genesislcap/foundation-utils';
6
7
  import { attr, customElement, FASTElement, observable, volatile } from '@microsoft/fast-element';
7
8
  import { getErrorFormat, logger } from '../utils';
@@ -83,6 +84,10 @@ let EntityManagement = class EntityManagement extends LifecycleMixin(FASTElement
83
84
  this.editModalVisible = false;
84
85
  this.hideEdit = false;
85
86
  this.hideDelete = false;
87
+ /**
88
+ * This attribute controls whether to enable the search-bar.
89
+ * @public
90
+ */
86
91
  this.enableSearchBar = false;
87
92
  /**
88
93
  * Determines where the modal dialog will appear on screen
@@ -128,6 +133,33 @@ let EntityManagement = class EntityManagement extends LifecycleMixin(FASTElement
128
133
  this.addEventListener('read-entity', this.readEntity);
129
134
  this.addEventListener('criteria-changed', this.criteriaChanged);
130
135
  this.addEventListener('submit-failure', this.submitFailureNotification);
136
+ if (!this.searchBarConfig) {
137
+ this.getDefaultSearchBarConfig();
138
+ }
139
+ });
140
+ }
141
+ /**
142
+ * Gets the default searchBarConfig if the user has not created their own.
143
+ * @internal
144
+ */
145
+ getDefaultSearchBarConfig() {
146
+ var _a;
147
+ return __awaiter(this, void 0, void 0, function* () {
148
+ const meta = yield this.connect
149
+ .getMetadata(this.resourceName)
150
+ .catch((e) => logger.error(`Metadata Fetch failed for ${this.resourceName}:`, e));
151
+ if (!meta) {
152
+ return;
153
+ }
154
+ this.searchBarConfig = (_a = meta.FIELD) === null || _a === void 0 ? void 0 : _a.map((field) => ({
155
+ field: field.NAME,
156
+ label: (searchTerm) => `${searchTerm} as ${field.NAME}`,
157
+ createCriteria: getCriteriaBuilder,
158
+ isEnabled: (searchTerm, selectedOption) => {
159
+ return (searchTerm.length >= INPUT_MIN_LENGTH &&
160
+ !selectedOption.some((e) => e.field === field.NAME));
161
+ },
162
+ }));
131
163
  });
132
164
  }
133
165
  /**
@@ -116,6 +116,11 @@ let Users = class Users extends LifecycleMixin(FASTElement) {
116
116
  * @public
117
117
  */
118
118
  this.persistColumnStateKey = 'entity_users_management';
119
+ /**
120
+ * This attribute controls whether to enable the search-bar.
121
+ * @public
122
+ */
123
+ this.enableSearchBar = false;
119
124
  /**
120
125
  * Column definition, default to the UsersColumnConfig
121
126
  */
@@ -267,6 +272,9 @@ __decorate([
267
272
  __decorate([
268
273
  attr({ attribute: 'persist-column-state-key' })
269
274
  ], Users.prototype, "persistColumnStateKey", void 0);
275
+ __decorate([
276
+ attr({ mode: 'boolean', attribute: 'enable-search-bar' })
277
+ ], Users.prototype, "enableSearchBar", void 0);
270
278
  __decorate([
271
279
  observable
272
280
  ], Users.prototype, "gridOptions", void 0);
@@ -75,12 +75,12 @@ export const UsersTemplate = html `
75
75
  resourceName=${(x) => x.resourceName}
76
76
  title="User Management"
77
77
  :gridOptions=${(x) => x.gridOptions}
78
- entityLabel="User"
79
78
  createEvent="${(x) => x.createEvent}"
80
79
  :readEventFn=${(x) => (user) => x.readUserData(user)}
81
80
  updateEvent="${(x) => x.updateEvent}"
82
81
  deleteEvent="${(x) => x.deleteEvent}"
83
82
  entityLabel="User Details"
83
+ enable-search-bar="${(x) => x.enableSearchBar}"
84
84
  :updateFormUiSchema=${(x) => editUserSchema(true, x.allAccessType, x.entityID, x.entityLabel, x.entityLabelKey, x.availableEntitiesEndpoint, x.additionalUpdateFields)}
85
85
  :createFormUiSchema=${(x) => editUserSchema(false, x.allAccessType, x.entityID, x.entityLabel, x.entityLabelKey, x.availableEntitiesEndpoint, x.additionalCreateFields)}
86
86
  persist-column-state-key=${(x) => x.persistColumnStateKey}
@@ -968,7 +968,7 @@
968
968
  {
969
969
  "kind": "Property",
970
970
  "canonicalReference": "@genesislcap/foundation-entity-management!EntityManagement#enableSearchBar:member",
971
- "docComment": "",
971
+ "docComment": "/**\n * This attribute controls whether to enable the search-bar.\n *\n * @public\n */\n",
972
972
  "excerptTokens": [
973
973
  {
974
974
  "kind": "Content",
@@ -2704,6 +2704,36 @@
2704
2704
  "isProtected": false,
2705
2705
  "isAbstract": false
2706
2706
  },
2707
+ {
2708
+ "kind": "Property",
2709
+ "canonicalReference": "@genesislcap/foundation-entity-management!Users#enableSearchBar:member",
2710
+ "docComment": "/**\n * This attribute controls whether to enable the search-bar.\n *\n * @public\n */\n",
2711
+ "excerptTokens": [
2712
+ {
2713
+ "kind": "Content",
2714
+ "text": "enableSearchBar: "
2715
+ },
2716
+ {
2717
+ "kind": "Content",
2718
+ "text": "boolean"
2719
+ },
2720
+ {
2721
+ "kind": "Content",
2722
+ "text": ";"
2723
+ }
2724
+ ],
2725
+ "isReadonly": false,
2726
+ "isOptional": false,
2727
+ "releaseTag": "Public",
2728
+ "name": "enableSearchBar",
2729
+ "propertyTypeTokenRange": {
2730
+ "startIndex": 1,
2731
+ "endIndex": 2
2732
+ },
2733
+ "isStatic": false,
2734
+ "isProtected": false,
2735
+ "isAbstract": false
2736
+ },
2707
2737
  {
2708
2738
  "kind": "Property",
2709
2739
  "canonicalReference": "@genesislcap/foundation-entity-management!Users#gridOptions:member",
@@ -228,6 +228,10 @@ export declare class EntityManagement extends EntityManagement_base {
228
228
  enableFilterBar: boolean;
229
229
  hideEdit: boolean;
230
230
  hideDelete: boolean;
231
+ /**
232
+ * This attribute controls whether to enable the search-bar.
233
+ * @public
234
+ */
231
235
  enableSearchBar: boolean;
232
236
  /**
233
237
  * The case type to use for the header names. If not set, the default CONSTANT_CASE will be used.
@@ -246,6 +250,11 @@ export declare class EntityManagement extends EntityManagement_base {
246
250
  * @internal
247
251
  */
248
252
  connectedCallback(): Promise<void>;
253
+ /**
254
+ * Gets the default searchBarConfig if the user has not created their own.
255
+ * @internal
256
+ */
257
+ private getDefaultSearchBarConfig;
249
258
  /**
250
259
  * Override the deepClone method to ensure that observable attributes are cloned
251
260
  * @public
@@ -346,10 +355,6 @@ declare const EntityManagement_base: (new (...args: any[]) => {
346
355
  readonly attributes: NamedNodeMap;
347
356
  readonly classList: DOMTokenList;
348
357
  className: string;
349
- /**
350
- * The name of the resource in the backend to interact with when dispatching actions from the update/create modal
351
- * @internal
352
- */
353
358
  readonly clientHeight: number;
354
359
  readonly clientLeft: number;
355
360
  readonly clientTop: number;
@@ -828,6 +833,11 @@ export declare class Users extends Users_base {
828
833
  * @public
829
834
  */
830
835
  persistColumnStateKey: string;
836
+ /**
837
+ * This attribute controls whether to enable the search-bar.
838
+ * @public
839
+ */
840
+ enableSearchBar: boolean;
831
841
  /**
832
842
  * GridOptions to be passed down from application
833
843
  * @public
@@ -1009,6 +1019,10 @@ declare const Users_base: (new (...args: any[]) => {
1009
1019
  outerHTML: string;
1010
1020
  readonly ownerDocument: Document;
1011
1021
  readonly part: DOMTokenList;
1022
+ /**
1023
+ * entityID used to control the definition of an optional entity column which is created with the {@link Users.entityColumn} function.
1024
+ * @internal
1025
+ */
1012
1026
  readonly prefix: string;
1013
1027
  readonly scrollHeight: number;
1014
1028
  scrollLeft: number;
@@ -1048,6 +1062,10 @@ declare const Users_base: (new (...args: any[]) => {
1048
1062
  removeAttributeNS(namespace: string, localName: string): void;
1049
1063
  removeAttributeNode(attr: Attr): Attr;
1050
1064
  requestFullscreen(options?: FullscreenOptions): Promise<void>;
1065
+ /**
1066
+ * Used as the callback function in {@link Users.statusColumn}
1067
+ * @internal
1068
+ */
1051
1069
  requestPointerLock(): void;
1052
1070
  scroll(options?: ScrollToOptions): void;
1053
1071
  scroll(x: number, y: number): void;
@@ -4,6 +4,8 @@
4
4
 
5
5
  ## EntityManagement.enableSearchBar property
6
6
 
7
+ This attribute controls whether to enable the search-bar.
8
+
7
9
  **Signature:**
8
10
 
9
11
  ```typescript
@@ -53,7 +53,7 @@ Where:<br /> - the title of the grid is `Counterparty Management`<br /> - the na
53
53
  | [enableCellFlashing](./foundation-entity-management.entitymanagement.enablecellflashing.md) | | boolean | If false, will disable cell flashing for all cells by default, unless otherwise defined in custom colDef |
54
54
  | [enableFilterBar](./foundation-entity-management.entitymanagement.enablefilterbar.md) | | boolean | |
55
55
  | [enableRowFlashing](./foundation-entity-management.entitymanagement.enablerowflashing.md) | | boolean | If true, will enable row flashing for all rows for <code>add</code> transactions |
56
- | [enableSearchBar](./foundation-entity-management.entitymanagement.enablesearchbar.md) | | boolean | |
56
+ | [enableSearchBar](./foundation-entity-management.entitymanagement.enablesearchbar.md) | | boolean | This attribute controls whether to enable the search-bar. |
57
57
  | [entityLabel](./foundation-entity-management.entitymanagement.entitylabel.md) | | string | Label for the entity which has usages such as being shown in the title of the modal wen editing the entity |
58
58
  | [formRenderers](./foundation-entity-management.entitymanagement.formrenderers.md) | | RendererEntry\[\] | Array with renderers used by foundation-forms |
59
59
  | [formUiSchema](./foundation-entity-management.entitymanagement.formuischema.md) | | any | |
@@ -0,0 +1,13 @@
1
+ <!-- Do not edit this file. It is automatically generated by API Documenter. -->
2
+
3
+ [Home](./index.md) &gt; [@genesislcap/foundation-entity-management](./foundation-entity-management.md) &gt; [Users](./foundation-entity-management.users.md) &gt; [enableSearchBar](./foundation-entity-management.users.enablesearchbar.md)
4
+
5
+ ## Users.enableSearchBar property
6
+
7
+ This attribute controls whether to enable the search-bar.
8
+
9
+ **Signature:**
10
+
11
+ ```typescript
12
+ enableSearchBar: boolean;
13
+ ```
@@ -58,6 +58,7 @@ const userColumns = [
58
58
  | [columns](./foundation-entity-management.users.columns.md) | | any | Column definition, default to the UsersColumnConfig |
59
59
  | [createEvent](./foundation-entity-management.users.createevent.md) | | string | String which contains event if we have permission to insert user of empty string if not |
60
60
  | [deleteEvent](./foundation-entity-management.users.deleteevent.md) | | string | String which contains event if we have permission to delete user of empty string if not |
61
+ | [enableSearchBar](./foundation-entity-management.users.enablesearchbar.md) | | boolean | This attribute controls whether to enable the search-bar. |
61
62
  | [gridOptions](./foundation-entity-management.users.gridoptions.md) | | GridOptions | GridOptions to be passed down from application |
62
63
  | [persistColumnStateKey](./foundation-entity-management.users.persistcolumnstatekey.md) | | string | This attribute controls whether and how the user manager stores the state of the columns when the user edits them. Defaulted to <code>entity_users_management</code>. |
63
64
  | [updateEvent](./foundation-entity-management.users.updateevent.md) | | string | String which contains event if we have permission to update user of empty string if not |
@@ -80,7 +80,6 @@ export class EntityManagement extends EntityManagement_base {
80
80
  // (undocumented)
81
81
  enableFilterBar: boolean;
82
82
  enableRowFlashing: boolean;
83
- // (undocumented)
84
83
  enableSearchBar: boolean;
85
84
  entityLabel: string;
86
85
  // @internal
@@ -206,6 +205,7 @@ export class Users extends Users_base {
206
205
  // (undocumented)
207
206
  deepClone(): Node;
208
207
  deleteEvent: string;
208
+ enableSearchBar: boolean;
209
209
  // @internal
210
210
  entityColumn(): {
211
211
  headerName: string;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/foundation-entity-management",
3
3
  "description": "Genesis Foundation Entity Management",
4
- "version": "14.150.1",
4
+ "version": "14.151.0",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -43,29 +43,29 @@
43
43
  "test:debug": "genx test --debug"
44
44
  },
45
45
  "devDependencies": {
46
- "@genesislcap/foundation-testing": "14.150.1",
47
- "@genesislcap/genx": "14.150.1",
48
- "@genesislcap/rollup-builder": "14.150.1",
49
- "@genesislcap/ts-builder": "14.150.1",
50
- "@genesislcap/uvu-playwright-builder": "14.150.1",
51
- "@genesislcap/vite-builder": "14.150.1",
52
- "@genesislcap/webpack-builder": "14.150.1",
46
+ "@genesislcap/foundation-testing": "14.151.0",
47
+ "@genesislcap/genx": "14.151.0",
48
+ "@genesislcap/rollup-builder": "14.151.0",
49
+ "@genesislcap/ts-builder": "14.151.0",
50
+ "@genesislcap/uvu-playwright-builder": "14.151.0",
51
+ "@genesislcap/vite-builder": "14.151.0",
52
+ "@genesislcap/webpack-builder": "14.151.0",
53
53
  "rimraf": "^3.0.2"
54
54
  },
55
55
  "dependencies": {
56
56
  "@ag-grid-community/core": "29.2.0",
57
- "@genesislcap/foundation-comms": "14.150.1",
58
- "@genesislcap/foundation-errors": "14.150.1",
59
- "@genesislcap/foundation-events": "14.150.1",
60
- "@genesislcap/foundation-forms": "14.150.1",
61
- "@genesislcap/foundation-logger": "14.150.1",
62
- "@genesislcap/foundation-login": "14.150.1",
63
- "@genesislcap/foundation-notifications": "14.150.1",
64
- "@genesislcap/foundation-ui": "14.150.1",
65
- "@genesislcap/foundation-utils": "14.150.1",
66
- "@genesislcap/foundation-zero": "14.150.1",
67
- "@genesislcap/foundation-zero-grid-pro": "14.150.1",
68
- "@genesislcap/grid-pro": "14.150.1",
57
+ "@genesislcap/foundation-comms": "14.151.0",
58
+ "@genesislcap/foundation-errors": "14.151.0",
59
+ "@genesislcap/foundation-events": "14.151.0",
60
+ "@genesislcap/foundation-forms": "14.151.0",
61
+ "@genesislcap/foundation-logger": "14.151.0",
62
+ "@genesislcap/foundation-login": "14.151.0",
63
+ "@genesislcap/foundation-notifications": "14.151.0",
64
+ "@genesislcap/foundation-ui": "14.151.0",
65
+ "@genesislcap/foundation-utils": "14.151.0",
66
+ "@genesislcap/foundation-zero": "14.151.0",
67
+ "@genesislcap/foundation-zero-grid-pro": "14.151.0",
68
+ "@genesislcap/grid-pro": "14.151.0",
69
69
  "@microsoft/fast-components": "^2.30.6",
70
70
  "@microsoft/fast-element": "^1.12.0",
71
71
  "@microsoft/fast-foundation": "^2.49.4",
@@ -81,5 +81,5 @@
81
81
  "access": "public"
82
82
  },
83
83
  "customElements": "dist/custom-elements.json",
84
- "gitHead": "9411fbb544e002ecf6f7ec283f67d1d747aa2bf5"
84
+ "gitHead": "e7584f85787986655c4c4aa9d2680e7e7e9d00a3"
85
85
  }