@rxap/schematics-ts-morph 18.0.3-dev.0 → 18.0.3-dev.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +4 -0
- package/package.json +8 -8
- package/src/index.d.ts +0 -3
- package/src/index.js +0 -3
- package/src/index.js.map +1 -1
- package/src/lib/nest/coerce-autocomplete-options-operation.d.ts +2 -2
- package/src/lib/nest/coerce-autocomplete-options-operation.js.map +1 -1
- package/src/lib/nest/coerce-form-submit-operation.js +1 -1
- package/src/lib/nest/coerce-form-submit-operation.js.map +1 -1
- package/src/lib/nest/coerce-get-by-id-operation.d.ts +2 -2
- package/src/lib/nest/coerce-get-by-id-operation.js +7 -7
- package/src/lib/nest/coerce-get-by-id-operation.js.map +1 -1
- package/src/lib/nest/coerce-get-operation.d.ts +1 -1
- package/src/lib/nest/coerce-get-operation.js.map +1 -1
- package/src/lib/nest/coerce-get-page-operation.d.ts +4 -5
- package/src/lib/nest/coerce-get-page-operation.js +4 -3
- package/src/lib/nest/coerce-get-page-operation.js.map +1 -1
- package/src/lib/nest/coerce-get-root-operation.d.ts +2 -3
- package/src/lib/nest/coerce-get-root-operation.js +1 -1
- package/src/lib/nest/coerce-get-root-operation.js.map +1 -1
- package/src/lib/nest/coerce-operation.d.ts +3 -45
- package/src/lib/nest/coerce-operation.js +3 -201
- package/src/lib/nest/coerce-operation.js.map +1 -1
- package/src/lib/nest/coerce-options-operation.d.ts +3 -3
- package/src/lib/nest/coerce-options-operation.js.map +1 -1
- package/src/lib/nest/coerce-page-dto-class.d.ts +2 -2
- package/src/lib/nest/coerce-page-dto-class.js +2 -2
- package/src/lib/nest/coerce-page-dto-class.js.map +1 -1
- package/src/lib/nest/coerce-row-dto-class.d.ts +2 -2
- package/src/lib/nest/coerce-row-dto-class.js +2 -2
- package/src/lib/nest/coerce-row-dto-class.js.map +1 -1
- package/src/lib/nest/coerce-table-select-value-resolve-operation.d.ts +2 -2
- package/src/lib/nest/table-query-list.d.ts +1 -1
- package/src/lib/nest/add-operation-to-controller.d.ts +0 -41
- package/src/lib/nest/add-operation-to-controller.js +0 -238
- package/src/lib/nest/add-operation-to-controller.js.map +0 -1
- package/src/lib/nest/coerce-dto-class.d.ts +0 -16
- package/src/lib/nest/coerce-dto-class.js +0 -228
- package/src/lib/nest/coerce-dto-class.js.map +0 -1
- package/src/lib/nest/dto-class-property.d.ts +0 -11
- package/src/lib/nest/dto-class-property.js +0 -30
- package/src/lib/nest/dto-class-property.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,10 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [18.0.3-dev.1](https://gitlab.com/rxap/packages/compare/@rxap/schematics-ts-morph@18.0.3-dev.0...@rxap/schematics-ts-morph@18.0.3-dev.1) (2024-06-04)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @rxap/schematics-ts-morph
|
|
9
|
+
|
|
6
10
|
## [18.0.3-dev.0](https://gitlab.com/rxap/packages/compare/@rxap/schematics-ts-morph@18.0.2...@rxap/schematics-ts-morph@18.0.3-dev.0) (2024-06-03)
|
|
7
11
|
|
|
8
12
|
**Note:** Version bump only for package @rxap/schematics-ts-morph
|
package/package.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"version": "18.0.3-dev.
|
|
2
|
+
"version": "18.0.3-dev.1",
|
|
3
3
|
"name": "@rxap/schematics-ts-morph",
|
|
4
4
|
"license": "GPL-3.0-or-later",
|
|
5
5
|
"dependencies": {
|
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
"@angular-devkit/core": "^18.0.2",
|
|
12
12
|
"@angular-devkit/schematics": "^18.0.2",
|
|
13
13
|
"@rxap/schematics-utilities": "^18.0.1",
|
|
14
|
-
"@rxap/ts-morph": "^1.
|
|
14
|
+
"@rxap/ts-morph": "^1.3.0",
|
|
15
15
|
"@rxap/utilities": "^16.2.2",
|
|
16
|
-
"@rxap/workspace-ts-morph": "^19.0.
|
|
17
|
-
"@rxap/workspace-utilities": "^19.0.1",
|
|
16
|
+
"@rxap/workspace-ts-morph": "^19.0.2",
|
|
17
|
+
"@rxap/workspace-utilities": "^19.2.0-dev.1",
|
|
18
18
|
"ts-morph": "^18.0.0"
|
|
19
19
|
},
|
|
20
20
|
"author": {
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
},
|
|
47
47
|
{
|
|
48
48
|
"package": "@rxap/ts-morph",
|
|
49
|
-
"version": "1.
|
|
49
|
+
"version": "1.3.0"
|
|
50
50
|
},
|
|
51
51
|
{
|
|
52
52
|
"package": "@rxap/utilities",
|
|
@@ -54,11 +54,11 @@
|
|
|
54
54
|
},
|
|
55
55
|
{
|
|
56
56
|
"package": "@rxap/workspace-ts-morph",
|
|
57
|
-
"version": "19.0.
|
|
57
|
+
"version": "19.0.2"
|
|
58
58
|
},
|
|
59
59
|
{
|
|
60
60
|
"package": "@rxap/workspace-utilities",
|
|
61
|
-
"version": "19.0.1"
|
|
61
|
+
"version": "19.2.0-dev.1"
|
|
62
62
|
}
|
|
63
63
|
]
|
|
64
64
|
},
|
|
@@ -72,6 +72,6 @@
|
|
|
72
72
|
"directory": "packages/schematic/ts-morph"
|
|
73
73
|
},
|
|
74
74
|
"type": "commonjs",
|
|
75
|
-
"gitHead": "
|
|
75
|
+
"gitHead": "ae79ca2aed680609ef2b560fe7528fb03ec87756",
|
|
76
76
|
"main": "./src/index.js"
|
|
77
77
|
}
|
package/src/index.d.ts
CHANGED
|
@@ -17,13 +17,11 @@ export * from './lib/nest/add-nest-module-import';
|
|
|
17
17
|
export * from './lib/nest/add-nest-module-provider';
|
|
18
18
|
export * from './lib/nest/add-nest-module-to-app-module';
|
|
19
19
|
export * from './lib/nest/add-nest-provider-to-array';
|
|
20
|
-
export * from './lib/nest/add-operation-to-controller';
|
|
21
20
|
export * from './lib/nest/assert-nest-project';
|
|
22
21
|
export * from './lib/nest/build-nest-base-path';
|
|
23
22
|
export * from './lib/nest/build-nest-controller-name';
|
|
24
23
|
export * from './lib/nest/coerce-autocomplete-options-operation';
|
|
25
24
|
export * from './lib/nest/coerce-autocomplete-table-select-value-resolve-operation';
|
|
26
|
-
export * from './lib/nest/coerce-dto-class';
|
|
27
25
|
export * from './lib/nest/coerce-form-submit-operation';
|
|
28
26
|
export * from './lib/nest/coerce-get-by-id-operation';
|
|
29
27
|
export * from './lib/nest/coerce-get-children-operation';
|
|
@@ -42,7 +40,6 @@ export * from './lib/nest/coerce-submit-data-grid-operation';
|
|
|
42
40
|
export * from './lib/nest/coerce-table-select-operation';
|
|
43
41
|
export * from './lib/nest/coerce-table-select-value-resolve-operation';
|
|
44
42
|
export * from './lib/nest/coerce-tree-operation';
|
|
45
|
-
export * from './lib/nest/dto-class-property';
|
|
46
43
|
export * from './lib/nest/find-nest-module-declaration';
|
|
47
44
|
export * from './lib/nest/find-nest-module-source-file';
|
|
48
45
|
export * from './lib/nest/get-nest-module-metadata';
|
package/src/index.js
CHANGED
|
@@ -25,13 +25,11 @@ tslib_1.__exportStar(require("./lib/nest/add-nest-module-import"), exports);
|
|
|
25
25
|
tslib_1.__exportStar(require("./lib/nest/add-nest-module-provider"), exports);
|
|
26
26
|
tslib_1.__exportStar(require("./lib/nest/add-nest-module-to-app-module"), exports);
|
|
27
27
|
tslib_1.__exportStar(require("./lib/nest/add-nest-provider-to-array"), exports);
|
|
28
|
-
tslib_1.__exportStar(require("./lib/nest/add-operation-to-controller"), exports);
|
|
29
28
|
tslib_1.__exportStar(require("./lib/nest/assert-nest-project"), exports);
|
|
30
29
|
tslib_1.__exportStar(require("./lib/nest/build-nest-base-path"), exports);
|
|
31
30
|
tslib_1.__exportStar(require("./lib/nest/build-nest-controller-name"), exports);
|
|
32
31
|
tslib_1.__exportStar(require("./lib/nest/coerce-autocomplete-options-operation"), exports);
|
|
33
32
|
tslib_1.__exportStar(require("./lib/nest/coerce-autocomplete-table-select-value-resolve-operation"), exports);
|
|
34
|
-
tslib_1.__exportStar(require("./lib/nest/coerce-dto-class"), exports);
|
|
35
33
|
tslib_1.__exportStar(require("./lib/nest/coerce-form-submit-operation"), exports);
|
|
36
34
|
tslib_1.__exportStar(require("./lib/nest/coerce-get-by-id-operation"), exports);
|
|
37
35
|
tslib_1.__exportStar(require("./lib/nest/coerce-get-children-operation"), exports);
|
|
@@ -50,7 +48,6 @@ tslib_1.__exportStar(require("./lib/nest/coerce-submit-data-grid-operation"), ex
|
|
|
50
48
|
tslib_1.__exportStar(require("./lib/nest/coerce-table-select-operation"), exports);
|
|
51
49
|
tslib_1.__exportStar(require("./lib/nest/coerce-table-select-value-resolve-operation"), exports);
|
|
52
50
|
tslib_1.__exportStar(require("./lib/nest/coerce-tree-operation"), exports);
|
|
53
|
-
tslib_1.__exportStar(require("./lib/nest/dto-class-property"), exports);
|
|
54
51
|
tslib_1.__exportStar(require("./lib/nest/find-nest-module-declaration"), exports);
|
|
55
52
|
tslib_1.__exportStar(require("./lib/nest/find-nest-module-source-file"), exports);
|
|
56
53
|
tslib_1.__exportStar(require("./lib/nest/get-nest-module-metadata"), exports);
|
package/src/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../packages/schematic/ts-morph/src/index.ts"],"names":[],"mappings":";;;AAAA,eAAe;AACf,uEAA6C;AAC7C,YAAY;AAEZ,kBAAkB;AAClB,gFAAsD;AACtD,qFAA2D;AAC3D,+EAAqD;AACrD,0EAAgD;AAChD,yEAA+C;AAC/C,wEAA8C;AAC9C,0EAAgD;AAChD,sFAA4D;AAC5D,2EAAiD;AACjD,2EAAiD;AACjD,uEAA6C;AAC7C,oEAA0C;AAC1C,YAAY;AAEZ,cAAc;AACd,yEAA+C;AAC/C,gFAAsD;AACtD,4EAAkD;AAClD,8EAAoD;AACpD,mFAAyD;AACzD,gFAAsD;AACtD,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../packages/schematic/ts-morph/src/index.ts"],"names":[],"mappings":";;;AAAA,eAAe;AACf,uEAA6C;AAC7C,YAAY;AAEZ,kBAAkB;AAClB,gFAAsD;AACtD,qFAA2D;AAC3D,+EAAqD;AACrD,0EAAgD;AAChD,yEAA+C;AAC/C,wEAA8C;AAC9C,0EAAgD;AAChD,sFAA4D;AAC5D,2EAAiD;AACjD,2EAAiD;AACjD,uEAA6C;AAC7C,oEAA0C;AAC1C,YAAY;AAEZ,cAAc;AACd,yEAA+C;AAC/C,gFAAsD;AACtD,4EAAkD;AAClD,8EAAoD;AACpD,mFAAyD;AACzD,gFAAsD;AACtD,yEAA+C;AAC/C,0EAAgD;AAChD,gFAAsD;AACtD,2FAAiE;AACjE,8GAAoF;AACpF,kFAAwD;AACxD,gFAAsD;AACtD,mFAAyD;AACzD,oFAA0D;AAC1D,0EAAgD;AAChD,+EAAqD;AACrD,+EAAqD;AACrD,4EAAkD;AAClD,wEAA8C;AAC9C,iFAAuD;AACvD,sEAA4C;AAC5C,8EAAoD;AACpD,2EAAiD;AACjD,0EAAgD;AAChD,uFAA6D;AAC7D,mFAAyD;AACzD,iGAAuE;AACvE,2EAAiD;AACjD,kFAAwD;AACxD,kFAAwD;AACxD,8EAAoD;AACpD,yEAA+C;AAC/C,2EAAiD;AACjD,qEAA2C;AAC3C,0EAAgD;AAChD,0EAAgD;AAChD,4EAAkD;AAClD,iFAAuD;AACvD,mFAAyD;AACzD,sEAA4C;AAC5C,YAAY;AAEZ,iBAAiB;AACjB,iFAAuD;AACvD,oFAA0D;AAC1D,6EAAmD;AACnD,4EAAkD;AAClD,+EAAqD;AACrD,8EAAoD;AACpD,iFAAuD;AACvD,6EAAmD;AACnD,6EAAmD;AACnD,+EAAqD;AACrD,gFAAsD;AACtD,mFAAyD;AACzD,+EAAqD;AACrD,yEAA+C;AAC/C,iFAAuD;AACvD,gFAAsD;AACtD,6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2
2
|
import { NormalizedDataProperty } from '@rxap/ts-morph';
|
|
3
3
|
import { ClassDeclaration, SourceFile, WriterFunction } from 'ts-morph';
|
|
4
|
-
import { CoerceDtoClassOutput } from '
|
|
5
|
-
import { CoerceOperationOptions
|
|
4
|
+
import { CoerceDtoClassOutput, TransformOperation } from '@rxap/ts-morph';
|
|
5
|
+
import { CoerceOperationOptions } from './coerce-operation';
|
|
6
6
|
export interface CoerceAutocompleteOptionsOperationRuleOptions extends CoerceOperationOptions {
|
|
7
7
|
toDisplayProperty: NormalizedDataProperty;
|
|
8
8
|
toValueProperty: NormalizedDataProperty;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-autocomplete-options-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-autocomplete-options-operation.ts"],"names":[],"mappings":";;;AACA,6CAGwB;AACxB,+CAAmD;AACnD,uCAKkB;AAElB,
|
|
1
|
+
{"version":3,"file":"coerce-autocomplete-options-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-autocomplete-options-operation.ts"],"names":[],"mappings":";;;AACA,6CAGwB;AACxB,+CAAmD;AACnD,uCAKkB;AAElB,yDAG4B;AAO5B,SAAgB,mDAAmD,CACjE,gBAAkC,EAClC,gBAA4B,EAC5B,GAAgC,EAChC,OAAgE;IAEhE,MAAM,EACJ,OAAO,GACR,GAAG,OAAO,CAAC;IACZ,OAAO,GAAG,EAAE;QACV,MAAM,EAAE,QAAQ,EAAE,eAAe,EAAE,iBAAiB,EAAE,GAAG,OAAO,CAAC;QACjE,IAAI,QAAQ,IAAI,IAAA,6CAAkC,EAAC,QAAQ,CAAC,EAAE,CAAC;YAC7D,OAAO,CAAC,CAAC,EAAE;gBACT,CAAC,CAAC,KAAK,CAAC,sCAAsC,CAAC,CAAC;gBAChD,CAAC,CAAC,MAAM,CAAC,GAAG,EAAE;oBACZ,CAAC,CAAC,SAAS,CAAC,eAAe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AAK,CAAC,MAAM,CAAC;oBAC3B,IAAI,EAAE,GAAG;oBACT,IAAI,EAAE,IAAI;iBACX,CAAC;aACH,CAAC,CAAC;QACL,CAAC;QACD,OAAO,EAAE,CAAC;IACZ,CAAC,CAAC;AACJ,CAAC;AAzBD,kIAyBC;AAED,SAAgB,sCAAsC,CAAC,OAAgE;IACrH,MAAM,EACJ,gCAAgC,GAAG,mDAAmD,EACtF,wCAAwC,GAAG,2DAA2D,EACtG,OAAO,GAAG,IAAI,EACd,YAAY,GAAG,EAAE,EACjB,SAAS,GAAG,EAAE,GACf,GAAG,OAAO,CAAC;IACZ,IAAA,4BAAgB,EAAC,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,QAAQ,EAAE,gBAAgB,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC;IACvH,IAAA,4BAAgB,EAAC,YAAY,EAAE;wCAExB,OAAO,CAAC,eAAe,KAC1B,IAAI,EAAE,OAAO,EACb,MAAM,EAAE,OAAO,CAAC,eAAe,CAAC,IAAI;wCAGjC,OAAO,CAAC,iBAAiB,KAC5B,IAAI,EAAE,SAAS,EACf,MAAM,EAAE,OAAO,CAAC,iBAAiB,CAAC,IAAI;KAEzC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,IAAI,CAAC,CAAC;IAChC,OAAO,IAAA,kCAAe,kCACjB,OAAO,KACV,YAAY;QACZ,OAAO;QACP,SAAS;QACT,wCAAwC;QACxC,gCAAgC,IAChC,CAAC;AACL,CAAC;AA7BD,wFA6BC"}
|
|
@@ -16,7 +16,7 @@ function CoerceFormSubmitOperation(options) {
|
|
|
16
16
|
if (!dto) {
|
|
17
17
|
throw new Error('The dto must be created for an submit operation');
|
|
18
18
|
}
|
|
19
|
-
return Object.assign({ body: dto.className, method: 'post' }, tsMorphTransform(project, sourceFile, classDeclaration, controllerName, moduleSourceFile, dto));
|
|
19
|
+
return Object.assign({ body: dto.className, method: 'post' }, tsMorphTransform(project, sourceFile, classDeclaration, controllerName, moduleSourceFile, dto, options));
|
|
20
20
|
} }));
|
|
21
21
|
}
|
|
22
22
|
exports.CoerceFormSubmitOperation = CoerceFormSubmitOperation;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-form-submit-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-form-submit-operation.ts"],"names":[],"mappings":";;;AAAA,+CAGyB;AACzB,6EAGsC;AAMtC,SAAgB,yBAAyB,CAAC,OAAyC;IACjF,MAAM,EACJ,gBAAgB,GAAG,gBAAI,EACvB,WAAW,EACX,YAAY,GAAG,IAAI;IACnB,qGAAqG;IACrG,UAAU,GAAG,IAAI,EACjB,aAAa,GAAG,UAAU,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,QAAQ,EACpD,kBAAkB,GAAG,SAAS,GAC/B,GAAG,OAAO,CAAC;IAEZ,OAAO,IAAA,mDAAsB,kCACxB,OAAO,KACV,aAAa;QACb,YAAY;QACZ,UAAU;QACV,kBAAkB,EAClB,0BAA0B,EAAE,CAAC,cAAc,EAAE,EAAE,YAAY,EAAE,kBAAkB,GAAG,SAAS,EAAE,EAAE,EAAE;YAC/F,OAAO,YAAY,aAAZ,YAAY,cAAZ,YAAY,GAAI,IAAA,wBAAY,EAAC,WAAW,aAAX,WAAW,cAAX,WAAW,GAAI,cAAc,EAAE,kBAAkB,CAAC,CAAC;QACzF,CAAC,EACD,gBAAgB,EAAE,CAChB,OAAO,EACP,UAAU,EACV,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,GAAG,EACH,EAAE;YAEF,IAAI,CAAC,GAAG,EAAE,CAAC;gBACT,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;YACrE,CAAC;YAED,uBACE,IAAI,EAAE,GAAG,CAAC,SAAS,EACnB,MAAM,EAAE,MAAM,IACX,gBAAiB,CAAC,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,cAAc,EAAE,gBAAgB,EAAE,GAAG,CAAC,
|
|
1
|
+
{"version":3,"file":"coerce-form-submit-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-form-submit-operation.ts"],"names":[],"mappings":";;;AAAA,+CAGyB;AACzB,6EAGsC;AAMtC,SAAgB,yBAAyB,CAAC,OAAyC;IACjF,MAAM,EACJ,gBAAgB,GAAG,gBAAI,EACvB,WAAW,EACX,YAAY,GAAG,IAAI;IACnB,qGAAqG;IACrG,UAAU,GAAG,IAAI,EACjB,aAAa,GAAG,UAAU,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,CAAC,QAAQ,EACpD,kBAAkB,GAAG,SAAS,GAC/B,GAAG,OAAO,CAAC;IAEZ,OAAO,IAAA,mDAAsB,kCACxB,OAAO,KACV,aAAa;QACb,YAAY;QACZ,UAAU;QACV,kBAAkB,EAClB,0BAA0B,EAAE,CAAC,cAAc,EAAE,EAAE,YAAY,EAAE,kBAAkB,GAAG,SAAS,EAAE,EAAE,EAAE;YAC/F,OAAO,YAAY,aAAZ,YAAY,cAAZ,YAAY,GAAI,IAAA,wBAAY,EAAC,WAAW,aAAX,WAAW,cAAX,WAAW,GAAI,cAAc,EAAE,kBAAkB,CAAC,CAAC;QACzF,CAAC,EACD,gBAAgB,EAAE,CAChB,OAAO,EACP,UAAU,EACV,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,GAAG,EACH,EAAE;YAEF,IAAI,CAAC,GAAG,EAAE,CAAC;gBACT,MAAM,IAAI,KAAK,CAAC,iDAAiD,CAAC,CAAC;YACrE,CAAC;YAED,uBACE,IAAI,EAAE,GAAG,CAAC,SAAS,EACnB,MAAM,EAAE,MAAM,IACX,gBAAiB,CAAC,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,cAAc,EAAE,gBAAgB,EAAE,GAAG,EAAE,OAAO,CAAC,EAC3G;QAEJ,CAAC,IACD,CAAC;AAEL,CAAC;AA1CD,8DA0CC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { OperationParameter } from '@rxap/ts-morph';
|
|
2
2
|
import { ClassDeclaration, SourceFile, WriterFunction } from 'ts-morph';
|
|
3
|
-
import { CoerceDtoClassOutput } from '
|
|
3
|
+
import { CoerceDtoClassOutput } from '@rxap/ts-morph';
|
|
4
4
|
import { CoerceGetControllerOptions } from './coerce-get-operation';
|
|
5
|
-
import { TransformOperation } from '
|
|
5
|
+
import { TransformOperation } from '@rxap/ts-morph';
|
|
6
6
|
export interface CoerceGetByIdControllerOptions extends CoerceGetControllerOptions {
|
|
7
7
|
idProperty?: OperationParameter | null;
|
|
8
8
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.CoerceGetByIdOperation = exports.BuiltGetByIdDtoDataMapperImplementation = exports.BuildUpstreamGetByIdParametersImplementation = void 0;
|
|
4
|
+
const ts_morph_1 = require("@rxap/ts-morph");
|
|
4
5
|
const utilities_1 = require("@rxap/utilities");
|
|
5
|
-
const
|
|
6
|
+
const ts_morph_2 = require("ts-morph");
|
|
6
7
|
const coerce_get_operation_1 = require("./coerce-get-operation");
|
|
7
|
-
const dto_class_property_1 = require("./dto-class-property");
|
|
8
8
|
function BuildUpstreamGetByIdParametersImplementation(classDeclaration, moduleSourceFile, dto, options) {
|
|
9
9
|
return () => {
|
|
10
10
|
const { idProperty } = options;
|
|
@@ -18,7 +18,7 @@ function UpstreamMapper(sourceProperty, propertyList, idProperty) {
|
|
|
18
18
|
if (idProperty) {
|
|
19
19
|
mapper[idProperty.name] = idProperty.name;
|
|
20
20
|
}
|
|
21
|
-
for (const property of propertyList.filter(p => !idProperty || p.name !== idProperty.name).map(p => (0,
|
|
21
|
+
for (const property of propertyList.filter(p => !idProperty || p.name !== idProperty.name).map(p => (0, ts_morph_1.NormalizeDataClassProperty)(p))) {
|
|
22
22
|
mapper[property.name] = `${sourceProperty}.${(_a = property.source) !== null && _a !== void 0 ? _a : property.name}`;
|
|
23
23
|
if (property.isType) {
|
|
24
24
|
// property is a complex object
|
|
@@ -26,12 +26,12 @@ function UpstreamMapper(sourceProperty, propertyList, idProperty) {
|
|
|
26
26
|
mapper[property.name] = w => {
|
|
27
27
|
var _a;
|
|
28
28
|
w.write(`${sourceProperty}.${(_a = property.source) !== null && _a !== void 0 ? _a : property.name}.map(item => (`);
|
|
29
|
-
|
|
29
|
+
ts_morph_2.Writers.object(UpstreamMapper('item', property.memberList))(w);
|
|
30
30
|
w.write('))');
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
33
|
else {
|
|
34
|
-
mapper[property.name] =
|
|
34
|
+
mapper[property.name] = ts_morph_2.Writers.object(UpstreamMapper(mapper[property.name], property.memberList));
|
|
35
35
|
}
|
|
36
36
|
}
|
|
37
37
|
}
|
|
@@ -44,12 +44,12 @@ function BuiltGetByIdDtoDataMapperImplementation(classDeclaration, moduleSourceF
|
|
|
44
44
|
if (isArray) {
|
|
45
45
|
return w => {
|
|
46
46
|
w.write('data.map(item => (');
|
|
47
|
-
|
|
47
|
+
ts_morph_2.Writers.object(UpstreamMapper('data', propertyList, idProperty))(w);
|
|
48
48
|
w.write('))');
|
|
49
49
|
};
|
|
50
50
|
}
|
|
51
51
|
else {
|
|
52
|
-
return
|
|
52
|
+
return ts_morph_2.Writers.object(UpstreamMapper('data', propertyList, idProperty));
|
|
53
53
|
}
|
|
54
54
|
}
|
|
55
55
|
else {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-get-by-id-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-by-id-operation.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"coerce-get-by-id-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-by-id-operation.ts"],"names":[],"mappings":";;;AAAA,6CAIwB;AACxB,+CAAmD;AACnD,uCAKkB;AAElB,iEAGgC;AAOhC,SAAgB,4CAA4C,CAC1D,gBAAkC,EAClC,gBAA4B,EAC5B,GAAgC,EAChC,OAAiD;IAEjD,OAAO,GAAG,EAAE;QACV,MAAM,EAAE,UAAU,EAAC,GAAG,OAAO,CAAC;QAC9B,OAAO,UAAU,CAAC,CAAC,CAAC,mBAAoB,UAAU,CAAC,IAAK,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC;IACtE,CAAC,CAAC;AACJ,CAAC;AAVD,oGAUC;AAED,SAAS,cAAc,CAAC,cAAsB,EAAE,YAAgC,EAAE,UAAsC;;IACtH,MAAM,MAAM,GAA4C,EAAE,CAAC;IAC3D,IAAI,UAAU,EAAE,CAAC;QACf,MAAM,CAAC,UAAU,CAAC,IAAI,CAAC,GAAG,UAAU,CAAC,IAAI,CAAC;IAC5C,CAAC;IACD,KAAK,MAAM,QAAQ,IAAI,YAAY,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,UAAU,IAAI,CAAC,CAAC,IAAI,KAAK,UAAU,CAAC,IAAI,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,IAAA,qCAA0B,EAAC,CAAC,CAAC,CAAC,EAAE,CAAC;QACnI,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,GAAG,GAAG,cAAc,IAAK,MAAA,QAAQ,CAAC,MAAM,mCAAI,QAAQ,CAAC,IAAK,EAAE,CAAC;QAClF,IAAI,QAAQ,CAAC,MAAM,EAAE,CAAC;YACpB,+BAA+B;YAC/B,IAAI,QAAQ,CAAC,OAAO,EAAE,CAAC;gBACrB,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE;;oBAC1B,CAA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CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IAEzC,CAAC;IAED,OAAO,IAAA,yCAAkB,kCACpB,OAAO,KACV,aAAa;QACb,SAAS;QACT,YAAY;QACZ,wCAAwC;QACxC,gCAAgC,IAChC,CAAC;AAEL,CAAC;AA3DD,wDA2DC"}
|
|
@@ -2,4 +2,4 @@ import { CoerceOperationOptions } from './coerce-operation';
|
|
|
2
2
|
export interface CoerceGetControllerOptions extends Omit<CoerceOperationOptions, 'operationName'> {
|
|
3
3
|
operationName?: string;
|
|
4
4
|
}
|
|
5
|
-
export declare function CoerceGetOperation
|
|
5
|
+
export declare function CoerceGetOperation(options: CoerceGetControllerOptions): import("@angular-devkit/schematics").Rule;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-get-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-operation.ts"],"names":[],"mappings":";;;AAAA,yDAG4B;AAM5B,SAAgB,kBAAkB,
|
|
1
|
+
{"version":3,"file":"coerce-get-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-operation.ts"],"names":[],"mappings":";;;AAAA,yDAG4B;AAM5B,SAAgB,kBAAkB,CAAC,OAAmC;IACpE,MAAM,EACJ,aAAa,GAAG,KAAK,EACrB,YAAY,GAAG,KAAK,EACrB,GAAG,OAAO,CAAC;IAEZ,OAAO,IAAA,kCAAe,kCACjB,OAAO,KACV,aAAa;QACb,YAAY,IACZ,CAAC;AAEL,CAAC;AAZD,gDAYC"}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { NormalizedUpstreamOptions, OperationParameter, TypeImport } from '@rxap/ts-morph';
|
|
2
2
|
import { ClassDeclaration, Project, SourceFile, WriterFunction } from 'ts-morph';
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { DtoClassProperty } from './dto-class-property';
|
|
3
|
+
import { CoerceOperationOptions as NEW_CoerceOperationOptions, CoerceDtoClassOutput, TransformOperation } from '@rxap/ts-morph';
|
|
4
|
+
import { CoerceOperationOptions } from './coerce-operation';
|
|
5
|
+
import { DtoClassProperty } from '@rxap/ts-morph';
|
|
7
6
|
export interface CoerceGetPageOperationOptions extends Omit<CoerceOperationOptions, 'operationName' | 'tsMorphTransform' | 'coerceOperationDtoClass'> {
|
|
8
|
-
tsMorphTransform?: (project: Project, sourceFile: SourceFile, classDeclaration: ClassDeclaration, controllerName: string, moduleSourceFile: SourceFile, pageClassName: string, rowClassName: string) => Partial<
|
|
7
|
+
tsMorphTransform?: (project: Project, sourceFile: SourceFile, classDeclaration: ClassDeclaration, controllerName: string, moduleSourceFile: SourceFile, pageClassName: string, rowClassName: string) => Partial<NEW_CoerceOperationOptions>;
|
|
9
8
|
/**
|
|
10
9
|
* the name of the property used as row id value. defaults to the value 'uuid'. If null the __rowId property will be
|
|
11
10
|
* set to the absolute row index absolute row index = page * pageSize + rowIndex
|
|
@@ -7,6 +7,7 @@ const utilities_1 = require("@rxap/utilities");
|
|
|
7
7
|
const ts_morph_2 = require("ts-morph");
|
|
8
8
|
const coerce_type_alias_1 = require("../ts-morph/coerce-type-alias");
|
|
9
9
|
const write_type_1 = require("../ts-morph/write-type");
|
|
10
|
+
const ts_morph_3 = require("@rxap/ts-morph");
|
|
10
11
|
const coerce_operation_1 = require("./coerce-operation");
|
|
11
12
|
const coerce_page_dto_class_1 = require("./coerce-page-dto-class");
|
|
12
13
|
const coerce_row_dto_class_1 = require("./coerce-row-dto-class");
|
|
@@ -123,7 +124,7 @@ function CoerceGetPageDataMethod(sourceFile, classDeclaration, moduleSourceFile,
|
|
|
123
124
|
const { upstream } = options;
|
|
124
125
|
const statements = [];
|
|
125
126
|
if (upstream && (0, ts_morph_1.IsNormalizedOpenApiUpstreamOptions)(upstream)) {
|
|
126
|
-
const { memberName, className: commandClassName } = (0,
|
|
127
|
+
const { memberName, className: commandClassName } = (0, ts_morph_3.CoerceUpstreamBasicOperationImplementation)(classDeclaration, moduleSourceFile, upstream);
|
|
127
128
|
(0, ts_morph_1.CoercePropertyDeclaration)(classDeclaration, memberName, {
|
|
128
129
|
type: commandClassName,
|
|
129
130
|
scope: ts_morph_2.Scope.Private,
|
|
@@ -256,7 +257,7 @@ exports.BuildGetPageGetDataImplementation = BuildGetPageGetDataImplementation;
|
|
|
256
257
|
function CoerceGetPageOperationDtoClass(classDeclaration, controllerName, moduleSourceFile, options) {
|
|
257
258
|
const sourceFile = classDeclaration.getSourceFile();
|
|
258
259
|
const project = sourceFile.getProject();
|
|
259
|
-
const { propertyList, coerceToRowDtoMethod = CoerceToRowDtoMethod, coerceToPageDtoMethod = CoerceToPageDtoMethod, coerceGetPageDataMethod = CoerceGetPageDataMethod, buildOperationDtoClassName =
|
|
260
|
+
const { propertyList, coerceToRowDtoMethod = CoerceToRowDtoMethod, coerceToPageDtoMethod = CoerceToPageDtoMethod, coerceGetPageDataMethod = CoerceGetPageDataMethod, buildOperationDtoClassName = ts_morph_3.BuildOperationDtoClassName, dtoClassName = buildOperationDtoClassName(controllerName, options), rowId, } = options;
|
|
260
261
|
const { className: rowClassName, filePath: rowFilePath, } = (0, coerce_row_dto_class_1.CoerceRowDtoClass)({
|
|
261
262
|
project,
|
|
262
263
|
name: dtoClassName,
|
|
@@ -335,7 +336,7 @@ function CoerceGetPageOperation(options) {
|
|
|
335
336
|
type: 'any',
|
|
336
337
|
});
|
|
337
338
|
}
|
|
338
|
-
return Object.assign({ queryList: table_query_list_1.TABLE_QUERY_LIST }, tsMorphTransform(project, sourceFile, classDeclaration, controllerName, moduleSourceFile, (0, coerce_page_dto_class_1.BuildPageDtoClassName)((0,
|
|
339
|
+
return Object.assign({ queryList: table_query_list_1.TABLE_QUERY_LIST }, tsMorphTransform(project, sourceFile, classDeclaration, controllerName, moduleSourceFile, (0, coerce_page_dto_class_1.BuildPageDtoClassName)((0, ts_morph_3.BuildOperationDtoClassName)(controllerName, options)), (0, coerce_row_dto_class_1.BuildRowDtoClassName)((0, ts_morph_3.BuildOperationDtoClassName)(controllerName, options))));
|
|
339
340
|
} }));
|
|
340
341
|
}
|
|
341
342
|
exports.CoerceGetPageOperation = CoerceGetPageOperation;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-get-page-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-page-operation.ts"],"names":[],"mappings":";;;AAAA,qEAAsD;AACtD,6CAYwB;AACxB,+CAIyB;AACzB,uCAOkB;AAClB,qEAAgE;AAChE,uDAAmD;
|
|
1
|
+
{"version":3,"file":"coerce-get-page-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-page-operation.ts"],"names":[],"mappings":";;;AAAA,qEAAsD;AACtD,6CAYwB;AACxB,+CAIyB;AACzB,uCAOkB;AAClB,qEAAgE;AAChE,uDAAmD;AACnD,6CAC8C;AAC9C,yDAK4B;AAC5B,mEAGiC;AACjC,iEAGgC;AAEhC,yDAAsD;AAgDtD,SAAgB,gCAAgC,CAAC,QAA0B;;IACzE,IAAI,YAAY,GAAG,IAAA,+BAAQ,EAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;IAC3C,MAAM,WAAW,GAAG,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAEjD,IAAI,WAAW,EAAE,CAAC;QAChB,YAAY,GAAG,IAAA,+BAAQ,EAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,CAAC;QAC1D,YAAY,GAAG,WAAW,CAAC,CAAC,CAAC,GAAG,YAAY,CAAC;IAC/C,CAAC;IACD,OAAO,GAAI,YAAa,UAAW,MAAA,QAAQ,CAAC,MAAM,mCAAI,IAAA,+BAAQ,EAAC,QAAQ,CAAC,IAAI,CAAE,EAAE,CA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C,IAAI;gBACrB,IAAI,EAAE,UAAU,CAAC,IAAI;gBACrB,UAAU,EAAE,MAAA,UAAU,CAAC,UAAU,mCAAI,CAAC,kBAAkB;aACzD,CAAC,EAAE,CAAC,CAAC,EAAE,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,KAAK,CAAC,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IAEzC,CAAC;IAED,OAAO,IAAA,kCAAe,kCACjB,OAAO,KACV,YAAY;QACZ,SAAS;QACT,aAAa;QACb,gCAAgC;QAChC,uBAAuB;QACvB,0BAA0B,EAC1B,gBAAgB,EAAE,CAChB,OAAO,EACP,UAAU,EACV,gBAAgB,EAChB,cAAc,EACd,gBAAgB,EAChB,EAAE;YAEF,IAAI,CAAC,QAAQ,IAAI,CAAC,IAAA,6CAAkC,EAAC,QAAQ,CAAC,EAAE,CAAC;gBAC/D,IAAA,mCAAe,EAAC,UAAU,EAAE,YAAY,EAAE;oBACxC,UAAU,EAAE,KAAK;oBACjB,IAAI,EAAE,KAAK;iBACZ,CAAC,CAAC;YACL,CAAC;YAED,uBACE,SAAS,EAAE,mCAAgB,IACxB,gBAAgB,CAAC,OAAO,EAAE,UAAU,EAAE,gBAAgB,EAAE,cAAc,EAAE,gBAAgB,EAAE,IAAA,6CAAqB,EAAC,IAAA,qCAA0B,EAAC,cAAc,EAAE,OAAO,CAAC,CAAC,EAAE,IAAA,2CAAoB,EAAC,IAAA,qCAA0B,EAAC,cAAc,EAAE,OAAO,CAAC,CAAC,CAAC,EACnP;QACJ,CAAC,IACD,CAAC;AACL,CAAC;AAlFD,wDAkFC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
+
import { CoerceDtoClassOutput, CoerceOperationOptions as NEW_CoerceOperationOptions, TransformOperation } from '@rxap/ts-morph';
|
|
1
2
|
import { ClassDeclaration, SourceFile, WriterFunction } from 'ts-morph';
|
|
2
|
-
import { CoerceDtoClassOutput } from './coerce-dto-class';
|
|
3
3
|
import { CoerceGetByIdControllerOptions } from './coerce-get-by-id-operation';
|
|
4
|
-
import { CoerceOperationOptions, TransformOperation } from './coerce-operation';
|
|
5
4
|
export interface CoerceGetRootOperationOptions extends CoerceGetByIdControllerOptions {
|
|
6
5
|
}
|
|
7
|
-
export declare function BuildGetRootDtoDataMapperImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<
|
|
6
|
+
export declare function BuildGetRootDtoDataMapperImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<NEW_CoerceOperationOptions>): TransformOperation<string | WriterFunction>;
|
|
8
7
|
export declare function CoerceGetRootOperation(options: Readonly<CoerceGetRootOperationOptions>): import("@angular-devkit/schematics").Rule;
|
|
@@ -33,7 +33,7 @@ function CoerceGetRootOperation(options) {
|
|
|
33
33
|
dtoClassNameSuffix,
|
|
34
34
|
isArray,
|
|
35
35
|
builtDtoDataMapperImplementation, tsMorphTransform: (project, sourceFile, classDeclaration, controllerName, moduleSourceFile, dto) => {
|
|
36
|
-
return Object.assign({ queryList: table_query_list_1.TABLE_QUERY_LIST }, tsMorphTransform(project, sourceFile, classDeclaration, controllerName, moduleSourceFile, dto));
|
|
36
|
+
return Object.assign({ queryList: table_query_list_1.TABLE_QUERY_LIST }, tsMorphTransform(project, sourceFile, classDeclaration, controllerName, moduleSourceFile, dto, options));
|
|
37
37
|
} }));
|
|
38
38
|
}
|
|
39
39
|
exports.CoerceGetRootOperation = CoerceGetRootOperation;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"coerce-get-root-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-root-operation.ts"],"names":[],"mappings":";;;AAAA,
|
|
1
|
+
{"version":3,"file":"coerce-get-root-operation.js","sourceRoot":"","sources":["../../../../../../../packages/schematic/ts-morph/src/lib/nest/coerce-get-root-operation.ts"],"names":[],"mappings":";;;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E,cAAc,EAAE,gBAAgB,EAAE,GAAG,EAAE,OAAO,CAAC,EAC3G;QACJ,CAAC,IACD,CAAC;AACL,CAAC;AA7CD,wDA6CC"}
|
|
@@ -1,52 +1,10 @@
|
|
|
1
1
|
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
-
import {
|
|
3
|
-
import { NormalizedUpstreamOptions } from '@rxap/ts-morph';
|
|
2
|
+
import { CoerceOperationOptions as NEW_CoerceOperationOptions } from '@rxap/ts-morph';
|
|
4
3
|
import { TsMorphNestProjectTransformOptions } from '@rxap/workspace-ts-morph';
|
|
5
|
-
|
|
6
|
-
import { OperationOptions, OperationParameter } from './add-operation-to-controller';
|
|
7
|
-
import { CoerceDtoClassOutput } from './coerce-dto-class';
|
|
8
|
-
import { DtoClassProperty } from './dto-class-property';
|
|
9
|
-
export interface CoerceOperationOptions<Options = Record<string, any>> extends TsMorphNestProjectTransformOptions {
|
|
4
|
+
export interface CoerceOperationOptions extends TsMorphNestProjectTransformOptions, NEW_CoerceOperationOptions {
|
|
10
5
|
controllerName: string;
|
|
11
6
|
shared?: boolean;
|
|
12
7
|
nestModule?: string | null;
|
|
13
8
|
skipCoerce?: boolean;
|
|
14
|
-
paramList?: OperationParameter[];
|
|
15
|
-
queryList?: OperationParameter[];
|
|
16
|
-
tsMorphTransform?: (project: Project, sourceFile: SourceFile, classDeclaration: ClassDeclaration, controllerName: string, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null) => Partial<OperationOptions>;
|
|
17
|
-
operationName: string;
|
|
18
|
-
path?: string;
|
|
19
|
-
controllerPath?: string;
|
|
20
|
-
/**
|
|
21
|
-
* true - the control path is overwritten with
|
|
22
|
-
*/
|
|
23
|
-
overwriteControllerPath?: boolean;
|
|
24
|
-
context?: string | null;
|
|
25
|
-
coerceUpstreamOperationImplementation?: (classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions & Options>) => TransformOperation;
|
|
26
|
-
buildUpstreamGetParametersImplementation?: (classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions & Options>) => TransformOperation<string | WriterFunction>;
|
|
27
|
-
buildDtoReturnImplementation?: (classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions & Options>) => TransformOperation;
|
|
28
|
-
builtDtoDataMapperImplementation?: (classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions & Options>) => TransformOperation<string | WriterFunction>;
|
|
29
|
-
buildUpstreamGetDataImplementation?: (classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions & Options>) => TransformOperation<void>;
|
|
30
|
-
buildGetDataImplementation?: (classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions & Options>) => TransformOperation<void>;
|
|
31
|
-
coerceOperationDtoClass?: (classDeclaration: ClassDeclaration, controllerName: string, moduleSourceFile: SourceFile, options: Readonly<CoerceOperationOptions & Options>) => CoerceDtoClassOutput | null;
|
|
32
|
-
buildOperationDtoClassName?: (controllerName: string, options: Readonly<Pick<CoerceOperationOptions, 'dtoClassNameSuffix' | 'dtoClassName'>>) => string;
|
|
33
|
-
upstream?: NormalizedUpstreamOptions | null;
|
|
34
|
-
propertyList?: DtoClassProperty[];
|
|
35
|
-
isArray?: boolean;
|
|
36
|
-
isReturnVoid?: boolean;
|
|
37
|
-
dtoClassNameSuffix?: string;
|
|
38
|
-
dtoClassName?: string;
|
|
39
|
-
overwrite: OverwriteOptions;
|
|
40
9
|
}
|
|
41
|
-
export declare function
|
|
42
|
-
className: string;
|
|
43
|
-
memberName: string;
|
|
44
|
-
};
|
|
45
|
-
export declare function BuildOperationDtoClassName(controllerName: string, options: Readonly<Pick<CoerceOperationOptions, 'dtoClassNameSuffix' | 'dtoClassName'>>): string;
|
|
46
|
-
export declare function CoerceOperationDtoClass(classDeclaration: ClassDeclaration, controllerName: string, moduleSourceFile: SourceFile, options: Readonly<CoerceOperationOptions>): CoerceDtoClassOutput | null;
|
|
47
|
-
export type TransformOperation<T = void> = (operationOptions: OperationOptions) => T;
|
|
48
|
-
export declare function BuiltDtoDataMapperImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions>): TransformOperation<string | WriterFunction>;
|
|
49
|
-
export declare function BuildDtoReturnImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions>): TransformOperation;
|
|
50
|
-
export declare function BuildUpstreamGetDataImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions>): TransformOperation;
|
|
51
|
-
export declare function CoerceUpstreamDefaultOperationImplementation(classDeclaration: ClassDeclaration, moduleSourceFile: SourceFile, dto: CoerceDtoClassOutput | null, options: Readonly<CoerceOperationOptions>): TransformOperation;
|
|
52
|
-
export declare function CoerceOperation<Options = Record<string, any>>(options: CoerceOperationOptions<Options>): Rule;
|
|
10
|
+
export declare function CoerceOperation(options: CoerceOperationOptions): Rule;
|