pg-manipulator 1.0.45 → 1.0.46

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.
@@ -17,7 +17,8 @@ export type item_fields = {
17
17
  cest: string;
18
18
  gtin: string;
19
19
  nve: string;
20
- cfop: string;
21
20
  ipi: string;
22
21
  ativo?: boolean;
22
+ cfopi: string;
23
+ cfope: string;
23
24
  };
@@ -17,7 +17,8 @@ export type item_order = {
17
17
  cest?: 'desc' | 'asc';
18
18
  gtin?: 'desc' | 'asc';
19
19
  nve?: 'desc' | 'asc';
20
- cfop?: 'desc' | 'asc';
21
20
  ipi?: 'desc' | 'asc';
22
21
  ativo?: 'desc' | 'asc';
22
+ cfopi?: 'desc' | 'asc';
23
+ cfope?: 'desc' | 'asc';
23
24
  };
@@ -19,9 +19,10 @@ export type item_select = {
19
19
  cest?: string;
20
20
  gtin?: string;
21
21
  nve?: string;
22
- cfop?: string;
23
22
  ipi?: string;
24
23
  ativo?: boolean;
24
+ cfopi?: string;
25
+ cfope?: string;
25
26
  where: item_where;
26
27
  order?: item_order;
27
28
  };
@@ -18,8 +18,9 @@ export type item_update = {
18
18
  cest?: string;
19
19
  gtin?: string;
20
20
  nve?: string;
21
- cfop?: string;
22
21
  ipi?: string;
23
22
  ativo?: boolean;
23
+ cfopi?: string;
24
+ cfope?: string;
24
25
  where: item_where;
25
26
  };
@@ -18,7 +18,8 @@ export type item_where = {
18
18
  cest?: where_string | string;
19
19
  gtin?: where_string | string;
20
20
  nve?: where_string | string;
21
- cfop?: where_string | string;
22
21
  ipi?: where_string | string;
23
22
  ativo?: where_boolean | boolean;
23
+ cfopi?: where_string | string;
24
+ cfope?: where_string | string;
24
25
  };
@@ -1,37 +1,37 @@
1
1
  import { PoolClient } from 'pg';
2
2
  import { pool_tsx } from '../../@types';
3
- import ecommerce_item from './ecommerce_item';
4
- import marca from './marca';
5
- import entidade from './entidade';
3
+ import atributo from './atributo';
6
4
  import entidade_endereco from './entidade_endereco';
7
- import ecommerce from './ecommerce';
8
5
  import usuario from './usuario';
9
- import item_variacao from './item_variacao';
10
6
  import item_variacao_atributo from './item_variacao_atributo';
7
+ import empresa from './empresa';
11
8
  import operacao_item from './operacao_item';
12
9
  import item from './item';
13
- import operacao_pagamento from './operacao_pagamento';
10
+ import entidade from './entidade';
14
11
  import categoria from './categoria';
12
+ import item_variacao from './item_variacao';
13
+ import marca from './marca';
14
+ import ecommerce from './ecommerce';
15
+ import ecommerce_item from './ecommerce_item';
15
16
  import operacao from './operacao';
16
- import empresa from './empresa';
17
- import atributo from './atributo';
17
+ import operacao_pagamento from './operacao_pagamento';
18
18
  declare const _default: {
19
19
  query(query_string: string, query_params: Array<any>, transaction?: PoolClient | any): Promise<any>;
20
20
  transaction(callback: pool_tsx): Promise<void>;
21
- ecommerce_item: typeof ecommerce_item;
22
- marca: typeof marca;
23
- entidade: typeof entidade;
21
+ atributo: typeof atributo;
24
22
  entidade_endereco: typeof entidade_endereco;
25
- ecommerce: typeof ecommerce;
26
23
  usuario: typeof usuario;
27
- item_variacao: typeof item_variacao;
28
24
  item_variacao_atributo: typeof item_variacao_atributo;
25
+ empresa: typeof empresa;
29
26
  operacao_item: typeof operacao_item;
30
27
  item: typeof item;
31
- operacao_pagamento: typeof operacao_pagamento;
28
+ entidade: typeof entidade;
32
29
  categoria: typeof categoria;
30
+ item_variacao: typeof item_variacao;
31
+ marca: typeof marca;
32
+ ecommerce: typeof ecommerce;
33
+ ecommerce_item: typeof ecommerce_item;
33
34
  operacao: typeof operacao;
34
- empresa: typeof empresa;
35
- atributo: typeof atributo;
35
+ operacao_pagamento: typeof operacao_pagamento;
36
36
  };
