tango-app-api-payment-subscription 3.0.11-dev → 3.0.13-dev
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.
- package/.eslintrc.cjs +1 -0
- package/package.json +1 -1
- package/src/controllers/paymentSubscription.controllers.js +246 -139
- package/src/dtos/validation.dtos.js +26 -2
- package/src/hbs/trialInitiateEmail.hbs +322 -0
- package/src/routes/paymentSubscription.routes.js +3 -1
- package/src/services/store.service.js +4 -0
- package/src/utils/validations/client.validation.js +0 -1
- package/src/utils/validations/helper/handlebar.helper.js +14 -0
- package/script-new.js +0 -376
|
@@ -63,7 +63,7 @@ export const validateTrialandUnsubscribeParams = {
|
|
|
63
63
|
export const validateTrialExtendRequestParams = {
|
|
64
64
|
body: joi.object( {
|
|
65
65
|
clientId: joi.string().required(),
|
|
66
|
-
days: joi.
|
|
66
|
+
days: joi.number().required(),
|
|
67
67
|
product: joi.string().required(),
|
|
68
68
|
} ),
|
|
69
69
|
};
|
|
@@ -86,8 +86,9 @@ export const validateStoreViewParams = {
|
|
|
86
86
|
export const validateAddStoreProductParams = {
|
|
87
87
|
body: joi.object( {
|
|
88
88
|
clientId: joi.string().required(),
|
|
89
|
-
store: joi.array().required(),
|
|
89
|
+
store: joi.array().required().empty(),
|
|
90
90
|
product: joi.array().required(),
|
|
91
|
+
selectAll: joi.boolean().optional(),
|
|
91
92
|
} ),
|
|
92
93
|
};
|
|
93
94
|
|
|
@@ -101,6 +102,7 @@ export const validateInvoiceParams = {
|
|
|
101
102
|
sortColumn: joi.string().optional(),
|
|
102
103
|
sortBy: joi.number().optional(),
|
|
103
104
|
clientId: joi.string().required(),
|
|
105
|
+
export: joi.boolean().optional(),
|
|
104
106
|
} ),
|
|
105
107
|
};
|
|
106
108
|
|
|
@@ -127,3 +129,25 @@ export const validatePriceListParams = {
|
|
|
127
129
|
clientId: joi.string().required(),
|
|
128
130
|
} ),
|
|
129
131
|
};
|
|
132
|
+
|
|
133
|
+
export const validateStoreProductsParams = {
|
|
134
|
+
body: joi.object( {
|
|
135
|
+
clientId: joi.string().required(),
|
|
136
|
+
store: joi.array().required().empty(),
|
|
137
|
+
} ),
|
|
138
|
+
};
|
|
139
|
+
|
|
140
|
+
export const validateUpdateSubscriptionSchema = {
|
|
141
|
+
body: joi.object( {
|
|
142
|
+
clientId: joi.string().required(),
|
|
143
|
+
price: joi.number().required(),
|
|
144
|
+
priceType: joi.string().required(),
|
|
145
|
+
subscriptionType: joi.string().required(),
|
|
146
|
+
subscriptionPeriod: joi.string().required(),
|
|
147
|
+
storeCount: joi.number().required(),
|
|
148
|
+
totalCamera: joi.number().required(),
|
|
149
|
+
totalStores: joi.string().required(),
|
|
150
|
+
storeSize: joi.string().required(),
|
|
151
|
+
products: joi.array().required(),
|
|
152
|
+
} ),
|
|
153
|
+
};
|
|
@@ -0,0 +1,322 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html>
|
|
3
|
+
|
|
4
|
+
<head>
|
|
5
|
+
|
|
6
|
+
<meta charset="utf-8">
|
|
7
|
+
<meta http-equiv="x-ua-compatible" content="ie=edge">
|
|
8
|
+
<title>Batch Upload</title>
|
|
9
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
10
|
+
<style type="text/css">
|
|
11
|
+
@media screen {
|
|
12
|
+
@font-face {
|
|
13
|
+
font-family: 'Inter';
|
|
14
|
+
font-style: normal;
|
|
15
|
+
font-weight: 400;
|
|
16
|
+
font-display: swap;
|
|
17
|
+
src: local("Inter"), local("Inter-Regular"), url(https://fonts.gstatic.com/s/inter/v12/UcCO3FwrK3iLTeHuS_fvQtMwCp50KnMw2boKoduKmMEVuLyfAZJhiI2B.woff2) format('woff2');
|
|
18
|
+
unicode-range: U+0460-052F, U+1C80-1C88, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
body {
|
|
23
|
+
font-family: "Inter", sans-serif !important;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
body,
|
|
27
|
+
table,
|
|
28
|
+
td,
|
|
29
|
+
a {
|
|
30
|
+
-ms-text-size-adjust: 100%;
|
|
31
|
+
-webkit-text-size-adjust: 100%;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
table,
|
|
35
|
+
td {
|
|
36
|
+
mso-table-rspace: 0pt;
|
|
37
|
+
mso-table-lspace: 0pt;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
img {
|
|
41
|
+
-ms-interpolation-mode: bicubic;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
a[x-apple-data-detectors] {
|
|
45
|
+
font-family: "inherit" !important;
|
|
46
|
+
font-size: inherit !important;
|
|
47
|
+
font-weight: inherit !important;
|
|
48
|
+
line-height: inherit !important;
|
|
49
|
+
color: inherit !important;
|
|
50
|
+
text-decoration: none !important;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
div[style*="margin: 16px 0;"
|
|
55
|
+
|
|
56
|
+
] {
|
|
57
|
+
margin: 0 !important;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
body {
|
|
61
|
+
width: 100% !important;
|
|
62
|
+
height: 100% !important;
|
|
63
|
+
padding: 0 !important;
|
|
64
|
+
margin: 0 !important;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
table {
|
|
69
|
+
border-collapse: collapse !important;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
a {
|
|
73
|
+
color: #1a82e2;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
img {
|
|
77
|
+
height: auto;
|
|
78
|
+
line-height: 100%;
|
|
79
|
+
text-decoration: none;
|
|
80
|
+
border: 0;
|
|
81
|
+
outline: none;
|
|
82
|
+
}
|
|
83
|
+
</style>
|
|
84
|
+
|
|
85
|
+
</head>
|
|
86
|
+
|
|
87
|
+
<body style="background-color: #dbe5ea;">
|
|
88
|
+
|
|
89
|
+
<div class="preheader"
|
|
90
|
+
style="display: none; max-width: 0; max-height: 0; overflow: hidden; font-size: 1px; line-height: 1px; color: #fff; opacity: 0;">
|
|
91
|
+
Email Summary (Hidden)
|
|
92
|
+
</div>
|
|
93
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="padding-left:10px;padding-right:10px">
|
|
94
|
+
<tr>
|
|
95
|
+
<td bgcolor="#dbe5ea" style="padding:32px 10px 0 10px">
|
|
96
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 680px;" align="center">
|
|
97
|
+
<tr>
|
|
98
|
+
<td class="o_bg-white o_px-md o_py-md o_sans o_text"
|
|
99
|
+
style="margin-top: 0px;margin-bottom: 0px;font-size: 16px;line-height: 24px;background-color: #ffffff;padding-left: 18px;padding-right: 24px;padding-top: 24px;padding-bottom: 24px;">
|
|
100
|
+
<p style="margin-top: 0px;margin-bottom: 0px;"><a class="o_text-white"
|
|
101
|
+
href="https://tangoeye.ai/"
|
|
102
|
+
style="text-decoration: none;outline: none;color: #ffffff;"><img
|
|
103
|
+
src="https://pub-f88985f8e0964d3d8cd7fa6f2dde6962.r2.dev/TangoLogo/Tango%20Eye%20Logo%20color%20option-01.png"
|
|
104
|
+
width="200" height="100" alt="SimpleApp"
|
|
105
|
+
style="-ms-interpolation-mode: bicubic;vertical-align: middle;border: 0;line-height: 100%;height: auto;outline: none;text-decoration: none;"></a>
|
|
106
|
+
</p>
|
|
107
|
+
</td>
|
|
108
|
+
</tr>
|
|
109
|
+
<tr>
|
|
110
|
+
<td align="left" bgcolor="#ffffff"
|
|
111
|
+
style="padding-left: 30px;padding-right: 24px; font-size: 14px; line-height: 24px;">
|
|
112
|
+
<p class="o_heading o_mb-xxs"
|
|
113
|
+
style="width: 624px;height: 0px;border: 1px solid #CBD5E1;flex: none;order: 1;flex-grow: 0;">
|
|
114
|
+
</p>
|
|
115
|
+
</td>
|
|
116
|
+
</tr>
|
|
117
|
+
<tr>
|
|
118
|
+
<td class="o_bg-white o_px-md o_py-xl o_xs-py-md"
|
|
119
|
+
style="background-color: #ffffff;padding-left: 30px;padding-right: 24px;padding-bottom: 10px;">
|
|
120
|
+
<div class="o_col-6s o_sans o_text-md o_text-light o_center"
|
|
121
|
+
style="margin-top: 0px;margin-bottom: 0px;font-size: 24px;line-height: 28px;color: #82899a;">
|
|
122
|
+
<span class="o_heading o_text-dark o_mb-xxs"
|
|
123
|
+
style="font-weight: 700;margin-top: 0px;margin-bottom: 4px;color: #121A26;line-height: 140%;">
|
|
124
|
+
Welcome to Tango Zone Trial - Explore Premium Features! </span>
|
|
125
|
+
</div>
|
|
126
|
+
</td>
|
|
127
|
+
</tr>
|
|
128
|
+
</table>
|
|
129
|
+
</td>
|
|
130
|
+
</tr>
|
|
131
|
+
<tr>
|
|
132
|
+
<td align="center" bgcolor="#dbe5ea" style="padding:0 10px 0 10px">
|
|
133
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 680px;">
|
|
134
|
+
<tr>
|
|
135
|
+
<td align="left" bgcolor="#ffffff"
|
|
136
|
+
style="padding-left: 30px; padding-right: 24px;padding-top:10px;padding-bottom: 10px;font-weight: 400;font-size: 16px;line-height: 150%;color:#384860">
|
|
137
|
+
<p style="margin: 0;">Dear test,</p>
|
|
138
|
+
</td>
|
|
139
|
+
</tr>
|
|
140
|
+
<tr>
|
|
141
|
+
<td align="left" bgcolor="#ffffff"
|
|
142
|
+
style="padding-left: 30px;padding-right: 24px;padding-top:10px; font-size: 16px; line-height: 24px;font-weight:400;color:#384860">
|
|
143
|
+
<p style="margin: 0;">Welcome to the Tango Eye family! Your trial has begun, unlocking
|
|
144
|
+
premium features for you to explore:
|
|
145
|
+
</p>
|
|
146
|
+
</td>
|
|
147
|
+
</tr>
|
|
148
|
+
</table>
|
|
149
|
+
</td>
|
|
150
|
+
</tr>
|
|
151
|
+
<tr>
|
|
152
|
+
<td align="center" bgcolor="#dbe5ea" style="padding:0 10px 0 10px">
|
|
153
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 680px;">
|
|
154
|
+
<tr>
|
|
155
|
+
<td align="left" bgcolor="#ffffff">
|
|
156
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%">
|
|
157
|
+
<tr width="100">
|
|
158
|
+
<td bgcolor="#ffffff" style="padding:30px 20px 20px 30px;">
|
|
159
|
+
<div style="width:100% !important;background-color:#E2E8F0;">
|
|
160
|
+
<table border="0" cellpadding="0" cellspacing="0">
|
|
161
|
+
<tr>
|
|
162
|
+
<td class="o_bg-white o_px-md o_py-xl o_xs-py-md"
|
|
163
|
+
style="background-color: #E2E8F0;padding:20px 24px 10px 25px;">
|
|
164
|
+
<div class="o_col-6s o_sans o_text-md o_text-light o_center"
|
|
165
|
+
style="margin-top: 0px;margin-bottom: 0px;font-size: 18px;line-height: 28px;">
|
|
166
|
+
<span class="o_heading o_text-dark o_mb-xxs"
|
|
167
|
+
style="font-weight: 700;margin-top: 0px;margin-bottom: 4px;color: #121A26;line-height: 150%;">
|
|
168
|
+
Trial Features
|
|
169
|
+
</span>
|
|
170
|
+
</div>
|
|
171
|
+
</td>
|
|
172
|
+
</tr>
|
|
173
|
+
<tr>
|
|
174
|
+
<td class="o_bg-white o_px-md o_py-xl o_xs-py-md" align="center"
|
|
175
|
+
bgcolor="#E2E8F0"
|
|
176
|
+
style="background-color: #E2E8F0;padding:10px 24px 10px 25px;">
|
|
177
|
+
<div style="display:flex">
|
|
178
|
+
<div style="display:flex;width:280px;">
|
|
179
|
+
<div>
|
|
180
|
+
<img src="https://pub-f88985f8e0964d3d8cd7fa6f2dde6962.r2.dev/icons/email-check-success.png"
|
|
181
|
+
alt="SimpleApp"
|
|
182
|
+
style="-ms-interpolation-mode: bicubic;vertical-align: middle;border: 0;line-height: 100%;height: auto;outline: none;text-decoration: none;width: 25px;height:25px;">
|
|
183
|
+
</div>
|
|
184
|
+
<div style="margin:1px 0 0 10px">
|
|
185
|
+
<span
|
|
186
|
+
style="color:#121A26;font-size:16px;font-weight:500">Tag
|
|
187
|
+
zones of your choice</span>
|
|
188
|
+
</div>
|
|
189
|
+
</div>
|
|
190
|
+
<div style="display:flex;width:280px;">
|
|
191
|
+
<div>
|
|
192
|
+
<img src="https://pub-f88985f8e0964d3d8cd7fa6f2dde6962.r2.dev/icons/email-check-success.png"
|
|
193
|
+
alt="SimpleApp"
|
|
194
|
+
style="-ms-interpolation-mode: bicubic;vertical-align: middle;border: 0;line-height: 100%;height: auto;outline: none;text-decoration: none;width: 25px;height:25px;">
|
|
195
|
+
</div>
|
|
196
|
+
<div style="margin:1px 0 0 10px">
|
|
197
|
+
<span
|
|
198
|
+
style="color:#121A26;font-size:16px;font-weight:500">Plan
|
|
199
|
+
Merchandise </span>
|
|
200
|
+
</div>
|
|
201
|
+
</div>
|
|
202
|
+
</div>
|
|
203
|
+
</td>
|
|
204
|
+
</tr>
|
|
205
|
+
<tr>
|
|
206
|
+
<td class="o_bg-white o_px-md o_py-xl o_xs-py-md" align="center"
|
|
207
|
+
bgcolor="#E2E8F0"
|
|
208
|
+
style="background-color: #E2E8F0;padding:10px 24px 30px 25px;">
|
|
209
|
+
<div style="display:flex">
|
|
210
|
+
<div style="display:flex;width:280px;">
|
|
211
|
+
<div>
|
|
212
|
+
<img src="https://pub-f88985f8e0964d3d8cd7fa6f2dde6962.r2.dev/icons/email-check-success.png"
|
|
213
|
+
alt="SimpleApp"
|
|
214
|
+
style="-ms-interpolation-mode: bicubic;vertical-align: middle;border: 0;line-height: 100%;height: auto;outline: none;text-decoration: none;width: 25px;height:25px;">
|
|
215
|
+
</div>
|
|
216
|
+
<div style="margin:1px 0 0 10px">
|
|
217
|
+
<span
|
|
218
|
+
style="color:#121A26;font-size:16px;font-weight:500">Identifying
|
|
219
|
+
Hot spots</span>
|
|
220
|
+
</div>
|
|
221
|
+
</div>
|
|
222
|
+
<div style="display:flex;width:280px;">
|
|
223
|
+
<div>
|
|
224
|
+
<img src="https://pub-f88985f8e0964d3d8cd7fa6f2dde6962.r2.dev/icons/email-check-success.png"
|
|
225
|
+
alt="SimpleApp"
|
|
226
|
+
style="-ms-interpolation-mode: bicubic;vertical-align: middle;border: 0;line-height: 100%;height: auto;outline: none;text-decoration: none;width: 25px;height:25px;">
|
|
227
|
+
</div>
|
|
228
|
+
<div style="margin:1px 0 0 10px">
|
|
229
|
+
<span
|
|
230
|
+
style="color:#121A26;font-size:16px;font-weight:500">Premium
|
|
231
|
+
Customer Support </span>
|
|
232
|
+
</div>
|
|
233
|
+
</div>
|
|
234
|
+
</div>
|
|
235
|
+
</td>
|
|
236
|
+
</tr>
|
|
237
|
+
</table>
|
|
238
|
+
</div>
|
|
239
|
+
</td>
|
|
240
|
+
</tr>
|
|
241
|
+
</table>
|
|
242
|
+
</td>
|
|
243
|
+
</tr>
|
|
244
|
+
</table>
|
|
245
|
+
</td>
|
|
246
|
+
</tr>
|
|
247
|
+
<tr>
|
|
248
|
+
<td align="center" bgcolor="#dbe5ea" style="padding:0 10px 0 10px">
|
|
249
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 680px;">
|
|
250
|
+
<tr>
|
|
251
|
+
<td bgcolor="#ffffff" style="padding: 20px;padding-top:10px;padding-left:30px;">
|
|
252
|
+
<table border="0" cellpadding="0" cellspacing="0">
|
|
253
|
+
<tr>
|
|
254
|
+
<td align="center" bgcolor="#00A3FF" style="border-radius: 6px;">
|
|
255
|
+
<a href="data.uiDomainName" target="_blank"
|
|
256
|
+
style="display: inline-block; padding: 16px 36px; font-size: 16px; color: #ffffff; text-decoration: none; border-radius: 6px;">View
|
|
257
|
+
Dashboard
|
|
258
|
+
</a>
|
|
259
|
+
</td>
|
|
260
|
+
</tr>
|
|
261
|
+
</table>
|
|
262
|
+
</td>
|
|
263
|
+
</tr>
|
|
264
|
+
</table>
|
|
265
|
+
</td>
|
|
266
|
+
</tr>
|
|
267
|
+
<tr>
|
|
268
|
+
<td align="center" bgcolor="#dbe5ea" style="padding:0 10px 0 10px">
|
|
269
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 680px;">
|
|
270
|
+
<tr>
|
|
271
|
+
<td align="left" bgcolor="#ffffff"
|
|
272
|
+
style="padding-left: 30px;padding-right: 24px;padding-top:10px; font-size: 16px; line-height: 24px;font-weight:400;color:#384860">
|
|
273
|
+
<p style="margin: 0;">Enjoy the full potential of Tango Zone Module. If you have any
|
|
274
|
+
questions or need assistance, our support team is here to help.
|
|
275
|
+
</p>
|
|
276
|
+
</td>
|
|
277
|
+
</tr>
|
|
278
|
+
<tr>
|
|
279
|
+
<td align="left" bgcolor="#ffffff"
|
|
280
|
+
style="padding-left: 30px;padding-right: 24px;padding-top:20px; font-size: 16px; line-height: 24px;font-weight:400;color:#384860">
|
|
281
|
+
<p style="margin: 0;">
|
|
282
|
+
Happy exploring!</p>
|
|
283
|
+
</td>
|
|
284
|
+
</tr>
|
|
285
|
+
</table>
|
|
286
|
+
</td>
|
|
287
|
+
</tr>
|
|
288
|
+
<tr>
|
|
289
|
+
<td align="center" bgcolor="#dbe5ea" style="padding:0 10px 32px 10px">
|
|
290
|
+
<table border="0" cellpadding="0" cellspacing="0" width="100%" style="max-width: 680px;">
|
|
291
|
+
<tr>
|
|
292
|
+
<td class="o_bg-white o_px-md o_py-xl o_xs-py-md"
|
|
293
|
+
style="background-color: #ffffff;padding-left: 30px;padding-right: 24px;padding-top:35px">
|
|
294
|
+
<div class="o_col-6s o_sans o_text-md o_text-light o_center"
|
|
295
|
+
style="margin-top: 0px;margin-bottom: 0px;font-size: 12px;color: #202B3C;font-style: normal;font-weight: 400;font-size: 12px;line-height: 150%;">
|
|
296
|
+
<p>
|
|
297
|
+
If you'd rather not receive this kind of email, Don’t want any more emails from
|
|
298
|
+
TangoEye? <a
|
|
299
|
+
style="color: var(--Primary-Base, #00A3FF); text-decoration-line: underline; letter-spacing: 0.2px;">Unsubscribe.</a>
|
|
300
|
+
</p>
|
|
301
|
+
</div>
|
|
302
|
+
</td>
|
|
303
|
+
</tr>
|
|
304
|
+
<tr>
|
|
305
|
+
<td class="o_bg-white o_px-md o_py-xl o_xs-py-md"
|
|
306
|
+
style="background-color: #ffffff;padding-left: 30px;padding-right: 24px;padding-bottom:15px">
|
|
307
|
+
<div class="o_col-6s o_sans o_text-md o_text-light o_center"
|
|
308
|
+
style="margin-top: 0px;margin-bottom: 0px;font-size: 12px;color: #202B3C;font-style: normal;font-weight: 400;font-size: 12px;line-height: 150%;">
|
|
309
|
+
<p>
|
|
310
|
+
© Tango Eye. All rights reserved.</p>
|
|
311
|
+
</div>
|
|
312
|
+
</td>
|
|
313
|
+
</tr>
|
|
314
|
+
</table>
|
|
315
|
+
</td>
|
|
316
|
+
</tr>
|
|
317
|
+
|
|
318
|
+
</table>
|
|
319
|
+
|
|
320
|
+
</body>
|
|
321
|
+
|
|
322
|
+
</html>
|
|
@@ -12,7 +12,7 @@ paymentSubscriptionRouter.get( '/clientBillingSubscriptionInfo/:clientId', isAll
|
|
|
12
12
|
|
|
13
13
|
paymentSubscriptionRouter.post( '/basePricing', validate( validationDtos.validateProducts ), paymentController.pricingInfo );
|
|
14
14
|
|
|
15
|
-
paymentSubscriptionRouter.put( '/update/subscription/:clientId', isAllowedSessionHandler, validate( validationDtos.
|
|
15
|
+
paymentSubscriptionRouter.put( '/update/subscription/:clientId', isAllowedSessionHandler, validate( validationDtos.validateUpdateSubscriptionSchema ), validateClient, paymentController.updateSubscription );
|
|
16
16
|
|
|
17
17
|
paymentSubscriptionRouter.get( '/getTrialProducts', isAllowedSessionHandler, validate( validationDtos.validateStoreParams ), paymentController.trialProductList );
|
|
18
18
|
|
|
@@ -54,4 +54,6 @@ paymentSubscriptionRouter.post( '/creditNotes', isAllowedSessionHandler, validat
|
|
|
54
54
|
|
|
55
55
|
paymentSubscriptionRouter.get( '/creditNotes/invoiceList/:clientId', isAllowedSessionHandler, validate( validationDtos.validateBrandParams ), paymentController.unpaidInvoiceList );
|
|
56
56
|
|
|
57
|
+
paymentSubscriptionRouter.post( '/admin/getStoreProducts', isAllowedSessionHandler, validate( validationDtos.validateStoreProductsParams ), paymentController.getStoreProducts );
|
|
58
|
+
|
|
57
59
|
|
|
@@ -19,3 +19,7 @@ export const updateMany = ( query = {}, record = {} ) => {
|
|
|
19
19
|
export const addremoveElement = ( query = {}, record ={} ) => {
|
|
20
20
|
return model.storeModel.updateMany( query, record );
|
|
21
21
|
};
|
|
22
|
+
|
|
23
|
+
export const updateOne = ( query = {}, record ={} ) => {
|
|
24
|
+
return model.storeModel.updateOne( query, { $set: record } );
|
|
25
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
const Handlebars = require( 'handlebars' );
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
// Handlebars.registerHelper( 'eq', function( arg1, arg2, options ) {
|
|
5
|
+
// return ( arg1 == arg2 ) ? options.fn( this ) : options.inverse( this );
|
|
6
|
+
// } );
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
// Handlebars.registerHelper( 'neq', function( a, b, options ) {
|
|
10
|
+
// return a !== b ? options.fn( this ) : options.inverse( this );
|
|
11
|
+
// } );
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
module.exports = Handlebars;
|