cecon-interfaces 1.4.31 → 1.5.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (26) hide show
  1. package/dist/esm2022/mobyo/resumes/vouchers/entities/index.mjs +4 -0
  2. package/dist/esm2022/mobyo/resumes/vouchers/entities/resume-voucher-item-detail.entity.mjs +17 -0
  3. package/dist/esm2022/mobyo/resumes/vouchers/entities/resume-voucher-item.entity.mjs +15 -0
  4. package/dist/esm2022/mobyo/resumes/vouchers/entities/resume-voucher.entity.mjs +21 -0
  5. package/dist/esm2022/mobyo/resumes/vouchers/index.mjs +2 -1
  6. package/dist/esm2022/mobyo/resumes/vouchers/interfaces/i-resume-voucher-item.mjs +1 -1
  7. package/dist/esm2022/mobyo/resumes/vouchers/interfaces/index.mjs +1 -1
  8. package/dist/esm2022/voucher/entities/voucher.entity.mjs +4 -4
  9. package/dist/esm2022/voucher/interfaces/i-voucher.mjs +1 -1
  10. package/dist/fesm2022/cecon-interfaces.mjs +54 -4
  11. package/dist/fesm2022/cecon-interfaces.mjs.map +1 -1
  12. package/dist/mobyo/resumes/vouchers/entities/index.d.ts +3 -0
  13. package/dist/mobyo/resumes/vouchers/entities/index.js +9 -0
  14. package/dist/mobyo/resumes/vouchers/entities/resume-voucher-item-detail.entity.d.ts +10 -0
  15. package/dist/mobyo/resumes/vouchers/entities/resume-voucher-item-detail.entity.js +21 -0
  16. package/dist/mobyo/resumes/vouchers/entities/resume-voucher-item.entity.d.ts +7 -0
  17. package/dist/mobyo/resumes/vouchers/entities/resume-voucher-item.entity.js +19 -0
  18. package/dist/mobyo/resumes/vouchers/entities/resume-voucher.entity.d.ts +20 -0
  19. package/dist/mobyo/resumes/vouchers/entities/resume-voucher.entity.js +25 -0
  20. package/dist/mobyo/resumes/vouchers/index.d.ts +1 -0
  21. package/dist/mobyo/resumes/vouchers/index.js +1 -0
  22. package/dist/package.json +1 -1
  23. package/dist/voucher/entities/voucher.entity.d.ts +2 -2
  24. package/dist/voucher/entities/voucher.entity.js +3 -3
  25. package/dist/voucher/interfaces/i-voucher.d.ts +2 -2
  26. package/package.json +1 -1
