@things-factory/shell 9.0.0-beta.71 → 9.0.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.
Files changed (71) hide show
  1. package/dist-server/graphql-local-client.js +4 -1
  2. package/dist-server/graphql-local-client.js.map +1 -1
  3. package/dist-server/initializers/database.js +8 -2
  4. package/dist-server/initializers/database.js.map +1 -1
  5. package/dist-server/middlewares/index.js +2 -2
  6. package/dist-server/middlewares/index.js.map +1 -1
  7. package/dist-server/migrations/1000000000000-SeedDomain.js +3 -1
  8. package/dist-server/migrations/1000000000000-SeedDomain.js.map +1 -1
  9. package/dist-server/pubsub-log-transport.js +4 -1
  10. package/dist-server/pubsub-log-transport.js.map +1 -1
  11. package/dist-server/pubsub.js +7 -3
  12. package/dist-server/pubsub.js.map +1 -1
  13. package/dist-server/schema.js +24 -5
  14. package/dist-server/schema.js.map +1 -1
  15. package/dist-server/server-dev.js +5 -3
  16. package/dist-server/server-dev.js.map +1 -1
  17. package/dist-server/server.js +5 -3
  18. package/dist-server/server.js.map +1 -1
  19. package/dist-server/service/attribute-set/attribute-set-item-type.d.ts +2 -2
  20. package/dist-server/service/attribute-set/attribute-set-item-type.js +37 -23
  21. package/dist-server/service/attribute-set/attribute-set-item-type.js.map +1 -1
  22. package/dist-server/service/attribute-set/attribute-set-mutation.js +43 -19
  23. package/dist-server/service/attribute-set/attribute-set-mutation.js.map +1 -1
  24. package/dist-server/service/attribute-set/attribute-set-query.js +13 -5
  25. package/dist-server/service/attribute-set/attribute-set-query.js.map +1 -1
  26. package/dist-server/service/attribute-set/attribute-set-type.js +22 -14
  27. package/dist-server/service/attribute-set/attribute-set-type.js.map +1 -1
  28. package/dist-server/service/attribute-set/attribute-set.js +12 -7
  29. package/dist-server/service/attribute-set/attribute-set.js.map +1 -1
  30. package/dist-server/service/common-types/index.js +2 -0
  31. package/dist-server/service/common-types/index.js.map +1 -1
  32. package/dist-server/service/common-types/list-param.js +17 -16
  33. package/dist-server/service/common-types/list-param.js.map +1 -1
  34. package/dist-server/service/common-types/log.js +5 -5
  35. package/dist-server/service/common-types/log.js.map +1 -1
  36. package/dist-server/service/common-types/object-ref.js +6 -4
  37. package/dist-server/service/common-types/object-ref.js.map +1 -1
  38. package/dist-server/service/common-types/scalar-any.js +1 -1
  39. package/dist-server/service/common-types/scalar-any.js.map +1 -1
  40. package/dist-server/service/common-types/scalar-date.js +1 -1
  41. package/dist-server/service/common-types/scalar-date.js.map +1 -1
  42. package/dist-server/service/common-types/scalar-object.js +1 -1
  43. package/dist-server/service/common-types/scalar-object.js.map +1 -1
  44. package/dist-server/service/directive-transaction/transaction.js +5 -3
  45. package/dist-server/service/directive-transaction/transaction.js.map +1 -1
  46. package/dist-server/service/domain/domain-mutation.js +22 -9
  47. package/dist-server/service/domain/domain-mutation.js.map +1 -1
  48. package/dist-server/service/domain/domain-query.js +14 -5
  49. package/dist-server/service/domain/domain-query.js.map +1 -1
  50. package/dist-server/service/domain/domain-types.js +30 -19
  51. package/dist-server/service/domain/domain-types.js.map +1 -1
  52. package/dist-server/service/domain/domain.js +28 -20
  53. package/dist-server/service/domain/domain.js.map +1 -1
  54. package/dist-server/service/subscription-data/data-resolver.js +5 -5
  55. package/dist-server/service/subscription-data/data-resolver.js.map +1 -1
  56. package/dist-server/service/subscription-data/data-types.js +9 -4
  57. package/dist-server/service/subscription-data/data-types.js.map +1 -1
  58. package/dist-server/service/subscription-data/index.js +3 -0
  59. package/dist-server/service/subscription-data/index.js.map +1 -1
  60. package/dist-server/tsconfig.tsbuildinfo +1 -1
  61. package/dist-server/utils/get-domain.js +6 -8
  62. package/dist-server/utils/get-domain.js.map +1 -1
  63. package/dist-server/utils/get-query-builder-from-list-params.js +4 -5
  64. package/dist-server/utils/get-query-builder-from-list-params.js.map +1 -1
  65. package/dist-server/utils/get-times-for-period.js +2 -2
  66. package/dist-server/utils/get-times-for-period.js.map +1 -1
  67. package/dist-server/utils/list-params-converter.js +9 -6
  68. package/dist-server/utils/list-params-converter.js.map +1 -1
  69. package/dist-server/utils/list-query-builder.js +8 -9
  70. package/dist-server/utils/list-query-builder.js.map +1 -1
  71. package/package.json +12 -12
@@ -16,74 +16,88 @@ var AttributeSetItemType;
16
16
  })(AttributeSetItemType || (exports.AttributeSetItemType = AttributeSetItemType = {}));
17
17
  (0, type_graphql_1.registerEnumType)(AttributeSetItemType, {
18
18
  name: 'AttributeSetItemType',
19
- description: 'type enumeration of a attribute-set-item'
19
+ description: 'Enumeration of possible types for an attribute set item, such as number, text, boolean, select, date, datetime, or file.'
20
20
  });
21
21
  let AttributeSetItem = class AttributeSetItem {
22
22
  };
23
23
  exports.AttributeSetItem = AttributeSetItem;
24
24
  tslib_1.__decorate([
25
- (0, type_graphql_1.Field)(),
25
+ (0, type_graphql_1.Field)({ description: 'The name of the attribute item.' }),
26
26
  tslib_1.__metadata("design:type", String)
27
27
  ], AttributeSetItem.prototype, "name", void 0);
28
28
  tslib_1.__decorate([
29
- (0, type_graphql_1.Field)({ nullable: true }),
29
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A description of the attribute item.' }),
30
30
  tslib_1.__metadata("design:type", String)
31
31
  ], AttributeSetItem.prototype, "description", void 0);
32
32
  tslib_1.__decorate([
33
- (0, type_graphql_1.Field)({ nullable: true }),
33
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A tag for categorizing or identifying the attribute item.' }),
34
34
  tslib_1.__metadata("design:type", String)
35
35
  ], AttributeSetItem.prototype, "tag", void 0);
36
36
  tslib_1.__decorate([
37
- (0, type_graphql_1.Field)({ nullable: true }),
38
- tslib_1.__metadata("design:type", Boolean)
39
- ], AttributeSetItem.prototype, "active", void 0);
40
- tslib_1.__decorate([
41
- (0, type_graphql_1.Field)({ nullable: true }),
42
- tslib_1.__metadata("design:type", Boolean)
43
- ], AttributeSetItem.prototype, "hidden", void 0);
44
- tslib_1.__decorate([
45
- (0, type_graphql_1.Field)({ nullable: true }),
37
+ (0, type_graphql_1.Field)(type => AttributeSetItemType, {
38
+ nullable: true,
39
+ description: 'The type of the attribute item (e.g., number, text, boolean).'
40
+ }),
46
41
  tslib_1.__metadata("design:type", String)
47
42
  ], AttributeSetItem.prototype, "type", void 0);
48
43
  tslib_1.__decorate([
49
- (0, type_graphql_1.Field)(type => scalar_object_js_1.ScalarObject, { nullable: true }),
44
+ (0, type_graphql_1.Field)(type => scalar_object_js_1.ScalarObject, {
45
+ nullable: true,
46
+ description: 'Options or additional settings for the attribute item.'
47
+ }),
50
48
  tslib_1.__metadata("design:type", Object)
51
49
  ], AttributeSetItem.prototype, "options", void 0);
50
+ tslib_1.__decorate([
51
+ (0, type_graphql_1.Field)({ nullable: true, description: 'Whether the attribute item is active.' }),
52
+ tslib_1.__metadata("design:type", Boolean)
53
+ ], AttributeSetItem.prototype, "active", void 0);
54
+ tslib_1.__decorate([
55
+ (0, type_graphql_1.Field)({ nullable: true, description: 'Whether the attribute item is hidden.' }),
56
+ tslib_1.__metadata("design:type", Boolean)
57
+ ], AttributeSetItem.prototype, "hidden", void 0);
52
58
  exports.AttributeSetItem = AttributeSetItem = tslib_1.__decorate([
53
- (0, type_graphql_1.ObjectType)({ description: 'Entity for AttributeSetItem' })
59
+ (0, type_graphql_1.ObjectType)({
60
+ description: 'Represents an item (attribute) within an AttributeSet, including its type, options, and metadata.'
61
+ })
54
62
  ], AttributeSetItem);
55
63
  let AttributeSetItemPatch = class AttributeSetItemPatch {
56
64
  };