37
37
  export default _default;
@@ -4,21 +4,21 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  const database_1 = __importDefault(require("../../database"));
7
- const ecommerce_item_1 = __importDefault(require("./ecommerce_item"));
8
- const marca_1 = __importDefault(require("./marca"));
9
- const entidade_1 = __importDefault(require("./entidade"));
7
+ const atributo_1 = __importDefault(require("./atributo"));
10
8
  const entidade_endereco_1 = __importDefault(require("./entidade_endereco"));
11
- const ecommerce_1 = __importDefault(require("./ecommerce"));
12
9
  const usuario_1 = __importDefault(require("./usuario"));
13
- const item_variacao_1 = __importDefault(require("./item_variacao"));
14
10
  const item_variacao_atributo_1 = __importDefault(require("./item_variacao_atributo"));
11
+ const empresa_1 = __importDefault(require("./empresa"));
15
12
  const operacao_item_1 = __importDefault(require("./operacao_item"));
16
13
  const item_1 = __importDefault(require("./item"));
17
- const operacao_pagamento_1 = __importDefault(require("./operacao_pagamento"));
14
+ const entidade_1 = __importDefault(require("./entidade"));
18
15
  const categoria_1 = __importDefault(require("./categoria"));
16
+ const item_variacao_1 = __importDefault(require("./item_variacao"));
17
+ const marca_1 = __importDefault(require("./marca"));
18
+ const ecommerce_1 = __importDefault(require("./ecommerce"));
19
+ const ecommerce_item_1 = __importDefault(require("./ecommerce_item"));
19
20
  const operacao_1 = __importDefault(require("./operacao"));