@@ -0,0 +1,3 @@
1
+ export { ResumeVoucherItemDetailEntity } from './resume-voucher-item-detail.entity';
2
+ export { ResumeVoucherItemEntity } from './resume-voucher-item.entity';
3
+ export { ResumeVoucherEntity } from './resume-voucher.entity';
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ResumeVoucherEntity = exports.ResumeVoucherItemEntity = exports.ResumeVoucherItemDetailEntity = void 0;
4
+ var resume_voucher_item_detail_entity_1 = require("./resume-voucher-item-detail.entity");
5
+ Object.defineProperty(exports, "ResumeVoucherItemDetailEntity", { enumerable: true, get: function () { return resume_voucher_item_detail_entity_1.ResumeVoucherItemDetailEntity; } });
6
+ var resume_voucher_item_entity_1 = require("./resume-voucher-item.entity");
7
+ Object.defineProperty(exports, "ResumeVoucherItemEntity", { enumerable: true, get: function () { return resume_voucher_item_entity_1.ResumeVoucherItemEntity; } });
8
+ var resume_voucher_entity_1 = require("./resume-voucher.entity");
9
+ Object.defineProperty(exports, "ResumeVoucherEntity", { enumerable: true, get: function () { return resume_voucher_entity_1.ResumeVoucherEntity; } });
@@ -0,0 +1,10 @@
1
+ import { ICoords } from '../../../../general';
2
+ import { IResumeVoucherItemDetail } from '../interfaces';
3
+ export declare class ResumeVoucherItemDetailEntity implements IResumeVoucherItemDetail {
4
+ cords: ICoords[];
5
+ count: number;
6
+ orderItemsCount: number;
7
+ totalAmount: number;
8
+ totalDiscount: number;
9
+ constructor(data?: Partial<ResumeVoucherItemDetailEntity>);
10
+ }
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ResumeVoucherItemDetailEntity = void 0;
4
+ var ResumeVoucherItemDetailEntity = /** @class */ (function () {
5
+ function ResumeVoucherItemDetailEntity(data) {
6
+ this.cords = [];
7
+ this.count = 0;
8
+ this.orderItemsCount = 0;
9
+ this.totalAmount = 0;
10
+ this.totalDiscount = 0;
11
+ if (data) {
12
+ for (var key in data) {
13
+ if (data.hasOwnProperty(key) && key in this) {
14
+ this[key] = data[key];
15
+ }
16
+ }
17
+ }
18
+ }
19
+ return ResumeVoucherItemDetailEntity;
20
+ }());
21
+ exports.ResumeVoucherItemDetailEntity = ResumeVoucherItemDetailEntity;
@@ -0,0 +1,7 @@
1
+ import { IResumeVoucherItem } from '../interfaces';
2
+ import { ResumeVoucherItemDetailEntity } from './resume-voucher-item-detail.entity';
3
+ export declare class ResumeVoucherItemEntity implements IResumeVoucherItem {
4
+ confirmed: ResumeVoucherItemDetailEntity;
5
+ cancelled: ResumeVoucherItemDetailEntity;
6
+ constructor(data?: Partial<ResumeVoucherItemEntity>);
7
+ }
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ResumeVoucherItemEntity = void 0;
4
+ var resume_voucher_item_detail_entity_1 = require("./resume-voucher-item-detail.entity");
5
+ var ResumeVoucherItemEntity = /** @class */ (function () {
6
+ function ResumeVoucherItemEntity(data) {
7
+ this.confirmed = new resume_voucher_item_detail_entity_1.ResumeVoucherItemDetailEntity();
8
+ this.cancelled = new resume_voucher_item_detail_entity_1.ResumeVoucherItemDetailEntity();
9
+ if (data) {
10
+ for (var key in data) {
11
+ if (data.hasOwnProperty(key) && key in this) {
12
+ this[key] = data[key];
13
+ }
14
+ }
15
+ }
16
+ }
17
+ return ResumeVoucherItemEntity;
18
+ }());
19
+ exports.ResumeVoucherItemEntity = ResumeVoucherItemEntity;
@@ -0,0 +1,20 @@
1
+ import { IMobyoInfo, INatiInfo } from '../../../../general';
2
+ import { EVoucherTargetTypes } from '../../../../voucher';
3
+ import { IResumeVoucher } from '../interfaces';
4
+ import { ResumeVoucherItemEntity } from './resume-voucher-item.entity';
5
+ export declare class ResumeVoucherEntity implements IResumeVoucher {
6
+ id: string;
7
+ createdAt: Date;
8
+ updatedAt: Date;
9
+ item: ResumeVoucherItemEntity;
10
+ items: {
11
+ id: string;
12
+ item: ResumeVoucherItemEntity;
13
+ }[];
14
+ targetType: {
15
+ id: EVoucherTargetTypes;
16
+ item: ResumeVoucherItemEntity;
17
+ }[];
18
+ info: IMobyoInfo | INatiInfo;
19
+ constructor(data?: Partial<ResumeVoucherEntity>);
20
+ }
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ResumeVoucherEntity = void 0;
4
+ var general_1 = require("../../../../general");
5
+ var resume_voucher_item_entity_1 = require("./resume-voucher-item.entity");
6
+ var ResumeVoucherEntity = /** @class */ (function () {
7
+ function ResumeVoucherEntity(data) {
8
+ this.id = ''; // padrão AAAAMMDD
9
+ this.createdAt = new Date();
10
+ this.updatedAt = new Date();
11
+ this.item = new resume_voucher_item_entity_1.ResumeVoucherItemEntity();
12
+ this.items = []; // id no padrão MM - DD - HH
13
+ this.targetType = [];
14
+ this.info = new general_1.MobyoInfoEntity();
15
+ if (data) {
16
+ for (var key in data) {
17
+ if (data.hasOwnProperty(key) && key in this) {
18
+ this[key] = data[key];
19
+ }
20
+ }
21
+ }
22
+ }
23
+ return ResumeVoucherEntity;
24
+ }());
25
+ exports.ResumeVoucherEntity = ResumeVoucherEntity;
@@ -1 +1,2 @@
1
+ export * from './entities';
1
2
  export * from './interfaces';