57
65
  exports.AttributeSetItemPatch = AttributeSetItemPatch;
58
66
  tslib_1.__decorate([
59
- (0, type_graphql_1.Field)({ nullable: true }),
67
+ (0, type_graphql_1.Field)({ nullable: true, description: 'The name of the attribute item.' }),
60
68
  tslib_1.__metadata("design:type", String)
61
69
  ], AttributeSetItemPatch.prototype, "name", void 0);
62
70
  tslib_1.__decorate([
63
- (0, type_graphql_1.Field)({ nullable: true }),
71
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A description of the attribute item.' }),
64
72
  tslib_1.__metadata("design:type", String)
65
73
  ], AttributeSetItemPatch.prototype, "description", void 0);
66
74
  tslib_1.__decorate([
67
- (0, type_graphql_1.Field)({ nullable: true }),
75
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A tag for categorizing or identifying the attribute item.' }),
68
76
  tslib_1.__metadata("design:type", String)
69
77
  ], AttributeSetItemPatch.prototype, "tag", void 0);
70
78
  tslib_1.__decorate([
71
- (0, type_graphql_1.Field)(type => AttributeSetItemType, { nullable: true }),
79
+ (0, type_graphql_1.Field)(type => AttributeSetItemType, {
80
+ nullable: true,
81
+ description: 'The type of the attribute item (e.g., number, text, boolean).'
82
+ }),
72
83
  tslib_1.__metadata("design:type", String)
73
84
  ], AttributeSetItemPatch.prototype, "type", void 0);
74
85
  tslib_1.__decorate([
75
- (0, type_graphql_1.Field)(type => scalar_object_js_1.ScalarObject, { nullable: true }),
86
+ (0, type_graphql_1.Field)(type => scalar_object_js_1.ScalarObject, {
87
+ nullable: true,
88
+ description: 'Options or additional settings for the attribute item.'
89
+ }),
76
90
  tslib_1.__metadata("design:type", Object)
77
91
  ], AttributeSetItemPatch.prototype, "options", void 0);
78
92
  tslib_1.__decorate([
79
- (0, type_graphql_1.Field)({ nullable: true }),
93
+ (0, type_graphql_1.Field)({ nullable: true, description: 'Whether the attribute item is active.' }),
80
94
  tslib_1.__metadata("design:type", Boolean)
81
95
  ], AttributeSetItemPatch.prototype, "active", void 0);
82
96
  tslib_1.__decorate([
83
- (0, type_graphql_1.Field)({ nullable: true }),
97
+ (0, type_graphql_1.Field)({ nullable: true, description: 'Whether the attribute item is hidden.' }),
84
98
  tslib_1.__metadata("design:type", Boolean)
85
99
  ], AttributeSetItemPatch.prototype, "hidden", void 0);
86
100
  exports.AttributeSetItemPatch = AttributeSetItemPatch = tslib_1.__decorate([
87
- (0, type_graphql_1.InputType)()
101
+ (0, type_graphql_1.InputType)({ description: 'Input type for creating or updating an AttributeSetItem.' })
88
102
  ], AttributeSetItemPatch);
89
103
  //# sourceMappingURL=attribute-set-item-type.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"attribute-set-item-type.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-item-type.ts"],"names":[],"mappings":";;;;AAAA,+CAAkF;AAClF,uEAA+D;AAE/D,IAAY,oBAQX;AARD,WAAY,oBAAoB;IAC9B,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,2CAAmB,CAAA;IACnB,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;IACrB,qCAAa,CAAA;AACf,CAAC,EARW,oBAAoB,oCAApB,oBAAoB,QAQ/B;AAED,IAAA,+BAAgB,EAAC,oBAAoB,EAAE;IACrC,IAAI,EAAE,sBAAsB;IAC5B,WAAW,EAAE,0CAA0C;CACxD,CAAC,CAAA;AAGK,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;CAqB5B,CAAA;AArBY,4CAAgB;AAE3B;IADC,IAAA,oBAAK,GAAE;;8CACI;AAGZ;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;qDACN;AAGpB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;6CACd;AAGZ;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gDACV;AAGhB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gDACV;AAGhB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;8CACC;AAG3B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,+BAAY,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACb;2BApBxB,gBAAgB;IAD5B,IAAA,yBAAU,EAAC,EAAE,WAAW,EAAE,6BAA6B,EAAE,CAAC;GAC9C,gBAAgB,CAqB5B;AAGM,IAAM,qBAAqB,GAA3B,MAAM,qBAAqB;CAqBjC,CAAA;AArBY,sDAAqB;AAEhC;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mDACb;AAGb;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;0DACN;AAGpB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;kDACd;AAGZ;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,oBAAoB,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;mDAC7B;AAG3B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,+BAAY,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sDACb;AAGnC;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;qDACV;AAGhB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;qDACV;gCApBL,qBAAqB;IADjC,IAAA,wBAAS,GAAE;GACC,qBAAqB,CAqBjC","sourcesContent":["import { Field, InputType, Int, ObjectType, registerEnumType } from 'type-graphql'\nimport { ScalarObject } from '../common-types/scalar-object.js'\n\nexport enum AttributeSetItemType {\n number = 'number',\n text = 'text',\n boolean = 'boolean',\n select = 'select',\n date = 'date',\n datetime = 'datetime',\n file = 'file'\n}\n\nregisterEnumType(AttributeSetItemType, {\n name: 'AttributeSetItemType',\n description: 'type enumeration of a attribute-set-item'\n})\n\n@ObjectType({ description: 'Entity for AttributeSetItem' })\nexport class AttributeSetItem {\n @Field()\n name: string\n\n @Field({ nullable: true })\n description?: string\n\n @Field({ nullable: true })\n tag?: string\n\n @Field({ nullable: true })\n active?: boolean\n\n @Field({ nullable: true })\n hidden?: boolean\n\n @Field({ nullable: true })\n type?: AttributeSetItemType\n\n @Field(type => ScalarObject, { nullable: true })\n options?: { [option: string]: any }\n}\n\n@InputType()\nexport class AttributeSetItemPatch {\n @Field({ nullable: true })\n name?: string\n\n @Field({ nullable: true })\n description?: string\n\n @Field({ nullable: true })\n tag?: string\n\n @Field(type => AttributeSetItemType, { nullable: true })\n type?: AttributeSetItemType\n\n @Field(type => ScalarObject, { nullable: true })\n options?: { [option: string]: any }\n\n @Field({ nullable: true })\n active?: boolean\n\n @Field({ nullable: true })\n hidden?: boolean\n}\n"]}
