@merkaly/api 0.2.4-10 → 0.2.4-12
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/.output/modules/inventory/brands/brand.entity.d.ts +2 -0
- package/.output/modules/inventory/brands/brand.validator.d.ts +2 -0
- package/.output/modules/inventory/brands/brand.validator.js +9 -0
- package/.output/modules/inventory/categories/category.entity.d.ts +2 -0
- package/.output/modules/inventory/categories/category.validator.d.ts +2 -0
- package/.output/modules/inventory/categories/category.validator.js +9 -0
- package/.output/modules/sales/clients/client.entity.d.ts +2 -1
- package/.output/modules/sales/clients/client.validator.d.ts +5 -2
- package/.output/modules/sales/clients/client.validator.js +13 -1
- package/README.md +1 -1
- package/package.json +6 -6
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import { AbstractEntity } from '../../../abstract/abstract.entity';
|
|
2
|
+
import { AssetEntity } from '../../assets/asset.entity';
|
|
2
3
|
export declare class BrandEntity extends AbstractEntity {
|
|
3
4
|
static readonly $index = "inventory_brands";
|
|
4
5
|
name: string;
|
|
5
6
|
description: string;
|
|
7
|
+
image: AssetEntity;
|
|
6
8
|
}
|
|
@@ -2,8 +2,10 @@ import { AbstractValidator } from "../../../abstract/abstract.validator";
|
|
|
2
2
|
export declare class CreateBrandValidator extends AbstractValidator {
|
|
3
3
|
name: string;
|
|
4
4
|
description?: string;
|
|
5
|
+
image: string;
|
|
5
6
|
}
|
|
6
7
|
export declare class UpdateBrandValidator extends AbstractValidator {
|
|
7
8
|
name?: string;
|
|
8
9
|
description?: string;
|
|
10
|
+
image: string;
|
|
9
11
|
}
|
|
@@ -42,6 +42,10 @@ var CreateBrandValidator = (function (_super) {
|
|
|
42
42
|
(0, class_validator_1.IsOptional)(),
|
|
43
43
|
__metadata("design:type", String)
|
|
44
44
|
], CreateBrandValidator.prototype, "description", void 0);
|
|
45
|
+
__decorate([
|
|
46
|
+
(0, class_validator_1.IsMongoId)(),
|
|
47
|
+
__metadata("design:type", String)
|
|
48
|
+
], CreateBrandValidator.prototype, "image", void 0);
|
|
45
49
|
return CreateBrandValidator;
|
|
46
50
|
}(abstract_validator_1.AbstractValidator));
|
|
47
51
|
exports.CreateBrandValidator = CreateBrandValidator;
|
|
@@ -61,6 +65,11 @@ var UpdateBrandValidator = (function (_super) {
|
|
|
61
65
|
(0, class_validator_1.IsOptional)(),
|
|
62
66
|
__metadata("design:type", String)
|
|
63
67
|
], UpdateBrandValidator.prototype, "description", void 0);
|
|
68
|
+
__decorate([
|
|
69
|
+
(0, class_validator_1.IsMongoId)(),
|
|
70
|
+
(0, class_validator_1.IsOptional)(),
|
|
71
|
+
__metadata("design:type", String)
|
|
72
|
+
], UpdateBrandValidator.prototype, "image", void 0);
|
|
64
73
|
return UpdateBrandValidator;
|
|
65
74
|
}(abstract_validator_1.AbstractValidator));
|
|
66
75
|
exports.UpdateBrandValidator = UpdateBrandValidator;
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { AbstractEntity } from '../../../abstract/abstract.entity';
|
|
2
2
|
import { PropertyEntity } from '../properties/property.entity';
|
|
3
|
+
import { AssetEntity } from '../../assets/asset.entity';
|
|
3
4
|
export declare class CategoryEntity extends AbstractEntity {
|
|
4
5
|
static readonly $index = "inventory_categories";
|
|
5
6
|
name: string;
|
|
6
7
|
description: string;
|
|
7
8
|
icon: string;
|
|
8
9
|
properties: PropertyEntity[];
|
|
10
|
+
image: AssetEntity;
|
|
9
11
|
}
|
|
@@ -3,9 +3,11 @@ export declare class CreateCategoryValidator extends AbstractValidator {
|
|
|
3
3
|
name: string;
|
|
4
4
|
description?: string;
|
|
5
5
|
icon: string;
|
|
6
|
+
image: string;
|
|
6
7
|
}
|
|
7
8
|
export declare class UpdateCategoryValidator extends AbstractValidator {
|
|
8
9
|
name: string;
|
|
9
10
|
description?: string;
|
|
10
11
|
icon: string;
|
|
12
|
+
image: string;
|
|
11
13
|
}
|
|
@@ -49,6 +49,10 @@ var CreateCategoryValidator = (function (_super) {
|
|
|
49
49
|
(0, class_validator_1.IsOptional)(),
|
|
50
50
|
__metadata("design:type", Object)
|
|
51
51
|
], CreateCategoryValidator.prototype, "icon", void 0);
|
|
52
|
+
__decorate([
|
|
53
|
+
(0, class_validator_1.IsMongoId)(),
|
|
54
|
+
__metadata("design:type", String)
|
|
55
|
+
], CreateCategoryValidator.prototype, "image", void 0);
|
|
52
56
|
return CreateCategoryValidator;
|
|
53
57
|
}(abstract_validator_1.AbstractValidator));
|
|
54
58
|
exports.CreateCategoryValidator = CreateCategoryValidator;
|
|
@@ -74,6 +78,11 @@ var UpdateCategoryValidator = (function (_super) {
|
|
|
74
78
|
(0, class_validator_1.IsOptional)(),
|
|
75
79
|
__metadata("design:type", Object)
|
|
76
80
|
], UpdateCategoryValidator.prototype, "icon", void 0);
|
|
81
|
+
__decorate([
|
|
82
|
+
(0, class_validator_1.IsMongoId)(),
|
|
83
|
+
(0, class_validator_1.IsOptional)(),
|
|
84
|
+
__metadata("design:type", String)
|
|
85
|
+
], UpdateCategoryValidator.prototype, "image", void 0);
|
|
77
86
|
return UpdateCategoryValidator;
|
|
78
87
|
}(abstract_validator_1.AbstractValidator));
|
|
79
88
|
exports.UpdateCategoryValidator = UpdateCategoryValidator;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { User } from 'auth0';
|
|
2
2
|
import { AbstractEntity } from '../../../abstract/abstract.entity';
|
|
3
|
-
import { MetaAddress } from
|
|
3
|
+
import { MetaAddress } from '../../../types';
|
|
4
4
|
export declare class ClientEntity extends AbstractEntity implements User {
|
|
5
5
|
static readonly $index = "store_clients";
|
|
6
6
|
readonly name: string;
|
|
@@ -8,4 +8,5 @@ export declare class ClientEntity extends AbstractEntity implements User {
|
|
|
8
8
|
readonly phone?: string;
|
|
9
9
|
readonly identificationNumber: string;
|
|
10
10
|
readonly addresses: MetaAddress[];
|
|
11
|
+
users: string[];
|
|
11
12
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MetaAddress } from
|
|
2
|
-
import { AbstractValidator } from
|
|
1
|
+
import { MetaAddress } from '../../../types';
|
|
2
|
+
import { AbstractValidator } from '../../../abstract/abstract.validator';
|
|
3
3
|
export declare class CreateClientValidator extends AbstractValidator {
|
|
4
4
|
name: string;
|
|
5
5
|
email: string;
|
|
@@ -13,3 +13,6 @@ export declare class UpdateClientValidator extends CreateClientValidator {
|
|
|
13
13
|
phone: string;
|
|
14
14
|
identificationNumber: string;
|
|
15
15
|
}
|
|
16
|
+
export declare class AddClientUsers {
|
|
17
|
+
ids: string[];
|
|
18
|
+
}
|
|
@@ -24,7 +24,7 @@ var __metadata = (this && this.__metadata) || function (k, v) {
|
|
|
24
24
|
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
|
|
25
25
|
};
|
|
26
26
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
|
-
exports.UpdateClientValidator = exports.CreateClientValidator = void 0;
|
|
27
|
+
exports.AddClientUsers = exports.UpdateClientValidator = exports.CreateClientValidator = void 0;
|
|
28
28
|
var class_transformer_1 = require("class-transformer");
|
|
29
29
|
var class_validator_1 = require("class-validator");
|
|
30
30
|
var abstract_validator_1 = require("../../../abstract/abstract.validator");
|
|
@@ -93,3 +93,15 @@ var UpdateClientValidator = (function (_super) {
|
|
|
93
93
|
return UpdateClientValidator;
|
|
94
94
|
}(CreateClientValidator));
|
|
95
95
|
exports.UpdateClientValidator = UpdateClientValidator;
|
|
96
|
+
var AddClientUsers = (function () {
|
|
97
|
+
function AddClientUsers() {
|
|
98
|
+
}
|
|
99
|
+
__decorate([
|
|
100
|
+
(0, class_validator_1.IsArray)(),
|
|
101
|
+
(0, class_validator_1.IsString)({ each: true }),
|
|
102
|
+
(0, class_validator_1.ArrayMinSize)(1),
|
|
103
|
+
__metadata("design:type", Array)
|
|
104
|
+
], AddClientUsers.prototype, "ids", void 0);
|
|
105
|
+
return AddClientUsers;
|
|
106
|
+
}());
|
|
107
|
+
exports.AddClientUsers = AddClientUsers;
|
package/README.md
CHANGED
|
@@ -43,7 +43,7 @@ $ yarn install
|
|
|
43
43
|
|
|
44
44
|
```bash
|
|
45
45
|
$ mkdir ".cert"
|
|
46
|
-
$ openssl req -x509 -
|
|
46
|
+
$ openssl req -x509 -newkey rsa:4096 -nodes -keyout ./.cert/key.pem -out ./.cert/cert.pem -days 365
|
|
47
47
|
```
|
|
48
48
|
|
|
49
49
|
## Running the app
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@merkaly/api",
|
|
3
|
-
"version": "0.2.4-
|
|
3
|
+
"version": "0.2.4-12",
|
|
4
4
|
"description": "NestJS Backend ApiRest Service",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -55,11 +55,11 @@
|
|
|
55
55
|
"@nestjs/mongoose": "^9.2.0",
|
|
56
56
|
"@nestjs/passport": "^9.0.0",
|
|
57
57
|
"@nestjs/platform-express": "^9.0.11",
|
|
58
|
-
"@nestjs/platform-socket.io": "^9.
|
|
58
|
+
"@nestjs/platform-socket.io": "^9.4.0",
|
|
59
59
|
"@nestjs/schematics": "^9.0.1",
|
|
60
60
|
"@nestjs/swagger": "^6.1.0",
|
|
61
61
|
"@nestjs/testing": "^9.0.11",
|
|
62
|
-
"@nestjs/websockets": "^9.
|
|
62
|
+
"@nestjs/websockets": "^9.4.0",
|
|
63
63
|
"@types/cache-manager": "^4.0.1",
|
|
64
64
|
"@types/express": "^4.17.12",
|
|
65
65
|
"@types/express-session": "^1.17.5",
|
|
@@ -98,10 +98,10 @@
|
|
|
98
98
|
"typescript": "4.4.4",
|
|
99
99
|
"webpack": "^5"
|
|
100
100
|
},
|
|
101
|
-
"engines": {
|
|
102
|
-
"node": "^16"
|
|
103
|
-
},
|
|
104
101
|
"publishConfig": {
|
|
105
102
|
"access": "public"
|
|
103
|
+
},
|
|
104
|
+
"engines": {
|
|
105
|
+
"node": ">=16"
|
|
106
106
|
}
|
|
107
107
|
}
|