@solidstarters/solid-core 1.2.184 → 1.2.185

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 (43) hide show
  1. package/dist/config/iam.config.d.ts +2 -0
  2. package/dist/config/iam.config.d.ts.map +1 -1
  3. package/dist/config/iam.config.js +1 -0
  4. package/dist/config/iam.config.js.map +1 -1
  5. package/dist/interfaces.d.ts +9 -1
  6. package/dist/interfaces.d.ts.map +1 -1
  7. package/dist/interfaces.js.map +1 -1
  8. package/dist/jobs/database/trigger-mcp-client-subscriber-database.service.d.ts.map +1 -1
  9. package/dist/jobs/database/trigger-mcp-client-subscriber-database.service.js +3 -2
  10. package/dist/jobs/database/trigger-mcp-client-subscriber-database.service.js.map +1 -1
  11. package/dist/seeders/seed-data/solid-core-metadata.json +48 -48
  12. package/dist/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.d.ts +10 -0
  13. package/dist/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.d.ts.map +1 -0
  14. package/dist/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.js +35 -0
  15. package/dist/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.js.map +1 -0
  16. package/dist/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.d.ts +16 -0
  17. package/dist/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.d.ts.map +1 -0
  18. package/dist/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.js +74 -0
  19. package/dist/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.js.map +1 -0
  20. package/dist/services/model-metadata.service.js +4 -4
  21. package/dist/services/model-metadata.service.js.map +1 -1
  22. package/dist/services/setting.service.d.ts.map +1 -1
  23. package/dist/services/setting.service.js +4 -2
  24. package/dist/services/setting.service.js.map +1 -1
  25. package/dist/services/solid-ts-morph.service.d.ts +5 -0
  26. package/dist/services/solid-ts-morph.service.d.ts.map +1 -1
  27. package/dist/services/solid-ts-morph.service.js +21 -0
  28. package/dist/services/solid-ts-morph.service.js.map +1 -1
  29. package/dist/solid-core.module.d.ts.map +1 -1
  30. package/dist/solid-core.module.js +4 -0
  31. package/dist/solid-core.module.js.map +1 -1
  32. package/dist/tsconfig.tsbuildinfo +1 -1
  33. package/package.json +1 -1
  34. package/src/config/iam.config.ts +2 -1
  35. package/src/interfaces.ts +12 -1
  36. package/src/jobs/database/trigger-mcp-client-subscriber-database.service.ts +4 -3
  37. package/src/seeders/seed-data/solid-core-metadata.json +48 -48
  38. package/src/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.ts +34 -0
  39. package/src/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.ts +69 -0
  40. package/src/services/model-metadata.service.ts +4 -4
  41. package/src/services/setting.service.ts +4 -2
  42. package/src/services/solid-ts-morph.service.ts +37 -0
  43. package/src/solid-core.module.ts +6 -1
@@ -6242,7 +6242,7 @@
6242
6242
  "attrs": {
6243
6243
  "name": "group-1",
6244
6244
  "label": "",
6245
- "className": "col-6"
6245
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
6246
6246
  },