20
- const empresa_1 = __importDefault(require("./empresa"));
21
- const atributo_1 = __importDefault(require("./atributo"));
21
+ const operacao_pagamento_1 = __importDefault(require("./operacao_pagamento"));
22
22
  exports.default = {
23
23
  async query(query_string, query_params, transaction = undefined) {
24
24
  return await database_1.default.query('admin', query_string, query_params, transaction);
@@ -26,19 +26,19 @@ exports.default = {
26
26
  async transaction(callback) {
27
27
  return await database_1.default.transaction('admin', callback);
28
28
  },
29
- ecommerce_item: ecommerce_item_1.default,
30
- marca: marca_1.default,
31
- entidade: entidade_1.default,
29
+ atributo: atributo_1.default,
32
30
  entidade_endereco: entidade_endereco_1.default,
33
- ecommerce: ecommerce_1.default,
34
31
  usuario: usuario_1.default,
35
- item_variacao: item_variacao_1.default,
36
32
  item_variacao_atributo: item_variacao_atributo_1.default,
33
+ empresa: empresa_1.default,
37
34
  operacao_item: operacao_item_1.default,
38
35
  item: item_1.default,
39
- operacao_pagamento: operacao_pagamento_1.default,
36
+ entidade: entidade_1.default,
40
37
  categoria: categoria_1.default,
38
+ item_variacao: item_variacao_1.default,
39
+ marca: marca_1.default,
40
+ ecommerce: ecommerce_1.default,
41
+ ecommerce_item: ecommerce_item_1.default,
41
42
  operacao: operacao_1.default,
42
- empresa: empresa_1.default,
43
- atributo: atributo_1.default
43
+ operacao_pagamento: operacao_pagamento_1.default
44
44
  };
@@ -1,31 +1,5 @@
1
1
  declare const _default: {
2
- ecommerce_item: {
3
- columns: {
4
- name: string;
5
- value: {
6
- type: string;
7
- is_null: string;
8
- maxlength: null;
9
- };
10
- fk_table: string;
11
- fk_reference: string;
12
- pk: boolean;
13
- }[];
14
- fathers: {
15
- name: string;
16
- value: {
17
- type: string;
18
- is_null: string;
19
- maxlength: null;
20
- };
21
- fk_table: string;
22
- fk_reference: string;
23
- pk: boolean;
24
- }[];
25
- childrens: never[];
26
- name: string;
27
- };
28
- marca: {
2
+ atributo: {
29
3
  columns: ({
30
4
  name: string;
31
5
  value: {
@@ -61,7 +35,7 @@ declare const _default: {
61
35
  }[];
62
36
  name: string;
63
37
  };
64
- entidade: {
38
+ entidade_endereco: {
65
39
  columns: ({
66
40
  name: string;
67
41
  value: {
@@ -83,8 +57,7 @@ declare const _default: {
83
57
  fk_reference: null;
84
58
  pk: boolean;
85
59
  })[];
86
- fathers: never[];
87
- childrens: {
60
+ fathers: {
88
61
  name: string;
89
62
  value: {
90
63
  type: string;
@@ -95,9 +68,10 @@ declare const _default: {
95
68
  fk_reference: string;
96
69
  pk: boolean;
97
70
  }[];
71
+ childrens: never[];
98
72
  name: string;
99
73
  };
100
- entidade_endereco: {
74
+ usuario: {
101
75
  columns: ({
102
76
  name: string;
103
77
  value: {
@@ -119,6 +93,22 @@ declare const _default: {
119
93
  fk_reference: null;
120
94
  pk: boolean;
121
95
  })[];
96
+ fathers: never[];
97
+ childrens: never[];
98
+ name: string;
99
+ };
100
+ item_variacao_atributo: {
101
+ columns: {
102
+ name: string;
103
+ value: {
104
+ type: string;
105
+ is_null: string;
106
+ maxlength: null;
107
+ };
108
+ fk_table: string;
109
+ fk_reference: string;
110
+ pk: boolean;
111
+ }[];
122
112
  fathers: {
123
113
  name: string;
124
114
  value: {
@@ -133,7 +123,7 @@ declare const _default: {
133
123
  childrens: never[];
134
124
  name: string;
135
125
  };
136
- ecommerce: {
126
+ empresa: {
137
127
  columns: ({
138
128
  name: string;
139
129
  value: {
@@ -155,17 +145,7 @@ declare const _default: {
155
145
  fk_reference: null;
156
146
  pk: boolean;
157
147
  })[];
158
- fathers: {
159
- name: string;
160
- value: {
161
- type: string;
162
- is_null: string;
163
- maxlength: null;
164
- };
165
- fk_table: string;
166
- fk_reference: string;
167
- pk: boolean;
168
- }[];
148
+ fathers: never[];
169
149
  childrens: {
170
150
  name: string;
171
151
  value: {
@@ -179,7 +159,7 @@ declare const _default: {
179
159
  }[];
180
160
  name: string;
181
161
  };
182
- usuario: {
162
+ operacao_item: {
183
163
  columns: ({
184
164
  name: string;
185
165
  value: {
@@ -201,11 +181,21 @@ declare const _default: {
201
181
  fk_reference: null;
202
182
  pk: boolean;
203
183
  })[];
204
- fathers: never[];
184
+ fathers: {
185
+ name: string;
186
+ value: {
187
+ type: string;
188
+ is_null: string;
189
+ maxlength: null;
190
+ };
191
+ fk_table: string;
192
+ fk_reference: string;
193
+ pk: boolean;
194
+ }[];
205
195
  childrens: never[];
206
196
  name: string;
207
197
  };
208
- item_variacao: {
198
+ item: {
209
199
  columns: ({
210
200
  name: string;
211
201
  value: {
@@ -251,8 +241,8 @@ declare const _default: {
251
241
  }[];
252
242
  name: string;
253
243
  };
254
- item_variacao_atributo: {
255
- columns: {
244
+ entidade: {
245
+ columns: ({
256
246
  name: string;
257
247
  value: {
258
248
  type: string;
@@ -262,8 +252,19 @@ declare const _default: {
262
252
  fk_table: string;
263
253
  fk_reference: string;
264
254
  pk: boolean;
265
- }[];
266
- fathers: {
255
+ } | {
256
+ name: string;
257
+ value: {
258
+ type: string;
259
+ is_null: string;
260
+ maxlength: null;
261
+ };
262
+ fk_table: null;
263
+ fk_reference: null;
264
+ pk: boolean;
265
+ })[];
266
+ fathers: never[];
267
+ childrens: {
267
268
  name: string;
268
269
  value: {
269
270
  type: string;
@@ -274,10 +275,9 @@ declare const _default: {
274
275
  fk_reference: string;
275
276
  pk: boolean;
276
277
  }[];
277
- childrens: never[];
278
278
  name: string;
279
279
  };
280
- operacao_item: {
280
+ categoria: {
281
281
  columns: ({
282
282
  name: string;
283
283
  value: {
@@ -299,7 +299,8 @@ declare const _default: {
299
299
  fk_reference: null;
300
300
  pk: boolean;
301
301
  })[];
302
- fathers: {
302
+ fathers: never[];
303
+ childrens: {
303
304
  name: string;
304
305
  value: {
305
306
  type: string;
@@ -310,10 +311,9 @@ declare const _default: {
310
311
  fk_reference: string;
311
312
  pk: boolean;
312
313
  }[];
313
- childrens: never[];
314
314
  name: string;
315
315
  };
316
- item: {
316
+ item_variacao: {
317
317
  columns: ({
318
318
  name: string;
319
319
  value: {
@@ -359,7 +359,7 @@ declare const _default: {
359
359
  }[];
360
360
  name: string;
361
361
  };
362
- operacao_pagamento: {
362
+ marca: {
363
363
  columns: ({
364
364
  name: string;
365
365
  value: {
@@ -381,7 +381,8 @@ declare const _default: {
381
381
  fk_reference: null;
382
382
  pk: boolean;
383
383
  })[];
384
- fathers: {
384
+ fathers: never[];
385
+ childrens: {
385
386
  name: string;
386
387
  value: {
387
388
  type: string;
@@ -392,10 +393,9 @@ declare const _default: {
392
393
  fk_reference: string;
393
394
  pk: boolean;
394
395
  }[];
395
- childrens: never[];
396
396
  name: string;
397
397
  };
398
- categoria: {
398
+ ecommerce: {
399
399
  columns: ({
400
400
  name: string;
401
401
  value: {
@@ -417,8 +417,7 @@ declare const _default: {
417
417
  fk_reference: null;
418
418
  pk: boolean;
419
419
  })[];
420
- fathers: never[];
421
- childrens: {
420
+ fathers: {
422
421
  name: string;
423
422
  value: {
424
423
  type: string;
@@ -429,10 +428,7 @@ declare const _default: {
429
428
  fk_reference: string;
430
429
  pk: boolean;
431
430
  }[];
432
- name: string;
433
- };
434
- operacao: {
435
- columns: ({
431
+ childrens: {
436
432
  name: string;
437
433
  value: {
438
434
  type: string;
@@ -442,18 +438,11 @@ declare const _default: {
442
438
  fk_table: string;
443
439
  fk_reference: string;
444
440
  pk: boolean;
445
- } | {
446
- name: string;
447
- value: {
448
- type: string;
449
- is_null: string;
450
- maxlength: null;
451
- };
452
- fk_table: null;
453
- fk_reference: null;
454
- pk: boolean;
455
- })[];
456
- fathers: {
441
+ }[];
442
+ name: string;
443
+ };
444
+ ecommerce_item: {
445
+ columns: {
457
446
  name: string;
458
447
  value: {
459
448
  type: string;
@@ -464,7 +453,7 @@ declare const _default: {
464
453
  fk_reference: string;
465
454
  pk: boolean;
466
455
  }[];
467
- childrens: {
456
+ fathers: {
468
457
  name: string;
469
458
  value: {
470
459
  type: string;
@@ -475,9 +464,10 @@ declare const _default: {
475
464
  fk_reference: string;
476
465
  pk: boolean;
477
466
  }[];
467
+ childrens: never[];
478
468
  name: string;
479
469
  };
480
- empresa: {
470
+ operacao: {
481
471
  columns: ({
482
472
  name: string;
483
473
  value: {
@@ -499,7 +489,17 @@ declare const _default: {
499
489
  fk_reference: null;
500
490
  pk: boolean;
501
491
  })[];
502
- fathers: never[];
492
+ fathers: {
493
+ name: string;
494
+ value: {
495
+ type: string;
496
+ is_null: string;
497
+ maxlength: null;
498
+ };
499
+ fk_table: string;
500
+ fk_reference: string;
501
+ pk: boolean;
502
+ }[];
503
503
  childrens: {
504
504
  name: string;
505
505
  value: {
@@ -513,7 +513,7 @@ declare const _default: {
513
513
  }[];
514
514
  name: string;
515
515
  };
516
- atributo: {
516
+ operacao_pagamento: {
517
517
  columns: ({
518
518
  name: string;
519
519
  value: {
@@ -535,8 +535,7 @@ declare const _default: {
535
535
  fk_reference: null;
536
536
  pk: boolean;
537
537
  })[];
538
- fathers: never[];
539
- childrens: {
538
+ fathers: {
540
539
  name: string;
541
540
  value: {
542
541
  type: string;
@@ -547,6 +546,7 @@ declare const _default: {
547
546
  fk_reference: string;
548
547
  pk: boolean;
549
548
  }[];
549
+ childrens: never[];
550
550
  name: string;
551
551
  };
552
552
  };
@@ -3,35 +3,35 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- const ecommerce_item_1 = __importDefault(require("./ecommerce_item"));
7
- const marca_1 = __importDefault(require("./marca"));
8
- const entidade_1 = __importDefault(require("./entidade"));
6
+ const atributo_1 = __importDefault(require("./atributo"));
9
7
  const entidade_endereco_1 = __importDefault(require("./entidade_endereco"));
10
- const ecommerce_1 = __importDefault(require("./ecommerce"));
11
8
  const usuario_1 = __importDefault(require("./usuario"));
12
- const item_variacao_1 = __importDefault(require("./item_variacao"));
13
9
  const item_variacao_atributo_1 = __importDefault(require("./item_variacao_atributo"));
10
+ const empresa_1 = __importDefault(require("./empresa"));
14
11
  const operacao_item_1 = __importDefault(require("./operacao_item"));
15
12
  const item_1 = __importDefault(require("./item"));
16
- const operacao_pagamento_1 = __importDefault(require("./operacao_pagamento"));
13
+ const entidade_1 = __importDefault(require("./entidade"));
17
14
  const categoria_1 = __importDefault(require("./categoria"));
15
+ const item_variacao_1 = __importDefault(require("./item_variacao"));
16
+ const marca_1 = __importDefault(require("./marca"));
17
+ const ecommerce_1 = __importDefault(require("./ecommerce"));
18
+ const ecommerce_item_1 = __importDefault(require("./ecommerce_item"));
18
19
  const operacao_1 = __importDefault(require("./operacao"));
19
- const empresa_1 = __importDefault(require("./empresa"));
20
- const atributo_1 = __importDefault(require("./atributo"));
20
+ const operacao_pagamento_1 = __importDefault(require("./operacao_pagamento"));
21
21
  exports.default = {
22
- ecommerce_item: ecommerce_item_1.default,
23
- marca: marca_1.default,
24
- entidade: entidade_1.default,
22
+ atributo: atributo_1.default,
25
23
  entidade_endereco: entidade_endereco_1.default,
26
- ecommerce: ecommerce_1.default,
27
24
  usuario: usuario_1.default,
28
- item_variacao: item_variacao_1.default,
29
25
  item_variacao_atributo: item_variacao_atributo_1.default,
26
+ empresa: empresa_1.default,
30
27
  operacao_item: operacao_item_1.default,
31
28
  item: item_1.default,
32
- operacao_pagamento: operacao_pagamento_1.default,
29
+ entidade: entidade_1.default,
33
30
  categoria: categoria_1.default,
31
+ item_variacao: item_variacao_1.default,
32
+ marca: marca_1.default,
33
+ ecommerce: ecommerce_1.default,
34
+ ecommerce_item: ecommerce_item_1.default,
34
35
  operacao: operacao_1.default,
35
- empresa: empresa_1.default,
36
- atributo: atributo_1.default
36
+ operacao_pagamento: operacao_pagamento_1.default
37
37
  };
@@ -201,7 +201,7 @@ exports.default = {
201
201
  "pk": false
202
202
  },
203
203
  {
204
- "name": "cfop",
204
+ "name": "ipi",
205
205
  "value": {
206
206
  "type": "character varying",
207
207
  "is_null": "NO",
@@ -212,7 +212,18 @@ exports.default = {
212
212
  "pk": false
213
213
  },
214
214
  {
215
- "name": "ipi",
215
+ "name": "ativo",
216
+ "value": {
217
+ "type": "boolean",
218
+ "is_null": "YES",
219
+ "maxlength": null
220
+ },
221
+ "fk_table": null,
222
+ "fk_reference": null,
223
+ "pk": false
224
+ },
225
+ {
226
+ "name": "cfopi",
216
227
  "value": {
217
228
  "type": "character varying",
218
229
  "is_null": "NO",
@@ -223,10 +234,10 @@ exports.default = {
223
234
  "pk": false
224
235
  },
225
236
  {
226
- "name": "ativo",
237
+ "name": "cfope",
227
238
  "value": {
228
- "type": "boolean",
229
- "is_null": "YES",
239
+ "type": "character varying",
240
+ "is_null": "NO",
230
241
  "maxlength": null
231
242
  },
232
243
  "fk_table": null,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pg-manipulator",
3
- "version": "1.0.45",
3
+ "version": "1.0.46",
4
4
  "description": "postgresql database handler",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",