pg-manipulator 1.0.44 → 1.0.45

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.
@@ -8,4 +8,5 @@ export type item_variacao_fields = {
8
8
  preco_personalizacao: number;
9
9
  campos_personalizados?: any;
10
10
  ativo?: boolean;
11
+ item: number;
11
12
  };
@@ -8,4 +8,5 @@ export type item_variacao_order = {
8
8
  preco_personalizacao?: 'desc' | 'asc';
9
9
  campos_personalizados?: 'desc' | 'asc';
10
10
  ativo?: 'desc' | 'asc';
11
+ item?: 'desc' | 'asc';
11
12
  };
@@ -10,6 +10,7 @@ export type item_variacao_select = {
10
10
  preco_personalizacao?: number;
11
11
  campos_personalizados?: any;
12
12
  ativo?: boolean;
13
+ item?: number;
13
14
  where: item_variacao_where;
14
15
  order?: item_variacao_order;
15
16
  };
@@ -9,5 +9,6 @@ export type item_variacao_update = {
9
9
  preco_personalizacao?: number;
10
10
  campos_personalizados?: any;
11
11
  ativo?: boolean;
12
+ item?: number;
12
13
  where: item_variacao_where;
13
14
  };
@@ -9,4 +9,5 @@ export type item_variacao_where = {
9
9
  preco_personalizacao?: where_number | number;
10
10
  campos_personalizados?: any;
11
11
  ativo?: where_boolean | boolean;
12
+ item?: where_number | number;
12
13
  };
@@ -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';
6
+ import entidade_endereco from './entidade_endereco';
3
7
  import ecommerce from './ecommerce';
8
+ import usuario from './usuario';
9
+ import item_variacao from './item_variacao';
4
10
  import item_variacao_atributo from './item_variacao_atributo';
11
+ import operacao_item from './operacao_item';
5
12
  import item from './item';
6
- import entidade from './entidade';
7
- import categoria from './categoria';
8
- import marca from './marca';
9
13
  import operacao_pagamento from './operacao_pagamento';
10
- import item_variacao from './item_variacao';
11
- import usuario from './usuario';
12
- import ecommerce_item from './ecommerce_item';
13
- import entidade_endereco from './entidade_endereco';
14
- import atributo from './atributo';
14
+ import categoria from './categoria';
15
15
  import operacao from './operacao';
16
- import operacao_item from './operacao_item';
17
16
  import empresa from './empresa';
17
+ import atributo from './atributo';
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;
24
+ entidade_endereco: typeof entidade_endereco;
21
25
  ecommerce: typeof ecommerce;
26
+ usuario: typeof usuario;
27
+ item_variacao: typeof item_variacao;
22
28
  item_variacao_atributo: typeof item_variacao_atributo;
29
+ operacao_item: typeof operacao_item;
23
30
  item: typeof item;
24
- entidade: typeof entidade;
25
- categoria: typeof categoria;
26
- marca: typeof marca;
27
31
  operacao_pagamento: typeof operacao_pagamento;
28
- item_variacao: typeof item_variacao;
29
- usuario: typeof usuario;
30
- ecommerce_item: typeof ecommerce_item;
31
- entidade_endereco: typeof entidade_endereco;
32
- atributo: typeof atributo;
32
+ categoria: typeof categoria;
33
33
  operacao: typeof operacao;
34
- operacao_item: typeof operacao_item;
35
34
  empresa: typeof empresa;
35
+ atributo: typeof atributo;
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"));
10
+ const entidade_endereco_1 = __importDefault(require("./entidade_endereco"));
7
11
  const ecommerce_1 = __importDefault(require("./ecommerce"));
12
+ const usuario_1 = __importDefault(require("./usuario"));
13
+ const item_variacao_1 = __importDefault(require("./item_variacao"));
8
14
  const item_variacao_atributo_1 = __importDefault(require("./item_variacao_atributo"));
