test-entity-library-asm 3.9.55 → 3.9.57

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 (49) hide show
  1. package/dist/entities/Company.js +5 -11
  2. package/dist/entities/Country.d.ts +2 -2
  3. package/dist/entities/Country.js +7 -7
  4. package/dist/entities/DiscountCodeCompany.js +1 -4
  5. package/dist/entities/DiscountCodeUser.js +1 -3
  6. package/dist/entities/Local.js +6 -7
  7. package/dist/entities/LocalChange.js +1 -2
  8. package/dist/entities/LocalPlan.js +1 -3
  9. package/dist/entities/Master.js +1 -3
  10. package/dist/entities/MasterNotification.js +1 -3
  11. package/dist/entities/Partner.js +1 -3
  12. package/dist/entities/PartnerNotification.js +1 -3
  13. package/dist/entities/PaymentMethod.js +1 -3
  14. package/dist/entities/Plan.js +1 -3
  15. package/dist/entities/Square.js +1 -3
  16. package/dist/entities/User.js +1 -3
  17. package/dist/views/DiscountsCodeUser.js +2 -15
  18. package/dist/views/LocalReserves.js +2 -15
  19. package/dist/views/LocalsCompanyInformationForTheMap.js +10 -22
  20. package/dist/views/LocalsCompanyInformationForTheTable.d.ts +2 -2
  21. package/dist/views/LocalsCompanyInformationForTheTable.js +16 -28
  22. package/dist/views/MasterNotifications.js +5 -10
  23. package/dist/views/PartnerNotifications.js +3 -8
  24. package/dist/views/Partners.js +2 -15
  25. package/dist/views/ViewLocalsCompanies.js +1 -6
  26. package/package.json +2 -1
  27. package/src/entities/Company.ts +5 -11
  28. package/src/entities/Country.ts +9 -9
  29. package/src/entities/DiscountCodeCompany.ts +1 -4
  30. package/src/entities/DiscountCodeUser.ts +1 -3
  31. package/src/entities/Local.ts +7 -9
  32. package/src/entities/LocalChange.ts +1 -1
  33. package/src/entities/LocalPlan.ts +1 -3
  34. package/src/entities/Master.ts +2 -4
  35. package/src/entities/MasterNotification.ts +1 -3
  36. package/src/entities/Partner.ts +1 -3
  37. package/src/entities/PartnerNotification.ts +1 -3
  38. package/src/entities/PaymentMethod.ts +1 -3
  39. package/src/entities/Plan.ts +1 -3
  40. package/src/entities/Square.ts +1 -3
  41. package/src/entities/User.ts +1 -3
  42. package/src/views/DiscountsCodeUser.ts +2 -16
  43. package/src/views/LocalReserves.ts +2 -15
  44. package/src/views/LocalsCompanyInformationForTheMap.ts +10 -22
  45. package/src/views/LocalsCompanyInformationForTheTable.ts +17 -29
  46. package/src/views/MasterNotifications.ts +5 -11
  47. package/src/views/PartnerNotifications.ts +3 -9
  48. package/src/views/Partners.ts +2 -15
  49. package/src/views/ViewLocalsCompanies.ts +1 -7
