ts-glitter 21.3.7 → 21.3.8
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/lowcode/Entry.js +1 -1
- package/lowcode/Entry.ts +1 -1
- package/lowcode/cms-plugin/POS-setting.js +2 -2
- package/lowcode/cms-plugin/POS-setting.ts +2 -2
- package/lowcode/cms-plugin/pos-pages/payment-page.js +1 -1
- package/lowcode/cms-plugin/pos-pages/payment-page.ts +1 -1
- package/lowcode/cms-plugin/pos-pages/products-page.js +9 -5
- package/lowcode/cms-plugin/pos-pages/products-page.ts +12 -5
- package/package.json +1 -1
package/lowcode/Entry.js
CHANGED
|
@@ -146,7 +146,7 @@ export class Entry {
|
|
|
146
146
|
}
|
|
147
147
|
window.renderClock = (_b = window.renderClock) !== null && _b !== void 0 ? _b : createClock();
|
|
148
148
|
console.log(`Entry-time:`, window.renderClock.stop());
|
|
149
|
-
glitter.share.editerVersion = 'V_21.3.
|
|
149
|
+
glitter.share.editerVersion = 'V_21.3.8';
|
|
150
150
|
glitter.share.start = new Date();
|
|
151
151
|
const vm = { appConfig: [] };
|
|
152
152
|
window.saasConfig = {
|
package/lowcode/Entry.ts
CHANGED
|
@@ -150,7 +150,7 @@ export class Entry {
|
|
|
150
150
|
}
|
|
151
151
|
(window as any).renderClock = (window as any).renderClock ?? createClock();
|
|
152
152
|
console.log(`Entry-time:`, (window as any).renderClock.stop());
|
|
153
|
-
glitter.share.editerVersion = 'V_21.3.
|
|
153
|
+
glitter.share.editerVersion = 'V_21.3.8';
|
|
154
154
|
glitter.share.start = new Date();
|
|
155
155
|
const vm = { appConfig: [] };
|
|
156
156
|
(window as any).saasConfig = {
|
|
@@ -364,7 +364,7 @@ export class POSSetting {
|
|
|
364
364
|
>
|
|
365
365
|
<div
|
|
366
366
|
class="d-flex flex-column position-relative"
|
|
367
|
-
style="width: 542px;padding:
|
|
367
|
+
style="width: 542px;padding: 24px;background-color: white;border-radius: 10px;max-width: calc(100% - 20px);overflow-y:auto;max-height:calc(100% - 20px);"
|
|
368
368
|
onclick="${gvc.event((_, event) => event.stopPropagation())}"
|
|
369
369
|
>
|
|
370
370
|
<div class="w-100 d-block d-sm-flex flex-column flex-sm-row m" style="gap:24px;">
|
|
@@ -564,7 +564,7 @@ export class POSSetting {
|
|
|
564
564
|
class: 'd-flex align-items-center justify-content-center',
|
|
565
565
|
style: `
|
|
566
566
|
flex: 1;
|
|
567
|
-
padding: 12px
|
|
567
|
+
padding: 12px 12px;
|
|
568
568
|
font-size: 20px;
|
|
569
569
|
color: #fff;
|
|
570
570
|
font-weight: 500;
|
|
@@ -420,7 +420,7 @@ export class POSSetting {
|
|
|
420
420
|
>
|
|
421
421
|
<div
|
|
422
422
|
class="d-flex flex-column position-relative"
|
|
423
|
-
style="width: 542px;padding:
|
|
423
|
+
style="width: 542px;padding: 24px;background-color: white;border-radius: 10px;max-width: calc(100% - 20px);overflow-y:auto;max-height:calc(100% - 20px);"
|
|
424
424
|
onclick="${gvc.event((_, event) => event.stopPropagation())}"
|
|
425
425
|
>
|
|
426
426
|
<div class="w-100 d-block d-sm-flex flex-column flex-sm-row m" style="gap:24px;">
|
|
@@ -641,7 +641,7 @@ export class POSSetting {
|
|
|
641
641
|
class: 'd-flex align-items-center justify-content-center',
|
|
642
642
|
style: `
|
|
643
643
|
flex: 1;
|
|
644
|
-
padding: 12px
|
|
644
|
+
padding: 12px 12px;
|
|
645
645
|
font-size: 20px;
|
|
646
646
|
color: #fff;
|
|
647
647
|
font-weight: 500;
|
|
@@ -29,7 +29,9 @@ export class ProductsPage {
|
|
|
29
29
|
};
|
|
30
30
|
function loadData() {
|
|
31
31
|
let category = vm.categories.find((category) => category.select == true);
|
|
32
|
-
|
|
32
|
+
if ((!vm.productSearch) || !vm.productSearch.length) {
|
|
33
|
+
dialog.dataLoading({ visible: true });
|
|
34
|
+
}
|
|
33
35
|
ApiShop.getProduct({
|
|
34
36
|
page: pVM.pageIndex - 1,
|
|
35
37
|
collection: category.key == 'all' ? '' : category.key,
|
|
@@ -40,9 +42,11 @@ export class ProductsPage {
|
|
|
40
42
|
whereStore: POSSetting.config.where_store,
|
|
41
43
|
orderBy: 'created_time_desc',
|
|
42
44
|
}).then(res => {
|
|
45
|
+
if ((!vm.productSearch) || !vm.productSearch.length) {
|
|
46
|
+
dialog.dataLoading({ visible: false });
|
|
47
|
+
}
|
|
43
48
|
vm.productSearch = res.response.data;
|
|
44
49
|
pVM.pageSize = Math.ceil(res.response.total / parseInt(pVM.limit, 10));
|
|
45
|
-
dialog.dataLoading({ visible: false });
|
|
46
50
|
gvc.notifyDataChange(`productShow`);
|
|
47
51
|
});
|
|
48
52
|
}
|
|
@@ -101,7 +105,7 @@ export class ProductsPage {
|
|
|
101
105
|
},
|
|
102
106
|
divCreate: {
|
|
103
107
|
class: `d-flex px-3 `,
|
|
104
|
-
style: `width:100%;overflow: scroll
|
|
108
|
+
style: `width:100%;overflow: scroll;${document.body.clientWidth > 992 ? `padding-left:32px !important;padding-right:32px !important;padding-bottom:32px;` : `padding-top:20px;padding-bottom:20px;`}`,
|
|
105
109
|
},
|
|
106
110
|
})}
|
|
107
111
|
${gvc.bindView(() => {
|
|
@@ -117,7 +121,7 @@ export class ProductsPage {
|
|
|
117
121
|
}
|
|
118
122
|
let maxwidth = (parent.offsetWidth - 72 - (rowItem - 1) * 26) / rowItem;
|
|
119
123
|
if (document.body.offsetWidth < 600) {
|
|
120
|
-
maxwidth +=
|
|
124
|
+
maxwidth += 30;
|
|
121
125
|
}
|
|
122
126
|
if (vm.productSearch.length > 0) {
|
|
123
127
|
return (vm.productSearch
|
|
@@ -191,7 +195,7 @@ export class ProductsPage {
|
|
|
191
195
|
if (document.body.offsetWidth < 800) {
|
|
192
196
|
return {
|
|
193
197
|
class: `d-flex flex-wrap w-100 product-show`,
|
|
194
|
-
style: `overflow:scroll;max-height:100%;padding-left:
|
|
198
|
+
style: `overflow:scroll;max-height:100%;padding-left:12px;padding-right:12px;justify-content: space-between;padding-bottom:100px;`,
|
|
195
199
|
};
|
|
196
200
|
}
|
|
197
201
|
else {
|
|
@@ -6,6 +6,7 @@ import { POSSetting } from '../POS-setting.js';
|
|
|
6
6
|
import { Swal } from '../../modules/sweetAlert.js';
|
|
7
7
|
import { PaymentPage } from './payment-page.js';
|
|
8
8
|
import { PayConfig } from './pay-config.js';
|
|
9
|
+
import { fa } from '@faker-js/faker';
|
|
9
10
|
|
|
10
11
|
const html = String.raw;
|
|
11
12
|
|
|
@@ -108,7 +109,10 @@ export class ProductsPage {
|
|
|
108
109
|
|
|
109
110
|
function loadData() {
|
|
110
111
|
let category = vm.categories.find((category: any) => category.select == true);
|
|
111
|
-
|
|
112
|
+
if((!vm.productSearch) || !vm.productSearch.length){
|
|
113
|
+
dialog.dataLoading({ visible: true });
|
|
114
|
+
}
|
|
115
|
+
// dialog.dataLoading({ visible: true });
|
|
112
116
|
ApiShop.getProduct({
|
|
113
117
|
page: pVM.pageIndex - 1,
|
|
114
118
|
collection: category.key == 'all' ? '' : category.key,
|
|
@@ -119,9 +123,12 @@ export class ProductsPage {
|
|
|
119
123
|
whereStore: POSSetting.config.where_store,
|
|
120
124
|
orderBy: 'created_time_desc',
|
|
121
125
|
}).then(res => {
|
|
126
|
+
if((!vm.productSearch) || !vm.productSearch.length){
|
|
127
|
+
dialog.dataLoading({ visible: false });
|
|
128
|
+
}
|
|
122
129
|
vm.productSearch = res.response.data;
|
|
123
130
|
pVM.pageSize = Math.ceil(res.response.total / parseInt(pVM.limit as any, 10));
|
|
124
|
-
dialog.dataLoading({ visible: false });
|
|
131
|
+
// dialog.dataLoading({ visible: false });
|
|
125
132
|
gvc.notifyDataChange(`productShow`);
|
|
126
133
|
});
|
|
127
134
|
}
|
|
@@ -183,7 +190,7 @@ export class ProductsPage {
|
|
|
183
190
|
},
|
|
184
191
|
divCreate: {
|
|
185
192
|
class: `d-flex px-3 `,
|
|
186
|
-
style: `width:100%;overflow: scroll
|
|
193
|
+
style: `width:100%;overflow: scroll;${document.body.clientWidth > 992 ? `padding-left:32px !important;padding-right:32px !important;padding-bottom:32px;` : `padding-top:20px;padding-bottom:20px;`}`,
|
|
187
194
|
},
|
|
188
195
|
})}
|
|
189
196
|
${gvc.bindView(() => {
|
|
@@ -199,7 +206,7 @@ export class ProductsPage {
|
|
|
199
206
|
}
|
|
200
207
|
let maxwidth = (parent.offsetWidth - 72 - (rowItem - 1) * 26) / rowItem;
|
|
201
208
|
if (document.body.offsetWidth < 600) {
|
|
202
|
-
maxwidth +=
|
|
209
|
+
maxwidth += 30;
|
|
203
210
|
}
|
|
204
211
|
|
|
205
212
|
if (vm.productSearch.length > 0) {
|
|
@@ -279,7 +286,7 @@ export class ProductsPage {
|
|
|
279
286
|
if (document.body.offsetWidth < 800) {
|
|
280
287
|
return {
|
|
281
288
|
class: `d-flex flex-wrap w-100 product-show`,
|
|
282
|
-
style: `overflow:scroll;max-height:100%;padding-left:
|
|
289
|
+
style: `overflow:scroll;max-height:100%;padding-left:12px;padding-right:12px;justify-content: space-between;padding-bottom:100px;`,
|
|
283
290
|
};
|
|
284
291
|
} else {
|
|
285
292
|
return {
|