15
+ const operacao_item_1 = __importDefault(require("./operacao_item"));
9
16
  const item_1 = __importDefault(require("./item"));
10
- const entidade_1 = __importDefault(require("./entidade"));
11
- const categoria_1 = __importDefault(require("./categoria"));
12
- const marca_1 = __importDefault(require("./marca"));
13
17
  const operacao_pagamento_1 = __importDefault(require("./operacao_pagamento"));
14
- const item_variacao_1 = __importDefault(require("./item_variacao"));
15
- const usuario_1 = __importDefault(require("./usuario"));
16
- const ecommerce_item_1 = __importDefault(require("./ecommerce_item"));
17
- const entidade_endereco_1 = __importDefault(require("./entidade_endereco"));
18
- const atributo_1 = __importDefault(require("./atributo"));
18
+ const categoria_1 = __importDefault(require("./categoria"));
19
19
  const operacao_1 = __importDefault(require("./operacao"));
20
- const operacao_item_1 = __importDefault(require("./operacao_item"));
21
20
  const empresa_1 = __importDefault(require("./empresa"));
21
+ const atributo_1 = __importDefault(require("./atributo"));
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,
32
+ entidade_endereco: entidade_endereco_1.default,
29
33
  ecommerce: ecommerce_1.default,
34
+ usuario: usuario_1.default,
35
+ item_variacao: item_variacao_1.default,
30
36
  item_variacao_atributo: item_variacao_atributo_1.default,
37
+ operacao_item: operacao_item_1.default,
31
38
  item: item_1.default,
32
- entidade: entidade_1.default,
33
- categoria: categoria_1.default,
34
- marca: marca_1.default,
35
39
  operacao_pagamento: operacao_pagamento_1.default,
36
- item_variacao: item_variacao_1.default,
37
- usuario: usuario_1.default,
38
- ecommerce_item: ecommerce_item_1.default,
39
- entidade_endereco: entidade_endereco_1.default,
40
- atributo: atributo_1.default,
40
+ categoria: categoria_1.default,
41
41
  operacao: operacao_1.default,
42
- operacao_item: operacao_item_1.default,
43
- empresa: empresa_1.default
42
+ empresa: empresa_1.default,
43
+ atributo: atributo_1.default
44
44
  };