@@ -11,7 +11,6 @@ import {
11
11
  import { City } from "./City";
12
12
  import { Local } from "./Local";
13
13
  import { User } from "./User";
14
- import { jsonTransformer } from "../transformers/jsonTransformer";
15
14
 
16
15
  @Entity({
17
16
  comment:
@@ -66,10 +65,9 @@ export class Square {
66
65
  longitude: number;
67
66
 
68
67
  @Column({
69
- type: "mediumtext",
68
+ type: "json",
70
69
  nullable: true,
71
70
  default: null,
72
- transformer: jsonTransformer,
73
71
  comment:
74
72
  "Campo de tipo JSON por si se llega a necesitar agregar otras columnas para las plazoletas de los centros comerciales.",
75
73
  })
@@ -15,7 +15,6 @@ import {
15
15
  RequestLocalPayment,
16
16
  UserPaymentMethod,
17
17
  } from "..";
18
- import { jsonTransformer } from "../transformers/jsonTransformer";
19
18
  import { City } from "./City";
20
19
  import { CodeRedemptionHistoryUser } from "./CodeRedemptionHistoryUser";
21
20
  import { Local } from "./Local";
@@ -88,10 +87,9 @@ export class User {
88
87
  password: string;
89
88
 
90
89
  @Column({
91
- type: "longtext",
90
+ type: "json",
92
91
  nullable: true,
93
92
  default: null,
94
- transformer: jsonTransformer,
95
93
  comment:
96
94
  "Campo de tipo JSON donde se guarda información necesaria para el registro.",
97
95
  })
@@ -1,19 +1,5 @@
1
1
  import { ViewColumn, ViewEntity } from "typeorm";
2
2
 
3
- // JSON Transformer
4
- const jsonTransformer = {
5
- to: (value: any) => JSON.stringify(value),
6
-
7
- from: (value: string) => {
8
- try {
9
- return JSON.parse(value);
10
- } catch (error) {
11
- console.log(error, "Transformer error");
12
- return null;
13
- }
14
- },
15
- };
16
-
17
3
  @ViewEntity({
18
4
  name: "discounts_code_user",
19
5
  })
@@ -51,7 +37,7 @@ export class DiscountsCodeUser {
51
37
  @ViewColumn()
52
38
  expiration: string;
53
39
 
54
- @ViewColumn({ transformer: jsonTransformer })
40
+ @ViewColumn()
55
41
  repeat_days: any;
56
42
 
57
43
  @ViewColumn()
@@ -87,7 +73,7 @@ export class DiscountsCodeUser {
87
73
  @ViewColumn()
88
74
  partner_surname: string;
89
75
 
90
- @ViewColumn({ transformer: jsonTransformer })
76
+ @ViewColumn()
91
77
  partner_profile: any;
92
78
 
93
79
  @ViewColumn()
@@ -1,18 +1,5 @@
1
1
  import { ViewColumn, ViewEntity } from "typeorm";
2
2
 
3
- // JSON Transformer
4
- const jsonTransformer = {
5
- to: (value: any) => JSON.stringify(value),
6
- from: (value: string) => {
7
- try {
8
- return JSON.parse(value);
9
- } catch (error) {
10
- console.log(error, "Transformer error");
11
- return null;
12
- }
13
- },
14
- };
15
-
16
3
  @ViewEntity({
17
4
  name: "local_reserves",
18
5
  })
@@ -176,7 +163,7 @@ export class LocalReserves {
176
163
  @ViewColumn()
177
164
  partner_email: string | null;
178
165
 
179
- @ViewColumn({ transformer: jsonTransformer })
166
+ @ViewColumn()
180
167
  partner_profile: any | null;
181
168
 
182
169
  @ViewColumn()
@@ -206,7 +193,7 @@ export class LocalReserves {
206
193
  @ViewColumn()
207
194
  user_table_phone: string | null;
208
195
 
209
- @ViewColumn({ transformer: jsonTransformer })
196
+ @ViewColumn()
210
197
  user_table_profile: any | null;
211
198
 
212
199
  @ViewColumn()
@@ -1,17 +1,5 @@
1
1
  import { ViewColumn, ViewEntity } from "typeorm";
2
2
 
3
- const jsonTransformer = {
4
- to: (value: any) => JSON.stringify(value),
5
- from: (value: string) => {
6
- try {
7
- return JSON.parse(value);
8
- } catch (error) {
9
- console.log(error, "Transformer error");
10
- return null;
11
- }
12
- },
13
- };
14
-
15
3
  @ViewEntity({
16
4
  name: "locals_company_information_for_the_map",
17
5
  })
@@ -37,7 +25,7 @@ export class LocalsCompanyInformationForTheMap {
37
25
  @ViewColumn()
38
26
  longitude: number;
39
27
 
40
- @ViewColumn({ transformer: jsonTransformer })
28
+ @ViewColumn()
41
29
  details: any | null;
42
30
 
43
31
  @ViewColumn()
@@ -55,7 +43,7 @@ export class LocalsCompanyInformationForTheMap {
55
43
  @ViewColumn()
56
44
  pos_system: number;
57
45
 
58
- @ViewColumn({ transformer: jsonTransformer })
46
+ @ViewColumn()
59
47
  pos_system_settings: any | null;
60
48
 
61
49
  @ViewColumn()
@@ -64,7 +52,7 @@ export class LocalsCompanyInformationForTheMap {
64
52
  @ViewColumn()
65
53
  visible: number;
66
54
 
67
- @ViewColumn({ transformer: jsonTransformer })
55
+ @ViewColumn()
68
56
  contact_details: any | null;
69
57
 
70
58
  @ViewColumn()
@@ -76,13 +64,13 @@ export class LocalsCompanyInformationForTheMap {
76
64
  @ViewColumn()
77
65
  company_partner: number;
78
66
 
79
- @ViewColumn({ transformer: jsonTransformer })
67
+ @ViewColumn()
80
68
  company_profile: any | null;
81
69
 
82
- @ViewColumn({ transformer: jsonTransformer })
70
+ @ViewColumn()
83
71
  company_contact_details: any | null;
84
72
 
85
- @ViewColumn({ transformer: jsonTransformer })
73
+ @ViewColumn()
86
74
  company_settings: any | null;
87
75
 
88
76
  @ViewColumn()
@@ -121,7 +109,7 @@ export class LocalsCompanyInformationForTheMap {
121
109
  @ViewColumn()
122
110
  square_longitude: number;
123
111
 
124
- @ViewColumn({ transformer: jsonTransformer })
112
+ @ViewColumn()
125
113
  square_details: any | null;
126
114
 
127
115
  @ViewColumn()
@@ -166,13 +154,13 @@ export class LocalsCompanyInformationForTheMap {
166
154
  @ViewColumn()
167
155
  country_structure_phone: string;
168
156
 
169
- @ViewColumn({ transformer: jsonTransformer })
157
+ @ViewColumn()
170
158
  country_legal_information: any | null;
171
159
 
172
160
  @ViewColumn()
173
161
  country_legal_agent: string;
174
162
 
175
- @ViewColumn({ transformer: jsonTransformer })
163
+ @ViewColumn()
176
164
  country_details: any | null;
177
165
 
178
166
  @ViewColumn()
@@ -199,7 +187,7 @@ export class LocalsCompanyInformationForTheMap {
199
187
  @ViewColumn()
200
188
  partner_address: string;
201
189
 
202
- @ViewColumn({ transformer: jsonTransformer })
190
+ @ViewColumn()
203
191
  partner_profile: any | null;
204
192
 
205
193
  @ViewColumn()
@@ -1,17 +1,5 @@
1
1
  import { ViewColumn, ViewEntity } from "typeorm";
2
2
 
3
- const jsonTransformer = {
4
- to: (value: any) => JSON.stringify(value),
5
- from: (value: string) => {
6
- try {
7
- return JSON.parse(value);
8
- } catch (error) {
9
- console.log(error, "Transformer error");
10
- return null;
11
- }
12
- },
13
- };
14
-
15
3
  @ViewEntity({
16
4
  name: "locals_company_information_for_the_table",
17
5
  })
@@ -40,7 +28,7 @@ export class LocalsCompanyInformationForTheTable {
40
28
  @ViewColumn()
41
29
  longitude: number;
42
30
 
43
- @ViewColumn({ transformer: jsonTransformer })
31
+ @ViewColumn()
44
32
  details: any | null;
45
33
 
46
34
  @ViewColumn()
@@ -61,7 +49,7 @@ export class LocalsCompanyInformationForTheTable {
61
49
  @ViewColumn()
62
50
  pos_system: number;
63
51
 
64
- @ViewColumn({ transformer: jsonTransformer })
52
+ @ViewColumn()
65
53
  pos_system_settings: any | null;
66
54
 
67
55
  @ViewColumn()
@@ -70,7 +58,7 @@ export class LocalsCompanyInformationForTheTable {
70
58
  @ViewColumn()
71
59
  visible: number;
72
60
 
73
- @ViewColumn({ transformer: jsonTransformer })
61
+ @ViewColumn()
74
62
  contact_details: any | null;
75
63
 
76
64
  @ViewColumn()
@@ -124,19 +112,19 @@ export class LocalsCompanyInformationForTheTable {
124
112
  @ViewColumn()
125
113
  company_partner: number;
126
114
 
127
- @ViewColumn({ transformer: jsonTransformer })
115
+ @ViewColumn()
128
116
  company_contact_details: any | null;
129
117
 
130
- @ViewColumn({ transformer: jsonTransformer })
118
+ @ViewColumn()
131
119
  company_profile: any | null;
132
120
 
133
121
  @ViewColumn()
134
- company_legal_agent: string;
122
+ company_legal_agent: any | null;
135
123
 
136
- @ViewColumn({ transformer: jsonTransformer })
124
+ @ViewColumn()
137
125
  company_legal_information: any | null;
138
126
 
139
- @ViewColumn({ transformer: jsonTransformer })
127
+ @ViewColumn()
140
128
  company_settings: any | null;
141
129
 
142
130
  @ViewColumn()
@@ -175,13 +163,13 @@ export class LocalsCompanyInformationForTheTable {
175
163
  @ViewColumn()
176
164
  country_currency: string;
177
165
 
178
- @ViewColumn({ transformer: jsonTransformer })
166
+ @ViewColumn()
179
167
  country_details: any | null;
180
168
 
181
- @ViewColumn({ transformer: jsonTransformer })
182
- country_legal_agent: string | null;
169
+ @ViewColumn()
170
+ country_legal_agent: any | null;
183
171
 
184
- @ViewColumn({ transformer: jsonTransformer })
172
+ @ViewColumn()
185
173
  country_legal_information: any | null;
186
174
 
187
175
  @ViewColumn()
@@ -226,7 +214,7 @@ export class LocalsCompanyInformationForTheTable {
226
214
  @ViewColumn()
227
215
  created_by_address: string | null;
228
216
 
229
- @ViewColumn({ transformer: jsonTransformer })
217
+ @ViewColumn()
230
218
  created_by_profile: any | null;
231
219
 
232
220
  @ViewColumn()
@@ -274,7 +262,7 @@ export class LocalsCompanyInformationForTheTable {
274
262
  @ViewColumn()
275
263
  partner_address: string | null;
276
264
 
277
- @ViewColumn({ transformer: jsonTransformer })
265
+ @ViewColumn()
278
266
  partner_profile: any | null;
279
267
 
280
268
  @ViewColumn()
@@ -292,7 +280,7 @@ export class LocalsCompanyInformationForTheTable {
292
280
  @ViewColumn()
293
281
  square_id: number;
294
282
 
295
- @ViewColumn({ transformer: jsonTransformer })
283
+ @ViewColumn()
296
284
  square_details: any | null;
297
285
 
298
286
  @ViewColumn()
@@ -334,7 +322,7 @@ export class LocalsCompanyInformationForTheTable {
334
322
  @ViewColumn()
335
323
  local_plan_end_date: Date;
336
324
 
337
- @ViewColumn({ transformer: jsonTransformer })
325
+ @ViewColumn()
338
326
  local_plan_settings: any | null;
339
327
 
340
328
  @ViewColumn()
@@ -355,7 +343,7 @@ export class LocalsCompanyInformationForTheTable {
355
343
  @ViewColumn()
356
344
  plan_id: number;
357
345
 
358
- @ViewColumn({ transformer: jsonTransformer })
346
+ @ViewColumn()
359
347
  plan_description: any | null;
360
348
 
361
349
  @ViewColumn()
@@ -1,11 +1,5 @@
1
1
  import { ViewEntity, ViewColumn } from "typeorm";
2
2
 
3
- // JSON Transformer
4
- const jsonTransformer = {
5
- to: (value: any) => JSON.stringify(value),
6
- from: (value: string) => JSON.parse(value),
7
- };
8
-
9
3
  @ViewEntity({
10
4
  name: "master_notifications",
11
5
  })
@@ -25,7 +19,7 @@ export class MasterNotifications {
25
19
  @ViewColumn()
26
20
  description: string;
27
21
 
28
- @ViewColumn({ transformer: jsonTransformer })
22
+ @ViewColumn()
29
23
  settings: any;
30
24
 
31
25
  @ViewColumn()
@@ -40,7 +34,7 @@ export class MasterNotifications {
40
34
  @ViewColumn()
41
35
  partner_surname: string;
42
36
 
43
- @ViewColumn({ transformer: jsonTransformer })
37
+ @ViewColumn()
44
38
  partner_profile: any;
45
39
 
46
40
  @ViewColumn()
@@ -67,7 +61,7 @@ export class MasterNotifications {
67
61
  @ViewColumn()
68
62
  master_phone: string;
69
63
 
70
- @ViewColumn({ transformer: jsonTransformer })
64
+ @ViewColumn()
71
65
  master_profile: any;
72
66
 
73
67
  @ViewColumn()
@@ -76,7 +70,7 @@ export class MasterNotifications {
76
70
  @ViewColumn()
77
71
  verify_local_id: number;
78
72
 
79
- @ViewColumn({ transformer: jsonTransformer })
73
+ @ViewColumn()
80
74
  verify_local_local_information: any;
81
75
 
82
76
  @ViewColumn()
@@ -91,7 +85,7 @@ export class MasterNotifications {
91
85
  @ViewColumn()
92
86
  company_name: string;
93
87
 
94
- @ViewColumn({ transformer: jsonTransformer })
88
+ @ViewColumn()
95
89
  company_profile: any;
96
90
 
97
91
  @ViewColumn()
@@ -1,11 +1,5 @@
1
1
  import { ViewEntity, ViewColumn } from "typeorm";
2
2
 
3
- // JSON Transformer
4
- const jsonTransformer = {
5
- to: (value: any) => JSON.stringify(value),
6
- from: (value: string) => JSON.parse(value),
7
- };
8
-
9
3
  @ViewEntity({
10
4
  name: "partner_notifications",
11
5
  })
@@ -25,7 +19,7 @@ export class PartnerNotifications {
25
19
  @ViewColumn()
26
20
  description: string;
27
21
 
28
- @ViewColumn({ transformer: jsonTransformer })
22
+ @ViewColumn()
29
23
  settings: any;
30
24
 
31
25
  @ViewColumn()
@@ -40,7 +34,7 @@ export class PartnerNotifications {
40
34
  @ViewColumn()
41
35
  partner_surname: string;
42
36
 
43
- @ViewColumn({ transformer: jsonTransformer })
37
+ @ViewColumn()
44
38
  partner_profile: any;
45
39
 
46
40
  @ViewColumn()
@@ -67,7 +61,7 @@ export class PartnerNotifications {
67
61
  @ViewColumn()
68
62
  master_phone: string;
69
63
 
70
- @ViewColumn({ transformer: jsonTransformer })
64
+ @ViewColumn()
71
65
  master_profile: any;
72
66
 
73
67
  @ViewColumn()
@@ -1,18 +1,5 @@
1
1
  import { ViewEntity, ViewColumn } from "typeorm";
2
2
 
3
- // JSON Transformer
4
- const jsonTransformer = {
5
- to: (value: any) => JSON.stringify(value),
6
- from: (value: string) => {
7
- try {
8
- return JSON.parse(value);
9
- } catch (error) {
10
- console.log(error, "Transformer error");
11
- return null;
12
- }
13
- },
14
- };
15
-
16
3
  @ViewEntity({
17
4
  name: "partners",
18
5
  })
@@ -50,7 +37,7 @@ export class Partners {
50
37
  @ViewColumn()
51
38
  password: string;
52
39
 
53
- @ViewColumn({ transformer: jsonTransformer })
40
+ @ViewColumn()
54
41
  profile: any;
55
42
 
56
43
  @ViewColumn()
@@ -101,7 +88,7 @@ export class Partners {
101
88
  @ViewColumn()
102
89
  country_structure_phone: string;
103
90
 
104
- @ViewColumn({ transformer: jsonTransformer })
91
+ @ViewColumn()
105
92
  country_details: any;
106
93
 
107
94
  @ViewColumn()
@@ -1,11 +1,5 @@
1
1
  import { ViewEntity, ViewColumn } from "typeorm";
2
2
 
3
- // JSON Transformer
4
- const jsonTransformer = {
5
- to: (value: any) => JSON.stringify(value),
6
- from: (value: string) => JSON.parse(value),
7
- };
8
-
9
3
  @ViewEntity({
10
4
  name: "view_locals_companies",
11
5
  })
@@ -28,7 +22,7 @@ export class ViewLocalsCompanies {
28
22
  @ViewColumn()
29
23
  has_square: number;
30
24
 
31
- @ViewColumn({ transformer: jsonTransformer })
25
+ @ViewColumn()
32
26
  details_local: any;
33
27
 
34
28
  @ViewColumn()