@@ -14,4 +14,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./entities"), exports);
17
18
  __exportStar(require("./interfaces"), exports);
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cecon-interfaces",
3
- "version": "1.4.31",
3
+ "version": "1.5.02",
4
4
  "description": "Interfaces de Projetos Cecon",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -3,13 +3,13 @@ import { EVoucherStatus, EVoucherTargetTypes } from '../enums';
3
3
  import { IVoucher, IVoucherRule, IVoucherSponsorship } from '../interfaces';
4
4
  export declare class VoucherEntity implements IVoucher {
5
5
  info: IMobyoInfo | INatiInfo;
6
- concludedAt: Date;
6
+ concludedAt: Date | null;
7
7
  createdAt: Date;
8
8
  id: string;
9
9
  isPublic: boolean;
10
10
  key: string;
11
11
  name: string;
12
- activatedAt: Date;
12
+ activatedAt: Date | null;
13
13
  rules: IVoucherRule[];
14
14
  type: EDiscountType;
15
15
  amount: number;
@@ -7,18 +7,18 @@ var VoucherEntity = /** @class */ (function () {
7
7
  function VoucherEntity(data) {
8
8
  // #region Properties (10)
9
9
  this.info = new general_1.MobyoInfoEntity();
10
- this.concludedAt = new Date();
10
+ this.concludedAt = null;
11
11
  this.createdAt = new Date();
12
12
  this.id = '';
13
13
  this.isPublic = false;
14
14
  this.key = '';
15
15
  this.name = '';
16
- this.activatedAt = new Date();
16
+ this.activatedAt = null;
17
17
  this.rules = [];
18
18
  this.type = general_1.EDiscountType.PERCENT;
19
19
  this.amount = 0;
20
20
  this.sponsorship = [];
21
- this.status = enums_1.EVoucherStatus.ACTIVE;
21
+ this.status = enums_1.EVoucherStatus.PLACED;
22
22
  this.targetsId = [];
23
23
  this.targetType = enums_1.EVoucherTargetTypes.CART;
24
24
  this.updatedAt = new Date();
@@ -5,13 +5,13 @@ import { IVoucherRule } from './i-voucher-rule';
5
5
  import { IVoucherSponsorship } from './i-voucher-sponsorship';
6
6
  export interface IVoucher {
7
7
  info: IMobyoInfo | INatiInfo;
8
- concludedAt: Date;
8
+ concludedAt: Date | null;
9
9
  createdAt: Date;
10
10
  id: string;
11
11
  isPublic: boolean;
12
12
  key: string;
13
13
  name: string;
14
- activatedAt: Date;
14
+ activatedAt: Date | null;
15
15
  rules: IVoucherRule[];
16
16
  type: EDiscountType;
17
17
  amount: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cecon-interfaces",
3
- "version": "1.4.31",
3
+ "version": "1.5.02",
4
4
  "description": "Interfaces de Projetos Cecon",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",