@@ -1,6 +1,6 @@
1
1
  declare const _default: {
2
- ecommerce: {
3
- columns: ({
2
+ ecommerce_item: {
3
+ columns: {
4
4
  name: string;
5
5
  value: {
6
6
  type: string;
@@ -10,18 +10,23 @@ declare const _default: {
10
10
  fk_table: string;
11
11
  fk_reference: string;
12
12
  pk: boolean;
13
- } | {
13
+ }[];
14
+ fathers: {
14
15
  name: string;
15
16
  value: {
16
17
  type: string;
17
18
  is_null: string;
18
19
  maxlength: null;
19
20
  };
20
- fk_table: null;
21
- fk_reference: null;
21
+ fk_table: string;
22
+ fk_reference: string;
22
23
  pk: boolean;
23
- })[];
24
- fathers: {
24
+ }[];
25
+ childrens: never[];
26
+ name: string;
27
+ };
28
+ marca: {
29
+ columns: ({
25
30
  name: string;
26
31
  value: {
27
32
  type: string;
@@ -31,7 +36,18 @@ declare const _default: {
31
36
  fk_table: string;
32
37
  fk_reference: string;
33
38
  pk: boolean;
34
- }[];
39
+ } | {
40
+ name: string;
41
+ value: {
42
+ type: string;
43
+ is_null: string;
44
+ maxlength: null;
45
+ };
46
+ fk_table: null;
47
+ fk_reference: null;
48
+ pk: boolean;
49
+ })[];
50
+ fathers: never[];
35
51
  childrens: {
36
52
  name: string;
37
53
  value: {
@@ -45,8 +61,8 @@ declare const _default: {
45
61
  }[];
46
62
  name: string;
47
63
  };
48
- item_variacao_atributo: {
49
- columns: {
64
+ entidade: {
65
+ columns: ({
50
66
  name: string;
51
67
  value: {
52
68
  type: string;
@@ -56,8 +72,19 @@ declare const _default: {
56
72
  fk_table: string;
57
73
  fk_reference: string;
58
74
  pk: boolean;
59
- }[];
60
- fathers: {
75
+ } | {
76
+ name: string;
77
+ value: {
78
+ type: string;
79
+ is_null: string;
80
+ maxlength: null;
81
+ };
82
+ fk_table: null;
83
+ fk_reference: null;
84
+ pk: boolean;
85
+ })[];
86
+ fathers: never[];
87
+ childrens: {
61
88
  name: string;
62
89
  value: {
63
90
  type: string;
@@ -68,10 +95,9 @@ declare const _default: {
68
95
  fk_reference: string;
69
96
  pk: boolean;
70
97
  }[];
71
- childrens: never[];
72
98
  name: string;
73
99
  };
74
- item: {
100
+ entidade_endereco: {
75
101
  columns: ({
76
102
  name: string;
77
103
  value: {
@@ -104,20 +130,10 @@ declare const _default: {
104
130
  fk_reference: string;
105
131
  pk: boolean;
106
132
  }[];
107
- childrens: {
108
- name: string;
109
- value: {
110
- type: string;
111
- is_null: string;
112
- maxlength: null;
113
- };
114
- fk_table: string;
115
- fk_reference: string;
116
- pk: boolean;
117
- }[];
133
+ childrens: never[];
118
134
  name: string;
119
135
  };
120
- entidade: {
136
+ ecommerce: {
121
137
  columns: ({
122
138
  name: string;
123
139
  value: {
@@ -139,7 +155,17 @@ declare const _default: {
139
155
  fk_reference: null;
140
156
  pk: boolean;
141
157
  })[];
142
- fathers: never[];
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
+ }[];
143
169
  childrens: {
144
170
  name: string;
145
171
  value: {
@@ -153,7 +179,7 @@ declare const _default: {
153
179
  }[];
154
180
  name: string;
155
181
  };
156
- categoria: {
182
+ usuario: {
157
183
  columns: ({
158
184
  name: string;
159
185
  value: {
@@ -176,20 +202,10 @@ declare const _default: {
176
202
  pk: boolean;
177
203
  })[];
178
204
  fathers: never[];
179
- childrens: {
180
- name: string;
181
- value: {
182
- type: string;
183
- is_null: string;
184
- maxlength: null;
185
- };
186
- fk_table: string;
187
- fk_reference: string;
188
- pk: boolean;
189
- }[];
205
+ childrens: never[];
190
206
  name: string;
191
207
  };
192
- marca: {
208
+ item_variacao: {
193
209
  columns: ({
194
210
  name: string;
195
211
  value: {
@@ -211,8 +227,7 @@ declare const _default: {
211
227
  fk_reference: null;
212
228
  pk: boolean;
213
229
  })[];
214
- fathers: never[];
215
- childrens: {
230
+ fathers: {
216
231
  name: string;
217
232
  value: {
218
233
  type: string;
@@ -223,10 +238,7 @@ declare const _default: {
223
238
  fk_reference: string;
224
239
  pk: boolean;
225
240
  }[];
226
- name: string;
227
- };
228
- operacao_pagamento: {
229
- columns: ({
241
+ childrens: {
230
242
  name: string;
231
243
  value: {
232
244
  type: string;
@@ -236,17 +248,21 @@ declare const _default: {
236
248
  fk_table: string;
237
249
  fk_reference: string;
238
250
  pk: boolean;
239
- } | {
251
+ }[];
252
+ name: string;
253
+ };
254
+ item_variacao_atributo: {
255
+ columns: {
240
256
  name: string;
241
257
  value: {
242
258
  type: string;
243
259
  is_null: string;
244
260
  maxlength: null;
245
261
  };
246
- fk_table: null;
247
- fk_reference: null;
262
+ fk_table: string;
263
+ fk_reference: string;
248
264
  pk: boolean;
249
- })[];
265
+ }[];
250
266
  fathers: {
251
267
  name: string;
252
268
  value: {
@@ -261,7 +277,7 @@ declare const _default: {
261
277
  childrens: never[];
262
278
  name: string;
263
279
  };
264
- item_variacao: {
280
+ operacao_item: {
265
281
  columns: ({
266
282
  name: string;
267
283
  value: {
@@ -283,8 +299,7 @@ declare const _default: {
283
299
  fk_reference: null;
284
300
  pk: boolean;
285
301
  })[];
286
- fathers: never[];
287
- childrens: {
302
+ fathers: {
288
303
  name: string;
289
304
  value: {
290
305
  type: string;
@@ -295,9 +310,10 @@ declare const _default: {
295
310
  fk_reference: string;
296
311
  pk: boolean;
297
312
  }[];
313
+ childrens: never[];
298
314
  name: string;
299
315
  };
300
- usuario: {
316
+ item: {
301
317
  columns: ({
302
318
  name: string;
303
319
  value: {
@@ -319,12 +335,7 @@ declare const _default: {
319
335
  fk_reference: null;
320
336
  pk: boolean;
321
337
  })[];
322
- fathers: never[];
323
- childrens: never[];
324
- name: string;
325
- };
326
- ecommerce_item: {
327
- columns: {
338
+ fathers: {
328
339
  name: string;
329
340
  value: {
330
341
  type: string;
@@ -335,7 +346,7 @@ declare const _default: {
335
346
  fk_reference: string;
336
347
  pk: boolean;
337
348
  }[];
338
- fathers: {
349
+ childrens: {
339
350
  name: string;
340
351
  value: {
341
352
  type: string;
@@ -346,10 +357,9 @@ declare const _default: {
346
357
  fk_reference: string;
347
358
  pk: boolean;
348
359
  }[];
349
- childrens: never[];
350
360
  name: string;
351
361
  };
352
- entidade_endereco: {
362
+ operacao_pagamento: {
353
363
  columns: ({
354
364
  name: string;
355
365
  value: {
@@ -385,7 +395,7 @@ declare const _default: {
385
395
  childrens: never[];
386
396
  name: string;
387
397
  };
388
- atributo: {
398
+ categoria: {
389
399
  columns: ({
390
400
  name: string;
391
401
  value: {
@@ -467,7 +477,7 @@ declare const _default: {
467
477
  }[];
468
478
  name: string;
469
479
  };
470
- operacao_item: {
480
+ empresa: {
471
481
  columns: ({
472
482
  name: string;
473
483
  value: {
@@ -489,7 +499,8 @@ declare const _default: {
489
499
  fk_reference: null;
490
500
  pk: boolean;
491
501
  })[];
492
- fathers: {
502
+ fathers: never[];
503
+ childrens: {
493
504
  name: string;
494
505
  value: {
495
506
  type: string;
@@ -500,10 +511,9 @@ declare const _default: {
500
511
  fk_reference: string;
501
512
  pk: boolean;
502
513
  }[];
503
- childrens: never[];
504
514
  name: string;
505
515
  };
506
- empresa: {
516
+ atributo: {
507
517
  columns: ({
508
518
  name: string;
509
519
  value: {
@@ -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"));
9
+ const entidade_endereco_1 = __importDefault(require("./entidade_endereco"));
6
10
  const ecommerce_1 = __importDefault(require("./ecommerce"));
11
+ const usuario_1 = __importDefault(require("./usuario"));
12
+ const item_variacao_1 = __importDefault(require("./item_variacao"));
7
13
  const item_variacao_atributo_1 = __importDefault(require("./item_variacao_atributo"));
14
+ const operacao_item_1 = __importDefault(require("./operacao_item"));
8
15
  const item_1 = __importDefault(require("./item"));
9
- const entidade_1 = __importDefault(require("./entidade"));
10
- const categoria_1 = __importDefault(require("./categoria"));
11
- const marca_1 = __importDefault(require("./marca"));
12
16
  const operacao_pagamento_1 = __importDefault(require("./operacao_pagamento"));
13
- const item_variacao_1 = __importDefault(require("./item_variacao"));
14
- const usuario_1 = __importDefault(require("./usuario"));
15
- const ecommerce_item_1 = __importDefault(require("./ecommerce_item"));
16
- const entidade_endereco_1 = __importDefault(require("./entidade_endereco"));
17
- const atributo_1 = __importDefault(require("./atributo"));
17
+ const categoria_1 = __importDefault(require("./categoria"));
18
18
  const operacao_1 = __importDefault(require("./operacao"));
19
- const operacao_item_1 = __importDefault(require("./operacao_item"));
20
19
  const empresa_1 = __importDefault(require("./empresa"));
20
+ const atributo_1 = __importDefault(require("./atributo"));
21
21
  exports.default = {
22
+ ecommerce_item: ecommerce_item_1.default,
23
+ marca: marca_1.default,
24
+ entidade: entidade_1.default,
25
+ entidade_endereco: entidade_endereco_1.default,
22
26
  ecommerce: ecommerce_1.default,
27
+ usuario: usuario_1.default,
28
+ item_variacao: item_variacao_1.default,
23
29
  item_variacao_atributo: item_variacao_atributo_1.default,
30
+ operacao_item: operacao_item_1.default,
24
31
  item: item_1.default,
25
- entidade: entidade_1.default,
26
- categoria: categoria_1.default,
27
- marca: marca_1.default,
28
32
  operacao_pagamento: operacao_pagamento_1.default,
29
- item_variacao: item_variacao_1.default,
30
- usuario: usuario_1.default,
31
- ecommerce_item: ecommerce_item_1.default,
32
- entidade_endereco: entidade_endereco_1.default,
33
- atributo: atributo_1.default,
33
+ categoria: categoria_1.default,
34
34
  operacao: operacao_1.default,
35
- operacao_item: operacao_item_1.default,
36
- empresa: empresa_1.default
35
+ empresa: empresa_1.default,
36
+ atributo: atributo_1.default
37
37
  };
@@ -20,7 +20,17 @@ declare const _default: {
20
20
  fk_reference: null;
21
21
  pk: boolean;
22
22
  })[];
23
- fathers: never[];
23
+ fathers: {
24
+ name: string;
25
+ value: {
26
+ type: string;
27
+ is_null: string;
28
+ maxlength: null;
29
+ };
30
+ fk_table: string;
31
+ fk_reference: string;
32
+ pk: boolean;
33
+ }[];
24
34
  childrens: {
25
35
  name: string;
26
36
  value: {
@@ -100,9 +100,32 @@ exports.default = {
100
100
  "fk_table": null,
101
101
  "fk_reference": null,
102
102
  "pk": false
103
+ },
104
+ {
105
+ "name": "item",
106
+ "value": {
107
+ "type": "integer",
108
+ "is_null": "NO",
109
+ "maxlength": null
110
+ },
111
+ "fk_table": "item",
112
+ "fk_reference": "id",
113
+ "pk": false
114
+ }
115
+ ],
116
+ "fathers": [
117
+ {
118
+ "name": "item",
119
+ "value": {
120
+ "type": "integer",
121
+ "is_null": "NO",
122
+ "maxlength": null
123
+ },
124
+ "fk_table": "item",
125
+ "fk_reference": "id",
126
+ "pk": false
103
127
  }
104
128
  ],
105
- "fathers": [],
106
129
  "childrens": [
107
130
  {
108
131
  "name": "item_variacao",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pg-manipulator",
3
- "version": "1.0.44",
3
+ "version": "1.0.45",
4
4
  "description": "postgresql database handler",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",