@things-factory/operato-wms 4.0.8 → 4.0.12
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/client/pages/adjustment/transfer-inventory.js +368 -165
- package/client/pages/billing/claim-chit/claim-chit-list.js +7 -6
- package/client/pages/bulk-operation/bulk-operation.js +316 -0
- package/client/pages/bulk-operation/validate-ro-popup.js +445 -0
- package/client/pages/components/select-product-popup.js +15 -2
- package/client/pages/constants/inventory.js +1 -0
- package/client/pages/constants/location.js +33 -6
- package/client/pages/constants/order.js +10 -0
- package/client/pages/constants/worksheet.js +2 -2
- package/client/pages/inbound/inbound-worksheet.js +78 -9
- package/client/pages/inbound/putaway-product.js +214 -139
- package/client/pages/inbound/putaway-worksheet-generate-popup.js +24 -2
- package/client/pages/inbound/unload-product.js +153 -61
- package/client/pages/inbound/worksheet-putaway-return.js +22 -5
- package/client/pages/inbound/worksheet-putaway.js +21 -8
- package/client/pages/inbound/worksheet-unloading-return.js +22 -5
- package/client/pages/inbound/worksheet-unloading.js +8 -0
- package/client/pages/inventory/inventory-adjustment-approval.js +11 -19
- package/client/pages/inventory/inventory-adjustment.js +88 -73
- package/client/pages/inventory/inventory-by-product-detail.js +3 -5
- package/client/pages/inventory/inventory-by-product.js +8 -0
- package/client/pages/inventory/inventory-history-by-pallet.js +12 -5
- package/client/pages/inventory/inventory-history.js +14 -5
- package/client/pages/inventory/onhand-inventory.js +11 -2
- package/client/pages/inventory-check/create-cycle-count.js +12 -6
- package/client/pages/inventory-check/cycle-count-report.js +8 -0
- package/client/pages/inventory-check/inspecting-product.js +146 -80
- package/client/pages/inventory-check/worksheet-cycle-count.js +14 -0
- package/client/pages/manifest/create-loading-manifest.js +314 -0
- package/client/pages/manifest/dispatcher-verification-popup.js +86 -0
- package/client/pages/manifest/loading-manifest-detail.js +345 -0
- package/client/pages/manifest/loading-manifest-list.js +305 -0
- package/client/pages/master/location-list.js +58 -17
- package/client/pages/master/product/product-detail-bizplace-setting-popup.js +2 -2
- package/client/pages/master/product/product-details-popup.js +2 -2
- package/client/pages/master/product/product-list.js +5 -5
- package/client/pages/order/arrival-notice/arrival-notice-detail.js +134 -115
- package/client/pages/order/arrival-notice/arrival-notice-list.js +87 -6
- package/client/pages/order/arrival-notice/arrival-notice-requests.js +83 -6
- package/client/pages/order/arrival-notice/assign-buffer-location.js +8 -1
- package/client/pages/order/arrival-notice/check-arrived-notice.js +9 -1
- package/client/pages/order/arrival-notice/create-arrival-notice.js +38 -3
- package/client/pages/order/arrival-notice/duplicate-arrival-notice.js +290 -25
- package/client/pages/order/arrival-notice/edit-product-popup.js +36 -5
- package/client/pages/order/arrival-notice/receive-arrival-notice.js +8 -1
- package/client/pages/order/goods-received-note/received-note-list.js +138 -6
- package/client/pages/order/release-order/b2b/b2b-order-list.js +45 -5
- package/client/pages/order/release-order/b2b/b2b-order-requests.js +52 -12
- package/client/pages/order/release-order/b2c/b2c-order-requests.js +244 -24
- package/client/pages/order/release-order/bulk-print-packing-list.js +23 -0
- package/client/pages/order/release-order/create-release-order.js +55 -8
- package/client/pages/order/release-order/receive-release-order-request.js +35 -24
- package/client/pages/order/release-order/release-extra-product-popup.js +204 -63
- package/client/pages/order/release-order/release-order-detail.js +301 -74
- package/client/pages/order/return-order/check-return-order.js +9 -1
- package/client/pages/order/return-order/create-return-order.js +14 -2
- package/client/pages/order/return-order/receive-return-order-requests.js +9 -1
- package/client/pages/order/return-order/return-order-detail.js +15 -6
- package/client/pages/order/return-order/return-order-inventory-popup.js +7 -0
- package/client/pages/order/reverse-kitting-order/reverse-kitting-order-detail.js +115 -50
- package/client/pages/order/reverse-kitting-order/reverse-kitting-order-list.js +1 -6
- package/client/pages/order/reverse-kitting-order/reverse-kitting-pallet-label-popup.js +239 -0
- package/client/pages/order/transport-order/delivery-order-list.js +102 -59
- package/client/pages/outbound/inventory-assign-popup.js +23 -6
- package/client/pages/outbound/inventory-auto-assign-popup.js +22 -6
- package/client/pages/outbound/loading-product.js +4 -1
- package/client/pages/outbound/merged-outbound-worksheet.js +43 -1
- package/client/pages/outbound/packing-product.js +4 -1
- package/client/pages/outbound/packing-worksheet-list.js +39 -1
- package/client/pages/outbound/picking-product.js +803 -431
- package/client/pages/outbound/picking-replacement-popup.js +1 -1
- package/client/pages/outbound/serial-number-popup.js +280 -0
- package/client/pages/outbound/single-outbound-worksheet.js +47 -1
- package/client/pages/outbound/worksheet-batch-picking.js +22 -8
- package/client/pages/outbound/worksheet-loading.js +22 -5
- package/client/pages/outbound/worksheet-packing.js +8 -0
- package/client/pages/outbound/worksheet-picking.js +62 -8
- package/client/pages/outbound/worksheet-return.js +9 -1
- package/client/pages/outbound/worksheet-sorting.js +9 -1
- package/client/pages/report/custom-elccl/elccl-inventory-report.js +31 -30
- package/client/pages/report/custom-elccl/elccl-inventory-summary-report.js +23 -26
- package/client/pages/report/inventory-pallet-storage-report.js +11 -10
- package/client/pages/report/inventory-report.js +41 -43
- package/client/pages/report/inventory-summary-report.js +25 -28
- package/client/pages/report/product-label-report.js +401 -0
- package/client/pages/support/inventory-comparison.js +296 -0
- package/client/pages/vas/print-product-label.js +298 -132
- package/client/pages/vas/reverse-kitting/execute-reverse-kitting.js +32 -12
- package/client/pages/vas/reverse-kitting/popup-combination-sets.js +106 -10
- package/client/pages/vas/reverse-kitting/popup-reverse-kitting-template.js +130 -19
- package/client/pages/vas/vas-pallet-label-popup.js +5 -8
- package/client/route.js +28 -0
- package/config.development.js +73 -0
- package/config.production.js +113 -0
- package/dist-server/graphql/resolvers/custom/elccl/elccl-inventory-history-report.js +1 -1
- package/dist-server/graphql/resolvers/custom/elccl/elccl-inventory-history-report.js.map +1 -1
- package/dist-server/graphql/resolvers/custom/elccl/elccl-inventory-history-summary-report.js +64 -54
- package/dist-server/graphql/resolvers/custom/elccl/elccl-inventory-history-summary-report.js.map +1 -1
- package/dist-server/graphql/resolvers/extra/add-release-good-products.js +34 -9
- package/dist-server/graphql/resolvers/extra/add-release-good-products.js.map +1 -1
- package/dist-server/graphql/resolvers/index.js +5 -1
- package/dist-server/graphql/resolvers/index.js.map +1 -1
- package/dist-server/graphql/resolvers/inventory-comparison/index.js +6 -0
- package/dist-server/graphql/resolvers/inventory-comparison/index.js.map +1 -0
- package/dist-server/graphql/resolvers/inventory-comparison/inventory-comparison-list.js +78 -0
- package/dist-server/graphql/resolvers/inventory-comparison/inventory-comparison-list.js.map +1 -0
- package/dist-server/graphql/resolvers/reports/index.js +2 -1
- package/dist-server/graphql/resolvers/reports/index.js.map +1 -1
- package/dist-server/graphql/resolvers/reports/product-label-report.js +56 -0
- package/dist-server/graphql/resolvers/reports/product-label-report.js.map +1 -0
- package/dist-server/graphql/resolvers/shipping-provider/index.js +6 -0
- package/dist-server/graphql/resolvers/shipping-provider/index.js.map +1 -0
- package/dist-server/graphql/resolvers/shipping-provider/shipping-providers.js +20 -0
- package/dist-server/graphql/resolvers/shipping-provider/shipping-providers.js.map +1 -0
- package/dist-server/graphql/types/custom/elccl/elccl-inventory-report.js +1 -1
- package/dist-server/graphql/types/index.js +8 -2
- package/dist-server/graphql/types/index.js.map +1 -1
- package/dist-server/graphql/types/inventory-comparison/index.js +13 -0
- package/dist-server/graphql/types/inventory-comparison/index.js.map +1 -0
- package/dist-server/graphql/types/inventory-comparison/inventory-comparison-list.js +14 -0
- package/dist-server/graphql/types/inventory-comparison/inventory-comparison-list.js.map +1 -0
- package/dist-server/graphql/types/inventory-comparison/inventory-comparison.js +18 -0
- package/dist-server/graphql/types/inventory-comparison/inventory-comparison.js.map +1 -0
- package/dist-server/graphql/types/reports/index.js +6 -1
- package/dist-server/graphql/types/reports/index.js.map +1 -1
- package/dist-server/graphql/types/reports/product-label-report-list.js +14 -0
- package/dist-server/graphql/types/reports/product-label-report-list.js.map +1 -0
- package/dist-server/graphql/types/reports/product-label-report.js +16 -0
- package/dist-server/graphql/types/reports/product-label-report.js.map +1 -0
- package/dist-server/graphql/types/shipping-provider/index.js +10 -0
- package/dist-server/graphql/types/shipping-provider/index.js.map +1 -0
- package/dist-server/graphql/types/shipping-provider/shipping-provider-list.js +13 -0
- package/dist-server/graphql/types/shipping-provider/shipping-provider-list.js.map +1 -0
- package/dist-server/graphql/types/shipping-provider/shipping-provider.js +13 -0
- package/dist-server/graphql/types/shipping-provider/shipping-provider.js.map +1 -0
- package/package.json +66 -66
- package/server/graphql/resolvers/custom/elccl/elccl-inventory-history-report.ts +4 -2
- package/server/graphql/resolvers/custom/elccl/elccl-inventory-history-summary-report.ts +75 -65
- package/server/graphql/resolvers/extra/add-release-good-products.ts +57 -15
- package/server/graphql/resolvers/index.ts +5 -1
- package/server/graphql/resolvers/inventory-comparison/index.ts +5 -0
- package/server/graphql/resolvers/inventory-comparison/inventory-comparison-list.ts +99 -0
- package/server/graphql/resolvers/reports/index.ts +3 -1
- package/server/graphql/resolvers/reports/product-label-report.ts +56 -0
- package/server/graphql/resolvers/shipping-provider/index.ts +5 -0
- package/server/graphql/resolvers/shipping-provider/shipping-providers.ts +20 -0
- package/server/graphql/types/custom/elccl/elccl-inventory-report.ts +1 -1
- package/server/graphql/types/index.ts +8 -2
- package/server/graphql/types/inventory-comparison/index.ts +11 -0
- package/server/graphql/types/inventory-comparison/inventory-comparison-list.ts +8 -0
- package/server/graphql/types/inventory-comparison/inventory-comparison.ts +12 -0
- package/server/graphql/types/reports/index.ts +6 -1
- package/server/graphql/types/reports/product-label-report-list.ts +8 -0
- package/server/graphql/types/reports/product-label-report.ts +10 -0
- package/server/graphql/types/shipping-provider/index.ts +8 -0
- package/server/graphql/types/shipping-provider/shipping-provider-list.ts +7 -0
- package/server/graphql/types/shipping-provider/shipping-provider.ts +7 -0
- package/things-factory.config.js +30 -0
- package/translations/en.json +91 -11
- package/translations/ko.json +109 -11
- package/translations/ms.json +111 -12
- package/translations/zh.json +123 -26
|
@@ -7,10 +7,9 @@ import { css, html } from 'lit-element'
|
|
|
7
7
|
|
|
8
8
|
import { getCodeByName } from '@things-factory/code-base'
|
|
9
9
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
10
|
-
import { openPopup } from '@things-factory/layout-base'
|
|
11
10
|
import { client, navigate, PageView } from '@things-factory/shell'
|
|
12
11
|
import { ScrollbarStyles } from '@things-factory/styles'
|
|
13
|
-
import {
|
|
12
|
+
import { isMobileDevice } from '@things-factory/utils'
|
|
14
13
|
|
|
15
14
|
class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
16
15
|
static get styles() {
|
|
@@ -126,6 +125,24 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
126
125
|
],
|
|
127
126
|
props: { searchOper: 'eq' }
|
|
128
127
|
},
|
|
128
|
+
{
|
|
129
|
+
label: i18next.t('field.ref_no'),
|
|
130
|
+
name: 'refNo',
|
|
131
|
+
type: 'text',
|
|
132
|
+
props: { searchOper: 'i_like' }
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
label: i18next.t('field.ref_no_2'),
|
|
136
|
+
name: 'refNo2',
|
|
137
|
+
type: 'text',
|
|
138
|
+
props: { searchOper: 'i_like' }
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
label: i18next.t('field.ref_no_3'),
|
|
142
|
+
name: 'refNo3',
|
|
143
|
+
type: 'text',
|
|
144
|
+
props: { searchOper: 'i_like' }
|
|
145
|
+
},
|
|
129
146
|
{
|
|
130
147
|
name: 'status',
|
|
131
148
|
label: i18next.t('label.status'),
|
|
@@ -193,6 +210,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
193
210
|
type: 'string',
|
|
194
211
|
name: 'name',
|
|
195
212
|
header: i18next.t('field.do_no'),
|
|
213
|
+
imex: { header: i18next.t('field.do_no'), key: 'name', width: 30, type: 'string' },
|
|
196
214
|
sortable: true,
|
|
197
215
|
width: 150
|
|
198
216
|
},
|
|
@@ -200,6 +218,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
200
218
|
type: 'object',
|
|
201
219
|
name: 'releaseGood',
|
|
202
220
|
header: i18next.t('field.ro_no'),
|
|
221
|
+
imex: { header: i18next.t('field.ro_no'), key: 'releaseGood.name', width: 30, type: 'string' },
|
|
203
222
|
sortable: true,
|
|
204
223
|
width: 150
|
|
205
224
|
},
|
|
@@ -207,6 +226,23 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
207
226
|
type: 'string',
|
|
208
227
|
name: 'refNo',
|
|
209
228
|
header: i18next.t('field.ref_no'),
|
|
229
|
+
imex: { header: i18next.t('field.refNo'), key: 'refNo', width: 25, type: 'string' },
|
|
230
|
+
sortable: true,
|
|
231
|
+
width: 150
|
|
232
|
+
},
|
|
233
|
+
{
|
|
234
|
+
type: 'string',
|
|
235
|
+
name: 'refNo2',
|
|
236
|
+
header: i18next.t('field.ref_no_2'),
|
|
237
|
+
imex: { header: i18next.t('field.ref_no_2'), key: 'refNo2', width: 25, type: 'string' },
|
|
238
|
+
sortable: true,
|
|
239
|
+
width: 150
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
type: 'string',
|
|
243
|
+
name: 'refNo3',
|
|
244
|
+
header: i18next.t('field.ref_no_3'),
|
|
245
|
+
imex: { header: i18next.t('field.ref_no_3'), key: 'refNo3', width: 25, type: 'string' },
|
|
210
246
|
sortable: true,
|
|
211
247
|
width: 150
|
|
212
248
|
},
|
|
@@ -214,6 +250,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
214
250
|
type: 'object',
|
|
215
251
|
name: 'bizplace',
|
|
216
252
|
header: i18next.t('field.company'),
|
|
253
|
+
imex: { header: i18next.t('field.company'), key: 'bizplace.name', width: 30, type: 'string' },
|
|
217
254
|
sortable: true,
|
|
218
255
|
width: 200
|
|
219
256
|
},
|
|
@@ -221,6 +258,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
221
258
|
type: 'date',
|
|
222
259
|
name: 'deliveryDate',
|
|
223
260
|
header: i18next.t('field.delivery_date'),
|
|
261
|
+
imex: { header: i18next.t('field.delivery_date'), key: 'deliveryDate', width: 20, type: 'string' },
|
|
224
262
|
sortable: true,
|
|
225
263
|
width: 160
|
|
226
264
|
},
|
|
@@ -228,6 +266,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
228
266
|
type: 'boolean',
|
|
229
267
|
name: 'ownCollection',
|
|
230
268
|
header: i18next.t('field.own_collection'),
|
|
269
|
+
imex: { header: i18next.t('field.own_collection'), key: 'ownCollection', width: 20, type: 'string' },
|
|
231
270
|
sortable: true,
|
|
232
271
|
width: 100
|
|
233
272
|
},
|
|
@@ -235,6 +274,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
235
274
|
type: 'string',
|
|
236
275
|
name: 'status',
|
|
237
276
|
header: i18next.t('field.status'),
|
|
277
|
+
imex: { header: i18next.t('field.status'), key: 'status', width: 20, type: 'string' },
|
|
238
278
|
sortable: true,
|
|
239
279
|
width: 150
|
|
240
280
|
},
|
|
@@ -242,6 +282,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
242
282
|
type: 'datetime',
|
|
243
283
|
name: 'createdAt',
|
|
244
284
|
header: i18next.t('field.created_at'),
|
|
285
|
+
imex: { header: i18next.t('field.created_at'), key: 'createdAt', width: 30, type: 'datetime' },
|
|
245
286
|
sortable: true,
|
|
246
287
|
width: 160
|
|
247
288
|
},
|
|
@@ -249,6 +290,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
249
290
|
type: 'datetime',
|
|
250
291
|
name: 'updatedAt',
|
|
251
292
|
header: i18next.t('field.updated_at'),
|
|
293
|
+
imex: { header: i18next.t('field.updated_at'), key: 'updatedAt', width: 30, type: 'datetime' },
|
|
252
294
|
sortable: true,
|
|
253
295
|
width: 160
|
|
254
296
|
},
|
|
@@ -256,6 +298,7 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
256
298
|
type: 'object',
|
|
257
299
|
name: 'updater',
|
|
258
300
|
header: i18next.t('field.updater'),
|
|
301
|
+
imex: { header: i18next.t('field.updater'), key: 'updater.name', width: 30, type: 'string' },
|
|
259
302
|
sortable: true,
|
|
260
303
|
width: 160
|
|
261
304
|
}
|
|
@@ -263,31 +306,14 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
263
306
|
}
|
|
264
307
|
}
|
|
265
308
|
|
|
266
|
-
async fetchHandler({ page, limit, sorters = [
|
|
309
|
+
async fetchHandler({ page, limit, sorters = [] }) {
|
|
267
310
|
let filters = this.searchForm.queryFilters
|
|
268
|
-
// let toDateIndex = filters.findIndex(x => x.name == 'toDate')
|
|
269
|
-
|
|
270
|
-
// if (toDateIndex >= 0) {
|
|
271
|
-
// let toDateFilter = new Date(filters[toDateIndex].value)
|
|
272
|
-
// filters[toDateIndex].value = new Date(toDateFilter.setDate(toDateFilter.getDate() + 1)).toISOString()
|
|
273
|
-
// }
|
|
274
|
-
// var datetime = new Date()
|
|
275
|
-
// var tzoffset = datetime.getTimezoneOffset() * 60
|
|
276
|
-
|
|
277
311
|
var tzoffset = new Date().getTimezoneOffset() * 60
|
|
278
312
|
|
|
279
313
|
const response = await client.query({
|
|
280
314
|
query: gql`
|
|
281
|
-
query {
|
|
282
|
-
deliveryOrders(${
|
|
283
|
-
filters: [
|
|
284
|
-
...filters,
|
|
285
|
-
{ name: 'status', operator: 'notin', value: ['CANCELLED'] },
|
|
286
|
-
{ name: 'tzoffset', operator: 'custom', value: tzoffset }
|
|
287
|
-
],
|
|
288
|
-
pagination: { page, limit },
|
|
289
|
-
sortings: sorters
|
|
290
|
-
})}) {
|
|
315
|
+
query deliveryOrders($filters: [Filter], $pagination: Pagination, $sortings: [Sorting]) {
|
|
316
|
+
deliveryOrders(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
291
317
|
items {
|
|
292
318
|
id
|
|
293
319
|
name
|
|
@@ -304,6 +330,8 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
304
330
|
name
|
|
305
331
|
description
|
|
306
332
|
refNo
|
|
333
|
+
refNo2
|
|
334
|
+
refNo3
|
|
307
335
|
}
|
|
308
336
|
ownCollection
|
|
309
337
|
createdAt
|
|
@@ -317,13 +345,30 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
317
345
|
total
|
|
318
346
|
}
|
|
319
347
|
}
|
|
320
|
-
|
|
348
|
+
`,
|
|
349
|
+
variables: {
|
|
350
|
+
filters: [
|
|
351
|
+
...filters,
|
|
352
|
+
{ name: 'status', operator: 'notin', value: ['CANCELLED'] },
|
|
353
|
+
{ name: 'tzoffset', operator: 'custom', value: tzoffset }
|
|
354
|
+
],
|
|
355
|
+
pagination: { page, limit },
|
|
356
|
+
sortings: sorters
|
|
357
|
+
}
|
|
321
358
|
})
|
|
322
359
|
|
|
323
360
|
if (!response.errors) {
|
|
324
361
|
return {
|
|
325
362
|
total: response.data.deliveryOrders.total || 0,
|
|
326
|
-
records:
|
|
363
|
+
records:
|
|
364
|
+
response.data.deliveryOrders.items.map(dord => {
|
|
365
|
+
return {
|
|
366
|
+
...dord,
|
|
367
|
+
refNo: dord?.releaseGood?.refNo || '',
|
|
368
|
+
refNo2: dord?.releaseGood?.refNo2 || '',
|
|
369
|
+
refNo3: dord?.releaseGood?.refNo3 || ''
|
|
370
|
+
}
|
|
371
|
+
}) || []
|
|
327
372
|
}
|
|
328
373
|
}
|
|
329
374
|
}
|
|
@@ -348,23 +393,6 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
348
393
|
if (!response.errors) {
|
|
349
394
|
return response.data.partnersBizplaces.items
|
|
350
395
|
}
|
|
351
|
-
|
|
352
|
-
// const response = await client.query({
|
|
353
|
-
// query: gql`
|
|
354
|
-
// query {
|
|
355
|
-
// bizplaces(${gqlBuilder.buildArgs({
|
|
356
|
-
// filters: [...bizplace]
|
|
357
|
-
// })}) {
|
|
358
|
-
// items{
|
|
359
|
-
// id
|
|
360
|
-
// name
|
|
361
|
-
// description
|
|
362
|
-
// }
|
|
363
|
-
// }
|
|
364
|
-
// }
|
|
365
|
-
// `
|
|
366
|
-
// })
|
|
367
|
-
// return response.data.bizplaces.items
|
|
368
396
|
}
|
|
369
397
|
|
|
370
398
|
_compareValues(key, order = 'asc') {
|
|
@@ -386,25 +414,40 @@ class DeliveryOrderList extends localize(i18next)(PageView) {
|
|
|
386
414
|
}
|
|
387
415
|
}
|
|
388
416
|
|
|
389
|
-
_uploadDeliveryNote(dnName, dnId) {
|
|
390
|
-
openPopup(
|
|
391
|
-
html`
|
|
392
|
-
<upload-delivery-note
|
|
393
|
-
.dnName="${dnName}"
|
|
394
|
-
.dnId="${dnId}"
|
|
395
|
-
.callback="${this.dataGrist.fetch.bind(this.dataGrist)}"
|
|
396
|
-
></upload-delivery-note>
|
|
397
|
-
`,
|
|
398
|
-
{
|
|
399
|
-
backdrop: true,
|
|
400
|
-
size: 'large',
|
|
401
|
-
title: i18next.t('title.upload_signed_gdn')
|
|
402
|
-
}
|
|
403
|
-
)
|
|
404
|
-
}
|
|
405
|
-
|
|
406
417
|
_exportableData() {
|
|
407
|
-
|
|
418
|
+
let records = []
|
|
419
|
+
if (this.dataGrist.selected && this.dataGrist.selected.length > 0) {
|
|
420
|
+
records = this.dataGrist.selected
|
|
421
|
+
} else {
|
|
422
|
+
records = this.dataGrist.data.records
|
|
423
|
+
}
|
|
424
|
+
|
|
425
|
+
var headerSetting = this.dataGrist._config.columns
|
|
426
|
+
.filter(column => column.type !== 'gutter' && column.record !== undefined && column.imex !== undefined)
|
|
427
|
+
.map(column => {
|
|
428
|
+
return column.imex
|
|
429
|
+
})
|
|
430
|
+
|
|
431
|
+
var data = records.map(item => {
|
|
432
|
+
return {
|
|
433
|
+
id: item.id,
|
|
434
|
+
...this._columns
|
|
435
|
+
.filter(column => column.type !== 'gutter' && column.imex !== undefined)
|
|
436
|
+
.reduce((record, column) => {
|
|
437
|
+
record[column.imex.key] = column.imex.key
|
|
438
|
+
.split('.')
|
|
439
|
+
.reduce((obj, key) => (obj && obj[key] !== 'undefined' ? obj[key] : undefined), item)
|
|
440
|
+
if (column.type === 'datetime') {
|
|
441
|
+
record[column.imex.key] = new Date(parseInt(record[column.imex.key])).toLocaleString()
|
|
442
|
+
}
|
|
443
|
+
if (record[column.imex.key] === 'Invalid Date') {
|
|
444
|
+
record[column.imex.key] = ''
|
|
445
|
+
}
|
|
446
|
+
return record
|
|
447
|
+
}, {})
|
|
448
|
+
}
|
|
449
|
+
})
|
|
450
|
+
return { header: headerSetting, data: data }
|
|
408
451
|
}
|
|
409
452
|
|
|
410
453
|
_modifyDateRange(e) {
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import '@things-factory/barcode-ui'
|
|
2
|
-
import { MultiColumnFormStyles } from '@things-factory/form-ui'
|
|
3
2
|
import '@things-factory/grist-ui'
|
|
3
|
+
|
|
4
|
+
import gql from 'graphql-tag'
|
|
5
|
+
import { css, html, LitElement } from 'lit-element'
|
|
6
|
+
|
|
7
|
+
import { MultiColumnFormStyles } from '@things-factory/form-ui'
|
|
4
8
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
5
9
|
import { client } from '@things-factory/shell'
|
|
6
10
|
import { isMobileDevice } from '@things-factory/utils'
|
|
7
|
-
|
|
8
|
-
import { css, html, LitElement } from 'lit-element'
|
|
11
|
+
|
|
9
12
|
import { fetchLocationSortingRule } from '../../fetch-location-sorting-rule'
|
|
10
13
|
import { LOCATION_SORTING_RULE, ORDER_TYPES, PICKING_STRATEGY, WORKSHEET_TYPE } from '../constants'
|
|
11
14
|
|
|
@@ -18,8 +21,10 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
18
21
|
productId: String,
|
|
19
22
|
productName: String,
|
|
20
23
|
productSku: String,
|
|
24
|
+
productBrand: String,
|
|
21
25
|
bizplaceId: String,
|
|
22
26
|
packingType: String,
|
|
27
|
+
uom: String,
|
|
23
28
|
packingSize: Number,
|
|
24
29
|
worksheetType: String,
|
|
25
30
|
releaseQty: Number,
|
|
@@ -143,6 +148,7 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
143
148
|
'picked',
|
|
144
149
|
'palletId',
|
|
145
150
|
'productSku',
|
|
151
|
+
'productBrand',
|
|
146
152
|
'product',
|
|
147
153
|
'location',
|
|
148
154
|
'pickedQty',
|
|
@@ -187,6 +193,12 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
187
193
|
header: i18next.t('field.product'),
|
|
188
194
|
width: 250
|
|
189
195
|
},
|
|
196
|
+
{
|
|
197
|
+
type: 'string',
|
|
198
|
+
name: 'productBrand',
|
|
199
|
+
header: i18next.t('field.brand'),
|
|
200
|
+
width: 130
|
|
201
|
+
},
|
|
190
202
|
{
|
|
191
203
|
type: 'object',
|
|
192
204
|
name: 'location',
|
|
@@ -249,8 +261,10 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
249
261
|
$productName: String!
|
|
250
262
|
$productSku: String!
|
|
251
263
|
$packingType: String!
|
|
264
|
+
$packingSize: Float!
|
|
265
|
+
$uom: String!
|
|
252
266
|
$pickingStrategy: String!
|
|
253
|
-
$locationSortingRules: [Sorting!]
|
|
267
|
+
$locationSortingRules: [Sorting!]!
|
|
254
268
|
) {
|
|
255
269
|
inventoriesByStrategy(
|
|
256
270
|
worksheetId: $worksheetId
|
|
@@ -259,7 +273,8 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
259
273
|
productName: $productName
|
|
260
274
|
productSku: $productSku
|
|
261
275
|
packingType: $packingType
|
|
262
|
-
|
|
276
|
+
packingSize: $packingSize
|
|
277
|
+
uom: $uom
|
|
263
278
|
pickingStrategy: $pickingStrategy
|
|
264
279
|
locationSortingRules: $locationSortingRules
|
|
265
280
|
) {
|
|
@@ -272,6 +287,7 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
272
287
|
name
|
|
273
288
|
description
|
|
274
289
|
sku
|
|
290
|
+
brand
|
|
275
291
|
}
|
|
276
292
|
location {
|
|
277
293
|
name
|
|
@@ -295,6 +311,7 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
295
311
|
productSku: this.productSku,
|
|
296
312
|
packingType: this.packingType,
|
|
297
313
|
packingSize: this.packingSize,
|
|
314
|
+
uom: this.uom,
|
|
298
315
|
pickingStrategy: this.selectedStrategy,
|
|
299
316
|
locationSortingRules: this.locationSortingRules
|
|
300
317
|
}
|
|
@@ -307,6 +324,7 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
307
324
|
...item,
|
|
308
325
|
...item.location,
|
|
309
326
|
productSku: item.product.sku,
|
|
327
|
+
productBrand: item.product.brand,
|
|
310
328
|
availableUomValue: item.uomValue + ' ' + item.uom
|
|
311
329
|
}
|
|
312
330
|
}),
|
|
@@ -439,7 +457,6 @@ class InventoryAssignPopup extends localize(i18next)(LitElement) {
|
|
|
439
457
|
batchId: $batchId
|
|
440
458
|
productId: $productId
|
|
441
459
|
packingType: $packingType
|
|
442
|
-
|
|
443
460
|
worksheetDetails: $worksheetDetails
|
|
444
461
|
)
|
|
445
462
|
}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import '@things-factory/barcode-ui'
|
|
2
|
-
import { MultiColumnFormStyles } from '@things-factory/form-ui'
|
|
3
2
|
import '@things-factory/grist-ui'
|
|
3
|
+
|
|
4
|
+
import gql from 'graphql-tag'
|
|
5
|
+
import { css, html, LitElement } from 'lit-element'
|
|
6
|
+
|
|
7
|
+
import { MultiColumnFormStyles } from '@things-factory/form-ui'
|
|
4
8
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
5
9
|
import { client, CustomAlert } from '@things-factory/shell'
|
|
6
10
|
import { isMobileDevice } from '@things-factory/utils'
|
|
7
|
-
|
|
8
|
-
import { css, html, LitElement } from 'lit-element'
|
|
11
|
+
|
|
9
12
|
import { ORDER_TYPES, PICKING_STRATEGY, WORKSHEET_TYPE } from '../constants'
|
|
10
13
|
|
|
11
14
|
class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
@@ -135,6 +138,12 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
135
138
|
header: i18next.t('field.product'),
|
|
136
139
|
width: 150
|
|
137
140
|
},
|
|
141
|
+
{
|
|
142
|
+
type: 'string',
|
|
143
|
+
name: 'productBrand',
|
|
144
|
+
header: i18next.t('field.brand'),
|
|
145
|
+
width: 100
|
|
146
|
+
},
|
|
138
147
|
{
|
|
139
148
|
type: 'string',
|
|
140
149
|
name: 'packingType',
|
|
@@ -228,9 +237,10 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
228
237
|
}
|
|
229
238
|
}
|
|
230
239
|
|
|
231
|
-
async fetchInventoriesByStrategy({ batchId, product, packingType, packingSize }, pickingStrategy, bizplaceId) {
|
|
240
|
+
async fetchInventoriesByStrategy({ batchId, product, packingType, packingSize, uom }, pickingStrategy, bizplaceId) {
|
|
232
241
|
const productName = product.name
|
|
233
242
|
const productSku = product.sku
|
|
243
|
+
const productBrand = product.brand
|
|
234
244
|
const response = await client.query({
|
|
235
245
|
query: gql`
|
|
236
246
|
query inventoriesByStrategy(
|
|
@@ -240,7 +250,8 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
240
250
|
$productName: String!
|
|
241
251
|
$productSku: String!
|
|
242
252
|
$packingType: String!
|
|
243
|
-
|
|
253
|
+
$packingSize: Float!
|
|
254
|
+
$uom: String!
|
|
244
255
|
$pickingStrategy: String!
|
|
245
256
|
) {
|
|
246
257
|
inventoriesByStrategy(
|
|
@@ -250,7 +261,8 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
250
261
|
productName: $productName
|
|
251
262
|
productSku: $productSku
|
|
252
263
|
packingType: $packingType
|
|
253
|
-
|
|
264
|
+
packingSize: $packingSize
|
|
265
|
+
uom: $uom
|
|
254
266
|
pickingStrategy: $pickingStrategy
|
|
255
267
|
) {
|
|
256
268
|
items {
|
|
@@ -263,6 +275,7 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
263
275
|
name
|
|
264
276
|
description
|
|
265
277
|
sku
|
|
278
|
+
brand
|
|
266
279
|
}
|
|
267
280
|
}
|
|
268
281
|
}
|
|
@@ -276,6 +289,7 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
276
289
|
productSku,
|
|
277
290
|
packingType,
|
|
278
291
|
packingSize,
|
|
292
|
+
uom,
|
|
279
293
|
pickingStrategy
|
|
280
294
|
}
|
|
281
295
|
})
|
|
@@ -286,6 +300,7 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
286
300
|
...item,
|
|
287
301
|
...item.location,
|
|
288
302
|
productSku: item.product.sku,
|
|
303
|
+
productBrand: item.product.brand,
|
|
289
304
|
releaseUomValue: item.uomValue + ' ' + item.uom
|
|
290
305
|
}
|
|
291
306
|
})
|
|
@@ -376,6 +391,7 @@ class InventoryAutoAssignPopup extends localize(i18next)(LitElement) {
|
|
|
376
391
|
productId: itm.product.id,
|
|
377
392
|
packingType: itm.packingType,
|
|
378
393
|
packingSize: itm.packingSize,
|
|
394
|
+
uom: itm.uom,
|
|
379
395
|
releaseQty: itm.releaseQty,
|
|
380
396
|
releaseUomValue: itm.releaseUomValue,
|
|
381
397
|
extraJsonData: JSON.stringify(itm.extraJsonData)
|
|
@@ -510,6 +510,9 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
510
510
|
query loadingWorksheet($releaseGoodNo: String!) {
|
|
511
511
|
loadingWorksheet(releaseGoodNo: $releaseGoodNo) {
|
|
512
512
|
worksheetInfo {
|
|
513
|
+
releaseGood {
|
|
514
|
+
name
|
|
515
|
+
}
|
|
513
516
|
bizplaceName
|
|
514
517
|
refNo
|
|
515
518
|
startedAt
|
|
@@ -542,7 +545,7 @@ class LoadingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
542
545
|
})
|
|
543
546
|
|
|
544
547
|
if (!response.errors) {
|
|
545
|
-
this._releaseGoodNo =
|
|
548
|
+
this._releaseGoodNo = response.data.loadingWorksheet.worksheetInfo.releaseGood.name
|
|
546
549
|
this._fillUpForm(this.infoForm, response.data.loadingWorksheet.worksheetInfo)
|
|
547
550
|
this._ownCollection = response.data.loadingWorksheet.worksheetInfo.ownCollection
|
|
548
551
|
this.pickedProductData = {
|
|
@@ -189,6 +189,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
189
189
|
type: 'string',
|
|
190
190
|
name: 'name',
|
|
191
191
|
header: i18next.t('field.worksheet_no'),
|
|
192
|
+
imex: { header: i18next.t('field.worksheet_no'), key: 'name', width: 30, type: 'string' },
|
|
192
193
|
sortable: true,
|
|
193
194
|
width: 150
|
|
194
195
|
},
|
|
@@ -196,6 +197,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
196
197
|
type: 'string',
|
|
197
198
|
name: 'taskNo',
|
|
198
199
|
header: i18next.t('field.task_no'),
|
|
200
|
+
imex: { header: i18next.t('field.task_no'), key: 'taskNo', width: 30, type: 'string' },
|
|
199
201
|
sortable: true,
|
|
200
202
|
width: 150
|
|
201
203
|
},
|
|
@@ -203,6 +205,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
203
205
|
type: 'object',
|
|
204
206
|
name: 'bizplace',
|
|
205
207
|
header: i18next.t('field.company'),
|
|
208
|
+
imex: { header: i18next.t('field.company'), key: 'bizplace.name', width: 30, type: 'string' },
|
|
206
209
|
sortable: true,
|
|
207
210
|
width: 240
|
|
208
211
|
},
|
|
@@ -210,6 +213,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
210
213
|
type: 'string',
|
|
211
214
|
name: 'type',
|
|
212
215
|
header: i18next.t('field.type'),
|
|
216
|
+
imex: { header: i18next.t('field.type'), key: 'type', width: 30, type: 'string' },
|
|
213
217
|
sortable: true,
|
|
214
218
|
width: 150
|
|
215
219
|
},
|
|
@@ -217,6 +221,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
217
221
|
type: 'string',
|
|
218
222
|
name: 'status',
|
|
219
223
|
header: i18next.t('field.status'),
|
|
224
|
+
imex: { header: i18next.t('field.status'), key: 'status', width: 30, type: 'string' },
|
|
220
225
|
sortable: true,
|
|
221
226
|
width: 100
|
|
222
227
|
},
|
|
@@ -224,6 +229,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
224
229
|
type: 'datetime',
|
|
225
230
|
name: 'createdAt',
|
|
226
231
|
header: i18next.t('field.created_at'),
|
|
232
|
+
imex: { header: i18next.t('field.created_at'), key: 'createdAt', width: 30, type: 'string' },
|
|
227
233
|
sortable: true,
|
|
228
234
|
width: 160
|
|
229
235
|
},
|
|
@@ -231,6 +237,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
231
237
|
type: 'datetime',
|
|
232
238
|
name: 'startedAt',
|
|
233
239
|
header: i18next.t('field.started_at'),
|
|
240
|
+
imex: { header: i18next.t('field.started_at'), key: 'startedAt', width: 30, type: 'string' },
|
|
234
241
|
sortable: true,
|
|
235
242
|
width: 160
|
|
236
243
|
},
|
|
@@ -238,6 +245,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
238
245
|
type: 'datetime',
|
|
239
246
|
name: 'endedAt',
|
|
240
247
|
header: i18next.t('field.ended_at'),
|
|
248
|
+
imex: { header: i18next.t('field.ended_at'), key: 'endedAt', width: 30, type: 'string' },
|
|
241
249
|
sortable: true,
|
|
242
250
|
width: 160
|
|
243
251
|
},
|
|
@@ -245,6 +253,7 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
245
253
|
type: 'object',
|
|
246
254
|
name: 'updater',
|
|
247
255
|
header: i18next.t('field.updater'),
|
|
256
|
+
imex: { header: i18next.t('field.updater'), key: 'updater.name', width: 30, type: 'string' },
|
|
248
257
|
sortable: true,
|
|
249
258
|
width: 150
|
|
250
259
|
}
|
|
@@ -396,7 +405,40 @@ class MergedOutboundWorksheet extends localize(i18next)(PageView) {
|
|
|
396
405
|
}
|
|
397
406
|
|
|
398
407
|
_exportableData() {
|
|
399
|
-
|
|
408
|
+
let records = []
|
|
409
|
+
if (this.dataGrist.selected && this.dataGrist.selected.length > 0) {
|
|
410
|
+
records = this.dataGrist.selected
|
|
411
|
+
} else {
|
|
412
|
+
records = this.dataGrist.data.records
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
var headerSetting = this.dataGrist._config.columns
|
|
416
|
+
.filter(column => column.type !== 'gutter' && column.imex !== undefined)
|
|
417
|
+
.map(column => {
|
|
418
|
+
return column.imex
|
|
419
|
+
})
|
|
420
|
+
|
|
421
|
+
var data = records.map(item => {
|
|
422
|
+
return {
|
|
423
|
+
id: item.id,
|
|
424
|
+
...this._columns
|
|
425
|
+
.filter(column => column.type !== 'gutter' && column.imex !== undefined)
|
|
426
|
+
.reduce((record, column) => {
|
|
427
|
+
record[column.imex.key] = column.imex.key
|
|
428
|
+
.split('.')
|
|
429
|
+
.reduce((obj, key) => (obj && obj[key] !== 'undefined' ? obj[key] : undefined), item)
|
|
430
|
+
if (column.type === 'datetime') {
|
|
431
|
+
record[column.imex.key] = new Date(parseInt(record[column.imex.key])).toLocaleString()
|
|
432
|
+
}
|
|
433
|
+
if (record[column.imex.key] === 'Invalid Date') {
|
|
434
|
+
record[column.imex.key] = ''
|
|
435
|
+
}
|
|
436
|
+
return record
|
|
437
|
+
}, {})
|
|
438
|
+
}
|
|
439
|
+
})
|
|
440
|
+
|
|
441
|
+
return { header: headerSetting, data: data }
|
|
400
442
|
}
|
|
401
443
|
}
|
|
402
444
|
|
|
@@ -439,6 +439,9 @@ class PackingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
439
439
|
query packingWorksheet($releaseGoodNo: String!) {
|
|
440
440
|
packingWorksheet(releaseGoodNo: $releaseGoodNo) {
|
|
441
441
|
worksheetInfo {
|
|
442
|
+
releaseGood {
|
|
443
|
+
name
|
|
444
|
+
}
|
|
442
445
|
bizplaceName
|
|
443
446
|
partnerDomainId
|
|
444
447
|
refNo
|
|
@@ -498,7 +501,7 @@ class PackingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
498
501
|
})
|
|
499
502
|
|
|
500
503
|
if (!response.errors) {
|
|
501
|
-
this.releaseGoodNo =
|
|
504
|
+
this.releaseGoodNo = response.data.packingWorksheet.worksheetInfo.releaseGood.name
|
|
502
505
|
if (!response.data?.packingWorksheet) return
|
|
503
506
|
|
|
504
507
|
const { worksheetInfo, worksheetDetailInfos } = response.data.packingWorksheet
|