@carlosdiazz/lottodiz-shared 3.5.5 → 3.5.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/dist/enum/method-valid.d.ts +0 -4
  2. package/dist/enum/method-valid.js +0 -5
  3. package/dist/enum/operation-type.enum.d.ts +5 -0
  4. package/dist/enum/operation-type.enum.js +7 -1
  5. package/dist/models/account/account.base.d.ts +0 -9
  6. package/dist/models/account/account.controller.d.ts +0 -4
  7. package/dist/models/account/account.datasource.d.ts +0 -6
  8. package/dist/models/account/account.resolver.d.ts +0 -4
  9. package/dist/models/account/account.service.d.ts +0 -4
  10. package/dist/models/account/index.d.ts +0 -2
  11. package/dist/models/account/index.js +0 -2
  12. package/dist/models/account/update-account.base.d.ts +1 -0
  13. package/dist/models/leader_entries/index.d.ts +0 -5
  14. package/dist/models/leader_entries/index.js +0 -5
  15. package/dist/models/leader_entries/leader_entries.service.d.ts +0 -3
  16. package/dist/models/operation/index.d.ts +0 -1
  17. package/dist/models/operation/index.js +0 -1
  18. package/dist/models/operation/operation.controller.d.ts +1 -2
  19. package/dist/models/operation/operation.datasource.d.ts +1 -2
  20. package/dist/models/operation/operation.resolver.d.ts +1 -2
  21. package/dist/models/operation/operation.service.d.ts +1 -2
  22. package/dist/models/operation/params-operation.base.d.ts +5 -8
  23. package/dist/models/ticket/index.d.ts +0 -1
  24. package/dist/models/ticket/index.js +0 -1
  25. package/dist/models/ticket/params-ticket.base.d.ts +19 -16
  26. package/dist/models/ticket/ticket-detail.base.d.ts +1 -1
  27. package/dist/models/ticket/ticket.controller.d.ts +1 -2
  28. package/dist/models/ticket/ticket.datasource.d.ts +1 -2
  29. package/dist/models/ticket/ticket.resolver.d.ts +1 -2
  30. package/dist/models/ticket/ticket.service.d.ts +1 -2
  31. package/package.json +1 -1