1
+ {"version":3,"file":"attribute-set-item-type.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-item-type.ts"],"names":[],"mappings":";;;;AAAA,+CAAkF;AAClF,uEAA+D;AAE/D,IAAY,oBAQX;AARD,WAAY,oBAAoB;IAC9B,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,2CAAmB,CAAA;IACnB,yCAAiB,CAAA;IACjB,qCAAa,CAAA;IACb,6CAAqB,CAAA;IACrB,qCAAa,CAAA;AACf,CAAC,EARW,oBAAoB,oCAApB,oBAAoB,QAQ/B;AAED,IAAA,+BAAgB,EAAC,oBAAoB,EAAE;IACrC,IAAI,EAAE,sBAAsB;IAC5B,WAAW,EACT,0HAA0H;CAC7H,CAAC,CAAA;AAKK,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;CA2B5B,CAAA;AA3BY,4CAAgB;AAE3B;IADC,IAAA,oBAAK,EAAC,EAAE,WAAW,EAAE,iCAAiC,EAAE,CAAC;;8CAC9C;AAGZ;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,sCAAsC,EAAE,CAAC;;qDAC3D;AAGpB;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,2DAA2D,EAAE,CAAC;;6CACxF;AAMZ;IAJC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,oBAAoB,EAAE;QACnC,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,+DAA+D;KAC7E,CAAC;;8CACyB;AAM3B;I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,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,uCAAuC,EAAE,CAAC;;qDAChE;gCA1BL,qBAAqB;IADjC,IAAA,wBAAS,EAAC,EAAE,WAAW,EAAE,0DAA0D,EAAE,CAAC;GAC1E,qBAAqB,CA2BjC","sourcesContent":["import { Field, InputType, Int, ObjectType, registerEnumType } from 'type-graphql'\nimport { ScalarObject } from '../common-types/scalar-object.js'\n\nexport enum AttributeSetItemType {\n number = 'number',\n text = 'text',\n boolean = 'boolean',\n select = 'select',\n date = 'date',\n datetime = 'datetime',\n file = 'file'\n}\n\nregisterEnumType(AttributeSetItemType, {\n name: 'AttributeSetItemType',\n description:\n 'Enumeration of possible types for an attribute set item, such as number, text, boolean, select, date, datetime, or file.'\n})\n\n@ObjectType({\n description: 'Represents an item (attribute) within an AttributeSet, including its type, options, and metadata.'\n})\nexport class AttributeSetItem {\n @Field({ description: 'The name of the attribute item.' })\n name: string\n\n @Field({ nullable: true, description: 'A description of the attribute item.' })\n description?: string\n\n @Field({ nullable: true, description: 'A tag for categorizing or identifying the attribute item.' })\n tag?: string\n\n @Field(type => AttributeSetItemType, {\n nullable: true,\n description: 'The type of the attribute item (e.g., number, text, boolean).'\n })\n type?: AttributeSetItemType\n\n @Field(type => ScalarObject, {\n nullable: true,\n description: 'Options or additional settings for the attribute item.'\n })\n options?: { [option: string]: any }\n\n @Field({ nullable: true, description: 'Whether the attribute item is active.' })\n active?: boolean\n\n @Field({ nullable: true, description: 'Whether the attribute item is hidden.' })\n hidden?: boolean\n}\n\n@InputType({ description: 'Input type for creating or updating an AttributeSetItem.' })\nexport class AttributeSetItemPatch {\n @Field({ nullable: true, description: 'The name of the attribute item.' })\n name?: string\n\n @Field({ nullable: true, description: 'A description of the attribute item.' })\n description?: string\n\n @Field({ nullable: true, description: 'A tag for categorizing or identifying the attribute item.' })\n tag?: string\n\n @Field(type => AttributeSetItemType, {\n nullable: true,\n description: 'The type of the attribute item (e.g., number, text, boolean).'\n })\n type?: AttributeSetItemType\n\n @Field(type => ScalarObject, {\n nullable: true,\n description: 'Options or additional settings for the attribute item.'\n })\n options?: { [option: string]: any }\n\n @Field({ nullable: true, description: 'Whether the attribute item is active.' })\n active?: boolean\n\n @Field({ nullable: true, description: 'Whether the attribute item is hidden.' })\n hidden?: boolean\n}\n"]}
@@ -9,7 +9,9 @@ const attribute_set_type_js_1 = require("./attribute-set-type.js");
9
9
  let AttributeSetMutation = class AttributeSetMutation {
10
10
  async createAttributeSet(attribute, context) {
11
11
  const { tx } = context.state;
12
- return await tx.getRepository(attribute_set_js_1.AttributeSet).save(Object.assign({}, attribute));
12
+ return await tx.getRepository(attribute_set_js_1.AttributeSet).save({
13
+ ...attribute
14
+ });
13
15
  }
14
16
  async updateAttributeSet(id, patch, context) {
15
17
  const { tx } = context.state;
@@ -17,7 +19,10 @@ let AttributeSetMutation = class AttributeSetMutation {
17
19
  const attribute = await repository.findOne({
18
20
  where: { id }
19
21
  });
20
- return await repository.save(Object.assign(Object.assign({}, attribute), patch));
22
+ return await repository.save({
23
+ ...attribute,
24
+ ...patch
25
+ });
21
26
  }
22
27
  async updateMultipleAttributeSet(patches, context) {
23
28
  const { tx } = context.state;
@@ -28,16 +33,21 @@ let AttributeSetMutation = class AttributeSetMutation {
28
33
  if (_createRecords.length > 0) {
29
34
  for (let i = 0; i < _createRecords.length; i++) {
30
35
  const newRecord = _createRecords[i];
31
- const result = await attributeRepo.save(Object.assign({}, newRecord));
32
- results.push(Object.assign(Object.assign({}, result), { cuFlag: '+' }));
36
+ const result = await attributeRepo.save({
37
+ ...newRecord
38
+ });
39
+ results.push({ ...result, cuFlag: '+' });
33
40
  }
34
41
  }
35
42
  if (_updateRecords.length > 0) {
36
43
  for (let i = 0; i < _updateRecords.length; i++) {
37
44
  const updateRecord = _updateRecords[i];
38
45
  const attribute = await attributeRepo.findOneBy({ id: updateRecord.id });
39
- const result = await attributeRepo.save(Object.assign(Object.assign({}, attribute), updateRecord));
40
- results.push(Object.assign(Object.assign({}, result), { cuFlag: 'M' }));
46
+ const result = await attributeRepo.save({
47
+ ...attribute,
48
+ ...updateRecord
49
+ });
50
+ results.push({ ...result, cuFlag: 'M' });
41
51
  }
42
52
  }
43
53
  return results;
@@ -66,8 +76,10 @@ exports.AttributeSetMutation = AttributeSetMutation;
66
76
  tslib_1.__decorate([
67
77
  (0, type_graphql_1.Directive)('@transaction'),
68
78
  (0, type_graphql_1.Directive)('@privilege(superUserGranted: true)'),
69
- (0, type_graphql_1.Mutation)(returns => attribute_set_js_1.AttributeSet, { description: 'To create new AttributeSet' }),
70
- tslib_1.__param(0, (0, type_graphql_1.Arg)('attribute')),
79
+ (0, type_graphql_1.Mutation)(returns => attribute_set_js_1.AttributeSet, {
80
+ description: 'Creates a new AttributeSet entity. Use this mutation to define a new set of attributes for a specific entity type.'
81
+ }),
82
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('attribute', { description: 'The input object containing the new AttributeSet details.' })),
71
83
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
72
84
  tslib_1.__metadata("design:type", Function),
73
85
  tslib_1.__metadata("design:paramtypes", [attribute_set_type_js_1.NewAttributeSet, Object]),
@@ -76,9 +88,11 @@ tslib_1.__decorate([
76
88
  tslib_1.__decorate([
77
89
  (0, type_graphql_1.Directive)('@transaction'),
78
90
  (0, type_graphql_1.Directive)('@privilege(superUserGranted: true)'),
79
- (0, type_graphql_1.Mutation)(returns => attribute_set_js_1.AttributeSet, { description: 'To modify AttributeSet information' }),
80
- tslib_1.__param(0, (0, type_graphql_1.Arg)('id')),
81
- tslib_1.__param(1, (0, type_graphql_1.Arg)('patch')),
91
+ (0, type_graphql_1.Mutation)(returns => attribute_set_js_1.AttributeSet, {
92
+ description: 'Updates an existing AttributeSet entity. Use this mutation to modify the properties or items of an AttributeSet.'
93
+ }),
94
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('id', { description: 'The unique identifier of the AttributeSet to update.' })),
95
+ tslib_1.__param(1, (0, type_graphql_1.Arg)('patch', { description: 'The patch object containing updated fields for the AttributeSet.' })),
82
96
  tslib_1.__param(2, (0, type_graphql_1.Ctx)()),
83
97
  tslib_1.__metadata("design:type", Function),
84
98
  tslib_1.__metadata("design:paramtypes", [String, attribute_set_type_js_1.AttributeSetPatch, Object]),
@@ -87,8 +101,12 @@ tslib_1.__decorate([
87
101
  tslib_1.__decorate([
88
102
  (0, type_graphql_1.Directive)('@transaction'),
89
103
  (0, type_graphql_1.Directive)('@privilege(superUserGranted: true)'),
90
- (0, type_graphql_1.Mutation)(returns => [attribute_set_js_1.AttributeSet], { description: "To modify multiple AttributeSets' information" }),
91
- tslib_1.__param(0, (0, type_graphql_1.Arg)('patches', type => [attribute_set_type_js_1.AttributeSetPatch])),
104
+ (0, type_graphql_1.Mutation)(returns => [attribute_set_js_1.AttributeSet], {
105
+ description: 'Updates or creates multiple AttributeSet entities in a single operation. Use this mutation for batch processing of attribute sets.'
106
+ }),
107
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('patches', type => [attribute_set_type_js_1.AttributeSetPatch], {
108
+ description: 'An array of patch objects for batch update or creation.'
109
+ })),
92
110
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
93
111
  tslib_1.__metadata("design:type", Function),
94
112
  tslib_1.__metadata("design:paramtypes", [Array, Object]),
@@ -97,8 +115,10 @@ tslib_1.__decorate([
97
115
  tslib_1.__decorate([
98
116
  (0, type_graphql_1.Directive)('@transaction'),
99
117
  (0, type_graphql_1.Directive)('@privilege(superUserGranted: true)'),
100
- (0, type_graphql_1.Mutation)(returns => Boolean, { description: 'To delete AttributeSet' }),
101
- tslib_1.__param(0, (0, type_graphql_1.Arg)('id')),
118
+ (0, type_graphql_1.Mutation)(returns => Boolean, {
119
+ description: 'Deletes an AttributeSet entity by its unique identifier. Use this mutation to permanently remove an attribute set.'
120
+ }),
121
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('id', { description: 'The unique identifier of the AttributeSet to delete.' })),
102
122
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
103
123
  tslib_1.__metadata("design:type", Function),
104
124
  tslib_1.__metadata("design:paramtypes", [String, Object]),
@@ -107,8 +127,10 @@ tslib_1.__decorate([
107
127
  tslib_1.__decorate([
108
128
  (0, type_graphql_1.Directive)('@transaction'),
109
129
  (0, type_graphql_1.Directive)('@privilege(superUserGranted: true)'),
110
- (0, type_graphql_1.Mutation)(returns => Boolean, { description: 'To delete multiple AttributeSets' }),
111
- tslib_1.__param(0, (0, type_graphql_1.Arg)('ids', type => [String])),
130
+ (0, type_graphql_1.Mutation)(returns => Boolean, {
131
+ description: 'Deletes multiple AttributeSet entities by their unique identifiers. Use this mutation to remove several attribute sets at once.'
132
+ }),
133
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('ids', type => [String], { description: 'An array of unique identifiers for the AttributeSets to delete.' })),
112
134
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
113
135
  tslib_1.__metadata("design:type", Function),
114
136
  tslib_1.__metadata("design:paramtypes", [Array, Object]),
@@ -117,8 +139,10 @@ tslib_1.__decorate([
117
139
  tslib_1.__decorate([
118
140
  (0, type_graphql_1.Directive)('@transaction'),
119
141
  (0, type_graphql_1.Directive)('@privilege(superUserGranted: true)'),
120
- (0, type_graphql_1.Mutation)(returns => Boolean, { description: 'To import multiple AttributeSets' }),
121
- tslib_1.__param(0, (0, type_graphql_1.Arg)('attributes', type => [attribute_set_type_js_1.AttributeSetPatch])),
142
+ (0, type_graphql_1.Mutation)(returns => Boolean, {
143
+ description: 'Imports multiple AttributeSet entities into the system. Use this mutation to bulk import attribute sets from external sources.'
144
+ }),
145
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('attributes', type => [attribute_set_type_js_1.AttributeSetPatch], { description: 'An array of AttributeSetPatch objects to import.' })),
122
146
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
123
147
  tslib_1.__metadata("design:type", Function),
124
148
  tslib_1.__metadata("design:paramtypes", [Array, Object]),
@@ -1 +1 @@
1
- {"version":3,"file":"attribute-set-mutation.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-mutation.ts"],"names":[],"mappings":";;;;AAAA,+CAAsE;AACtE,qCAA4B;AAE5B,yDAAiD;AACjD,mEAA4E;AAGrE,IAAM,oBAAoB,GAA1B,MAAM,oBAAoB;IAIzB,AAAN,KAAK,CAAC,kBAAkB,CAAmB,SAA0B,EAAS,OAAY;QACxF,MAAM,EAAE,EAAE,EAAE,GAAG,OAAO,CAAC,KAAK,CAAA;QAE5B,OAAO,MAAM,EAAE,CAAC,aAAa,CAAC,+BAAY,CAAC,CAAC,IAAI,mBAC3C,SAAS,EACZ,CAAA;IACJ,CAAC;IAKK,AAAN,KAAK,CAAC,kBAAkB,CACX,EAAU,EACP,KAAwB,EAC/B,OAAY;QAEnB,MAAM,EAAE,EAAE,EAAE,GAAG,OAAO,CAAC,KAAK,CAAA;QAE5B,MAAM,UAAU,GAAG,EAAE,CAAC,aAAa,CAAC,+BAAY,CAAC,CAAA;QACjD,MAAM,SAAS,GAAG,MAAM,UAAU,CAAC,OAAO,CAAC;YACzC,KAAK,EAAE,EAAE,EAAE,EAAE;SACd,CAAC,CAAA;QAEF,OAAO,MAAM,UAAU,CAAC,IAAI,iCACvB,SAAS,GACT,KAAK,EACR,CAAA;IACJ,CAAC;IAKK,AAAN,KAAK,CAAC,0BAA0B,CACe,OAA4B,EAClE,OAAY;QAEnB,MAAM,EAAE,EAAE,EAAE,GAAG,OAAO,CAAC,KAAK,CAAA;QAE5B,IAAI,OAAO,GAAG,EAAE,CAAA;QAChB,MAAM,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,KAAU,EAAE,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,WAAW,EAAE,KAAK,GAAG,CAAC,CAAA;QACzF,MAAM,cAAc,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC,KAAU,EAAE,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,WAAW,EAAE,KAA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,EAAE,CAAC,OAAO,EAAE,EAAE,WAAW,EAAE,kCAAkC,EAAE,CAAC;IAE/E,mBAAA,IAAA,kBAAG,EAAC,YAAY,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC,yCAAiB,CAAC,CAAC,CAAA;IAC9C,mBAAA,IAAA,kBAAG,GAAE,CAAA;;;;+DAWP;+BApHU,oBAAoB;IADhC,IAAA,uBAAQ,EAAC,+BAAY,CAAC;GACV,oBAAoB,CAqHhC","sourcesContent":["import { Resolver, Mutation, Arg, Ctx, Directive } from 'type-graphql'\nimport { In } from 'typeorm'\n\nimport { AttributeSet } from './attribute-set.js'\nimport { NewAttributeSet, AttributeSetPatch } from './attribute-set-type.js'\n\n@Resolver(AttributeSet)\nexport class AttributeSetMutation {\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => AttributeSet, { description: 'To create new AttributeSet' })\n async createAttributeSet(@Arg('attribute') attribute: NewAttributeSet, @Ctx() context: any): Promise<AttributeSet> {\n const { tx } = context.state\n\n return await tx.getRepository(AttributeSet).save({\n ...attribute\n })\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => AttributeSet, { description: 'To modify AttributeSet information' })\n async updateAttributeSet(\n @Arg('id') id: string,\n @Arg('patch') patch: AttributeSetPatch,\n @Ctx() context: any\n ): Promise<AttributeSet> {\n const { tx } = context.state\n\n const repository = tx.getRepository(AttributeSet)\n const attribute = await repository.findOne({\n where: { id }\n })\n\n return await repository.save({\n ...attribute,\n ...patch\n })\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => [AttributeSet], { description: \"To modify multiple AttributeSets' information\" })\n async updateMultipleAttributeSet(\n @Arg('patches', type => [AttributeSetPatch]) patches: AttributeSetPatch[],\n @Ctx() context: any\n ): Promise<AttributeSet[]> {\n const { tx } = context.state\n\n let results = []\n const _createRecords = patches.filter((patch: any) => patch.cuFlag.toUpperCase() === '+')\n const _updateRecords = patches.filter((patch: any) => patch.cuFlag.toUpperCase() === 'M')\n const attributeRepo = tx.getRepository(AttributeSet)\n\n if (_createRecords.length > 0) {\n for (let i = 0; i < _createRecords.length; i++) {\n const newRecord = _createRecords[i]\n\n const result = await attributeRepo.save({\n ...newRecord\n })\n\n results.push({ ...result, cuFlag: '+' })\n }\n }\n\n if (_updateRecords.length > 0) {\n for (let i = 0; i < _updateRecords.length; i++) {\n const updateRecord = _updateRecords[i]\n const attribute = await attributeRepo.findOneBy({ id: updateRecord.id })\n\n const result = await attributeRepo.save({\n ...attribute,\n ...updateRecord\n })\n\n results.push({ ...result, cuFlag: 'M' })\n }\n }\n\n return results\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => Boolean, { description: 'To delete AttributeSet' })\n async deleteAttributeSet(@Arg('id') id: string, @Ctx() context: any): Promise<boolean> {\n const { tx } = context.state\n\n await tx.getRepository(AttributeSet).delete({ id })\n\n return true\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => Boolean, { description: 'To delete multiple AttributeSets' })\n async deleteAttributeSets(@Arg('ids', type => [String]) ids: string[], @Ctx() context: any): Promise<boolean> {\n const { tx } = context.state\n\n await tx.getRepository(AttributeSet).delete({\n id: In(ids)\n })\n\n return true\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => Boolean, { description: 'To import multiple AttributeSets' })\n async importAttributeSets(\n @Arg('attributes', type => [AttributeSetPatch]) attributes: AttributeSetPatch[],\n @Ctx() context: any\n ): Promise<boolean> {\n const { tx } = context.state\n\n await Promise.all(\n attributes.map(async (attribute: AttributeSetPatch) => {\n await tx.getRepository(AttributeSet).save(attribute)\n })\n )\n\n return true\n }\n}\n"]}
1
+ {"version":3,"file":"attribute-set-mutation.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-mutation.ts"],"names":[],"mappings":";;;;AAAA,+CAAsE;AACtE,qCA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AE,EAAE,WAAW,EAAE,iEAAiE,EAAE,CAAC,CAAA;IAEhH,mBAAA,IAAA,kBAAG,GAAE,CAAA;;;;+DASP;AAQK;IANL,IAAA,wBAAS,EAAC,cAAc,CAAC;IACzB,IAAA,wBAAS,EAAC,oCAAoC,CAAC;IAC/C,IAAA,uBAAQ,EAAC,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE;QAC5B,WAAW,EACT,gIAAgI;KACnI,CAAC;IAEC,mBAAA,IAAA,kBAAG,EAAC,YAAY,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC,yCAAiB,CAAC,EAAE,EAAE,WAAW,EAAE,kDAAkD,EAAE,CAAC,CAAA;IAEnH,mBAAA,IAAA,kBAAG,GAAE,CAAA;;;;+DAWP;+BAtJU,oBAAoB;IADhC,IAAA,uBAAQ,EAAC,+BAAY,CAAC;GACV,oBAAoB,CAuJhC","sourcesContent":["import { Resolver, Mutation, Arg, Ctx, Directive } from 'type-graphql'\nimport { In } from 'typeorm'\n\nimport { AttributeSet } from './attribute-set.js'\nimport { NewAttributeSet, AttributeSetPatch } from './attribute-set-type.js'\n\n@Resolver(AttributeSet)\nexport class AttributeSetMutation {\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => AttributeSet, {\n description:\n 'Creates a new AttributeSet entity. Use this mutation to define a new set of attributes for a specific entity type.'\n })\n async createAttributeSet(\n @Arg('attribute', { description: 'The input object containing the new AttributeSet details.' })\n attribute: NewAttributeSet,\n @Ctx() context: any\n ): Promise<AttributeSet> {\n const { tx } = context.state\n\n return await tx.getRepository(AttributeSet).save({\n ...attribute\n })\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => AttributeSet, {\n description:\n 'Updates an existing AttributeSet entity. Use this mutation to modify the properties or items of an AttributeSet.'\n })\n async updateAttributeSet(\n @Arg('id', { description: 'The unique identifier of the AttributeSet to update.' }) id: string,\n @Arg('patch', { description: 'The patch object containing updated fields for the AttributeSet.' })\n patch: AttributeSetPatch,\n @Ctx() context: any\n ): Promise<AttributeSet> {\n const { tx } = context.state\n\n const repository = tx.getRepository(AttributeSet)\n const attribute = await repository.findOne({\n where: { id }\n })\n\n return await repository.save({\n ...attribute,\n ...patch\n })\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => [AttributeSet], {\n description:\n 'Updates or creates multiple AttributeSet entities in a single operation. Use this mutation for batch processing of attribute sets.'\n })\n async updateMultipleAttributeSet(\n @Arg('patches', type => [AttributeSetPatch], {\n description: 'An array of patch objects for batch update or creation.'\n })\n patches: AttributeSetPatch[],\n @Ctx() context: any\n ): Promise<AttributeSet[]> {\n const { tx } = context.state\n\n let results = []\n const _createRecords = patches.filter((patch: any) => patch.cuFlag.toUpperCase() === '+')\n const _updateRecords = patches.filter((patch: any) => patch.cuFlag.toUpperCase() === 'M')\n const attributeRepo = tx.getRepository(AttributeSet)\n\n if (_createRecords.length > 0) {\n for (let i = 0; i < _createRecords.length; i++) {\n const newRecord = _createRecords[i]\n\n const result = await attributeRepo.save({\n ...newRecord\n })\n\n results.push({ ...result, cuFlag: '+' })\n }\n }\n\n if (_updateRecords.length > 0) {\n for (let i = 0; i < _updateRecords.length; i++) {\n const updateRecord = _updateRecords[i]\n const attribute = await attributeRepo.findOneBy({ id: updateRecord.id })\n\n const result = await attributeRepo.save({\n ...attribute,\n ...updateRecord\n })\n\n results.push({ ...result, cuFlag: 'M' })\n }\n }\n\n return results\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => Boolean, {\n description:\n 'Deletes an AttributeSet entity by its unique identifier. Use this mutation to permanently remove an attribute set.'\n })\n async deleteAttributeSet(\n @Arg('id', { description: 'The unique identifier of the AttributeSet to delete.' }) id: string,\n @Ctx() context: any\n ): Promise<boolean> {\n const { tx } = context.state\n\n await tx.getRepository(AttributeSet).delete({ id })\n\n return true\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => Boolean, {\n description:\n 'Deletes multiple AttributeSet entities by their unique identifiers. Use this mutation to remove several attribute sets at once.'\n })\n async deleteAttributeSets(\n @Arg('ids', type => [String], { description: 'An array of unique identifiers for the AttributeSets to delete.' })\n ids: string[],\n @Ctx() context: any\n ): Promise<boolean> {\n const { tx } = context.state\n\n await tx.getRepository(AttributeSet).delete({\n id: In(ids)\n })\n\n return true\n }\n\n @Directive('@transaction')\n @Directive('@privilege(superUserGranted: true)')\n @Mutation(returns => Boolean, {\n description:\n 'Imports multiple AttributeSet entities into the system. Use this mutation to bulk import attribute sets from external sources.'\n })\n async importAttributeSets(\n @Arg('attributes', type => [AttributeSetPatch], { description: 'An array of AttributeSetPatch objects to import.' })\n attributes: AttributeSetPatch[],\n @Ctx() context: any\n ): Promise<boolean> {\n const { tx } = context.state\n\n await Promise.all(\n attributes.map(async (attribute: AttributeSetPatch) => {\n await tx.getRepository(AttributeSet).save(attribute)\n })\n )\n\n return true\n }\n}\n"]}
@@ -31,23 +31,31 @@ let AttributeSetQuery = class AttributeSetQuery {
31
31
  };
32
32
  exports.AttributeSetQuery = AttributeSetQuery;
33
33
  tslib_1.__decorate([
34
- (0, type_graphql_1.Query)(returns => attribute_set_js_1.AttributeSet, { nullable: true, description: 'To fetch a AttributeSet' }),
35
- tslib_1.__param(0, (0, type_graphql_1.Arg)('id')),
34
+ (0, type_graphql_1.Query)(returns => attribute_set_js_1.AttributeSet, {
35
+ nullable: true,
36
+ description: 'Fetches a single AttributeSet entity by its unique identifier. Use this query to retrieve the details of a specific attribute set.'
37
+ }),
38
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('id', { description: 'The unique identifier of the AttributeSet to fetch.' })),
36
39
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
37
40
  tslib_1.__metadata("design:type", Function),
38
41
  tslib_1.__metadata("design:paramtypes", [String, Object]),
39
42
  tslib_1.__metadata("design:returntype", Promise)
40
43
  ], AttributeSetQuery.prototype, "attributeSet", null);
41
44
  tslib_1.__decorate([
42
- (0, type_graphql_1.Query)(returns => attribute_set_js_1.AttributeSet, { nullable: true, description: 'To fetch a AttributeSet by Entity name' }),
43
- tslib_1.__param(0, (0, type_graphql_1.Arg)('entity')),
45
+ (0, type_graphql_1.Query)(returns => attribute_set_js_1.AttributeSet, {
46
+ nullable: true,
47
+ description: 'Fetches a single AttributeSet entity by the associated entity name. Use this query to retrieve the attribute set for a specific entity type.'
48
+ }),
49
+ tslib_1.__param(0, (0, type_graphql_1.Arg)('entity', { description: 'The entity name associated with the AttributeSet.' })),
44
50
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
45
51
  tslib_1.__metadata("design:type", Function),
46
52
  tslib_1.__metadata("design:paramtypes", [String, Object]),
47
53
  tslib_1.__metadata("design:returntype", Promise)
48
54
  ], AttributeSetQuery.prototype, "attributeSetByEntity", null);
49
55
  tslib_1.__decorate([
50
- (0, type_graphql_1.Query)(returns => attribute_set_type_js_1.AttributeSetList, { description: 'To fetch multiple AttributeSets' }),
56
+ (0, type_graphql_1.Query)(returns => attribute_set_type_js_1.AttributeSetList, {
57
+ description: 'Fetches a list of AttributeSet entities with pagination and filtering options. Use this query to retrieve multiple attribute sets.'
58
+ }),
51
59
  tslib_1.__param(0, (0, type_graphql_1.Args)(type => list_param_js_1.ListParam)),
52
60
  tslib_1.__param(1, (0, type_graphql_1.Ctx)()),
53
61
  tslib_1.__metadata("design:type", Function),
@@ -1 +1 @@
1
- {"version":3,"file":"attribute-set-query.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-query.ts"],"names":[],"mappings":";;;;AAAA,+CAA8F;AAC9F,yDAAiD;AACjD,mEAA0D;AAC1D,iEAAyD;AACzD,gEAA8D;AAC9D,6GAAiG;AAG1F,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;IAEtB,AAAN,KAAK,CAAC,YAAY,CAAY,EAAU,EAAS,OAAY;QAC3D,OAAO,MAAM,IAAA,2BAAa,EAAC,+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EAAE,EAAE,WAAW,EAAE,iCAAiC,EAAE,CAAC;IAClE,mBAAA,IAAA,mBAAI,EAAC,IAAI,CAAC,EAAE,CAAC,yBAAS,CAAC,CAAA;IAAqB,mBAAA,IAAA,kBAAG,GAAE,CAAA;;6CAAjB,yBAAS;;sDAU7D;4BA1BU,iBAAiB;IAD7B,IAAA,uBAAQ,EAAC,+BAAY,CAAC;GACV,iBAAiB,CA2B7B","sourcesContent":["import { Resolver, Query, FieldResolver, Root, Args, Arg, Ctx, Directive } from 'type-graphql'\nimport { AttributeSet } from './attribute-set.js'\nimport { AttributeSetList } from './attribute-set-type.js'\nimport { ListParam } from '../common-types/list-param.js'\nimport { getRepository } from '../../initializers/database.js'\nimport { getQueryBuilderFromListParams } from '../../utils/get-query-builder-from-list-params.js'\n\n@Resolver(AttributeSet)\nexport class AttributeSetQuery {\n @Query(returns => AttributeSet!, { nullable: true, description: 'To fetch a AttributeSet' })\n async attributeSet(@Arg('id') id: string, @Ctx() context: any): Promise<AttributeSet> {\n return await getRepository(AttributeSet).findOne({\n where: { id }\n })\n }\n\n @Query(returns => AttributeSet!, { nullable: true, description: 'To fetch a AttributeSet by Entity name' })\n async attributeSetByEntity(@Arg('entity') entity: string, @Ctx() context: any): Promise<AttributeSet> {\n return await getRepository(AttributeSet).findOne({\n where: { entity }\n })\n }\n\n @Query(returns => AttributeSetList, { description: 'To fetch multiple AttributeSets' })\n async attributeSets(@Args(type => ListParam) params: ListParam, @Ctx() context: any): Promise<AttributeSetList> {\n const queryBuilder = getQueryBuilderFromListParams({\n params,\n repository: await getRepository(AttributeSet),\n searchables: ['entity', 'description']\n })\n\n const [items, total] = await queryBuilder.getManyAndCount()\n\n return { items, total }\n }\n}\n"]}
1
+ {"version":3,"file":"attribute-set-query.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-query.ts"],"names":[],"mappings":";;;;AAAA,+CAA8F;AAC9F,yDAAiD;AACjD,mEAA0D;AAC1D,iEAAyD;AACzD,gEAA8D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ACT,8IAA8I;KACjJ,CAAC;IAEC,mBAAA,IAAA,kBAAG,EAAC,QAAQ,EAAE,EAAE,WAAW,EAAE,mDAAmD,EAAE,CAAC,CAAA;IACnF,mBAAA,IAAA,kBAAG,GAAE,CAAA;;;;6DAKP;AAMK;IAJL,IAAA,oBAAK,EAAC,OAAO,CAAC,EAAE,CAAC,wCAAgB,EAAE;QAClC,WAAW,EACT,oIAAoI;KACvI,CAAC;IACmB,mBAAA,IAAA,mBAAI,EAAC,IAAI,CAAC,EAAE,CAAC,yBAAS,CAAC,CAAA;IAAqB,mBAAA,IAAA,kBAAG,GAAE,CAAA;;6CAAjB,yBAAS;;sDAU7D;4BA3CU,iBAAiB;IAD7B,IAAA,uBAAQ,EAAC,+BAAY,CAAC;GACV,iBAAiB,CA4C7B","sourcesContent":["import { Resolver, Query, FieldResolver, Root, Args, Arg, Ctx, Directive } from 'type-graphql'\nimport { AttributeSet } from './attribute-set.js'\nimport { AttributeSetList } from './attribute-set-type.js'\nimport { ListParam } from '../common-types/list-param.js'\nimport { getRepository } from '../../initializers/database.js'\nimport { getQueryBuilderFromListParams } from '../../utils/get-query-builder-from-list-params.js'\n\n@Resolver(AttributeSet)\nexport class AttributeSetQuery {\n @Query(returns => AttributeSet!, {\n nullable: true,\n description:\n 'Fetches a single AttributeSet entity by its unique identifier. Use this query to retrieve the details of a specific attribute set.'\n })\n async attributeSet(\n @Arg('id', { description: 'The unique identifier of the AttributeSet to fetch.' }) id: string,\n @Ctx() context: any\n ): Promise<AttributeSet> {\n return await getRepository(AttributeSet).findOne({\n where: { id }\n })\n }\n\n @Query(returns => AttributeSet!, {\n nullable: true,\n description:\n 'Fetches a single AttributeSet entity by the associated entity name. Use this query to retrieve the attribute set for a specific entity type.'\n })\n async attributeSetByEntity(\n @Arg('entity', { description: 'The entity name associated with the AttributeSet.' }) entity: string,\n @Ctx() context: any\n ): Promise<AttributeSet> {\n return await getRepository(AttributeSet).findOne({\n where: { entity }\n })\n }\n\n @Query(returns => AttributeSetList, {\n description:\n 'Fetches a list of AttributeSet entities with pagination and filtering options. Use this query to retrieve multiple attribute sets.'\n })\n async attributeSets(@Args(type => ListParam) params: ListParam, @Ctx() context: any): Promise<AttributeSetList> {\n const queryBuilder = getQueryBuilderFromListParams({\n params,\n repository: await getRepository(AttributeSet),\n searchables: ['entity', 'description']\n })\n\n const [items, total] = await queryBuilder.getManyAndCount()\n\n return { items, total }\n }\n}\n"]}
@@ -9,62 +9,70 @@ let NewAttributeSet = class NewAttributeSet {
9
9
  };
10
10
  exports.NewAttributeSet = NewAttributeSet;
11
11
  tslib_1.__decorate([
12
- (0, type_graphql_1.Field)(),
12
+ (0, type_graphql_1.Field)({ description: 'The name of the entity this AttributeSet is associated with.' }),
13
13
  tslib_1.__metadata("design:type", String)
14
14
  ], NewAttributeSet.prototype, "entity", void 0);
15
15
  tslib_1.__decorate([
16
- (0, type_graphql_1.Field)({ nullable: true }),
16
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A description of the AttributeSet.' }),
17
17
  tslib_1.__metadata("design:type", String)
18
18
  ], NewAttributeSet.prototype, "description", void 0);
19
19
  tslib_1.__decorate([
20
- (0, type_graphql_1.Field)(type => [attribute_set_item_type_js_1.AttributeSetItemPatch], { nullable: true }),
20
+ (0, type_graphql_1.Field)(type => [attribute_set_item_type_js_1.AttributeSetItemPatch], {
21
+ nullable: true,
22
+ description: 'A list of items (attributes) included in this AttributeSet.'
23
+ }),
21
24
  tslib_1.__metadata("design:type", Array)
22
25
  ], NewAttributeSet.prototype, "items", void 0);
23
26
  tslib_1.__decorate([
24
- (0, type_graphql_1.Field)({ nullable: true }),
27
+ (0, type_graphql_1.Field)({ nullable: true, description: 'Whether this AttributeSet is active.' }),
25
28
  tslib_1.__metadata("design:type", Boolean)
26
29
  ], NewAttributeSet.prototype, "active", void 0);
27
30
  exports.NewAttributeSet = NewAttributeSet = tslib_1.__decorate([
28
- (0, type_graphql_1.InputType)()
31
+ (0, type_graphql_1.InputType)({
32
+ description: 'Input type for creating a new AttributeSet entity, including entity name, description, and items.'
33
+ })
29
34
  ], NewAttributeSet);
30
35
  let AttributeSetPatch = class AttributeSetPatch {
31
36
  };
32
37
  exports.AttributeSetPatch = AttributeSetPatch;
33
38
  tslib_1.__decorate([
34
- (0, type_graphql_1.Field)(type => type_graphql_1.ID, { nullable: true }),
39
+ (0, type_graphql_1.Field)(type => type_graphql_1.ID, { nullable: true, description: 'The unique identifier of the AttributeSet.' }),
35
40
  tslib_1.__metadata("design:type", String)
36
41
  ], AttributeSetPatch.prototype, "id", void 0);
37
42
  tslib_1.__decorate([
38
- (0, type_graphql_1.Field)({ nullable: true }),
43
+ (0, type_graphql_1.Field)({ nullable: true, description: 'The name of the entity this AttributeSet is associated with.' }),
39
44
  tslib_1.__metadata("design:type", String)
40
45
  ], AttributeSetPatch.prototype, "entity", void 0);
41
46
  tslib_1.__decorate([
42
- (0, type_graphql_1.Field)({ nullable: true }),
47
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A description of the AttributeSet.' }),
43
48
  tslib_1.__metadata("design:type", String)
44
49
  ], AttributeSetPatch.prototype, "description", void 0);
45
50
  tslib_1.__decorate([
46
- (0, type_graphql_1.Field)(type => [attribute_set_item_type_js_1.AttributeSetItemPatch], { nullable: true }),
51
+ (0, type_graphql_1.Field)(type => [attribute_set_item_type_js_1.AttributeSetItemPatch], {
52
+ nullable: true,
53
+ description: 'A list of items (attributes) to update in this AttributeSet.'
54
+ }),
47
55
  tslib_1.__metadata("design:type", Array)
48
56
  ], AttributeSetPatch.prototype, "items", void 0);
49
57
  tslib_1.__decorate([
50
- (0, type_graphql_1.Field)({ nullable: true }),
58
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A flag indicating create/update operation.' }),
51
59
  tslib_1.__metadata("design:type", String)
52
60
  ], AttributeSetPatch.prototype, "cuFlag", void 0);
53
61
  exports.AttributeSetPatch = AttributeSetPatch = tslib_1.__decorate([
54
- (0, type_graphql_1.InputType)()
62
+ (0, type_graphql_1.InputType)({ description: 'Input type for updating an existing AttributeSet entity.' })
55
63
  ], AttributeSetPatch);
56
64
  let AttributeSetList = class AttributeSetList {
57
65
  };
58
66
  exports.AttributeSetList = AttributeSetList;
59
67
  tslib_1.__decorate([
60
- (0, type_graphql_1.Field)(type => [attribute_set_js_1.AttributeSet]),
68
+ (0, type_graphql_1.Field)(type => [attribute_set_js_1.AttributeSet], { description: 'The list of AttributeSet entities.' }),
61
69
  tslib_1.__metadata("design:type", Array)
62
70
  ], AttributeSetList.prototype, "items", void 0);
63
71
  tslib_1.__decorate([
64
- (0, type_graphql_1.Field)(type => type_graphql_1.Int),
72
+ (0, type_graphql_1.Field)(type => type_graphql_1.Int, { description: 'The total number of AttributeSet entities.' }),
65
73
  tslib_1.__metadata("design:type", Number)
66
74
  ], AttributeSetList.prototype, "total", void 0);
67
75
  exports.AttributeSetList = AttributeSetList = tslib_1.__decorate([
68
- (0, type_graphql_1.ObjectType)()
76
+ (0, type_graphql_1.ObjectType)({ description: 'A paginated list of AttributeSet entities.' })
69
77
  ], AttributeSetList);
70
78
  //# sourceMappingURL=attribute-set-type.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"attribute-set-type.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-type.ts"],"names":[],"mappings":";;;;AAAA,+CAAoE;AAEpE,yDAAiD;AACjD,6EAAoE;AAG7D,IAAM,eAAe,GAArB,MAAM,eAAe;CAY3B,CAAA;AAZY,0CAAe;AAE1B;IADC,IAAA,oBAAK,GAAE;;+CACM;AAGd;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;oDACN;AAGpB;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,kDAAqB,CAAC,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;8CAC5B;AAG/B;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;+CACV;0BAXL,eAAe;IAD3B,IAAA,wBAAS,GAAE;GACC,eAAe,CAY3B;AAGM,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;CAe7B,CAAA;AAfY,8CAAiB;AAE5B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;6CAC3B;AAGX;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACX;AAGf;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;sDACN;AAGpB;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,kDAAqB,CAAC,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;gDAC5B;AAG/B;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACX;4BAdJ,iBAAiB;IAD7B,IAAA,wBAAS,GAAE;GACC,iBAAiB,CAe7B;AAGM,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;CAM5B,CAAA;AANY,4CAAgB;AAE3B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,+BAAY,CAAC,CAAC;;+CACT;AAGrB;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,kBAAG,CAAC;;+CACN;2BALF,gBAAgB;IAD5B,IAAA,yBAAU,GAAE;GACA,gBAAgB,CAM5B","sourcesContent":["import { ObjectType, Field, InputType, Int, ID } from 'type-graphql'\n\nimport { AttributeSet } from './attribute-set.js'\nimport { AttributeSetItemPatch } from './attribute-set-item-type.js'\n\n@InputType()\nexport class NewAttributeSet {\n @Field()\n entity: string\n\n @Field({ nullable: true })\n description?: string\n\n @Field(type => [AttributeSetItemPatch], { nullable: true })\n items?: AttributeSetItemPatch[]\n\n @Field({ nullable: true })\n active?: boolean\n}\n\n@InputType()\nexport class AttributeSetPatch {\n @Field(type => ID, { nullable: true })\n id?: string\n\n @Field({ nullable: true })\n entity?: string\n\n @Field({ nullable: true })\n description?: string\n\n @Field(type => [AttributeSetItemPatch], { nullable: true })\n items?: AttributeSetItemPatch[]\n\n @Field({ nullable: true })\n cuFlag?: string\n}\n\n@ObjectType()\nexport class AttributeSetList {\n @Field(type => [AttributeSet])\n items: AttributeSet[]\n\n @Field(type => Int)\n total: number\n}\n"]}
1
+ {"version":3,"file":"attribute-set-type.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set-type.ts"],"names":[],"mappings":";;;;AAAA,+CAAoE;AAEpE,yDAAiD;AACjD,6EAAoE;AAK7D,IAAM,eAAe,GAArB,MAAM,eAAe;CAe3B,CAAA;AAfY,0CAAe;AAE1B;IADC,IAAA,oBAAK,EAAC,EAAE,WAAW,EAAE,8DAA8D,EAAE,CAAC;;+CACzE;AAGd;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,oCAAoC,EAAE,CAAC;;oDACzD;AAMpB;IAJC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,kDAAqB,CAAC,EAAE;QACtC,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,6DAA6D;KAC3E,CAAC;;8CAC6B;AAG/B;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,sCAAsC,EAAE,CAAC;;+CAC/D;0BAdL,eAAe;IAH3B,IAAA,wBAAS,EAAC;QACT,WAAW,EAAE,mGAAmG;KACjH,CAAC;GACW,eAAe,CAe3B;AAGM,IAAM,iBAAiB,GAAvB,MAAM,iBAAiB;CAkB7B,CAAA;AAlBY,8CAAiB;AAE5B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,4CAA4C,EAAE,CAAC;;6CACtF;AAGX;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,8DAA8D,EAAE,CAAC;;iDACxF;AAGf;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,oCAAoC,EAAE,CAAC;;sDACzD;AAMpB;IAJC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,kDAAqB,CAAC,EAAE;QACtC,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,8DAA8D;KAC5E,CAAC;;gDAC6B;AAG/B;IADC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,4CAA4C,EAAE,CAAC;;iDACtE;4BAjBJ,iBAAiB;IAD7B,IAAA,wBAAS,EAAC,EAAE,WAAW,EAAE,0DAA0D,EAAE,CAAC;GAC1E,iBAAiB,CAkB7B;AAGM,IAAM,gBAAgB,GAAtB,MAAM,gBAAgB;CAM5B,CAAA;AANY,4CAAgB;AAE3B;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,+BAAY,CAAC,EAAE,EAAE,WAAW,EAAE,oCAAoC,EAAE,CAAC;;+CAChE;AAGrB;IADC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,kBAAG,EAAE,EAAE,WAAW,EAAE,4CAA4C,EAAE,CAAC;;+CACrE;2BALF,gBAAgB;IAD5B,IAAA,yBAAU,EAAC,EAAE,WAAW,EAAE,4CAA4C,EAAE,CAAC;GAC7D,gBAAgB,CAM5B","sourcesContent":["import { ObjectType, Field, InputType, Int, ID } from 'type-graphql'\n\nimport { AttributeSet } from './attribute-set.js'\nimport { AttributeSetItemPatch } from './attribute-set-item-type.js'\n\n@InputType({\n description: 'Input type for creating a new AttributeSet entity, including entity name, description, and items.'\n})\nexport class NewAttributeSet {\n @Field({ description: 'The name of the entity this AttributeSet is associated with.' })\n entity: string\n\n @Field({ nullable: true, description: 'A description of the AttributeSet.' })\n description?: string\n\n @Field(type => [AttributeSetItemPatch], {\n nullable: true,\n description: 'A list of items (attributes) included in this AttributeSet.'\n })\n items?: AttributeSetItemPatch[]\n\n @Field({ nullable: true, description: 'Whether this AttributeSet is active.' })\n active?: boolean\n}\n\n@InputType({ description: 'Input type for updating an existing AttributeSet entity.' })\nexport class AttributeSetPatch {\n @Field(type => ID, { nullable: true, description: 'The unique identifier of the AttributeSet.' })\n id?: string\n\n @Field({ nullable: true, description: 'The name of the entity this AttributeSet is associated with.' })\n entity?: string\n\n @Field({ nullable: true, description: 'A description of the AttributeSet.' })\n description?: string\n\n @Field(type => [AttributeSetItemPatch], {\n nullable: true,\n description: 'A list of items (attributes) to update in this AttributeSet.'\n })\n items?: AttributeSetItemPatch[]\n\n @Field({ nullable: true, description: 'A flag indicating create/update operation.' })\n cuFlag?: string\n}\n\n@ObjectType({ description: 'A paginated list of AttributeSet entities.' })\nexport class AttributeSetList {\n @Field(type => [AttributeSet], { description: 'The list of AttributeSet entities.' })\n items: AttributeSet[]\n\n @Field(type => Int, { description: 'The total number of AttributeSet entities.' })\n total: number\n}\n"]}
@@ -14,32 +14,35 @@ let AttributeSet = class AttributeSet {
14
14
  exports.AttributeSet = AttributeSet;
15
15
  tslib_1.__decorate([
16
16
  (0, typeorm_1.PrimaryGeneratedColumn)('uuid'),
17
- (0, type_graphql_1.Field)(type => type_graphql_1.ID),
17
+ (0, type_graphql_1.Field)(type => type_graphql_1.ID, { description: 'The unique identifier of the AttributeSet.' }),
18
18
  tslib_1.__metadata("design:type", String)
19
19
  ], AttributeSet.prototype, "id", void 0);
20
20
  tslib_1.__decorate([
21
21
  (0, typeorm_1.Column)({ nullable: true, default: '' }),
22
- (0, type_graphql_1.Field)({ nullable: true }),
22
+ (0, type_graphql_1.Field)({ nullable: true, description: 'The name of the entity this AttributeSet is associated with.' }),
23
23
  tslib_1.__metadata("design:type", String)
24
24
  ], AttributeSet.prototype, "entity", void 0);
25
25
  tslib_1.__decorate([
26
26
  (0, typeorm_1.Column)({ nullable: true, default: '' }),
27
- (0, type_graphql_1.Field)({ nullable: true }),
27
+ (0, type_graphql_1.Field)({ nullable: true, description: 'A description of the AttributeSet.' }),
28
28
  tslib_1.__metadata("design:type", String)
29
29
  ], AttributeSet.prototype, "description", void 0);
30
30
  tslib_1.__decorate([
31
31
  (0, typeorm_1.Column)('simple-json', { nullable: true }),
32
- (0, type_graphql_1.Field)(type => [attribute_set_item_type_js_1.AttributeSetItem], { nullable: true }),
32
+ (0, type_graphql_1.Field)(type => [attribute_set_item_type_js_1.AttributeSetItem], {
33
+ nullable: true,
34
+ description: 'A list of items (attributes) included in this AttributeSet.'
35
+ }),
33
36
  tslib_1.__metadata("design:type", Array)
34
37
  ], AttributeSet.prototype, "items", void 0);
35
38
  tslib_1.__decorate([
36
39
  (0, typeorm_1.CreateDateColumn)(),
37
- (0, type_graphql_1.Field)({ nullable: true }),
40
+ (0, type_graphql_1.Field)({ nullable: true, description: 'The date and time when this AttributeSet was created.' }),
38
41
  tslib_1.__metadata("design:type", Date)
39
42
  ], AttributeSet.prototype, "createdAt", void 0);
40
43
  tslib_1.__decorate([
41
44
  (0, typeorm_1.UpdateDateColumn)(),
42
- (0, type_graphql_1.Field)({ nullable: true }),
45
+ (0, type_graphql_1.Field)({ nullable: true, description: 'The date and time when this AttributeSet was last updated.' }),
43
46
  tslib_1.__metadata("design:type", Date)
44
47
  ], AttributeSet.prototype, "updatedAt", void 0);
45
48
  exports.AttributeSet = AttributeSet = tslib_1.__decorate([
@@ -47,6 +50,8 @@ exports.AttributeSet = AttributeSet = tslib_1.__decorate([
47
50
  (0, typeorm_1.Index)('ix_attribute_set_0', (attributeSet) => [attributeSet.entity], {
48
51
  unique: true
49
52
  }),
50
- (0, type_graphql_1.ObjectType)({ description: 'Entity for AttributeSet' })
53
+ (0, type_graphql_1.ObjectType)({
54
+ description: 'Represents an AttributeSet entity, which defines a set of attributes for a specific entity type.'
55
+ })
51
56
  ], AttributeSet);
52
57
  //# sourceMappingURL=attribute-set.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"attribute-set.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set.ts"],"names":[],"mappings":";;;;AAAA,qCAA2G;AAC3G,+CAAoD;AAEpD,6EAA+D;AAOxD,IAAM,YAAY,GAAlB,MAAM,YAAY;IAAlB;QAOL,WAAM,GAAW,EAAE,CAAA;QAInB,gBAAW,GAAW,EAAE,CAAA;IAa1B,CAAC;CAAA,CAAA;AAxBY,oCAAY;AAGd;IAFR,IAAA,gCAAsB,EAAC,MAAM,CAAC;IAC9B,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,CAAC;;wCACC;AAInB;IAFC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;IACvC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;4CACP;AAInB;IAFC,IAAA,gBAAM,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;IACvC,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;iDACF;AAIxB;IAFC,IAAA,gBAAM,EAAC,aAAa,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;IACzC,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,CAAC,6CAAgB,CAAC,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;;2CAC7B;AAIzB;IAFC,IAAA,0BAAgB,GAAE;IAClB,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;sCACd,IAAI;+CAAA;AAIhB;IAFC,IAAA,0BAAgB,GAAE;IAClB,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;sCACd,IAAI;+CAAA;uBAvBL,YAAY;IALxB,IAAA,gBAAM,GAAE;IACR,IAAA,eAAK,EAAC,oBAAoB,EAAE,CAAC,YAA0B,EAAE,EAAE,CAAC,CAAC,YAAY,CAAC,MAAM,CAAC,EAAE;QAClF,MAAM,EAAE,IAAI;KACb,CAAC;IACD,IAAA,yBAAU,EAAC,EAAE,WAAW,EAAE,yBAAyB,EAAE,CAAC;GAC1C,YAAY,CAwBxB","sourcesContent":["import { CreateDateColumn, UpdateDateColumn, Entity, Index, Column, PrimaryGeneratedColumn } from 'typeorm'\nimport { ObjectType, Field, ID } from 'type-graphql'\n\nimport { AttributeSetItem } from './attribute-set-item-type.js'\n\n@Entity()\n@Index('ix_attribute_set_0', (attributeSet: AttributeSet) => [attributeSet.entity], {\n unique: true\n})\n@ObjectType({ description: 'Entity for AttributeSet' })\nexport class AttributeSet {\n @PrimaryGeneratedColumn('uuid')\n @Field(type => ID)\n readonly id: string\n\n @Column({ nullable: true, default: '' })\n @Field({ nullable: true })\n entity: string = ''\n\n @Column({ nullable: true, default: '' })\n @Field({ nullable: true })\n description: string = ''\n\n @Column('simple-json', { nullable: true })\n @Field(type => [AttributeSetItem], { nullable: true })\n items: AttributeSetItem[]\n\n @CreateDateColumn()\n @Field({ nullable: true })\n createdAt?: Date\n\n @UpdateDateColumn()\n @Field({ nullable: true })\n updatedAt?: Date\n}\n"]}
1
+ {"version":3,"file":"attribute-set.js","sourceRoot":"","sources":["../../../server/service/attribute-set/attribute-set.ts"],"names":[],"mappings":";;;;AAAA,qCAA2G;AAC3G,+CAAoD;AAEpD,6EAA+D;AASxD,IAAM,YAAY,GAAlB,MAAM,YAAY;IAAlB;QAOL,WAAM,GAAW,EAAE,CAAA;QAInB,gBAAW,GAAW,EAAE,CAAA;IAgB1B,CAAC;CAAA,CAAA;AA3BY,oCAAY;AAGd;IAFR,IAAA,gCAAsB,EAAC,MAAM,CAAC;IAC9B,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,EAAE,EAAE,WAAW,EAAE,4CAA4C,EAAE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Column } from 'typeorm'\nimport { ObjectType, Field, ID } from 'type-graphql'\n\nimport { AttributeSetItem } from './attribute-set-item-type.js'\n\n@Entity()\n@Index('ix_attribute_set_0', (attributeSet: AttributeSet) => [attributeSet.entity], {\n unique: true\n})\n@ObjectType({\n description: 'Represents an AttributeSet entity, which defines a set of attributes for a specific entity type.'\n})\nexport class AttributeSet {\n @PrimaryGeneratedColumn('uuid')\n @Field(type => ID, { description: 'The unique identifier of the AttributeSet.' })\n readonly id: string\n\n @Column({ nullable: true, default: '' })\n @Field({ nullable: true, description: 'The name of the entity this AttributeSet is associated with.' })\n entity: string = ''\n\n @Column({ nullable: true, default: '' })\n @Field({ nullable: true, description: 'A description of the AttributeSet.' })\n description: string = ''\n\n @Column('simple-json', { nullable: true })\n @Field(type => [AttributeSetItem], {\n nullable: true,\n description: 'A list of items (attributes) included in this AttributeSet.'\n })\n items: AttributeSetItem[]\n\n @CreateDateColumn()\n @Field({ nullable: true, description: 'The date and time when this AttributeSet was created.' })\n createdAt?: Date\n\n @UpdateDateColumn()\n @Field({ nullable: true, description: 'The date and time when this AttributeSet was last updated.' })\n updatedAt?: Date\n}\n"]}
@@ -1,4 +1,6 @@
1
1
  "use strict";
2
+ // This module provides shared GraphQL types, scalars, and input types for use across the application.
3
+ // It includes flexible scalar types, object references, logging types, and list query parameter types.
2
4
  Object.defineProperty(exports, "__esModule", { value: true });
3
5
  const tslib_1 = require("tslib");
4
6
  tslib_1.__exportStar(require("./list-param.js"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../server/service/common-types/index.ts"],"names":[],"mappings":";;;AAAA,0DAA+B;AAC/B,0DAA+B;AAC/B,2DAAgC;AAChC,6DAAkC;AAClC,0DAA+B;AAC/B,mDAAwB","sourcesContent":["export * from './list-param.js'\nexport * from './scalar-any.js'\nexport * from './scalar-date.js'\nexport * from './scalar-object.js'\nexport * from './object-ref.js'\nexport * from './log.js'\n"]}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../server/service/common-types/index.ts"],"names":[],"mappings":";AAAA,sGAAsG;AACtG,uGAAuG;;;AAEvG,0DAA+B;AAC/B,0DAA+B;AAC/B,2DAAgC;AAChC,6DAAkC;AAClC,0DAA+B;AAC/B,mDAAwB","sourcesContent":["// This module provides shared GraphQL types, scalars, and input types for use across the application.\n// It includes flexible scalar types, object references, logging types, and list query parameter types.\n\nexport * from './list-param.js'\nexport * from './scalar-any.js'\nexport * from './scalar-date.js'\nexport * from './scalar-object.js'\nexport * from './object-ref.js'\nexport * from './log.js'\n"]}