6247
6247
  "children": [
6248
6248
  {
@@ -6432,7 +6432,7 @@
6432
6432
  "attrs": {
6433
6433
  "name": "group-1",
6434
6434
  "label": "",
6435
- "className": "col-6"
6435
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
6436
6436
  },
6437
6437
  "children": [
6438
6438
  {
@@ -6577,7 +6577,7 @@
6577
6577
  "attrs": {
6578
6578
  "name": "group-1",
6579
6579
  "label": "",
6580
- "className": "col-6"
6580
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
6581
6581
  },
6582
6582
  "children": [
6583
6583
  {
@@ -6643,7 +6643,7 @@
6643
6643
  "attrs": {
6644
6644
  "name": "group-1",
6645
6645
  "label": "",
6646
- "className": "col-6"
6646
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
6647
6647
  },
6648
6648
  "children": [
6649
6649
  {
@@ -6774,7 +6774,7 @@
6774
6774
  "attrs": {
6775
6775
  "name": "group-1",
6776
6776
  "label": "",
6777
- "className": "col-6"
6777
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
6778
6778
  },
6779
6779
  "children": [
6780
6780
  {
@@ -6893,7 +6893,7 @@
6893
6893
  "attrs": {
6894
6894
  "name": "group-1",
6895
6895
  "label": "",
6896
- "className": "col-6"
6896
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
6897
6897
  },
6898
6898
  "children": [
6899
6899
  {
@@ -7106,7 +7106,7 @@
7106
7106
  "attrs": {
7107
7107
  "name": "group-1",
7108
7108
  "label": "",
7109
- "className": "col-6"
7109
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7110
7110
  },
7111
7111
  "children": [
7112
7112
  {
@@ -7251,7 +7251,7 @@
7251
7251
  "attrs": {
7252
7252
  "name": "group-1",
7253
7253
  "label": "",
7254
- "className": "col-6"
7254
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7255
7255
  },
7256
7256
  "children": [
7257
7257
  {
@@ -7375,7 +7375,7 @@
7375
7375
  "attrs": {
7376
7376
  "name": "group-1",
7377
7377
  "label": "",
7378
- "className": "col-6"
7378
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7379
7379
  },
7380
7380
  "children": [
7381
7381
  {
@@ -7485,7 +7485,7 @@
7485
7485
  "attrs": {
7486
7486
  "name": "group-1",
7487
7487
  "label": "",
7488
- "className": "col-6"
7488
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7489
7489
  },
7490
7490
  "children": [
7491
7491
  {
@@ -7637,7 +7637,7 @@
7637
7637
  "attrs": {
7638
7638
  "name": "page-1-row-1-col-1",
7639
7639
  "label": "",
7640
- "className": "col-6"
7640
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7641
7641
  },
7642
7642
  "children": [
7643
7643
  {
@@ -7677,7 +7677,7 @@
7677
7677
  "attrs": {
7678
7678
  "name": "page-1-row-1-col-2",
7679
7679
  "label": "",
7680
- "className": "col-6"
7680
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7681
7681
  },
7682
7682
  "children": [
7683
7683
  {
@@ -7825,7 +7825,7 @@
7825
7825
  "attrs": {
7826
7826
  "name": "page-1-row-1-col-1",
7827
7827
  "label": "",
7828
- "className": "col-6"
7828
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7829
7829
  },
7830
7830
  "children": [
7831
7831
  {
@@ -7841,7 +7841,7 @@
7841
7841
  "attrs": {
7842
7842
  "name": "page-1-row-1-col-2",
7843
7843
  "label": "",
7844
- "className": "col-6"
7844
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
7845
7845
  },
7846
7846
  "children": [
7847
7847
  {
@@ -8013,7 +8013,7 @@
8013
8013
  "attrs": {
8014
8014
  "name": "page-1-row-1-col-1",
8015
8015
  "label": "",
8016
- "className": "col-6"
8016
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8017
8017
  },
8018
8018
  "children": [
8019
8019
  {
@@ -8059,7 +8059,7 @@
8059
8059
  "attrs": {
8060
8060
  "name": "page-1-row-1-col-2",
8061
8061
  "label": "",
8062
- "className": "col-6"
8062
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8063
8063
  },
8064
8064
  "children": [
8065
8065
  {
@@ -8106,7 +8106,7 @@
8106
8106
  "attrs": {
8107
8107
  "name": "page-2-row-1-col-1",
8108
8108
  "label": "",
8109
- "className": "col-6"
8109
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8110
8110
  },
8111
8111
  "children": [
8112
8112
  {
@@ -8123,7 +8123,7 @@
8123
8123
  "attrs": {
8124
8124
  "name": "page-2-row-1-col-1",
8125
8125
  "label": "",
8126
- "className": "col-6"
8126
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8127
8127
  },
8128
8128
  "children": [
8129
8129
  {
@@ -8246,7 +8246,7 @@
8246
8246
  "attrs": {
8247
8247
  "name": "group-1",
8248
8248
  "label": "",
8249
- "className": "col-6"
8249
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8250
8250
  },
8251
8251
  "children": [
8252
8252
  {
@@ -8337,7 +8337,7 @@
8337
8337
  "attrs": {
8338
8338
  "name": "group-1",
8339
8339
  "label": "",
8340
- "className": "col-6"
8340
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8341
8341
  },
8342
8342
  "children": [
8343
8343
  {
@@ -8558,7 +8558,7 @@
8558
8558
  "attrs": {
8559
8559
  "name": "group-1",
8560
8560
  "label": "",
8561
- "className": "col-6"
8561
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8562
8562
  },
8563
8563
  "children": [
8564
8564
  {
@@ -8915,7 +8915,7 @@
8915
8915
  "attrs": {
8916
8916
  "name": "group-1",
8917
8917
  "label": "",
8918
- "className": "col-6"
8918
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
8919
8919
  },
8920
8920
  "children": [
8921
8921
  {
@@ -9240,7 +9240,7 @@
9240
9240
  "attrs": {
9241
9241
  "name": "group-1",
9242
9242
  "label": "",
9243
- "className": "col-6"
9243
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
9244
9244
  },
9245
9245
  "children": [
9246
9246
  {
@@ -9472,7 +9472,7 @@
9472
9472
  "attrs": {
9473
9473
  "name": "group-1",
9474
9474
  "label": "",
9475
- "className": "col-6"
9475
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
9476
9476
  },
9477
9477
  "children": [
9478
9478
  {
@@ -9582,7 +9582,7 @@
9582
9582
  "attrs": {
9583
9583
  "name": "group-1",
9584
9584
  "label": "",
9585
- "className": "col-6"
9585
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
9586
9586
  },
9587
9587
  "children": [
9588
9588
  {
@@ -9635,7 +9635,7 @@
9635
9635
  "attrs": {
9636
9636
  "name": "group-1",
9637
9637
  "label": "",
9638
- "className": "col-6"
9638
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
9639
9639
  },
9640
9640
  "children": [
9641
9641
  {
@@ -9661,7 +9661,7 @@
9661
9661
  "attrs": {
9662
9662
  "name": "group-1",
9663
9663
  "label": "",
9664
- "className": "col-6"
9664
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
9665
9665
  },
9666
9666
  "children": [
9667
9667
  {
@@ -10091,7 +10091,7 @@
10091
10091
  "type": "column",
10092
10092
  "attrs": {
10093
10093
  "name": "col-1",
10094
- "className": "col-6"
10094
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10095
10095
  },
10096
10096
  "children": [
10097
10097
  {
@@ -10107,7 +10107,7 @@
10107
10107
  "type": "column",
10108
10108
  "attrs": {
10109
10109
  "name": "col-2",
10110
- "className": "col-6"
10110
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10111
10111
  },
10112
10112
  "children": [
10113
10113
  {
@@ -10390,7 +10390,7 @@
10390
10390
  "attrs": {
10391
10391
  "name": "group-basic",
10392
10392
  "label": "Basic",
10393
- "className": "col-6"
10393
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10394
10394
  },
10395
10395
  "children": [
10396
10396
  {
@@ -10424,7 +10424,7 @@
10424
10424
  "attrs": {
10425
10425
  "name": "group-config",
10426
10426
  "label": "Configuration",
10427
- "className": "col-6"
10427
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10428
10428
  },
10429
10429
  "children": [
10430
10430
  {
@@ -10584,7 +10584,7 @@
10584
10584
  "attrs": {
10585
10585
  "name": "group-1",
10586
10586
  "label": "",
10587
- "className": "col-6"
10587
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10588
10588
  },
10589
10589
  "children": [
10590
10590
  {
@@ -10783,7 +10783,7 @@
10783
10783
  "attrs": {
10784
10784
  "name": "group-1",
10785
10785
  "label": "",
10786
- "className": "col-6"
10786
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10787
10787
  },
10788
10788
  "children": [
10789
10789
  {
@@ -10811,7 +10811,7 @@
10811
10811
  "attrs": {
10812
10812
  "name": "group-2",
10813
10813
  "label": "",
10814
- "className": "col-6"
10814
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10815
10815
  },
10816
10816
  "children": [
10817
10817
  {
@@ -10899,7 +10899,7 @@
10899
10899
  "attrs": {
10900
10900
  "name": "group-1",
10901
10901
  "label": "",
10902
- "className": "col-6"
10902
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10903
10903
  },
10904
10904
  "children": [
10905
10905
  {
@@ -10937,7 +10937,7 @@
10937
10937
  "attrs": {
10938
10938
  "name": "group-1",
10939
10939
  "label": "",
10940
- "className": "col-6"
10940
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
10941
10941
  },
10942
10942
  "children": [
10943
10943
  {
@@ -11031,7 +11031,7 @@
11031
11031
  "attrs": {
11032
11032
  "name": "group-1",
11033
11033
  "label": "",
11034
- "className": "col-6"
11034
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11035
11035
  },
11036
11036
  "children": [
11037
11037
  {
@@ -11062,7 +11062,7 @@
11062
11062
  "attrs": {
11063
11063
  "name": "group-1",
11064
11064
  "label": "",
11065
- "className": "col-6"
11065
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11066
11066
  },
11067
11067
  "children": [
11068
11068
  {
@@ -11166,7 +11166,7 @@
11166
11166
  "attrs": {
11167
11167
  "name": "group-1",
11168
11168
  "label": "",
11169
- "className": "col-6"
11169
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11170
11170
  },
11171
11171
  "children": [
11172
11172
  {
@@ -11182,7 +11182,7 @@
11182
11182
  "attrs": {
11183
11183
  "name": "group-2",
11184
11184
  "label": "",
11185
- "className": "col-6"
11185
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11186
11186
  },
11187
11187
  "children": []
11188
11188
  }
@@ -11266,7 +11266,7 @@
11266
11266
  "attrs": {
11267
11267
  "name": "group-1",
11268
11268
  "label": "",
11269
- "className": "col-6"
11269
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11270
11270
  },
11271
11271
  "children": [
11272
11272
  {
@@ -11282,7 +11282,7 @@
11282
11282
  "attrs": {
11283
11283
  "name": "group-2",
11284
11284
  "label": "",
11285
- "className": "col-6"
11285
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11286
11286
  },
11287
11287
  "children": []
11288
11288
  }
@@ -11387,7 +11387,7 @@
11387
11387
  "attrs": {
11388
11388
  "name": "group-1",
11389
11389
  "label": "",
11390
- "className": "col-6"
11390
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11391
11391
  },
11392
11392
  "children": [
11393
11393
  {
@@ -11421,7 +11421,7 @@
11421
11421
  "attrs": {
11422
11422
  "name": "group-2",
11423
11423
  "label": "",
11424
- "className": "col-6"
11424
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11425
11425
  },
11426
11426
  "children": [
11427
11427
  {
@@ -11726,7 +11726,7 @@
11726
11726
  "attrs": {
11727
11727
  "name": "group-1",
11728
11728
  "label": "General Info",
11729
- "className": "col-6"
11729
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11730
11730
  },
11731
11731
  "children": [
11732
11732
  {
@@ -11760,7 +11760,7 @@
11760
11760
  "attrs": {
11761
11761
  "name": "group-1",
11762
11762
  "label": "Data Source",
11763
- "className": "col-6"
11763
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
11764
11764
  },
11765
11765
  "children": [
11766
11766
  {
@@ -12173,7 +12173,7 @@
12173
12173
  "attrs": {
12174
12174
  "name": "left-col",
12175
12175
  "label": "Interaction Details",
12176
- "className": "col-6"
12176
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
12177
12177
  },
12178
12178
  "children": [
12179
12179
  {
@@ -12214,7 +12214,7 @@
12214
12214
  "attrs": {
12215
12215
  "name": "right-col",
12216
12216
  "label": "Message Properties",
12217
- "className": "col-6"
12217
+ "className": "col-12 sm:col-12 md:col-6 lg:col-6"
12218
12218
  },
12219
12219
  "children": [
12220
12220
  {
@@ -0,0 +1,10 @@
1
+ import { IEntityPreComputeFieldProvider } from "../../../interfaces";
2
+ import { CommonEntity } from "src/entities/common.entity";
3
+ import { ComputedFieldMetadata } from "src/helpers/solid-registry";
4
+ export declare class UuidExternalIdEntityComputedFieldProvider implements IEntityPreComputeFieldProvider<CommonEntity, any, string> {
5
+ name(): string;
6
+ help(): string;
7
+ valueType(): string;
8
+ preComputeValue(triggerEntity: CommonEntity, computedFieldMetadata: ComputedFieldMetadata<any>): Promise<string>;
9
+ }
10
+ //# sourceMappingURL=uuid-externalid-entity-computed-field-provider.service.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"uuid-externalid-entity-computed-field-provider.service.d.ts","sourceRoot":"","sources":["../../../../src/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,8BAA8B,EAAE,MAAM,qBAAqB,CAAC;AACrE,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAC;AAC1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,4BAA4B,CAAC;AAGnE,qBAEa,yCACX,YAAW,8BAA8B,CAAC,YAAY,EAAE,GAAG,EAAE,MAAM,CAAC;IAEpE,IAAI,IAAI,MAAM;IAId,IAAI,IAAI,MAAM;IAId,SAAS,IAAI,MAAM;IAIb,eAAe,CACnB,aAAa,EAAE,YAAY,EAC3B,qBAAqB,EAAE,qBAAqB,CAAC,GAAG,CAAC,GAChD,OAAO,CAAC,MAAM,CAAC;CAMnB"}
@@ -0,0 +1,35 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.UuidExternalIdEntityComputedFieldProvider = void 0;
10
+ const uuid_1 = require("uuid");
11
+ const common_1 = require("@nestjs/common");
12
+ const computed_field_provider_decorator_1 = require("../../../decorators/computed-field-provider.decorator");
13
+ let UuidExternalIdEntityComputedFieldProvider = class UuidExternalIdEntityComputedFieldProvider {
14
+ name() {
15
+ return "UuidExternalIdEntityComputedFieldProvider";
16
+ }
17
+ help() {
18
+ return "Computed field provider used to compute the external id field as a UUID.";
19
+ }
20
+ valueType() {
21
+ return "string";
22
+ }
23
+ async preComputeValue(triggerEntity, computedFieldMetadata) {
24
+ const { computedFieldValueProviderCtxt } = computedFieldMetadata;
25
+ const prefix = computedFieldValueProviderCtxt?.prefix ?? "";
26
+ const generated = `${prefix}-${(0, uuid_1.v4)()}`;
27
+ return generated;
28
+ }
29
+ };
30
+ exports.UuidExternalIdEntityComputedFieldProvider = UuidExternalIdEntityComputedFieldProvider;
31
+ exports.UuidExternalIdEntityComputedFieldProvider = UuidExternalIdEntityComputedFieldProvider = __decorate([
32
+ (0, computed_field_provider_decorator_1.ComputedFieldProvider)(),
33
+ (0, common_1.Injectable)()
34
+ ], UuidExternalIdEntityComputedFieldProvider);
35
+ //# sourceMappingURL=uuid-externalid-entity-computed-field-provider.service.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"uuid-externalid-entity-computed-field-provider.service.js","sourceRoot":"","sources":["../../../../src/services/computed-fields/entity/uuid-externalid-entity-computed-field-provider.service.ts"],"names":[],"mappings":";;;;;;;;;AAAA,+BAAoC;AACpC,2CAA4C;AAI5C,6GAAyF;AAIlF,IAAM,yCAAyC,GAA/C,MAAM,yCAAyC;IAGpD,IAAI;QACF,OAAO,2CAA2C,CAAC;IACrD,CAAC;IAED,IAAI;QACF,OAAO,0EAA0E,CAAC;IACpF,CAAC;IAED,SAAS;QACP,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,KAAK,CAAC,eAAe,CACnB,aAA2B,EAC3B,qBAAiD;QAEjD,MAAM,EAAE,8BAA8B,EAAE,GAAG,qBAAqB,CAAC;QACjE,MAAM,MAAM,GAAG,8BAA8B,EAAE,MAAM,IAAI,EAAE,CAAC;QAC5D,MAAM,SAAS,GAAG,GAAG,MAAM,IAAI,IAAA,SAAM,GAAE,EAAE,CAAC;QAC1C,OAAO,SAAS,CAAC;IACnB,CAAC;CACF,CAAA;AAxBY,8FAAyC;oDAAzC,yCAAyC;IAFrD,IAAA,yDAAqB,GAAE;IACvB,IAAA,mBAAU,GAAE;GACA,yCAAyC,CAwBrD","sourcesContent":["import { v4 as uuidv4 } from \"uuid\";\nimport { Injectable } from \"@nestjs/common\";\nimport { IEntityPreComputeFieldProvider } from \"../../../interfaces\";\nimport { CommonEntity } from \"src/entities/common.entity\";\nimport { ComputedFieldMetadata } from \"src/helpers/solid-registry\";\nimport { ComputedFieldProvider } from \"src/decorators/computed-field-provider.decorator\";\n\n@ComputedFieldProvider()\n@Injectable()\nexport class UuidExternalIdEntityComputedFieldProvider\n implements IEntityPreComputeFieldProvider<CommonEntity, any, string>\n{\n name(): string {\n return \"UuidExternalIdEntityComputedFieldProvider\";\n }\n\n help(): string {\n return \"Computed field provider used to compute the external id field as a UUID.\";\n }\n\n valueType(): string {\n return \"string\";\n }\n\n async preComputeValue(\n triggerEntity: CommonEntity,\n computedFieldMetadata: ComputedFieldMetadata<any>\n ): Promise<string> {\n const { computedFieldValueProviderCtxt } = computedFieldMetadata;\n const prefix = computedFieldValueProviderCtxt?.prefix ?? \"\";\n const generated = `${prefix}-${uuidv4()}`;\n return generated;\n }\n}\n"]}
@@ -0,0 +1,16 @@
1
+ import { AiInteraction } from "src/entities/ai-interaction.entity";
2
+ import { IMcpToolResponseHandler } from "../../../interfaces";
3
+ import { SolidTsMorphService } from "src/services/solid-ts-morph.service";
4
+ export declare class SolidAddCustomServiceMethodMcpHandler implements IMcpToolResponseHandler {
5
+ private readonly tsMorph;
6
+ private readonly logger;
7
+ constructor(tsMorph: SolidTsMorphService);
8
+ apply(aiInteraction: AiInteraction): Promise<{
9
+ seedingRequired: boolean;
10
+ serverRebooting: boolean;
11
+ appliedSteps: number;
12
+ wroteFiles: number;
13
+ }>;
14
+ private safeParse;
15
+ }
16
+ //# sourceMappingURL=solid-add-custom-service-method-mcp-handler.service.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"solid-add-custom-service-method-mcp-handler.service.d.ts","sourceRoot":"","sources":["../../../../src/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAC;AACnE,OAAO,EAAE,uBAAuB,EAAyC,MAAM,qBAAqB,CAAC;AACrG,OAAO,EAAE,mBAAmB,EAAE,MAAM,qCAAqC,CAAC;AAI1E,qBACa,qCAAsC,YAAW,uBAAuB;IAGvE,OAAO,CAAC,QAAQ,CAAC,OAAO;IAFpC,OAAO,CAAC,QAAQ,CAAC,MAAM,CAA0D;gBAEpD,OAAO,EAAE,mBAAmB;IAEnD,KAAK,CAAC,aAAa,EAAE,aAAa;;;;;;IA+CxC,OAAO,CAAC,SAAS;CAQlB"}
@@ -0,0 +1,74 @@
1
+ "use strict";
2
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
6
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
7
+ };
8
+ var __metadata = (this && this.__metadata) || function (k, v) {
9
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
+ };
11
+ var SolidAddCustomServiceMethodMcpHandler_1;
12
+ Object.defineProperty(exports, "__esModule", { value: true });
13
+ exports.SolidAddCustomServiceMethodMcpHandler = void 0;
14
+ const common_1 = require("@nestjs/common");
15
+ const solid_ts_morph_service_1 = require("../../solid-ts-morph.service");
16
+ const RESTART_TOUCH_FILE = process.env.MCP_RESTART_TOUCH_FILE || "tmp/restart.touch";
17
+ let SolidAddCustomServiceMethodMcpHandler = SolidAddCustomServiceMethodMcpHandler_1 = class SolidAddCustomServiceMethodMcpHandler {
18
+ constructor(tsMorph) {
19
+ this.tsMorph = tsMorph;
20
+ this.logger = new common_1.Logger(SolidAddCustomServiceMethodMcpHandler_1.name);
21
+ }
22
+ async apply(aiInteraction) {
23
+ const raw = this.safeParse(aiInteraction.message);
24
+ const payload = (raw?.data?.plan ? raw.data : raw);
25
+ if (!payload || !Array.isArray(payload.plan)) {
26
+ throw new Error("SolidAddCustomServiceMethodMcpHandler: invalid MCP response; missing plan[]");
27
+ }
28
+ this.tsMorph.begin();
29
+ try {
30
+ for (const step of payload.plan) {
31
+ switch (step.type) {
32
+ case "createNewFile": {
33
+ const overwrite = step.overwrite ?? false;
34
+ this.tsMorph.createNewFile(step.path, step.content, overwrite);
35
+ break;
36
+ }
37
+ case "addMethodToExistingClass": {
38
+ this.tsMorph.addMethodToExistingClass(step.path, step.className, step.methodName, step.content);
39
+ break;
40
+ }
41
+ default:
42
+ throw new Error(`Unsupported plan step type: ${step.type}`);
43
+ }
44
+ }
45
+ const result = await this.tsMorph.commit();
46
+ return {
47
+ seedingRequired: false,
48
+ serverRebooting: true,
49
+ appliedSteps: payload.plan.length,
50
+ wroteFiles: result.wrote,
51
+ };
52
+ }
53
+ catch (err) {
54
+ this.logger.error(`Apply failed; rolling back. ${String(err)}`);
55
+ this.tsMorph.rollback();
56
+ throw err;
57
+ }
58
+ }
59
+ safeParse(str) {
60
+ try {
61
+ return JSON.parse(str);
62
+ }
63
+ catch {
64
+ const unescaped = str.replace(/\\'/g, "'");
65
+ return JSON.parse(unescaped);
66
+ }
67
+ }
68
+ };
69
+ exports.SolidAddCustomServiceMethodMcpHandler = SolidAddCustomServiceMethodMcpHandler;
70
+ exports.SolidAddCustomServiceMethodMcpHandler = SolidAddCustomServiceMethodMcpHandler = SolidAddCustomServiceMethodMcpHandler_1 = __decorate([
71
+ (0, common_1.Injectable)(),
72
+ __metadata("design:paramtypes", [solid_ts_morph_service_1.SolidTsMorphService])
73
+ ], SolidAddCustomServiceMethodMcpHandler);
74
+ //# sourceMappingURL=solid-add-custom-service-method-mcp-handler.service.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"solid-add-custom-service-method-mcp-handler.service.js","sourceRoot":"","sources":["../../../../src/services/genai/mcp-handlers/solid-add-custom-service-method-mcp-handler.service.ts"],"names":[],"mappings":";;;;;;;;;;;;;AAAA,2CAAoD;AAGpD,yEAA0E;AAE1E,MAAM,kBAAkB,GAAG,OAAO,CAAC,GAAG,CAAC,sBAAsB,IAAI,mBAAmB,CAAC;AAG9E,IAAM,qCAAqC,6CAA3C,MAAM,qCAAqC;IAGhD,YAA6B,OAA4B;QAA5B,YAAO,GAAP,OAAO,CAAqB;QAFxC,WAAM,GAAG,IAAI,eAAM,CAAC,uCAAqC,CAAC,IAAI,CAAC,CAAC;IAEpB,CAAC;IAE9D,KAAK,CAAC,KAAK,CAAC,aAA4B;QACtC,MAAM,GAAG,GAAG,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC,OAAO,CAAC,CAAC;QAClD,MAAM,OAAO,GAA4C,CAAC,GAAG,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,GAAG,CAAgC,CAAC;QAE3H,IAAI,CAAC,OAAO,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC;YAC7C,MAAM,IAAI,KAAK,CAAC,6EAA6E,CAAC,CAAC;QACjG,CAAC;QAGD,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC;QACrB,IAAI,CAAC;YACH,KAAK,MAAM,IAAI,IAAI,OAAO,CAAC,IAAkB,EAAE,CAAC;gBAC9C,QAAQ,IAAI,CAAC,IAAI,EAAE,CAAC;oBAClB,KAAK,eAAe,CAAC,CAAC,CAAC;wBACrB,MAAM,SAAS,GAAG,IAAI,CAAC,SAAS,IAAI,KAAK,CAAC;wBAC1C,IAAI,CAAC,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;wBAC/D,MAAM;oBACR,CAAC;oBACD,KAAK,0BAA0B,CAAC,CAAC,CAAC;wBAChC,IAAI,CAAC,OAAO,CAAC,wBAAwB,CACnC,IAAI,CAAC,IAAI,EACT,IAAI,CAAC,SAAS,EACd,IAAI,CAAC,UAAU,EACf,IAAI,CAAC,OAAO,CACb,CAAC;wBACF,MAAM;oBACR,CAAC;oBACD;wBACE,MAAM,IAAI,KAAK,CAAC,+BAAgC,IAAY,CAAC,IAAI,EAAE,CAAC,CAAC;gBACzE,CAAC;YACH,CAAC;YAED,MAAM,MAAM,GAAG,MAAM,IAAI,CAAC,OAAO,CAAC,MAAM,EAAE,CAAC;YAE3C,OAAO;gBACL,eAAe,EAAE,KAAK;gBACtB,eAAe,EAAE,IAAI;gBACrB,YAAY,EAAE,OAAO,CAAC,IAAI,CAAC,MAAM;gBACjC,UAAU,EAAE,MAAM,CAAC,KAAK;aACzB,CAAC;QACJ,CAAC;QAAC,OAAO,GAAG,EAAE,CAAC;YACb,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,+BAA+B,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;YAChE,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,CAAC;YACxB,MAAM,GAAG,CAAC;QACZ,CAAC;IACH,CAAC;IAEO,SAAS,CAAC,GAAW;QAC3B,IAAI,CAAC;YACH,OAAO,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;QACzB,CAAC;QAAC,MAAM,CAAC;YACP,MAAM,SAAS,GAAG,GAAG,CAAC,OAAO,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;YAC3C,OAAO,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;QAC/B,CAAC;IACH,CAAC;CACF,CAAA;AA5DY,sFAAqC;gDAArC,qCAAqC;IADjD,IAAA,mBAAU,GAAE;qCAI2B,4CAAmB;GAH9C,qCAAqC,CA4DjD","sourcesContent":["import { Injectable, Logger } from \"@nestjs/common\";\nimport { AiInteraction } from \"src/entities/ai-interaction.entity\";\nimport { IMcpToolResponseHandler, McpComputedProviderResponse, PlanStep } from \"../../../interfaces\";\nimport { SolidTsMorphService } from \"src/services/solid-ts-morph.service\";\n\nconst RESTART_TOUCH_FILE = process.env.MCP_RESTART_TOUCH_FILE || \"tmp/restart.touch\";\n\n@Injectable()\nexport class SolidAddCustomServiceMethodMcpHandler implements IMcpToolResponseHandler {\n private readonly logger = new Logger(SolidAddCustomServiceMethodMcpHandler.name);\n\n constructor(private readonly tsMorph: SolidTsMorphService) { }\n\n async apply(aiInteraction: AiInteraction) {\n const raw = this.safeParse(aiInteraction.message);\n const payload: McpComputedProviderResponse | undefined = (raw?.data?.plan ? raw.data : raw) as McpComputedProviderResponse;\n\n if (!payload || !Array.isArray(payload.plan)) {\n throw new Error(\"SolidAddCustomServiceMethodMcpHandler: invalid MCP response; missing plan[]\");\n }\n\n // Batch all plan steps in a single txn so nodemon restarts only once.\n this.tsMorph.begin();\n try {\n for (const step of payload.plan as PlanStep[]) {\n switch (step.type) {\n case \"createNewFile\": {\n const overwrite = step.overwrite ?? false;\n this.tsMorph.createNewFile(step.path, step.content, overwrite);\n break;\n }\n case \"addMethodToExistingClass\": {\n this.tsMorph.addMethodToExistingClass(\n step.path,\n step.className,\n step.methodName,\n step.content,\n );\n break;\n }\n default:\n throw new Error(`Unsupported plan step type: ${(step as any).type}`);\n }\n }\n\n const result = await this.tsMorph.commit();\n\n return {\n seedingRequired: false,\n serverRebooting: true,\n appliedSteps: payload.plan.length,\n wroteFiles: result.wrote,\n };\n } catch (err) {\n this.logger.error(`Apply failed; rolling back. ${String(err)}`);\n this.tsMorph.rollback();\n throw err;\n }\n }\n\n private safeParse(str: string): any {\n try {\n return JSON.parse(str);\n } catch {\n const unescaped = str.replace(/\\\\'/g, \"'\");\n return JSON.parse(unescaped);\n }\n }\n}"]}
@@ -701,12 +701,12 @@ let ModelMetadataService = class ModelMetadataService {
701
701
  children: [
702
702
  {
703
703
  type: "column",
704
- attrs: { name: "group-1", label: "", className: "col-6" },
704
+ attrs: { name: "group-1", label: "", className: "col-12 sm:col-12 md:col-6 lg:col-6" },
705
705
  children: column1Fields
706
706
  },
707
707
  {
708
708
  type: "column",
709
- attrs: { name: "group-2", label: "", className: "col-6" },
709
+ attrs: { name: "group-2", label: "", className: "col-12 sm:col-12 md:col-6 lg:col-6" },
710
710
  children: column2Fields
711
711
  }
712
712
  ]
@@ -796,12 +796,12 @@ let ModelMetadataService = class ModelMetadataService {
796
796
  children: [
797
797
  {
798
798
  type: "column",
799
- attrs: { name: "group-1", label: "", className: "col-6" },
799
+ attrs: { name: "group-1", label: "", className: "col-12 sm:col-12 md:col-6 lg:col-6" },
800
800
  children: firstHalf
801
801
  },
802
802
  {
803
803
  type: "column",
804
- attrs: { name: "group-2", label: "", className: "col-6" },
804
+ attrs: { name: "group-2", label: "", className: "col-12 sm:col-12 md:col-6 lg:col-6" },
805
805
  children: secondHalf
806
806
  }
807
807
  ]