@@ -230,11 +230,7 @@ export declare class MethodValid {
230
230
  static ACCOUNT_TYPE_FIND_ALL: string;
231
231
  static ACCOUNT_TYPE_UPDATE: string;
232
232
  static ACCOUNT_TYPE_REMOVE: string;
233
- static ACCOUNT_FIND_ONE: string;
234
- static ACCOUNT_FIND_ALL: string;
235
233
  static ACCOUNT_UPDATE: string;
236
- static LEADER_ENTRIES_FIND_ALL: string;
237
- static LEADER_ENTRIES_FIND_ONE: string;
238
234
  static TICKET_CREATE: string;
239
235
  static TICKET_FIND_ONE: string;
240
236
  static TICKET_FIND_ALL: string;
@@ -276,12 +276,7 @@ MethodValid.ACCOUNT_TYPE_FIND_ALL = "ACCOUNT_TYPE_FIND_ALL";
276
276
  MethodValid.ACCOUNT_TYPE_UPDATE = "ACCOUNT_TYPE_UPDATE";
277
277
  MethodValid.ACCOUNT_TYPE_REMOVE = "ACCOUNT_TYPE_REMOVE";
278
278
  // Account
279
- MethodValid.ACCOUNT_FIND_ONE = "ACCOUNT_FIND_ONE";
280
- MethodValid.ACCOUNT_FIND_ALL = "ACCOUNT_FIND_ALL";
281
279
  MethodValid.ACCOUNT_UPDATE = "ACCOUNT_UPDATE";
282
- // Transaction
283
- MethodValid.LEADER_ENTRIES_FIND_ALL = "LEADER_ENTRIES_FIND_ALL";
284
- MethodValid.LEADER_ENTRIES_FIND_ONE = "LEADER_ENTRIES_FIND_ONE";
285
280
  // Ticket
286
281
  MethodValid.TICKET_CREATE = "TICKET_CREATE";
287
282
  MethodValid.TICKET_FIND_ONE = "TICKET_FIND_ONE";
@@ -7,3 +7,8 @@ export declare enum OperationType {
7
7
  TRANSFER_GROUP = "TRANSFER_GROUP",
8
8
  TRANSFER_COMPANY = "TRANSFER_COMPANY"
9
9
  }
10
+ export declare enum FilterTicketType {
11
+ GREATER_THAN = "GREATER_THAN",
12
+ LESS_THAN = "LESS_THAN",
13
+ EQUAL_TO = "EQUAL_TO"
14
+ }
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.OperationType = void 0;
3
+ exports.FilterTicketType = exports.OperationType = void 0;
4
4
  var OperationType;
5
5
  (function (OperationType) {
6
6
  OperationType["TICKET_SALE"] = "TICKET_SALE";
@@ -11,3 +11,9 @@ var OperationType;
11
11
  OperationType["TRANSFER_GROUP"] = "TRANSFER_GROUP";
12
12
  OperationType["TRANSFER_COMPANY"] = "TRANSFER_COMPANY";
13
13
  })(OperationType || (exports.OperationType = OperationType = {}));
14
+ var FilterTicketType;
15
+ (function (FilterTicketType) {
16
+ FilterTicketType["GREATER_THAN"] = "GREATER_THAN";
17
+ FilterTicketType["LESS_THAN"] = "LESS_THAN";
18
+ FilterTicketType["EQUAL_TO"] = "EQUAL_TO";
19
+ })(FilterTicketType || (exports.FilterTicketType = FilterTicketType = {}));
@@ -13,12 +13,3 @@ export interface AccountInterface {
13
13
  create_at: Date;
14
14
  update_at: Date;
15
15
  }
16
- export interface AccountFormInterface {
17
- id: string;
18
- id_account_type: string;
19
- owner_type: AccountOwnerType;
20
- owner_id: string;
21
- balance: number;
22
- currency: string;
23
- active: boolean;
24
- }
@@ -1,9 +1,5 @@
1
1
  import { AccountInterface } from "./account.base";
2
- import { ParamsAccountInterface } from "./params-account.base";
3
- import { ResponseAccountInterface } from "./response-account.base";
4
2
  import { UpdateAccountInterface } from "./update-account.base";
5
3
  export interface AccountControllerInterface {
6
- findAll(pagination: ParamsAccountInterface): Promise<ResponseAccountInterface>;
7
- findOne(id: string): Promise<AccountInterface>;
8
4
  update(dto: UpdateAccountInterface): Promise<AccountInterface>;
9
5
  }
@@ -1,11 +1,5 @@
1
1
  import { AccountInterface } from "./account.base";
2
- import { ParamsAccountInterface } from "./params-account.base";
3
- import { ResponseAccountInterface } from "./response-account.base";
4
2
  import { UpdateAccountInterface } from "./update-account.base";
5
- import { ResponseInterface } from "../common";
6
3
  export interface AccountDatasourceInterface {
7
- findAll(pagination: ParamsAccountInterface): Promise<ResponseAccountInterface>;
8
- findOne(id: string): Promise<AccountInterface>;
9
4
  update(dto: UpdateAccountInterface): Promise<AccountInterface>;
10
- remove(id: string): Promise<ResponseInterface>;
11
5
  }
@@ -1,10 +1,6 @@
1
1
  import { UserInterface } from "../user";
2
2
  import { AccountInterface } from "./account.base";
3
- import { ParamsAccountInterface } from "./params-account.base";
4
- import { ResponseAccountInterface } from "./response-account.base";
5
3
  import { UpdateAccountInterface } from "./update-account.base";
6
4
  export interface AccountResolverInterface {
7
- findAll(pagination: ParamsAccountInterface, user?: UserInterface): Promise<ResponseAccountInterface>;
8
- findOne(id: string, user?: UserInterface): Promise<AccountInterface>;
9
5
  update(dto: UpdateAccountInterface, user?: UserInterface): Promise<AccountInterface>;
10
6
  }
@@ -1,9 +1,5 @@
1
1
  import { AccountInterface } from "./account.base";
2
- import { ParamsAccountInterface } from "./params-account.base";
3
- import { ResponseAccountInterface } from "./response-account.base";
4
2
  import { UpdateAccountInterface } from "./update-account.base";
5
3
  export interface AccountServiceInterface {
6
- findAll(pagination: ParamsAccountInterface): Promise<ResponseAccountInterface>;
7
- findOne(id: string): Promise<AccountInterface>;
8
4
  update(dto: UpdateAccountInterface): Promise<AccountInterface>;
9
5
  }
@@ -3,6 +3,4 @@ export * from "./account.controller";
3
3
  export * from "./account.datasource";
4
4
  export * from "./account.resolver";
5
5
  export * from "./account.service";
6
- export * from "./params-account.base";
7
- export * from "./response-account.base";
8
6
  export * from "./update-account.base";
@@ -19,6 +19,4 @@ __exportStar(require("./account.controller"), exports);
19
19
  __exportStar(require("./account.datasource"), exports);
20
20
  __exportStar(require("./account.resolver"), exports);
21
21
  __exportStar(require("./account.service"), exports);
22
- __exportStar(require("./params-account.base"), exports);
23
- __exportStar(require("./response-account.base"), exports);
24
22
  __exportStar(require("./update-account.base"), exports);
@@ -2,4 +2,5 @@ export interface UpdateAccountInterface {
2
2
  id: string;
3
3
  currency?: string;
4
4
  active?: boolean;
5
+ id_account_type?: boolean;
5
6
  }
@@ -1,8 +1,3 @@
1
1
  export * from "./leader_entries.base";
2
- export * from "./params-leader_entries.base";
3
- export * from "./response-leader_entries.base";
4
- export * from "./leader_entries.controller";
5
2
  export * from "./leader_entries.service";
6
- export * from "./leader_entries.resolver";
7
- export * from "./leader_entries.datasource";
8
3
  export * from "./leader_lines.base";
@@ -15,10 +15,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./leader_entries.base"), exports);
18
- __exportStar(require("./params-leader_entries.base"), exports);
19
- __exportStar(require("./response-leader_entries.base"), exports);
20
- __exportStar(require("./leader_entries.controller"), exports);
21
18
  __exportStar(require("./leader_entries.service"), exports);
22
- __exportStar(require("./leader_entries.resolver"), exports);
23
- __exportStar(require("./leader_entries.datasource"), exports);
24
19
  __exportStar(require("./leader_lines.base"), exports);
@@ -1,7 +1,4 @@
1
1
  import { LeaderEntriesInterface } from "./leader_entries.base";
2
- import { ParamsLeaderEntriesInterface } from "./params-leader_entries.base";
3
- import { ResponseLeaderEntriesInterface } from "./response-leader_entries.base";
4
2
  export interface LeaderEntriesServiceInterface {
5
- findAll(pagination: ParamsLeaderEntriesInterface): Promise<ResponseLeaderEntriesInterface>;
6
3
  findOne(id: string): Promise<LeaderEntriesInterface>;
7
4
  }
@@ -1,6 +1,5 @@
1
1
  export * from "./operation.base";
2
2
  export * from "./params-operation.base";
3
- export * from "./response-operation.base";
4
3
  export * from "./operation.controller";
5
4
  export * from "./operation.service";
6
5
  export * from "./operation.resolver";
@@ -16,7 +16,6 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./operation.base"), exports);
18
18
  __exportStar(require("./params-operation.base"), exports);
19
- __exportStar(require("./response-operation.base"), exports);
20
19
  __exportStar(require("./operation.controller"), exports);
21
20
  __exportStar(require("./operation.service"), exports);
22
21
  __exportStar(require("./operation.resolver"), exports);
@@ -1,7 +1,6 @@
1
1
  import { OperationInterface } from "./operation.base";
2
2
  import { ParamsOperationInterface } from "./params-operation.base";
3
- import { ResponseOperationInterface } from "./response-operation.base";
4
3
  export interface OperationControllerInterface {
5
- findAll(pagination: ParamsOperationInterface): Promise<ResponseOperationInterface>;
4
+ findAll(pagination: ParamsOperationInterface): Promise<OperationInterface[]>;
6
5
  findOne(id: string): Promise<OperationInterface>;
7
6
  }
@@ -1,7 +1,6 @@
1
1
  import { OperationInterface } from "./operation.base";
2
2
  import { ParamsOperationInterface } from "./params-operation.base";
3
- import { ResponseOperationInterface } from "./response-operation.base";
4
3
  export interface OperationDatasourceInterface {
5
- findAll(pagination: ParamsOperationInterface): Promise<ResponseOperationInterface>;
4
+ findAll(pagination: ParamsOperationInterface): Promise<OperationInterface[]>;
6
5
  findOne(id: string): Promise<OperationInterface>;
7
6
  }
@@ -1,8 +1,7 @@
1
1
  import { UserInterface } from "../user";
2
2
  import { OperationInterface } from "./operation.base";
3
3
  import { ParamsOperationInterface } from "./params-operation.base";
4
- import { ResponseOperationInterface } from "./response-operation.base";
5
4
  export interface OperationResolverInterface {
6
- findAll(pagination: ParamsOperationInterface, user?: UserInterface): Promise<ResponseOperationInterface>;
5
+ findAll(pagination: ParamsOperationInterface, user?: UserInterface): Promise<OperationInterface[]>;
7
6
  findOne(id: string, user?: UserInterface): Promise<OperationInterface>;
8
7
  }
@@ -1,7 +1,6 @@
1
1
  import { OperationInterface } from "./operation.base";
2
2
  import { ParamsOperationInterface } from "./params-operation.base";
3
- import { ResponseOperationInterface } from "./response-operation.base";
4
3
  export interface OperationServiceInterface {
5
- findAll(pagination: ParamsOperationInterface): Promise<ResponseOperationInterface>;
4
+ findAll(pagination: ParamsOperationInterface): Promise<OperationInterface[]>;
6
5
  findOne(id: string): Promise<OperationInterface>;
7
6
  }
@@ -1,11 +1,8 @@
1
1
  import { OperationType } from "../../enum";
2
- import { PaginationInterface } from "../common";
3
- export interface ParamsOperationInterface extends PaginationInterface {
4
- offset: number;
5
- limit: number;
6
- active: boolean;
2
+ export interface ParamsOperationInterface {
7
3
  type?: OperationType;
8
- id_company?: string;
9
- id_group?: string;
10
- id_pos?: string;
4
+ id_company?: string | null;
5
+ id_group?: string | null;
6
+ id_pos?: string | null;
7
+ date?: Date | null;
11
8
  }
@@ -2,7 +2,6 @@ export * from "./ticket.base";
2
2
  export * from "./ticket-detail.base";
3
3
  export * from "./create-ticket.base";
4
4
  export * from "./params-ticket.base";
5
- export * from "./response-ticket.base";
6
5
  export * from "./ticket.controller";
7
6
  export * from "./ticket.service";
8
7
  export * from "./ticket.resolver";
@@ -18,7 +18,6 @@ __exportStar(require("./ticket.base"), exports);
18
18
  __exportStar(require("./ticket-detail.base"), exports);
19
19
  __exportStar(require("./create-ticket.base"), exports);
20
20
  __exportStar(require("./params-ticket.base"), exports);
21
- __exportStar(require("./response-ticket.base"), exports);
22
21
  __exportStar(require("./ticket.controller"), exports);
23
22
  __exportStar(require("./ticket.service"), exports);
24
23
  __exportStar(require("./ticket.resolver"), exports);
@@ -1,17 +1,20 @@
1
- import { TicketStatus } from "../../enum";
2
- import { PaginationInterface } from "../common";
3
- export interface ParamsTicketInterface extends PaginationInterface {
4
- offset: number;
5
- limit: number;
6
- active: boolean;
7
- id_company?: string;
8
- id_group?: string;
9
- id_pos?: string;
10
- id_draw?: number;
11
- id_template_draw?: number;
12
- id_lottery?: number;
13
- id_country?: number;
14
- status?: TicketStatus;
15
- date_from?: Date;
16
- date_to?: Date;
1
+ import { FilterTicketType, TicketStatus } from "../../enum";
2
+ export interface ParamsTicketInterface {
3
+ id_company?: string | null;
4
+ id_group?: string | null;
5
+ id_pos?: string | null;
6
+ id_pos_user?: string | null;
7
+ id_country?: number | null;
8
+ id_lottery?: number | null;
9
+ id_template_draw?: number | null;
10
+ id_draw?: number | null;
11
+ status?: TicketStatus | null;
12
+ date_sale_from?: Date | null;
13
+ date_sale_to?: Date | null;
14
+ date_paid_at_from?: Date | null;
15
+ date_paid_at_to?: Date | null;
16
+ total_amount?: number | null;
17
+ prize_amount?: number | null;
18
+ filter_sale?: FilterTicketType | null;
19
+ filter_prize?: FilterTicketType | null;
17
20
  }
@@ -2,7 +2,7 @@ import { TicketInterface } from "./ticket.base";
2
2
  export interface TicketDetailInterface {
3
3
  id: string;
4
4
  id_ticket: string;
5
- number_played: string;
5
+ number_played: number[];
6
6
  amount: number;
7
7
  id_game_type: number;
8
8
  prize_amount: number;
@@ -1,9 +1,8 @@
1
1
  import { TicketInterface } from "./ticket.base";
2
2
  import { CreateTicketInterface } from "./create-ticket.base";
3
3
  import { ParamsTicketInterface } from "./params-ticket.base";
4
- import { ResponseTicketInterface } from "./response-ticket.base";
5
4
  export interface TicketControllerInterface {
6
5
  create(dto: CreateTicketInterface): Promise<TicketInterface>;
7
- findAll(pagination: ParamsTicketInterface): Promise<ResponseTicketInterface>;
6
+ findAll(pagination: ParamsTicketInterface): Promise<TicketInterface[]>;
8
7
  findOne(id: string): Promise<TicketInterface>;
9
8
  }
@@ -1,9 +1,8 @@
1
1
  import { TicketInterface } from "./ticket.base";
2
2
  import { CreateTicketInterface } from "./create-ticket.base";
3
3
  import { ParamsTicketInterface } from "./params-ticket.base";
4
- import { ResponseTicketInterface } from "./response-ticket.base";
5
4
  export interface TicketDatasourceInterface {
6
5
  create(dto: CreateTicketInterface): Promise<TicketInterface>;
7
- findAll(pagination: ParamsTicketInterface): Promise<ResponseTicketInterface>;
6
+ findAll(pagination: ParamsTicketInterface): Promise<TicketInterface[]>;
8
7
  findOne(id: string): Promise<TicketInterface>;
9
8
  }
@@ -2,9 +2,8 @@ import { UserInterface } from "../user";
2
2
  import { TicketInterface } from "./ticket.base";
3
3
  import { CreateTicketInterface } from "./create-ticket.base";
4
4
  import { ParamsTicketInterface } from "./params-ticket.base";
5
- import { ResponseTicketInterface } from "./response-ticket.base";
6
5
  export interface TicketResolverInterface {
7
6
  create(dto: CreateTicketInterface, user?: UserInterface): Promise<TicketInterface>;
8
- findAll(pagination: ParamsTicketInterface, user?: UserInterface): Promise<ResponseTicketInterface>;
7
+ findAll(pagination: ParamsTicketInterface, user?: UserInterface): Promise<TicketInterface[]>;
9
8
  findOne(id: string, user?: UserInterface): Promise<TicketInterface>;
10
9
  }
@@ -1,9 +1,8 @@
1
1
  import { TicketInterface } from "./ticket.base";
2
2
  import { CreateTicketInterface } from "./create-ticket.base";
3
3
  import { ParamsTicketInterface } from "./params-ticket.base";
4
- import { ResponseTicketInterface } from "./response-ticket.base";
5
4
  export interface TicketServiceInterface {
6
5
  create(dto: CreateTicketInterface): Promise<TicketInterface>;
7
- findAll(pagination: ParamsTicketInterface): Promise<ResponseTicketInterface>;
6
+ findAll(pagination: ParamsTicketInterface): Promise<TicketInterface[]>;
8
7
  findOne(id: string): Promise<TicketInterface>;
9
8
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@carlosdiazz/lottodiz-shared",
3
- "version": "3.5.5",
3
+ "version": "3.5.7",
4
4
  "description": "Shared Dtos, models, constants and utils",
5
5
  "main": "dist/index.js",
6
6
  "private": false,