@steroidsjs/nest 4.2.1 → 4.4.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.
- package/infrastructure/adapters/QueryAdapterTypeORM.js +2 -1
- package/infrastructure/adapters/QueryAdapterTypeORM.js.map +1 -1
- package/infrastructure/applications/BaseApplication.js +2 -1
- package/infrastructure/applications/BaseApplication.js.map +1 -1
- package/infrastructure/applications/rest/IRestAppModuleConfig.d.ts +4 -0
- package/infrastructure/applications/rest/RestApplication.d.ts +10 -0
- package/infrastructure/applications/rest/RestApplication.js +23 -6
- package/infrastructure/applications/rest/RestApplication.js.map +1 -1
- package/infrastructure/commands/MigrateCommand.d.ts +0 -1
- package/infrastructure/commands/MigrateCommand.js +0 -34
- package/infrastructure/commands/MigrateCommand.js.map +1 -1
- package/infrastructure/commands/generate/index.d.ts +6 -6
- package/infrastructure/commands/generate/index.js +7 -39
- package/infrastructure/commands/generate/index.js.map +1 -1
- package/infrastructure/decorators/Transform.d.ts +2 -2
- package/infrastructure/decorators/fields/BaseField.d.ts +15 -47
- package/infrastructure/decorators/fields/BaseField.js +36 -105
- package/infrastructure/decorators/fields/BaseField.js.map +1 -1
- package/infrastructure/decorators/fields/BooleanField.js +1 -1
- package/infrastructure/decorators/fields/BooleanField.js.map +1 -1
- package/infrastructure/decorators/fields/ComputableField.js +0 -1
- package/infrastructure/decorators/fields/ComputableField.js.map +1 -1
- package/infrastructure/decorators/fields/CoordinateField.js +1 -1
- package/infrastructure/decorators/fields/CoordinateField.js.map +1 -1
- package/infrastructure/decorators/fields/CreateTimeField.js +1 -1
- package/infrastructure/decorators/fields/CreateTimeField.js.map +1 -1
- package/infrastructure/decorators/fields/DateField.js +1 -1
- package/infrastructure/decorators/fields/DateField.js.map +1 -1
- package/infrastructure/decorators/fields/DateTimeField.js +2 -2
- package/infrastructure/decorators/fields/DateTimeField.js.map +1 -1
- package/infrastructure/decorators/fields/DecimalField.js +1 -1
- package/infrastructure/decorators/fields/DecimalField.js.map +1 -1
- package/infrastructure/decorators/fields/DecimalNumberField.js +1 -1
- package/infrastructure/decorators/fields/DecimalNumberField.js.map +1 -1
- package/infrastructure/decorators/fields/DeleteDateField.js +1 -1
- package/infrastructure/decorators/fields/DeleteDateField.js.map +1 -1
- package/infrastructure/decorators/fields/EmailField.js +1 -1
- package/infrastructure/decorators/fields/EmailField.js.map +1 -1
- package/infrastructure/decorators/fields/EnumField.js +1 -1
- package/infrastructure/decorators/fields/EnumField.js.map +1 -1
- package/infrastructure/decorators/fields/FileField.js +1 -1
- package/infrastructure/decorators/fields/FileField.js.map +1 -1
- package/infrastructure/decorators/fields/GeometryField.d.ts +2 -0
- package/infrastructure/decorators/fields/GeometryField.js +2 -1
- package/infrastructure/decorators/fields/GeometryField.js.map +1 -1
- package/infrastructure/decorators/fields/HtmlField.js +1 -1
- package/infrastructure/decorators/fields/HtmlField.js.map +1 -1
- package/infrastructure/decorators/fields/IntegerField.js +1 -1
- package/infrastructure/decorators/fields/IntegerField.js.map +1 -1
- package/infrastructure/decorators/fields/JSONBField.d.ts +4 -1
- package/infrastructure/decorators/fields/JSONBField.js +2 -2
- package/infrastructure/decorators/fields/JSONBField.js.map +1 -1
- package/infrastructure/decorators/fields/PasswordField.js +1 -1
- package/infrastructure/decorators/fields/PasswordField.js.map +1 -1
- package/infrastructure/decorators/fields/PhoneField.js +1 -1
- package/infrastructure/decorators/fields/PhoneField.js.map +1 -1
- package/infrastructure/decorators/fields/PrimaryKeyField.js +1 -1
- package/infrastructure/decorators/fields/PrimaryKeyField.js.map +1 -1
- package/infrastructure/decorators/fields/RelationField.d.ts +6 -4
- package/infrastructure/decorators/fields/RelationField.js +5 -8
- package/infrastructure/decorators/fields/RelationField.js.map +1 -1
- package/infrastructure/decorators/fields/RelationIdField.js +1 -1
- package/infrastructure/decorators/fields/RelationIdField.js.map +1 -1
- package/infrastructure/decorators/fields/StringField.js +1 -1
- package/infrastructure/decorators/fields/StringField.js.map +1 -1
- package/infrastructure/decorators/fields/TextField.js +1 -1
- package/infrastructure/decorators/fields/TextField.js.map +1 -1
- package/infrastructure/decorators/fields/TimeField.js +1 -1
- package/infrastructure/decorators/fields/TimeField.js.map +1 -1
- package/infrastructure/decorators/fields/UidField.js +1 -1
- package/infrastructure/decorators/fields/UidField.js.map +1 -1
- package/infrastructure/decorators/fields/UpdateTimeField.js +1 -1
- package/infrastructure/decorators/fields/UpdateTimeField.js.map +1 -1
- package/infrastructure/decorators/fields/helpers/InternalFieldMetadataHelpers.d.ts +27 -0
- package/infrastructure/decorators/fields/helpers/InternalFieldMetadataHelpers.js +104 -0
- package/infrastructure/decorators/fields/helpers/InternalFieldMetadataHelpers.js.map +1 -0
- package/infrastructure/decorators/typeorm/TypeOrmDecoratorFactory.d.ts +3 -2
- package/infrastructure/decorators/typeorm/TypeOrmDecoratorFactory.js.map +1 -1
- package/infrastructure/decorators/typeorm/TypeOrmTableFromModel.js.map +1 -1
- package/infrastructure/decorators/typeorm/fields/TypeOrmBooleanField/index.js +1 -1
- package/infrastructure/decorators/typeorm/fields/TypeOrmBooleanField/index.js.map +1 -1
- package/infrastructure/decorators/typeorm/fields/TypeOrmUidField/index.js +1 -1
- package/infrastructure/decorators/typeorm/fields/TypeOrmUidField/index.js.map +1 -1
- package/infrastructure/filters/UserExceptionFilter.d.ts +1 -0
- package/infrastructure/filters/UserExceptionFilter.js +1 -0
- package/infrastructure/filters/UserExceptionFilter.js.map +1 -1
- package/infrastructure/pipes/CreateDtoPipe.d.ts +5 -1
- package/infrastructure/pipes/CreateDtoPipe.js +23 -4
- package/infrastructure/pipes/CreateDtoPipe.js.map +1 -1
- package/infrastructure/pipes/CreateDtoPipe.test.d.ts +1 -0
- package/infrastructure/pipes/CreateDtoPipe.test.js +98 -0
- package/infrastructure/pipes/CreateDtoPipe.test.js.map +1 -0
- package/package.json +6 -2
- package/tsconfig.tsbuildinfo +1 -1
- package/usecases/base/SearchQuery.d.ts +11 -0
- package/usecases/base/SearchQuery.js +36 -19
- package/usecases/base/SearchQuery.js.map +1 -1
- package/usecases/base/SearchQuery.test.d.ts +1 -0
- package/usecases/base/SearchQuery.test.js +102 -0
- package/usecases/base/SearchQuery.test.js.map +1 -0
- package/usecases/exceptions/UserException.d.ts +1 -0
- package/usecases/exceptions/UserException.js +1 -0
- package/usecases/exceptions/UserException.js.map +1 -1
- package/usecases/helpers/DataMapper.js +13 -8
- package/usecases/helpers/DataMapper.js.map +1 -1
- package/usecases/helpers/getMetaRelationsFromObject.d.ts +2 -0
- package/usecases/helpers/getMetaRelationsFromObject.js +53 -0
- package/usecases/helpers/getMetaRelationsFromObject.js.map +1 -0
- package/usecases/helpers/getMetaRelationsFromObject.test.d.ts +1 -0
- package/usecases/helpers/getMetaRelationsFromObject.test.js +327 -0
- package/usecases/helpers/getMetaRelationsFromObject.test.js.map +1 -0
- package/usecases/services/CrudService.js +5 -1
- package/usecases/services/CrudService.js.map +1 -1
- package/usecases/utils/wrapInDoubleQuotes.d.ts +1 -0
- package/usecases/utils/wrapInDoubleQuotes.js +15 -0
- package/usecases/utils/wrapInDoubleQuotes.js.map +1 -0
- package/infrastructure/utils/getNewPermissions.d.ts +0 -2
- package/infrastructure/utils/getNewPermissions.js +0 -18
- package/infrastructure/utils/getNewPermissions.js.map +0 -1
|
@@ -1,123 +1,40 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
3
|
+
exports.isMetaClass = exports.getRelationsByFilter = exports.getMetaRelations = exports.getMetaPrimaryKey = exports.getMetaFields = exports.getFieldOptions = exports.getFieldInternalOptions = exports.getFieldDecoratorName = exports.getFieldDecorator = exports.getFieldAppType = exports.STEROIDS_META_KEYS = exports.STEROIDS_META_FIELD_OPTIONS = exports.STEROIDS_META_FIELD_INTERNAL_OPTIONS = exports.BaseField = void 0;
|
|
4
4
|
const common_1 = require("@nestjs/common");
|
|
5
5
|
const swagger_1 = require("@nestjs/swagger");
|
|
6
6
|
const class_validator_1 = require("class-validator");
|
|
7
7
|
const Transform_1 = require("../Transform");
|
|
8
|
-
|
|
9
|
-
exports.STEROIDS_META_FIELD_DECORATOR = 'steroids_meta_field_decorator';
|
|
10
|
-
exports.STEROIDS_META_KEYS = 'steroids_meta_keys';
|
|
11
|
-
const getMetaFields = (MetaClass) => {
|
|
12
|
-
if (!(MetaClass === null || MetaClass === void 0 ? void 0 : MetaClass.prototype)) {
|
|
13
|
-
throw new Error('Wrong meta class, prototype not found: ' + String(MetaClass));
|
|
14
|
-
}
|
|
15
|
-
return Reflect.getMetadata(exports.STEROIDS_META_KEYS, MetaClass.prototype) || [];
|
|
16
|
-
};
|
|
17
|
-
exports.getMetaFields = getMetaFields;
|
|
18
|
-
const getFieldOptions = (targetClass, fieldName) => targetClass && Reflect.getMetadata(exports.STEROIDS_META_FIELD, targetClass.prototype, fieldName);
|
|
19
|
-
exports.getFieldOptions = getFieldOptions;
|
|
20
|
-
const getMetaPrimaryKey = (targetClass) => (0, exports.getMetaFields)(targetClass)
|
|
21
|
-
.find(key => (0, exports.getFieldOptions)(targetClass, key).appType === 'primaryKey') || null;
|
|
22
|
-
exports.getMetaPrimaryKey = getMetaPrimaryKey;
|
|
23
|
-
const isMetaClass = (MetaClass) => Reflect.hasMetadata(exports.STEROIDS_META_KEYS, MetaClass.prototype);
|
|
24
|
-
exports.isMetaClass = isMetaClass;
|
|
25
|
-
const getMetaRelations = (MetaClass, parentPrefix = null) => {
|
|
26
|
-
const findRelationsRecursive = (MetaClass, foundClasses, parentPrefix = null) => (0, exports.getMetaFields)(MetaClass)
|
|
27
|
-
.filter(fieldName => {
|
|
28
|
-
const options = (0, exports.getFieldOptions)(MetaClass, fieldName);
|
|
29
|
-
if ((options === null || options === void 0 ? void 0 : options.appType) === 'computable' && (options === null || options === void 0 ? void 0 : options.requiredRelations)) {
|
|
30
|
-
return true;
|
|
31
|
-
}
|
|
32
|
-
return ['relationId', 'relation'].includes(options === null || options === void 0 ? void 0 : options.appType);
|
|
33
|
-
})
|
|
34
|
-
.reduce((allRelationsData, relationName) => {
|
|
35
|
-
const options = (0, exports.getFieldOptions)(MetaClass, relationName);
|
|
36
|
-
if ((options === null || options === void 0 ? void 0 : options.appType) === 'relationId') {
|
|
37
|
-
allRelationsData.push(relationName);
|
|
38
|
-
return allRelationsData;
|
|
39
|
-
}
|
|
40
|
-
if ((options === null || options === void 0 ? void 0 : options.appType) === 'computable' && (options === null || options === void 0 ? void 0 : options.requiredRelations)) {
|
|
41
|
-
allRelationsData.push(...options.requiredRelations);
|
|
42
|
-
}
|
|
43
|
-
if ((options === null || options === void 0 ? void 0 : options.appType) !== 'computable') {
|
|
44
|
-
allRelationsData.push({
|
|
45
|
-
relationName,
|
|
46
|
-
relationClass: options.relationClass,
|
|
47
|
-
});
|
|
48
|
-
}
|
|
49
|
-
return allRelationsData;
|
|
50
|
-
}, [])
|
|
51
|
-
.reduce((allRelations, relationData) => {
|
|
52
|
-
if ((0, class_validator_1.isString)(relationData)) {
|
|
53
|
-
allRelations.push(relationData);
|
|
54
|
-
return allRelations;
|
|
55
|
-
}
|
|
56
|
-
if (!allRelations.includes(relationData.relationName)) {
|
|
57
|
-
allRelations.push(relationData.relationName);
|
|
58
|
-
}
|
|
59
|
-
if (!relationData.relationClass) {
|
|
60
|
-
return allRelations;
|
|
61
|
-
}
|
|
62
|
-
const relationValue = relationData.relationClass();
|
|
63
|
-
// Из-за этого кода возвращаются не все реляции в случаях, когда у одного MetaClass'а
|
|
64
|
-
// есть несколько реляций с одним и тем же классом (см. ImageDownloadSchema для примера)
|
|
65
|
-
// @todo нужно исправить этот баг, иначе реализовав кэширование уже обработанных классов
|
|
66
|
-
const key = [relationData.relationName, relationValue.name].join('.');
|
|
67
|
-
if (foundClasses.includes(key)) {
|
|
68
|
-
return allRelations;
|
|
69
|
-
}
|
|
70
|
-
foundClasses.push(key);
|
|
71
|
-
if ((0, exports.isMetaClass)(relationValue)) {
|
|
72
|
-
const subRelationNames = findRelationsRecursive(relationValue, foundClasses, relationData.relationName)
|
|
73
|
-
.map(subRelationName => `${relationData.relationName}.${subRelationName}`);
|
|
74
|
-
allRelations = [...allRelations, ...subRelationNames];
|
|
75
|
-
}
|
|
76
|
-
return allRelations;
|
|
77
|
-
}, []);
|
|
78
|
-
return findRelationsRecursive(MetaClass, []);
|
|
79
|
-
};
|
|
80
|
-
exports.getMetaRelations = getMetaRelations;
|
|
81
|
-
const getRelationsByFilter = (MetaClass, filterCallBack) => (0, exports.getMetaFields)(MetaClass)
|
|
82
|
-
.filter(fieldName => {
|
|
83
|
-
const options = (0, exports.getFieldOptions)(MetaClass, fieldName);
|
|
84
|
-
return ['relation'].includes(options.appType);
|
|
85
|
-
})
|
|
86
|
-
.filter((relationName) => {
|
|
87
|
-
const relationOptions = (0, exports.getFieldOptions)(MetaClass, relationName);
|
|
88
|
-
return filterCallBack(relationOptions);
|
|
89
|
-
});
|
|
90
|
-
exports.getRelationsByFilter = getRelationsByFilter;
|
|
91
|
-
const getFieldDecoratorName = (targetClass, fieldName) => Reflect.getMetadata(exports.STEROIDS_META_FIELD_DECORATOR, targetClass.prototype, fieldName);
|
|
92
|
-
exports.getFieldDecoratorName = getFieldDecoratorName;
|
|
93
|
-
const getFieldDecorator = (targetClass, fieldName) => {
|
|
94
|
-
const decoratorName = (0, exports.getFieldDecoratorName)(targetClass, fieldName);
|
|
95
|
-
const decorator = require('./index')[decoratorName];
|
|
96
|
-
if (!decorator) {
|
|
97
|
-
throw new Error(`Not found Field decorator ${decoratorName}, property: ${fieldName}`);
|
|
98
|
-
}
|
|
99
|
-
return decorator;
|
|
100
|
-
};
|
|
101
|
-
exports.getFieldDecorator = getFieldDecorator;
|
|
8
|
+
const InternalFieldMetadataHelpers_1 = require("./helpers/InternalFieldMetadataHelpers");
|
|
102
9
|
const ColumnMetaDecorator = (options, internalOptions) => (object, propertyName) => {
|
|
103
10
|
//проверить getOwnMetadata
|
|
104
|
-
Reflect.defineMetadata(
|
|
105
|
-
Reflect.defineMetadata(
|
|
11
|
+
Reflect.defineMetadata(InternalFieldMetadataHelpers_1.STEROIDS_META_FIELD_OPTIONS, options, object, propertyName);
|
|
12
|
+
Reflect.defineMetadata(InternalFieldMetadataHelpers_1.STEROIDS_META_FIELD_INTERNAL_OPTIONS, internalOptions, object, propertyName);
|
|
106
13
|
// Add field to list
|
|
107
|
-
const fieldNames = (Reflect.getMetadata(
|
|
108
|
-
Reflect.defineMetadata(
|
|
14
|
+
const fieldNames = (Reflect.getMetadata(InternalFieldMetadataHelpers_1.STEROIDS_META_KEYS, object) || []).concat(propertyName);
|
|
15
|
+
Reflect.defineMetadata(InternalFieldMetadataHelpers_1.STEROIDS_META_KEYS, fieldNames, object);
|
|
109
16
|
};
|
|
110
|
-
|
|
17
|
+
/**
|
|
18
|
+
* Base decorator used by concrete Field decorators.
|
|
19
|
+
*
|
|
20
|
+
* @param options Public field options passed by the user or prepared by a concrete Field decorator.
|
|
21
|
+
* They describe user-facing field behavior and are stored in `STEROIDS_META_FIELD_OPTIONS`.
|
|
22
|
+
* Examples: `label`, `example`, `required`, `nullable`, `isArray`, `transform`, `noColumn`.
|
|
23
|
+
*
|
|
24
|
+
* @param internalOptions Internal service options set by concrete Field decorators.
|
|
25
|
+
* They are not part of the public Field API and are stored separately in
|
|
26
|
+
* `STEROIDS_META_FIELD_INTERNAL_OPTIONS`.
|
|
27
|
+
* Examples: `appType`, `decoratorName`, `swaggerType`.
|
|
28
|
+
*/
|
|
29
|
+
function BaseField(options = {}, internalOptions = {}) {
|
|
111
30
|
return (0, common_1.applyDecorators)(...[
|
|
112
|
-
ColumnMetaDecorator(
|
|
113
|
-
? options.isArray
|
|
114
|
-
: (internalOptions.isArray || null), appType: internalOptions.appType || null }), internalOptions),
|
|
31
|
+
ColumnMetaDecorator(options, internalOptions),
|
|
115
32
|
(0, swagger_1.ApiProperty)({
|
|
116
|
-
type:
|
|
33
|
+
type: internalOptions.swaggerType,
|
|
117
34
|
description: options.label || undefined,
|
|
118
35
|
example: options.example || undefined,
|
|
119
36
|
required: options.nullable === false,
|
|
120
|
-
isArray: options.isArray
|
|
37
|
+
isArray: options.isArray,
|
|
121
38
|
}),
|
|
122
39
|
options.transform && (0, Transform_1.Transform)(options.transform),
|
|
123
40
|
options.required && (0, class_validator_1.IsNotEmpty)({
|
|
@@ -126,4 +43,18 @@ function BaseField(options = null, internalOptions = {}) {
|
|
|
126
43
|
].filter(Boolean));
|
|
127
44
|
}
|
|
128
45
|
exports.BaseField = BaseField;
|
|
46
|
+
var InternalFieldMetadataHelpers_2 = require("./helpers/InternalFieldMetadataHelpers");
|
|
47
|
+
Object.defineProperty(exports, "STEROIDS_META_FIELD_INTERNAL_OPTIONS", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.STEROIDS_META_FIELD_INTERNAL_OPTIONS; } });
|
|
48
|
+
Object.defineProperty(exports, "STEROIDS_META_FIELD_OPTIONS", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.STEROIDS_META_FIELD_OPTIONS; } });
|
|
49
|
+
Object.defineProperty(exports, "STEROIDS_META_KEYS", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.STEROIDS_META_KEYS; } });
|
|
50
|
+
Object.defineProperty(exports, "getFieldAppType", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getFieldAppType; } });
|
|
51
|
+
Object.defineProperty(exports, "getFieldDecorator", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getFieldDecorator; } });
|
|
52
|
+
Object.defineProperty(exports, "getFieldDecoratorName", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getFieldDecoratorName; } });
|
|
53
|
+
Object.defineProperty(exports, "getFieldInternalOptions", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getFieldInternalOptions; } });
|
|
54
|
+
Object.defineProperty(exports, "getFieldOptions", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getFieldOptions; } });
|
|
55
|
+
Object.defineProperty(exports, "getMetaFields", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getMetaFields; } });
|
|
56
|
+
Object.defineProperty(exports, "getMetaPrimaryKey", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getMetaPrimaryKey; } });
|
|
57
|
+
Object.defineProperty(exports, "getMetaRelations", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getMetaRelations; } });
|
|
58
|
+
Object.defineProperty(exports, "getRelationsByFilter", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.getRelationsByFilter; } });
|
|
59
|
+
Object.defineProperty(exports, "isMetaClass", { enumerable: true, get: function () { return InternalFieldMetadataHelpers_2.isMetaClass; } });
|
|
129
60
|
//# sourceMappingURL=BaseField.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BaseField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/BaseField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,6CAA4C;
|
|
1
|
+
{"version":3,"file":"BaseField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/BaseField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,6CAA4C;AAC5C,qDAA2C;AAC3C,4CAA2D;AAC3D,yFAIgD;AAmDhD,MAAM,mBAAmB,GAAG,CAAC,OAAsB,EAAE,eAAsC,EAAE,EAAE,CAAC,CAAC,MAAM,EAAE,YAAY,EAAE,EAAE;IACrH,0BAA0B;IAC1B,OAAO,CAAC,cAAc,CAAC,0DAA2B,EAAE,OAAO,EAAE,MAAM,EAAE,YAAY,CAAC,CAAC;IACnF,OAAO,CAAC,cAAc,CAAC,mEAAoC,EAAE,eAAe,EAAE,MAAM,EAAE,YAAY,CAAC,CAAC;IAEpG,oBAAoB;IACpB,MAAM,UAAU,GAAG,CAAC,OAAO,CAAC,WAAW,CAAC,iDAAkB,EAAE,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC,MAAM,CAAC,YAAY,CAAC,CAAC;IAChG,OAAO,CAAC,cAAc,CAAC,iDAAkB,EAAE,UAAU,EAAE,MAAM,CAAC,CAAC;AACnE,CAAC,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,SAAgB,SAAS,CAAC,UAA6B,EAAE,EAAE,kBAAyC,EAAE;IAClG,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,mBAAmB,CAAC,OAAO,EAAE,eAAe,CAAC;QAC7C,IAAA,qBAAW,EAAC;YACR,IAAI,EAAE,eAAe,CAAC,WAAW;YACjC,WAAW,EAAE,OAAO,CAAC,KAAK,IAAI,SAAS;YACvC,OAAO,EAAE,OAAO,CAAC,OAAO,IAAI,SAAS;YACrC,QAAQ,EAAE,OAAO,CAAC,QAAQ,KAAK,KAAK;YACpC,OAAO,EAAE,OAAO,CAAC,OAAO;SAC3B,CAAC;QACF,OAAO,CAAC,SAAS,IAAI,IAAA,qBAAS,EAAC,OAAO,CAAC,SAAS,CAAC;QACjD,OAAO,CAAC,QAAQ,IAAI,IAAA,4BAAU,EAAC;YAC3B,OAAO,EAAE,4BAA4B;SACxC,CAAC;KACL,CAAC,MAAM,CAAC,OAAO,CAAC,CACpB,CAAC;AACN,CAAC;AAjBD,8BAiBC;AAED,uFAkBgD;AAb5C,oJAAA,oCAAoC,OAAA;AACpC,2IAAA,2BAA2B,OAAA;AAC3B,kIAAA,kBAAkB,OAAA;AAClB,+HAAA,eAAe,OAAA;AACf,iIAAA,iBAAiB,OAAA;AACjB,qIAAA,qBAAqB,OAAA;AACrB,uIAAA,uBAAuB,OAAA;AACvB,+HAAA,eAAe,OAAA;AACf,6HAAA,aAAa,OAAA;AACb,iIAAA,iBAAiB,OAAA;AACjB,gIAAA,gBAAgB,OAAA;AAChB,oIAAA,oBAAoB,OAAA;AACpB,2HAAA,WAAW,OAAA"}
|
|
@@ -12,7 +12,7 @@ function BooleanField(options = {}) {
|
|
|
12
12
|
return (0, common_1.applyDecorators)((0, BaseField_1.BaseField)(options, {
|
|
13
13
|
decoratorName: 'BooleanField',
|
|
14
14
|
appType: 'boolean',
|
|
15
|
-
|
|
15
|
+
swaggerType: 'boolean',
|
|
16
16
|
}), (0, Transform_1.Transform)(({ value }) => {
|
|
17
17
|
if (Array.isArray(value)) {
|
|
18
18
|
return value.map(exports.normalizeBoolean);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BooleanField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/BooleanField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAsD;AACtD,2CAAyD;AACzD,4CAAuC;AAEvC,MAAM,WAAW,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,EAAE,KAAK,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;AAE3D,MAAM,gBAAgB,GAAG,CAAC,KAAK,EAAE,EAAE,CAAC,WAAW,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;AAA1D,QAAA,gBAAgB,oBAA0C;AAEvE,SAAgB,YAAY,CAAC,UAA6B,EAAE;IACxD,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,cAAc;QAC7B,OAAO,EAAE,SAAS;QAClB,
|
|
1
|
+
{"version":3,"file":"BooleanField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/BooleanField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAsD;AACtD,2CAAyD;AACzD,4CAAuC;AAEvC,MAAM,WAAW,GAAG,CAAC,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,GAAG,EAAE,GAAG,EAAE,KAAK,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;AAE3D,MAAM,gBAAgB,GAAG,CAAC,KAAK,EAAE,EAAE,CAAC,WAAW,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;AAA1D,QAAA,gBAAgB,oBAA0C;AAEvE,SAAgB,YAAY,CAAC,UAA6B,EAAE;IACxD,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,cAAc;QAC7B,OAAO,EAAE,SAAS;QAClB,WAAW,EAAE,SAAS;KACzB,CAAC,EACF,IAAA,qBAAS,EAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE;QAClB,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,EAAE;YACtB,OAAO,KAAK,CAAC,GAAG,CAAC,wBAAgB,CAAC,CAAC;SACtC;QACD,OAAO,IAAA,wBAAgB,EAAC,KAAK,CAAC,CAAC;IACnC,CAAC,CAAC,EACF,IAAA,2BAAS,EAAC;QACN,OAAO,EAAE,qBAAqB;KACjC,CAAC,EACF,IAAA,4BAAU,GAAE,CACf,CAAC;AACN,CAAC;AAlBD,oCAkBC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ComputableField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/ComputableField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;
|
|
1
|
+
{"version":3,"file":"ComputableField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/ComputableField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAE/C,2CAAwE;AACxE,8CAA8D;AAW9D,SAAgB,eAAe,CAAC,OAAgC;IAC5D,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,iBAAiB;YAChC,OAAO,EAAE,YAAY;YACrB,WAAW,EAAE,OAAO,CAAC,WAAW;SACnC,CAAC;QACF,IAAA,uBAAU,EAAC,OAAO,CAAC,QAAQ,CAAC;KAC/B,CAAC,MAAM,CAAC,OAAO,CAAC,CACpB,CAAC;AACN,CAAC;AAXD,0CAWC"}
|
|
@@ -9,7 +9,7 @@ function CoordinateField(options = {}) {
|
|
|
9
9
|
(0, BaseField_1.BaseField)(options, {
|
|
10
10
|
decoratorName: 'CoordinateField',
|
|
11
11
|
appType: 'decimal',
|
|
12
|
-
|
|
12
|
+
swaggerType: 'number',
|
|
13
13
|
}),
|
|
14
14
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => value !== null),
|
|
15
15
|
(0, class_validator_1.IsString)(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CoordinateField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/CoordinateField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAqD;AACrD,2CAAyD;AAOzD,SAAgB,eAAe,CAAC,UAAmC,EAAE;IACjE,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,iBAAiB;YAChC,OAAO,EAAE,SAAS;YAClB,
|
|
1
|
+
{"version":3,"file":"CoordinateField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/CoordinateField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAqD;AACrD,2CAAyD;AAOzD,SAAgB,eAAe,CAAC,UAAmC,EAAE;IACjE,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,iBAAiB;YAChC,OAAO,EAAE,SAAS;YAClB,WAAW,EAAE,QAAQ;SACxB,CAAC;QACF,OAAO,CAAC,QAAQ,IAAI,IAAA,4BAAU,EAAC,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC,KAAK,KAAK,IAAI,CAAC;QACjE,IAAA,0BAAQ,GAAE;KACb,CAAC,MAAM,CAAC,OAAO,CAAC,CACpB,CAAC;AACN,CAAC;AAZD,0CAYC"}
|
|
@@ -12,7 +12,7 @@ function CreateTimeField(options = {}) {
|
|
|
12
12
|
return (0, common_1.applyDecorators)((0, BaseField_1.BaseField)(options, {
|
|
13
13
|
decoratorName: 'CreateTimeField',
|
|
14
14
|
appType: 'createTime',
|
|
15
|
-
|
|
15
|
+
swaggerType: 'string',
|
|
16
16
|
}), (0, Transform_1.Transform)(({ value }) => (0, DateTimeField_1.normalizeDateTime)(value, false), Transform_1.TRANSFORM_TYPE_FROM_DB), (0, Transform_1.Transform)(({ value }) => (0, DateTimeField_1.normalizeDateTime)(value, false), Transform_1.TRANSFORM_TYPE_TO_DB));
|
|
17
17
|
}
|
|
18
18
|
exports.CreateTimeField = CreateTimeField;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CreateTimeField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/CreateTimeField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AACzD,mDAAkD;AAClD,4CAAqF;AAMrF,SAAgB,eAAe,CAAC,UAAmC,EAAE;IACjE,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,QAAQ,CAAC;KAC5B;IAED,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,iBAAiB;QAChC,OAAO,EAAE,YAAY;QACrB,
|
|
1
|
+
{"version":3,"file":"CreateTimeField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/CreateTimeField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AACzD,mDAAkD;AAClD,4CAAqF;AAMrF,SAAgB,eAAe,CAAC,UAAmC,EAAE;IACjE,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,QAAQ,CAAC;KAC5B;IAED,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,iBAAiB;QAChC,OAAO,EAAE,YAAY;QACrB,WAAW,EAAE,QAAQ;KACxB,CAAC,EACF,IAAA,qBAAS,EAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,iCAAiB,EAAC,KAAK,EAAE,KAAK,CAAC,EAAE,kCAAsB,CAAC,EAC/E,IAAA,qBAAS,EAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,iCAAiB,EAAC,KAAK,EAAE,KAAK,CAAC,EAAE,gCAAoB,CAAC,CAChF,CAAC;AACN,CAAC;AAdD,0CAcC"}
|
|
@@ -36,7 +36,7 @@ function DateField(options = {}) {
|
|
|
36
36
|
(0, BaseField_1.BaseField)(options, {
|
|
37
37
|
decoratorName: 'DateField',
|
|
38
38
|
appType: 'date',
|
|
39
|
-
|
|
39
|
+
swaggerType: 'string',
|
|
40
40
|
}),
|
|
41
41
|
(0, Transform_1.Transform)(({ value }) => (0, exports.normalizeDate)(value), Transform_1.TRANSFORM_TYPE_FROM_DB),
|
|
42
42
|
(0, Transform_1.Transform)(({ value }) => (0, exports.normalizeDate)(value), Transform_1.TRANSFORM_TYPE_TO_DB),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DateField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA2E;AAC3E,uCAAiD;AACjD,2CAAyD;AACzD,4CAAqF;AACrF,mDAA8C;AAC9C,mDAA8C;AAEvC,MAAM,aAAa,GAAG,CAAC,QAAQ,EAAE,EAAE;IACtC,IAAI,CAAC,QAAQ,EAAE;QACX,OAAO,QAAQ,CAAC;KACnB;IAED,IAAI,KAAK,GAAG,QAAQ,CAAC;IACrB,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC3B,KAAK,GAAG,IAAA,mBAAQ,EAAC,QAAQ,CAAC,CAAC;KAC9B;IAED,IAAI;QACA,OAAO,IAAA,wBAAa,EAAC,KAAK,EAAE,EAAC,cAAc,EAAE,MAAM,EAAC,CAAC,CAAC;KACzD;IAAC,OAAO,CAAC,EAAE;QACR,OAAO,IAAI,CAAC;KACf;AACL,CAAC,CAAC;AAfW,QAAA,aAAa,iBAexB;AAEK,MAAM,qBAAqB,GAAG,CAAC,KAAK,EAAE,IAA0B,EAAE,EAAE;IACvE,IAAI,OAAO,KAAK,KAAK,UAAU,EAAE;QAC7B,KAAK,GAAG,KAAK,CAAC,IAAI,CAAC,CAAC;KACvB;IAED,OAAO,IAAA,qBAAa,EAAC,KAAK,CAAC,CAAC;AAChC,CAAC,CAAC;AANW,QAAA,qBAAqB,yBAMhC;AAOF,SAAgB,SAAS,CAAC,UAA6B,EAAE;IACrD,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,WAAW;YAC1B,OAAO,EAAE,MAAM;YACf,
|
|
1
|
+
{"version":3,"file":"DateField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DateField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA2E;AAC3E,uCAAiD;AACjD,2CAAyD;AACzD,4CAAqF;AACrF,mDAA8C;AAC9C,mDAA8C;AAEvC,MAAM,aAAa,GAAG,CAAC,QAAQ,EAAE,EAAE;IACtC,IAAI,CAAC,QAAQ,EAAE;QACX,OAAO,QAAQ,CAAC;KACnB;IAED,IAAI,KAAK,GAAG,QAAQ,CAAC;IACrB,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAC3B,KAAK,GAAG,IAAA,mBAAQ,EAAC,QAAQ,CAAC,CAAC;KAC9B;IAED,IAAI;QACA,OAAO,IAAA,wBAAa,EAAC,KAAK,EAAE,EAAC,cAAc,EAAE,MAAM,EAAC,CAAC,CAAC;KACzD;IAAC,OAAO,CAAC,EAAE;QACR,OAAO,IAAI,CAAC;KACf;AACL,CAAC,CAAC;AAfW,QAAA,aAAa,iBAexB;AAEK,MAAM,qBAAqB,GAAG,CAAC,KAAK,EAAE,IAA0B,EAAE,EAAE;IACvE,IAAI,OAAO,KAAK,KAAK,UAAU,EAAE;QAC7B,KAAK,GAAG,KAAK,CAAC,IAAI,CAAC,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CACpB,CAAC;AACN,CAAC;AAxBD,8BAwBC"}
|
|
@@ -7,7 +7,7 @@ const class_transformer_1 = require("class-transformer");
|
|
|
7
7
|
const date_fns_1 = require("date-fns");
|
|
8
8
|
const BaseField_1 = require("./BaseField");
|
|
9
9
|
const Transform_1 = require("../Transform");
|
|
10
|
-
const normalizeDateTime = (value, skipSeconds =
|
|
10
|
+
const normalizeDateTime = (value, skipSeconds = false) => value
|
|
11
11
|
? (0, date_fns_1.format)(typeof value === 'string'
|
|
12
12
|
? (0, date_fns_1.parseISO)(value)
|
|
13
13
|
: value, 'yyyy-MM-dd HH:mm' + (!skipSeconds ? ':ss' : ''))
|
|
@@ -18,7 +18,7 @@ function DateTimeField(options = {}) {
|
|
|
18
18
|
(0, BaseField_1.BaseField)(options, {
|
|
19
19
|
decoratorName: 'DateTimeField',
|
|
20
20
|
appType: 'dateTime',
|
|
21
|
-
|
|
21
|
+
swaggerType: 'string',
|
|
22
22
|
}),
|
|
23
23
|
// options.nullable && ValidateIf((object, value) => value !== null && typeof value !== 'undefined'),
|
|
24
24
|
// IsDateString({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DateTimeField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DateTimeField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2DAA2D;AAC3D,yDAAuC;AACvC,uCAA0C;AAC1C,2CAAyD;AACzD,4CAAqF;AAE9E,MAAM,iBAAiB,GAAG,CAAC,KAAK,EAAE,WAAW,GAAG,
|
|
1
|
+
{"version":3,"file":"DateTimeField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DateTimeField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2DAA2D;AAC3D,yDAAuC;AACvC,uCAA0C;AAC1C,2CAAyD;AACzD,4CAAqF;AAE9E,MAAM,iBAAiB,GAAG,CAAC,KAAK,EAAE,WAAW,GAAG,KAAK,EAAE,EAAE,CAAC,KAAK;IAClE,CAAC,CAAC,IAAA,iBAAM,EACJ,OAAO,KAAK,KAAK,QAAQ;QACrB,CAAC,CAAC,IAAA,mBAAQ,EAAC,KAAK,CAAC;QACjB,CAAC,CAAC,KAAK,EACX,kBAAkB,GAAG,CAAC,CAAC,WAAW,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CACnD;IACD,CAAC,CAAC,KAAK,CAAC;AAPC,QAAA,iBAAiB,qBAOlB;AAOZ,SAAgB,aAAa,CAAC,UAAuC,EAAE;IACnE,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,eAAe;YAC9B,OAAO,EAAE,UAAU;YACnB,WAAW,EAAE,QAAQ;SACxB,CAAC;QACF,qGAAqG;QACrG,iBAAiB;QACjB,2CAA2C;QAC3C,MAAM;QACN,IAAA,wBAAI,EAAC,GAAG,EAAE,CAAC,IAAI,CAAC;QAChB,IAAA,qBAAS,EACL,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,yBAAiB,EAAC,KAAK,EAAE,OAAO,CAAC,WAAW,CAAC,EAC1D,kCAAsB,CACzB;QACD,IAAA,qBAAS,EACL,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,yBAAiB,EAAC,KAAK,EAAE,OAAO,CAAC,WAAW,CAAC,EAC1D,gCAAoB,CACvB;KACJ,CAAC,MAAM,CAAC,OAAO,CAAC,CACpB,CAAC;AACN,CAAC;AAvBD,sCAuBC"}
|
|
@@ -34,7 +34,7 @@ function DecimalField(options = {}) {
|
|
|
34
34
|
(0, BaseField_1.BaseField)(options, {
|
|
35
35
|
decoratorName: 'DecimalField',
|
|
36
36
|
appType: 'decimal',
|
|
37
|
-
|
|
37
|
+
swaggerType: 'number',
|
|
38
38
|
}),
|
|
39
39
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => value !== null && typeof value !== 'undefined'),
|
|
40
40
|
(0, class_validator_1.IsDecimal)({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DecimalField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DecimalField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAqF;AACrF,2CAAyD;AACzD,8CAAwD;AAU3C,QAAA,oBAAoB,GAAG,mBAAmB,CAAC;AAE3C,QAAA,oBAAoB,GAAG,mBAAmB,CAAC;AAExD,SAAS,aAAa,CAClB,UAAkB,EAClB,gBAA6D,EAC7D,iBAAqC;IAErC,OAAO,IAAA,4BAAU,EACb;QACI,IAAI,EAAE,4BAAoB;QAC1B,WAAW,EAAE,CAAC,UAAU,CAAC;QACzB,SAAS,EAAE;YACP,QAAQ,EAAE,CAAC,KAAK,EAAE,IAAI,EAAW,EAAE,CAAC,gBAAgB,CAAC,KAAK,EAAE,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,WAAW,CAAC,CAAC,CAAC,CAAC;SACpF;KACJ,EACD,iBAAiB,CACpB,CAAC;AACN,CAAC;AAED,SAAS,SAAS,CAAC,GAAY,EAAE,GAAW;IACxC,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,MAAM,CAAC,GAAG,CAAC,IAAI,GAAG,CAAC;AACpF,CAAC;AAED,SAAS,SAAS,CAAC,QAAgB,EAAE,iBAAqC;IACtE,OAAO,aAAa,CAAC,QAAQ,EAAE,SAAS,EAAE,iBAAiB,CAAC,CAAC;AACjE,CAAC;AAED,SAAS,SAAS,CAAC,GAAY,EAAE,GAAW;IACxC,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,MAAM,CAAC,GAAG,CAAC,IAAI,GAAG,CAAC;AACpF,CAAC;AAED,SAAS,SAAS,CAAC,QAAgB,EAAE,iBAAqC;IACtE,OAAO,aAAa,CAAC,QAAQ,EAAE,SAAS,EAAE,iBAAiB,CAAC,CAAC;AACjE,CAAC;AAED,SAAgB,YAAY,CAAC,UAAgC,EAAE;;IAC3D,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,cAAc;YAC7B,OAAO,EAAE,SAAS;YAClB,
|
|
1
|
+
{"version":3,"file":"DecimalField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DecimalField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAqF;AACrF,2CAAyD;AACzD,8CAAwD;AAU3C,QAAA,oBAAoB,GAAG,mBAAmB,CAAC;AAE3C,QAAA,oBAAoB,GAAG,mBAAmB,CAAC;AAExD,SAAS,aAAa,CAClB,UAAkB,EAClB,gBAA6D,EAC7D,iBAAqC;IAErC,OAAO,IAAA,4BAAU,EACb;QACI,IAAI,EAAE,4BAAoB;QAC1B,WAAW,EAAE,CAAC,UAAU,CAAC;QACzB,SAAS,EAAE;YACP,QAAQ,EAAE,CAAC,KAAK,EAAE,IAAI,EAAW,EAAE,CAAC,gBAAgB,CAAC,KAAK,EAAE,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,WAAW,CAAC,CAAC,CAAC,CAAC;SACpF;KACJ,EACD,iBAAiB,CACpB,CAAC;AACN,CAAC;AAED,SAAS,SAAS,CAAC,GAAY,EAAE,GAAW;IACxC,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,MAAM,CAAC,GAAG,CAAC,IAAI,GAAG,CAAC;AACpF,CAAC;AAED,SAAS,SAAS,CAAC,QAAgB,EAAE,iBAAqC;IACtE,OAAO,aAAa,CAAC,QAAQ,EAAE,SAAS,EAAE,iBAAiB,CAAC,CAAC;AACjE,CAAC;AAED,SAAS,SAAS,CAAC,GAAY,EAAE,GAAW;IACxC,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,MAAM,CA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= {}) {
|
|
|
33
33
|
(0, BaseField_1.BaseField)(options, {
|
|
34
34
|
decoratorName: 'DecimalNumberField',
|
|
35
35
|
appType: 'decimal',
|
|
36
|
-
|
|
36
|
+
swaggerType: 'number',
|
|
37
37
|
}),
|
|
38
38
|
(0, Transform_1.Transform)(({ value }) => value ? Number(value) : value, Transform_1.TRANSFORM_TYPE_FROM_DB),
|
|
39
39
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => value !== null && typeof value !== 'undefined'),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DecimalNumberField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DecimalNumberField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA6G;AAG7G,2CAAsC;AACtC,4CAA+D;AAC/D,8CAAwD;AAE3C,QAAA,iBAAiB,GAAG,iBAAiB,CAAC;AAEnD,SAAgB,eAAe,CAAC,KAAc,EAAE,OAA8B;;IAC1E,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAAE,OAAO,KAAK,CAAC;KAAE;IAEhD,OAAO,IAAA,2BAAS,EAAC,KAAK,CAAC,QAAQ,EAAE,EAAE;QAC/B,cAAc,EAAE,IAAI,GAAG,CAAC,MAAA,OAAO,CAAC,KAAK,mCAAI,8BAAqB,CAAC;KAClE,CAAC,CAAC;AACP,CAAC;AAND,0CAMC;AAED,SAAgB,eAAe,CAC3B,OAA8B,EAC9B,iBAAqC;IAErC,OAAO,IAAA,4BAAU,EACb;QACI,IAAI,EAAE,yBAAiB;QACvB,WAAW,EAAE,CAAC,OAAO,CAAC;QACtB,SAAS,EAAE;YACP,QAAQ,EAAE,CAAC,KAAK,EAAE,IAAI,EAAW,EAAE,CAAC,eAAe,CAAC,KAAK,EAAE,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,WAAW,CAAC,CAAC,CAAC,CAAC;YAChF,cAAc,EAAE,IAAA,8BAAY,EACxB,UAAU,CAAC,EAAE,CAAC,UAAU,GAAG,0CAA0C,EACrE,iBAAiB,CACpB;SACJ;KACJ,EACD,iBAAiB,CACpB,CAAC;AACN,CAAC;AAlBD,0CAkBC;AAED,SAAgB,kBAAkB,CAAC,UAAgC,EAAE;IACjE,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,oBAAoB;YACnC,OAAO,EAAE,SAAS;YAClB,
|
|
1
|
+
{"version":3,"file":"DecimalNumberField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DecimalNumberField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA6G;AAG7G,2CAAsC;AACtC,4CAA+D;AAC/D,8CAAwD;AAE3C,QAAA,iBAAiB,GAAG,iBAAiB,CAAC;AAEnD,SAAgB,eAAe,CAAC,KAAc,EAAE,OAA8B;;IAC1E,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;QAAE,OAAO,KAAK,CAAC;KAAE;IAEhD,OAAO,IAAA,2BAAS,EAAC,KAAK,CAAC,QAAQ,EAAE,EAAE;QAC/B,cAAc,EAAE,IAAI,GAAG,CAAC,MAAA,OAAO,CAAC,KAAK,mCAAI,8BAAqB,CAAC;KAClE,CAAC,CAAC;AACP,CAAC;AAND,0CAMC;AAED,SAAgB,eAAe,CAC3B,OAA8B,EAC9B,iBAAqC;IAErC,OAAO,IAAA,4BAAU,EACb;QACI,IAAI,EAAE,yBAAiB;QACvB,WAAW,EAAE,CAAC,OAAO,CAAC;QACtB,SAAS,EAAE;YACP,QAAQ,EAAE,CAAC,KAAK,EAAE,IAAI,EAAW,EAAE,CAAC,eAAe,CAAC,KAAK,EAAE,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,WAAW,CAAC,CAAC,CAAC,CAAC;YAChF,cAAc,EAAE,IAAA,8BAAY,EACxB,UAAU,CAAC,EAAE,CAAC,UAAU,GAAG,0CAA0C,EACrE,iBAAiB,CACpB;SACJ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, BaseField_1.BaseField)(options, {
|
|
11
11
|
decoratorName: 'DeleteDateField',
|
|
12
12
|
appType: 'date',
|
|
13
|
-
|
|
13
|
+
swaggerType: 'string',
|
|
14
14
|
}),
|
|
15
15
|
(0, Transform_1.Transform)(({ value }) => (0, DateField_1.normalizeDate)(value), Transform_1.TRANSFORM_TYPE_FROM_DB),
|
|
16
16
|
(0, Transform_1.Transform)(({ value }) => (0, DateField_1.normalizeDate)(value), Transform_1.TRANSFORM_TYPE_TO_DB),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DeleteDateField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DeleteDateField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AACzD,4CAAqF;AACrF,2CAA0C;AAE1C,SAAgB,eAAe,CAAC,UAA6B,EAAE;IAC3D,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,iBAAiB;YAChC,OAAO,EAAE,MAAM;YACf,
|
|
1
|
+
{"version":3,"file":"DeleteDateField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/DeleteDateField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AACzD,4CAAqF;AACrF,2CAA0C;AAE1C,SAAgB,eAAe,CAAC,UAA6B,EAAE;IAC3D,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,iBAAiB;YAChC,OAAO,EAAE,MAAM;YACf,WAAW,EAAE,QAAQ;SACxB,CAAC;QACF,IAAA,qBAAS,EAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,yBAAa,EAAC,KAAK,CAAC,EAAE,kCAAsB,CAAC;QACpE,IAAA,qBAAS,EAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,yBAAa,EAAC,KAAK,CAAC,EAAE,gCAAoB,CAAC;KACrE,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;AACvB,CAAC;AAVD,0CAUC"}
|
|
@@ -12,7 +12,7 @@ function EmailField(options = {}) {
|
|
|
12
12
|
(0, BaseField_1.BaseField)(options, {
|
|
13
13
|
decoratorName: 'EmailField',
|
|
14
14
|
appType: 'email',
|
|
15
|
-
|
|
15
|
+
swaggerType: 'string',
|
|
16
16
|
}),
|
|
17
17
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => value !== null && typeof value !== 'undefined'),
|
|
18
18
|
(0, class_validator_1.IsEmail)({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"EmailField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/EmailField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAoD;AACpD,2CAAyD;AAMzD,SAAgB,UAAU,CAAC,UAA8B,EAAE;IACvD,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,OAAO,CAAC;KAC3B;IAED,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,YAAY;YAC3B,OAAO,EAAE,OAAO;YAChB,
|
|
1
|
+
{"version":3,"file":"EmailField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/EmailField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAoD;AACpD,2CAAyD;AAMzD,SAAgB,UAAU,CAAC,UAA8B,EAAE;IACvD,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,OAAO,CAAC;KAC3B;IAED,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,YAAY;YAC3B,OAAO,EAAE,OAAO;YAChB,WAAW,EAAE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B;YACD,OAAO,GAAG,CAAC;QACf,CAAC,EAAE,EAAE,CAAC,CAAC;KACV;IAED,IAAI,OAAO,UAAU,KAAK,UAAU,IAAI,UAAU,CAAC,SAAS,YAAY,kBAAQ,EAAE;QAC9E,OAAO,UAAU,CAAC,MAAM,EAAE,CAAC;KAC9B;IAED,OAAO,UAAU,CAAC;AACtB,CAAC;AAED,SAAgB,SAAS,CAAC,OAA0B;IAChD,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,WAAW;YAC1B,OAAO,EAAE,MAAM;YACf,
|
|
1
|
+
{"version":3,"file":"EnumField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/EnumField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAmD;AACnD,6CAA4C;AAC5C,2CAAyD;AACzD,4DAAqD;AAYrD,SAAS,cAAc,CAAC,UAA6C;IACjE,IAAI,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE;QAC3B,OAAO,UAAU,CAAC;KACrB;IAED,IAAI,OAAO,UAAU,KAAK,UAAU,IAAI,UAAU,CAAC,SAAS,YAAY,kBAAQ,EAAE;QAC9E,OAAQ,UAA4B,CAAC,OAAO,EAAE,CAAC;KAClD;IAED,OAAO,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,CAAC;AACrC,CAAC;AAED,SAAS,gBAAgB,CAAC,UAAmC;IACzD,IAAI,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,EAAE;QAC3B,OAAO,UAAU,CAAC,MAAM,CAAC,CAAC,GAAG,EAAE,KAAK,EAAE,EAAE;YACpC,IAAI,KAAK,CAAC,SAAS,YAAY,kBAAQ,EAAE;gBACrC,GAAG,mCACI,GAAG,GACH,KAAK,CAAC,MAAM,EAAE,CACpB,CAAC;aACL;iBAAM,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;gBAClC,GAAG,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC;aACtB;YACD,OAAO,GAAG,CAAC;QACf,CAAC,EAAE,EAAE,CAAC,CAAC;KACV;IAED,IAAI,OAAO,UAAU,KAAK,UAAU,IAAI,UAAU,CAAC,SAAS,YAAY,kBAAQ,EAAE;QAC9E,OAAO,UAAU,CAAC,MAAM,EAAE,CAAC;KAC9B;IAED,OAAO,UAAU,CAAC;AACtB,CAAC;AAED,SAAgB,SAAS,CAAC,OAA0B;IAChD,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,WAAW;YAC1B,OAAO,EAAE,MAAM;YACf,WAAW,EAAE,QAAQ;SACxB,CAAC;QACF,IAAA,qBAAW,EAAC;YACR,IAAI,EAAE,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC;YAClC,QAAQ,EAAE,OAAO,CAAC,QAAQ;YAC1B,OAAO,EAAE,OAAO,CAAC,OAAO;SAC3B,CAAC;QACF,OAAO,CAAC,QAAQ,IAAI,IAAA,4BAAU,EAAC,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,WAAW,CAAC;QACjG,IAAA,wBAAM,EACF,gBAAgB,CAAC,OAAO,CAAC,IAAI,CAAC,EAC9B;YACI,IAAI,EAAE,OAAO,CAAC,OAAO;YACrB,OAAO,EAAE,OAAO,CAAC,uBAAuB,IAAI,2BAA2B;SAC1E,CACJ;KACJ,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;AACvB,CAAC;AArBD,8BAqBC"}
|
|
@@ -9,7 +9,7 @@ function getFileFieldDecorators(options) {
|
|
|
9
9
|
(0, BaseField_1.BaseField)(options, {
|
|
10
10
|
decoratorName: 'FileField',
|
|
11
11
|
appType: 'file',
|
|
12
|
-
|
|
12
|
+
swaggerType: 'number',
|
|
13
13
|
}),
|
|
14
14
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => value),
|
|
15
15
|
options.multiple
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/FileField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA2D;AAC3D,2CAAyD;AAOzD,SAAgB,sBAAsB,CAAC,OAAmB;IACtD,OAAO;QACH,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,WAAW;YAC1B,OAAO,EAAE,MAAM;YACf,
|
|
1
|
+
{"version":3,"file":"FileField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/FileField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA2D;AAC3D,2CAAyD;AAOzD,SAAgB,sBAAsB,CAAC,OAAmB;IACtD,OAAO;QACH,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,WAAW;YAC1B,OAAO,EAAE,MAAM;YACf,WAAW,EAAE,QAAQ;SACxB,CAAC;QACF,OAAO,CAAC,QAAQ,IAAI,IAAA,4BAAU,EAAC,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC;QACxD,OAAO,CAAC,QAAQ;YACZ,CAAC,CAAC,IAAA,yBAAO,EAAC;gBACN,OAAO,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,kCAAkC,CAAC,CAAC,CAAC,4BAA4B;aAC/F,CAAC;YACF,CAAC,CAAC,IAAA,uBAAK,EAAC;gBACJ,OAAO,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,kCAAkC,CAAC,CAAC,CAAC,2BAA2B;aAC9F,CAAC;KACT,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;AACtB,CAAC;AAhBD,wDAgBC;AAED,SAAgB,SAAS,CAAC,UAAsB,EAAE;IAC9C,OAAO,IAAA,wBAAe,EAClB,GAAG,sBAAsB,CAAC,OAAO,CAAC,CACrC,CAAC;AACN,CAAC;AAJD,8BAIC"}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import { ApiPropertyOptions } from '@nestjs/swagger';
|
|
1
2
|
import { IBaseFieldOptions } from './BaseField';
|
|
2
3
|
export interface IGeometryFieldOptions extends IBaseFieldOptions {
|
|
3
4
|
srid: number;
|
|
4
5
|
spatialFeatureType: string;
|
|
6
|
+
swaggerType?: ApiPropertyOptions['type'];
|
|
5
7
|
}
|
|
6
8
|
export declare function GeometryField(options?: IGeometryFieldOptions): <TFunction extends Function, Y>(target: object | TFunction, propertyKey?: string | symbol, descriptor?: TypedPropertyDescriptor<Y>) => void;
|
|
@@ -7,11 +7,12 @@ function GeometryField(options = {
|
|
|
7
7
|
srid: 4326,
|
|
8
8
|
spatialFeatureType: 'Polygon',
|
|
9
9
|
}) {
|
|
10
|
+
var _a;
|
|
10
11
|
return (0, common_1.applyDecorators)(...[
|
|
11
12
|
(0, BaseField_1.BaseField)(options, {
|
|
12
13
|
decoratorName: 'GeometryField',
|
|
13
14
|
appType: 'geometry',
|
|
14
|
-
|
|
15
|
+
swaggerType: (_a = options.swaggerType) !== null && _a !== void 0 ? _a : 'object',
|
|
15
16
|
}),
|
|
16
17
|
].filter(Boolean));
|
|
17
18
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GeometryField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/GeometryField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;
|
|
1
|
+
{"version":3,"file":"GeometryField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/GeometryField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAE/C,2CAAyD;AASzD,SAAgB,aAAa,CAAC,UAAiC;IAC3D,IAAI,EAAE,IAAI;IACV,kBAAkB,EAAE,SAAS;CAChC;;IACG,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,eAAe;YAC9B,OAAO,EAAE,UAAU;YACnB,WAAW,EAAE,MAAA,OAAO,CAAC,WAAW,mCAAI,QAAQ;SAC/C,CAAC;KACL,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;AACvB,CAAC;AAXD,sCAWC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"HtmlField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/HtmlField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AAEzD,SAAgB,SAAS,CAAC,UAA6B,EAAE;IACrD,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,WAAW;QAC1B,OAAO,EAAE,MAAM;QACf,
|
|
1
|
+
{"version":3,"file":"HtmlField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/HtmlField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AAEzD,SAAgB,SAAS,CAAC,UAA6B,EAAE;IACrD,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,WAAW;QAC1B,OAAO,EAAE,MAAM;QACf,WAAW,EAAE,QAAQ;KACxB,CAAC,CACL,CAAC;AACN,CAAC;AARD,8BAQC"}
|
|
@@ -13,7 +13,7 @@ function IntegerField(options = {}) {
|
|
|
13
13
|
(0, BaseField_1.BaseField)(options, {
|
|
14
14
|
decoratorName: 'IntegerField',
|
|
15
15
|
appType: 'integer',
|
|
16
|
-
|
|
16
|
+
swaggerType: 'number',
|
|
17
17
|
}),
|
|
18
18
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => options.isArray ? !isArrayEmpty(value) : !isEmpty(value)),
|
|
19
19
|
(0, Transform_1.Transform)(({ value }) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"IntegerField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/IntegerField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,mCAA+C;AAC/C,qDAA4D;AAC5D,2CAAyD;AACzD,4CAAuC;AASvC,MAAM,OAAO,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,IAAI,KAAK,KAAK,CAAC,IAAI,KAAK,KAAK,GAAG,CAAC;AAChE,MAAM,YAAY,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,MAAK,CAAC,CAAC,CAAC;AAEtF,SAAgB,YAAY,CAAC,UAAgC,EAAE;IAC3D,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,cAAc;YAC7B,OAAO,EAAE,SAAS;YAClB,
|
|
1
|
+
{"version":3,"file":"IntegerField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/IntegerField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,mCAA+C;AAC/C,qDAA4D;AAC5D,2CAAyD;AACzD,4CAAuC;AASvC,MAAM,OAAO,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,IAAI,KAAK,KAAK,CAAC,IAAI,KAAK,KAAK,GAAG,CAAC;AAChE,MAAM,YAAY,GAAG,KAAK,CAAC,EAAE,CAAC,CAAC,KAAK,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,MAAK,CAAC,CAAC,CAAC;AAEtF,SAAgB,YAAY,CAAC,UAAgC,EAAE;IAC3D,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,cAAc;YAC7B,OAAO,EAAE,SAAS;YAClB,WAAW,EAAE,QAAQ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MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;AACvB,CAAC;AA3BD,oCA2BC"}
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import { ApiPropertyOptions } from '@nestjs/swagger';
|
|
1
2
|
import { IBaseFieldOptions } from './BaseField';
|
|
2
|
-
export
|
|
3
|
+
export interface IJSONBFieldOptions extends IBaseFieldOptions {
|
|
4
|
+
swaggerType?: ApiPropertyOptions['type'];
|
|
5
|
+
}
|
|
3
6
|
export declare function JSONBField(options?: IJSONBFieldOptions): <TFunction extends Function, Y>(target: object | TFunction, propertyKey?: string | symbol, descriptor?: TypedPropertyDescriptor<Y>) => void;
|
|
@@ -5,12 +5,12 @@ const common_1 = require("@nestjs/common");
|
|
|
5
5
|
const class_validator_1 = require("class-validator");
|
|
6
6
|
const BaseField_1 = require("./BaseField");
|
|
7
7
|
function JSONBField(options = {}) {
|
|
8
|
+
var _a;
|
|
8
9
|
return (0, common_1.applyDecorators)(...[
|
|
9
10
|
(0, BaseField_1.BaseField)(options, {
|
|
10
11
|
decoratorName: 'JSONBField',
|
|
11
12
|
appType: 'object',
|
|
12
|
-
|
|
13
|
-
swaggerType: 'string',
|
|
13
|
+
swaggerType: (_a = options.swaggerType) !== null && _a !== void 0 ? _a : 'string',
|
|
14
14
|
}),
|
|
15
15
|
!options.required && (0, class_validator_1.IsOptional)(),
|
|
16
16
|
].filter(Boolean));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"JSONBField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/JSONBField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;
|
|
1
|
+
{"version":3,"file":"JSONBField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/JSONBField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAE/C,qDAA2C;AAC3C,2CAAyD;AAOzD,SAAgB,UAAU,CAAC,UAA8B,EAAE;;IACvD,OAAO,IAAA,wBAAe,EAAC,GAAG;QACtB,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,YAAY;YAC3B,OAAO,EAAE,QAAQ;YACjB,WAAW,EAAE,MAAA,OAAO,CAAC,WAAW,mCAAI,QAAQ;SAC/C,CAAC;QACF,CAAC,OAAO,CAAC,QAAQ,IAAI,IAAA,4BAAU,GAAE;KACpC,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;AACvB,CAAC;AATD,gCASC"}
|
|
@@ -9,7 +9,7 @@ function PasswordField(options = {}) {
|
|
|
9
9
|
return (0, common_1.applyDecorators)((0, BaseField_1.BaseField)(finalOptions, {
|
|
10
10
|
decoratorName: 'PasswordField',
|
|
11
11
|
appType: 'password',
|
|
12
|
-
|
|
12
|
+
swaggerType: 'string',
|
|
13
13
|
}), (0, class_validator_1.IsStrongPassword)({
|
|
14
14
|
minLength: finalOptions.minLength,
|
|
15
15
|
minLowercase: finalOptions.minLowercase,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PasswordField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/PasswordField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAiD;AACjD,2CAAyD;AAWzD,SAAgB,aAAa,CAAC,UAAiC,EAAE;IAC7D,MAAM,YAAY,mBACd,KAAK,EAAE,QAAQ,EACf,SAAS,EAAE,CAAC,EACZ,YAAY,EAAE,CAAC,EACf,YAAY,EAAE,CAAC,EACf,UAAU,EAAE,CAAC,EACb,UAAU,EAAE,CAAC,EACb,iCAAiC,EAAE,mBAAmB,IACnD,OAAO,CACb,CAAC;IAEF,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,YAAY,EAAE;QACpB,aAAa,EAAE,eAAe;QAC9B,OAAO,EAAE,UAAU;QACnB,
|
|
1
|
+
{"version":3,"file":"PasswordField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/PasswordField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAAiD;AACjD,2CAAyD;AAWzD,SAAgB,aAAa,CAAC,UAAiC,EAAE;IAC7D,MAAM,YAAY,mBACd,KAAK,EAAE,QAAQ,EACf,SAAS,EAAE,CAAC,EACZ,YAAY,EAAE,CAAC,EACf,YAAY,EAAE,CAAC,EACf,UAAU,EAAE,CAAC,EACb,UAAU,EAAE,CAAC,EACb,iCAAiC,EAAE,mBAAmB,IACnD,OAAO,CACb,CAAC;IAEF,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,YAAY,EAAE;QACpB,aAAa,EAAE,eAAe;QAC9B,OAAO,EAAE,UAAU;QACnB,WAAW,EAAE,QAAQ;KACxB,CAAC,EACF,IAAA,kCAAgB,EAAC;QACb,SAAS,EAAE,YAAY,CAAC,SAAS;QACjC,YAAY,EAAE,YAAY,CAAC,YAAY;QACvC,YAAY,EAAE,YAAY,CAAC,YAAY;QACvC,UAAU,EAAE,YAAY,CAAC,UAAU;QACnC,UAAU,EAAE,YAAY,CAAC,UAAU;KACtC,EAAE;QACC,IAAI,EAAE,YAAY,CAAC,OAAO;QAC1B,OAAO,EAAE,YAAY,CAAC,iCAAiC;KAC1D,CAAC,CACL,CAAC;AACN,CAAC;AA7BD,sCA6BC"}
|
|
@@ -21,7 +21,7 @@ function PhoneField(options = {}) {
|
|
|
21
21
|
(0, BaseField_1.BaseField)(options, {
|
|
22
22
|
decoratorName: 'PhoneField',
|
|
23
23
|
appType: 'phone',
|
|
24
|
-
|
|
24
|
+
swaggerType: 'string',
|
|
25
25
|
}),
|
|
26
26
|
options.nullable && (0, class_validator_1.ValidateIf)((object, value) => value),
|
|
27
27
|
(0, Transform_1.Transform)(({ value }) => (0, exports.normalizePhone)(value)),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PhoneField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/PhoneField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA0D;AAC1D,2CAAyD;AACzD,4CAAuC;AAOhC,MAAM,cAAc,GAAG,KAAK,CAAC,EAAE,CAAC,KAAK;IACxC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC;SACV,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC;SACtB,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC;SACnB,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC;SACnB,OAAO,CAAC,KAAK,EAAE,GAAG,CAAC;IACxB,CAAC,CAAC,KAAK,CAAC;AANC,QAAA,cAAc,kBAMf;AAEZ,SAAgB,UAAU,CAAC,UAA8B,EAAE;IACvD,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,SAAS,CAAC;KAC7B;IAED,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,YAAY;YAC3B,OAAO,EAAE,OAAO;YAChB,
|
|
1
|
+
{"version":3,"file":"PhoneField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/PhoneField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,qDAA0D;AAC1D,2CAAyD;AACzD,4CAAuC;AAOhC,MAAM,cAAc,GAAG,KAAK,CAAC,EAAE,CAAC,KAAK;IACxC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC;SACV,OAAO,CAAC,SAAS,EAAE,EAAE,CAAC;SACtB,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC;SACnB,OAAO,CAAC,IAAI,EAAE,IAAI,CAAC;SACnB,OAAO,CAAC,KAAK,EAAE,GAAG,CAAC;IACxB,CAAC,CAAC,KAAK,CAAC;AANC,QAAA,cAAc,kBAMf;AAEZ,SAAgB,UAAU,CAAC,UAA8B,EAAE;IACvD,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,SAAS,CAAC;KAC7B;IAED,OAAO,IAAA,wBAAe,EAClB,GAAG;QACC,IAAA,qBAAS,EAAC,OAAO,EAAE;YACf,aAAa,EAAE,YAAY;YAC3B,OAAO,EAAE,OAAO;YAChB,WAAW,EAAE,QAAQ;SACxB,CAAC;QACF,OAAO,CAAC,QAAQ,IAAI,IAAA,4BAAU,EAAC,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC;QACxD,IAAA,qBAAS,EAAC,CAAC,EAAC,KAAK,EAAC,EAAE,EAAE,CAAC,IAAA,sBAAc,EAAC,KAAK,CAAC,CAAC;QAC7C,IAAA,+BAAa,EAAC,IAAI,EAAE;YAChB,OAAO,EAAE,OAAO,CAAC,iBAAiB,IAAI,6BAA6B;SACtE,CAAC;KACL,CAAC,MAAM,CAAC,OAAO,CAAC,CACpB,CAAC;AACN,CAAC;AAnBD,gCAmBC"}
|
|
@@ -10,7 +10,7 @@ function PrimaryKeyField(options = {}) {
|
|
|
10
10
|
return (0, common_1.applyDecorators)((0, BaseField_1.BaseField)(options, {
|
|
11
11
|
decoratorName: 'PrimaryKeyField',
|
|
12
12
|
appType: 'primaryKey',
|
|
13
|
-
|
|
13
|
+
swaggerType: 'number',
|
|
14
14
|
}));
|
|
15
15
|
}
|
|
16
16
|
exports.PrimaryKeyField = PrimaryKeyField;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PrimaryKeyField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/PrimaryKeyField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AAEzD,SAAgB,eAAe,CAAC,UAA6B,EAAE;IAC3D,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,IAAI,CAAC;KACxB;IAED,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,iBAAiB;QAChC,OAAO,EAAE,YAAY;QACrB,
|
|
1
|
+
{"version":3,"file":"PrimaryKeyField.js","sourceRoot":"","sources":["../../../../src/infrastructure/decorators/fields/PrimaryKeyField.ts"],"names":[],"mappings":";;;AAAA,2CAA+C;AAC/C,2CAAyD;AAEzD,SAAgB,eAAe,CAAC,UAA6B,EAAE;IAC3D,IAAI,CAAC,OAAO,CAAC,KAAK,EAAE;QAChB,OAAO,CAAC,KAAK,GAAG,IAAI,CAAC;KACxB;IAED,OAAO,IAAA,wBAAe,EAClB,IAAA,qBAAS,EAAC,OAAO,EAAE;QACf,aAAa,EAAE,iBAAiB;QAChC,OAAO,EAAE,YAAY;QACrB,WAAW,EAAE,QAAQ;KACxB,CAAC,CACL,CAAC;AACN,CAAC;AAZD,0CAYC"}
|