@things-factory/operato-wms 4.0.27 → 4.0.28
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/master/location-list.js +1 -0
- package/client/pages/master/print-location-label.js +131 -146
- package/client/pages/order/goods-received-note/received-note-detail.js +7 -6
- package/client/pages/order/release-order/batch-generate-single-picking-worksheet-popup.js +1 -1
- package/client/pages/order/release-order/release-order-detail.js +2 -2
- package/client/pages/outbound/packing-product.js +6 -0
- package/client/pages/outbound/worksheet-loading.js +16 -14
- package/client/pages/outbound/worksheet-packing.js +15 -13
- package/client/pages/report/custom-elccl/elccl-daily-collection-report.js +8 -9
- package/client/pages/report/custom-elccl/elccl-daily-order-inventory-report.js +26 -25
- package/client/pages/report/custom-elccl/elccl-delivery-order-summary.js +10 -9
- package/client/pages/report/custom-elccl/elccl-inventory-pallet-detail-report.js +13 -8
- package/client/pages/report/custom-elccl/elccl-inventory-report.js +11 -10
- package/client/pages/report/inventory-pallet-report.js +13 -12
- package/client/pages/report/job-sheet-popup.js +9 -9
- package/client/pages/report/job-sheet-report.js +6 -6
- package/client/pages/system/location-sorting-rule.js +53 -46
- package/client/pages/vas/abstract-execute-vas.js +47 -34
- package/client/pages/vas/execute-pure-vas.js +66 -62
- package/client/pages/vas/execute-ref-vas.js +39 -41
- package/client/pages/vas/related-vas-list.js +7 -6
- package/client/pages/vas/target-inventory-assignment-popup.js +16 -14
- package/client/pages/vas/vas-pallet-label-popup.js +1 -1
- package/client/pages/vas/vas-worksheet-list.js +9 -8
- package/client/pages/vas/worksheet-ref-vas.js +7 -6
- package/client/pages/vas/worksheet-vas.js +16 -14
- package/package.json +65 -65
|
@@ -673,6 +673,7 @@ class LocationList extends connect(store)(localize(i18next)(PageView)) {
|
|
|
673
673
|
|
|
674
674
|
/* for location record mapping */
|
|
675
675
|
searchParams.append('location', record.name)
|
|
676
|
+
searchParams.append('originalName', record.originalName)
|
|
676
677
|
searchParams.append('label', record.indicator)
|
|
677
678
|
|
|
678
679
|
try {
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import '@things-factory/form-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 { ScrollbarStyles } from '@things-factory/styles'
|
|
7
11
|
import { isMobileDevice } from '@things-factory/utils'
|
|
8
|
-
import gql from 'graphql-tag'
|
|
9
|
-
import { css, html, LitElement } from 'lit-element'
|
|
10
12
|
|
|
11
13
|
export class PrintLocationLabel extends localize(i18next)(LitElement) {
|
|
12
14
|
static get properties() {
|
|
@@ -94,9 +96,7 @@ export class PrintLocationLabel extends localize(i18next)(LitElement) {
|
|
|
94
96
|
name="labelFormat"
|
|
95
97
|
@change="${e => {
|
|
96
98
|
this._fullLocationFormat = e.currentTarget.value === 'full_format' ? true : false
|
|
97
|
-
if (this._labelIndicator.value != '')
|
|
98
|
-
this._getPrintPreview(this._labelIndicator.value)
|
|
99
|
-
}
|
|
99
|
+
if (this._labelIndicator.value != '') this.dataGrist.fetch()
|
|
100
100
|
}}"
|
|
101
101
|
>
|
|
102
102
|
<option value="full_format">A-01-01-01 (${i18next.t('text.full_format')})</option>
|
|
@@ -108,7 +108,7 @@ export class PrintLocationLabel extends localize(i18next)(LitElement) {
|
|
|
108
108
|
name="labelIndicator"
|
|
109
109
|
@change="${e => {
|
|
110
110
|
let indicator = e.currentTarget.value
|
|
111
|
-
if (indicator !== '') this.
|
|
111
|
+
if (indicator !== '') this.dataGrist.fetch()
|
|
112
112
|
}}"
|
|
113
113
|
>
|
|
114
114
|
<option value="">-- ${i18next.t('text.please_select_label_indicator')} --</option>
|
|
@@ -150,6 +150,12 @@ export class PrintLocationLabel extends localize(i18next)(LitElement) {
|
|
|
150
150
|
header: i18next.t('field.name'),
|
|
151
151
|
width: 250
|
|
152
152
|
},
|
|
153
|
+
{
|
|
154
|
+
type: 'string',
|
|
155
|
+
name: 'originalName',
|
|
156
|
+
header: i18next.t('field.original_name'),
|
|
157
|
+
width: 250
|
|
158
|
+
},
|
|
153
159
|
{
|
|
154
160
|
type: 'string',
|
|
155
161
|
name: 'indicator',
|
|
@@ -158,11 +164,6 @@ export class PrintLocationLabel extends localize(i18next)(LitElement) {
|
|
|
158
164
|
}
|
|
159
165
|
]
|
|
160
166
|
}
|
|
161
|
-
|
|
162
|
-
if (this.selectedLocations && this.selectedLocations.length > 0) {
|
|
163
|
-
this._records = []
|
|
164
|
-
this._total = 0
|
|
165
|
-
}
|
|
166
167
|
}
|
|
167
168
|
|
|
168
169
|
get _labelIndicator() {
|
|
@@ -173,173 +174,157 @@ export class PrintLocationLabel extends localize(i18next)(LitElement) {
|
|
|
173
174
|
return this.shadowRoot.querySelector('data-grist')
|
|
174
175
|
}
|
|
175
176
|
|
|
176
|
-
async fetchHandler() {
|
|
177
|
-
return
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
}
|
|
181
|
-
}
|
|
177
|
+
async fetchHandler({ page, limit, sorters = [{ name: 'name' }] }) {
|
|
178
|
+
if (this._labelIndicator.value == '') return
|
|
179
|
+
const fetcherDetail = { page, limit, sorters }
|
|
180
|
+
const indicator = this._labelIndicator.value || ''
|
|
182
181
|
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
182
|
+
let filters = [
|
|
183
|
+
{
|
|
184
|
+
name: 'warehouse_id',
|
|
185
|
+
operator: 'eq',
|
|
186
|
+
value: this.warehouseId
|
|
187
|
+
}
|
|
188
|
+
]
|
|
186
189
|
|
|
187
|
-
|
|
188
|
-
|
|
190
|
+
let locations = [],
|
|
191
|
+
totalLocations = 0
|
|
192
|
+
|
|
193
|
+
if (this.selectedLocations && this.selectedLocations.length) {
|
|
194
|
+
filters.push({
|
|
195
|
+
name: 'name',
|
|
196
|
+
operator: 'in',
|
|
197
|
+
value: this.selectedLocations.map(location => location.name)
|
|
198
|
+
})
|
|
199
|
+
const { records, total } = await this._fetchLocations(filters, fetcherDetail)
|
|
200
|
+
locations = records
|
|
201
|
+
totalLocations = total
|
|
189
202
|
} else {
|
|
190
|
-
if (this.
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
operator: 'noteq',
|
|
201
|
-
value: 'BUFFER'
|
|
202
|
-
}
|
|
203
|
-
]
|
|
204
|
-
locations = await this._fetchLocations(filters)
|
|
205
|
-
}
|
|
203
|
+
if (this._fullLocationFormat) {
|
|
204
|
+
filters.push({
|
|
205
|
+
name: 'type',
|
|
206
|
+
operator: 'noteq',
|
|
207
|
+
value: 'BUFFER'
|
|
208
|
+
})
|
|
209
|
+
const { records, total } = await this._fetchLocations(filters, fetcherDetail)
|
|
210
|
+
locations = records
|
|
211
|
+
totalLocations = total
|
|
212
|
+
} else {
|
|
206
213
|
// if partial format:
|
|
207
|
-
// prevent from printing same location label. eg: A-01-01-01, A-01-01-02 > will print A-01-01 twice
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
name: 'warehouse_id',
|
|
219
|
-
operator: 'eq',
|
|
220
|
-
value: this.warehouseId
|
|
221
|
-
}
|
|
222
|
-
]
|
|
223
|
-
locations = await this._fetchLocationsByGroup(filters)
|
|
224
|
-
}
|
|
214
|
+
// prevent from printing same location label. eg: A-01-01-01, A-01-01-02 > will print A-01-01 twice{
|
|
215
|
+
if (indicator == 'shelf') {
|
|
216
|
+
this._showToast({
|
|
217
|
+
level: 'error',
|
|
218
|
+
message: i18next.t('text.shelf_is_not_allowed_as_an_indicator_for_partial_format')
|
|
219
|
+
})
|
|
220
|
+
return
|
|
221
|
+
} else {
|
|
222
|
+
const { records, total } = await this._fetchLocationsByGroup(filters, fetcherDetail)
|
|
223
|
+
locations = records
|
|
224
|
+
totalLocations = total
|
|
225
225
|
}
|
|
226
226
|
}
|
|
227
227
|
}
|
|
228
228
|
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
...location,
|
|
233
|
-
indicator: location[indicator]
|
|
234
|
-
}
|
|
235
|
-
} else {
|
|
229
|
+
return {
|
|
230
|
+
total: totalLocations,
|
|
231
|
+
records: locations.map(location => {
|
|
236
232
|
return {
|
|
237
233
|
...location,
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
234
|
+
indicator: location[indicator],
|
|
235
|
+
originalName: location.name,
|
|
236
|
+
name:
|
|
237
|
+
location.type === 'BUFFER'
|
|
238
|
+
? ''
|
|
239
|
+
: this._fullLocationFormat // check if full location format is true
|
|
240
|
+
? `${location.zone}-${location.row}-${location.column}-${location.shelf}`
|
|
241
|
+
: `${location.zone}-${location.row}-${location.column}`
|
|
242
242
|
}
|
|
243
|
-
}
|
|
244
|
-
})
|
|
245
|
-
|
|
246
|
-
this._records = locations
|
|
247
|
-
this._total = locations.length
|
|
248
|
-
|
|
249
|
-
this._config = {
|
|
250
|
-
...this._config,
|
|
251
|
-
pagination: { pages: [20, 50, 100, 200] }
|
|
243
|
+
})
|
|
252
244
|
}
|
|
253
|
-
|
|
254
|
-
this.dataGrist.fetch()
|
|
255
245
|
}
|
|
256
246
|
|
|
257
|
-
async _fetchLocations(filters) {
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
zone
|
|
271
|
-
row
|
|
272
|
-
column
|
|
273
|
-
shelf
|
|
274
|
-
}
|
|
275
|
-
total
|
|
247
|
+
async _fetchLocations(filters, fetcherDetail) {
|
|
248
|
+
try {
|
|
249
|
+
const response = await client.query({
|
|
250
|
+
query: gql`
|
|
251
|
+
query locations($filters: [Filter!], $pagination: Pagination, $sortings: [Sorting!]) {
|
|
252
|
+
locations(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
253
|
+
items {
|
|
254
|
+
name
|
|
255
|
+
zone
|
|
256
|
+
row
|
|
257
|
+
column
|
|
258
|
+
shelf
|
|
259
|
+
type
|
|
276
260
|
}
|
|
261
|
+
total
|
|
277
262
|
}
|
|
278
|
-
`,
|
|
279
|
-
variables: {
|
|
280
|
-
filters,
|
|
281
|
-
sortings: sorters
|
|
282
263
|
}
|
|
283
|
-
|
|
264
|
+
`,
|
|
265
|
+
variables: {
|
|
266
|
+
filters,
|
|
267
|
+
paginations: { page: fetcherDetail.page, limit: fetcherDetail.limit },
|
|
268
|
+
sortings: fetcherDetail.sorters
|
|
269
|
+
}
|
|
270
|
+
})
|
|
284
271
|
|
|
285
|
-
|
|
286
|
-
|
|
272
|
+
if (!response.errors) {
|
|
273
|
+
return {
|
|
274
|
+
records: response.data.locations.items || [],
|
|
275
|
+
total: response.data.locations.total || 0
|
|
287
276
|
}
|
|
288
|
-
} catch (e) {
|
|
289
|
-
this._showToast({
|
|
290
|
-
level: 'error',
|
|
291
|
-
message: e
|
|
292
|
-
})
|
|
293
|
-
} finally {
|
|
294
|
-
this.dataGrist.hideSpinner()
|
|
295
277
|
}
|
|
278
|
+
} catch (e) {
|
|
279
|
+
this._showToast({
|
|
280
|
+
level: 'error',
|
|
281
|
+
message: e
|
|
282
|
+
})
|
|
296
283
|
}
|
|
297
284
|
}
|
|
298
285
|
|
|
299
|
-
async _fetchLocationsByGroup(filters) {
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
name
|
|
312
|
-
zone
|
|
313
|
-
row
|
|
314
|
-
column
|
|
315
|
-
}
|
|
316
|
-
total
|
|
286
|
+
async _fetchLocationsByGroup(filters, fetcherDetail) {
|
|
287
|
+
try {
|
|
288
|
+
const response = await client.query({
|
|
289
|
+
query: gql`
|
|
290
|
+
query locationsByGroup($filters: [Filter!], $pagination: Pagination, $sortings: [Sorting!]) {
|
|
291
|
+
locationsByGroup(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
292
|
+
items {
|
|
293
|
+
name
|
|
294
|
+
zone
|
|
295
|
+
row
|
|
296
|
+
column
|
|
297
|
+
type
|
|
317
298
|
}
|
|
299
|
+
total
|
|
318
300
|
}
|
|
319
|
-
`,
|
|
320
|
-
variables: {
|
|
321
|
-
filters,
|
|
322
|
-
sortings: sorters
|
|
323
301
|
}
|
|
324
|
-
|
|
302
|
+
`,
|
|
303
|
+
variables: {
|
|
304
|
+
filters,
|
|
305
|
+
paginations: { page: fetcherDetail.page, limit: fetcherDetail.limit },
|
|
306
|
+
sortings: fetcherDetail.sorters
|
|
307
|
+
}
|
|
308
|
+
})
|
|
325
309
|
|
|
326
|
-
|
|
327
|
-
|
|
310
|
+
if (!response.errors) {
|
|
311
|
+
return {
|
|
312
|
+
records: response.data.locationsByGroup.items || [],
|
|
313
|
+
total: response.data.locationsByGroup.total || 0
|
|
328
314
|
}
|
|
329
|
-
} catch (e) {
|
|
330
|
-
this._showToast({
|
|
331
|
-
level: 'error',
|
|
332
|
-
message: e
|
|
333
|
-
})
|
|
334
|
-
} finally {
|
|
335
|
-
this.dataGrist.hideSpinner()
|
|
336
315
|
}
|
|
316
|
+
} catch (e) {
|
|
317
|
+
this._showToast({
|
|
318
|
+
level: 'error',
|
|
319
|
+
message: e
|
|
320
|
+
})
|
|
337
321
|
}
|
|
338
322
|
}
|
|
339
323
|
|
|
340
324
|
_printLocations() {
|
|
341
|
-
|
|
342
|
-
|
|
325
|
+
const records = this.dataGrist.data && this.dataGrist.data.records
|
|
326
|
+
if (records && records.length) {
|
|
327
|
+
this.dispatchEvent(new CustomEvent(i18next.t('text.printing'), { detail: records }))
|
|
343
328
|
history.back()
|
|
344
329
|
} else {
|
|
345
330
|
this._showToast({
|
|
@@ -4,7 +4,7 @@ import { css, html } from 'lit-element'
|
|
|
4
4
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
5
5
|
import { client, navigate, PageView } from '@things-factory/shell'
|
|
6
6
|
import { CommonButtonStyles, ScrollbarStyles } from '@things-factory/styles'
|
|
7
|
-
import { getPathInfo
|
|
7
|
+
import { getPathInfo } from '@things-factory/utils'
|
|
8
8
|
|
|
9
9
|
class ReceivedNoteDetail extends localize(i18next)(PageView) {
|
|
10
10
|
static get properties() {
|
|
@@ -105,10 +105,8 @@ class ReceivedNoteDetail extends localize(i18next)(PageView) {
|
|
|
105
105
|
if (!this._grnNo) return
|
|
106
106
|
const response = await client.query({
|
|
107
107
|
query: gql`
|
|
108
|
-
query {
|
|
109
|
-
goodsReceivalNote(${
|
|
110
|
-
name: this._grnNo
|
|
111
|
-
})}) {
|
|
108
|
+
query goodsReceivalNote($name: String!) {
|
|
109
|
+
goodsReceivalNote(name: $name) {
|
|
112
110
|
id
|
|
113
111
|
name
|
|
114
112
|
status
|
|
@@ -118,7 +116,10 @@ class ReceivedNoteDetail extends localize(i18next)(PageView) {
|
|
|
118
116
|
}
|
|
119
117
|
}
|
|
120
118
|
}
|
|
121
|
-
|
|
119
|
+
`,
|
|
120
|
+
variables: {
|
|
121
|
+
name: this._grnNo
|
|
122
|
+
}
|
|
122
123
|
})
|
|
123
124
|
|
|
124
125
|
if (!response.errors) {
|
|
@@ -217,7 +217,7 @@ class BatchGenerateSinglePickingWorksheetPopup extends localize(i18next)(LitElem
|
|
|
217
217
|
|
|
218
218
|
const response = await client.query({
|
|
219
219
|
query: gql`
|
|
220
|
-
query releaseGoodRequests($filters: [Filter], $pagination: Pagination, $sortings: [Sorting]) {
|
|
220
|
+
query releaseGoodRequests($filters: [Filter!], $pagination: Pagination, $sortings: [Sorting!]) {
|
|
221
221
|
releaseGoodRequests(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
222
222
|
items {
|
|
223
223
|
id
|
|
@@ -907,8 +907,8 @@ class ReleaseOrderDetail extends connect(store)(localize(i18next)(PageView)) {
|
|
|
907
907
|
status: inventoryInfo.status,
|
|
908
908
|
existing: true,
|
|
909
909
|
roundedUomValue: `${roundedUomValue} ${inventoryInfo.uom}`,
|
|
910
|
-
addableQty: inventoryInfo.qty - inventoryInfo.lockedQty,
|
|
911
|
-
addableUomValue: inventoryInfo.uomValue - inventoryInfo.lockedUomValue
|
|
910
|
+
addableQty: inventoryInfo.qty - inventoryInfo.lockedQty - inventoryInfo.releaseQty,
|
|
911
|
+
addableUomValue: inventoryInfo.uomValue - inventoryInfo.lockedUomValue - inventoryInfo.releaseUomValue
|
|
912
912
|
}
|
|
913
913
|
})
|
|
914
914
|
|
|
@@ -537,6 +537,12 @@ class PackingProduct extends connect(store)(localize(i18next)(PageView)) {
|
|
|
537
537
|
var decodedHTML = atob(orderDocInfo[0].file)
|
|
538
538
|
this._callPrintDialog(decodedHTML)
|
|
539
539
|
break
|
|
540
|
+
|
|
541
|
+
default:
|
|
542
|
+
let url = new URL(window.location)
|
|
543
|
+
|
|
544
|
+
convertedPdfUrl = `${url.origin}/proxy?url=${encodeURIComponent(orderDocInfo[0].airwayBill)}`
|
|
545
|
+
this._callPrintDialog(convertedPdfUrl)
|
|
540
546
|
}
|
|
541
547
|
}
|
|
542
548
|
}
|
|
@@ -4,7 +4,7 @@ import '@things-factory/grist-ui'
|
|
|
4
4
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
5
5
|
import { getRenderer } from '@things-factory/grist-ui'
|
|
6
6
|
import { client, CustomAlert, navigate, PageView } from '@things-factory/shell'
|
|
7
|
-
import {
|
|
7
|
+
import { isMobileDevice } from '@things-factory/utils'
|
|
8
8
|
import { CommonButtonStyles } from '@things-factory/styles'
|
|
9
9
|
import gql from 'graphql-tag'
|
|
10
10
|
import { css, html } from 'lit-element'
|
|
@@ -367,10 +367,8 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
367
367
|
if (!this._worksheetNo) return
|
|
368
368
|
const response = await client.query({
|
|
369
369
|
query: gql`
|
|
370
|
-
query {
|
|
371
|
-
worksheet(${
|
|
372
|
-
name: this._worksheetNo
|
|
373
|
-
})}) {
|
|
370
|
+
query worksheet($name: String!) {
|
|
371
|
+
worksheet(name: $name) {
|
|
374
372
|
status
|
|
375
373
|
releaseGood {
|
|
376
374
|
name
|
|
@@ -434,7 +432,10 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
434
432
|
}
|
|
435
433
|
}
|
|
436
434
|
}
|
|
437
|
-
|
|
435
|
+
`,
|
|
436
|
+
variables: {
|
|
437
|
+
name: this._worksheetNo
|
|
438
|
+
}
|
|
438
439
|
})
|
|
439
440
|
|
|
440
441
|
if (!response.errors) {
|
|
@@ -541,17 +542,18 @@ class WorksheetLoading extends localize(i18next)(PageView) {
|
|
|
541
542
|
return
|
|
542
543
|
}
|
|
543
544
|
|
|
544
|
-
const response = await client.
|
|
545
|
-
|
|
546
|
-
mutation {
|
|
547
|
-
activateLoading(${
|
|
548
|
-
worksheetNo: this._worksheetNo,
|
|
549
|
-
loadingWorksheetDetails: this._getLoadingWorksheetDetails()
|
|
550
|
-
})}) {
|
|
545
|
+
const response = await client.mutate({
|
|
546
|
+
mutation: gql`
|
|
547
|
+
mutation activateLoading($worksheetNo: String!, $loadingWorksheetDetails: [WorksheetDetailPatch]) {
|
|
548
|
+
activateLoading(worksheetNo: $worksheetNo, loadingWorksheetDetails: $loadingWorksheetDetails) {
|
|
551
549
|
name
|
|
552
550
|
}
|
|
553
551
|
}
|
|
554
|
-
|
|
552
|
+
`,
|
|
553
|
+
variables: {
|
|
554
|
+
worksheetNo: this._worksheetNo,
|
|
555
|
+
loadingWorksheetDetails: this._getLoadingWorksheetDetails()
|
|
556
|
+
}
|
|
555
557
|
})
|
|
556
558
|
if (!response.errors) {
|
|
557
559
|
this._showToast({ message: i18next.t('text.worksheet_activated') })
|
|
@@ -10,7 +10,7 @@ import { i18next, localize } from '@things-factory/i18n-base'
|
|
|
10
10
|
import { openPopup } from '@things-factory/layout-base'
|
|
11
11
|
import { client, CustomAlert, navigate, PageView } from '@things-factory/shell'
|
|
12
12
|
import { CommonButtonStyles } from '@things-factory/styles'
|
|
13
|
-
import {
|
|
13
|
+
import { isMobileDevice } from '@things-factory/utils'
|
|
14
14
|
|
|
15
15
|
import { MARKETPLACE_STATUS, WORKSHEET_STATUS } from '../constants'
|
|
16
16
|
|
|
@@ -298,10 +298,8 @@ class WorksheetPacking extends localize(i18next)(PageView) {
|
|
|
298
298
|
if (!this._worksheetNo) return
|
|
299
299
|
const response = await client.query({
|
|
300
300
|
query: gql`
|
|
301
|
-
query {
|
|
302
|
-
worksheet(${
|
|
303
|
-
name: this._worksheetNo
|
|
304
|
-
})}) {
|
|
301
|
+
query worksheet($name: String!) {
|
|
302
|
+
worksheet(name: $name) {
|
|
305
303
|
status
|
|
306
304
|
releaseGood {
|
|
307
305
|
name
|
|
@@ -384,7 +382,10 @@ class WorksheetPacking extends localize(i18next)(PageView) {
|
|
|
384
382
|
}
|
|
385
383
|
}
|
|
386
384
|
}
|
|
387
|
-
|
|
385
|
+
`,
|
|
386
|
+
variables: {
|
|
387
|
+
name: this._worksheetNo
|
|
388
|
+
}
|
|
388
389
|
})
|
|
389
390
|
|
|
390
391
|
if (!response.errors) {
|
|
@@ -486,16 +487,17 @@ class WorksheetPacking extends localize(i18next)(PageView) {
|
|
|
486
487
|
return
|
|
487
488
|
}
|
|
488
489
|
|
|
489
|
-
const response = await client.
|
|
490
|
-
|
|
491
|
-
mutation {
|
|
492
|
-
activatePacking(${
|
|
493
|
-
worksheetNo: this._worksheetNo
|
|
494
|
-
})}) {
|
|
490
|
+
const response = await client.mutate({
|
|
491
|
+
mutation: gql`
|
|
492
|
+
mutation activatePacking($worksheetNo: String!) {
|
|
493
|
+
activatePacking(worksheetNo: $worksheetNo) {
|
|
495
494
|
name
|
|
496
495
|
}
|
|
497
496
|
}
|
|
498
|
-
|
|
497
|
+
`,
|
|
498
|
+
variables: {
|
|
499
|
+
worksheetNo: this._worksheetNo
|
|
500
|
+
}
|
|
499
501
|
})
|
|
500
502
|
if (!response.errors) {
|
|
501
503
|
this._showToast({ message: i18next.t('text.worksheet_activated') })
|
|
@@ -7,8 +7,6 @@ import { connect } from 'pwa-helpers/connect-mixin'
|
|
|
7
7
|
|
|
8
8
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
9
9
|
import { client, PageView, store } from '@things-factory/shell'
|
|
10
|
-
import { gqlBuilder } from '@things-factory/utils'
|
|
11
|
-
|
|
12
10
|
class ElcclDailyCollectionReport extends connect(store)(localize(i18next)(PageView)) {
|
|
13
11
|
static get styles() {
|
|
14
12
|
return css`
|
|
@@ -235,12 +233,8 @@ class ElcclDailyCollectionReport extends connect(store)(localize(i18next)(PageVi
|
|
|
235
233
|
var tzoffset = new Date().getTimezoneOffset() * 60
|
|
236
234
|
const response = await client.query({
|
|
237
235
|
query: gql`
|
|
238
|
-
query {
|
|
239
|
-
elcclDailyCollectionReport(${
|
|
240
|
-
filters: [...this.searchForm.queryFilters, { name: 'tzoffset', operator: 'custom', value: tzoffset }],
|
|
241
|
-
pagination: { page, limit },
|
|
242
|
-
sortings: sorters
|
|
243
|
-
})}) {
|
|
236
|
+
query elcclDailyCollectionReport($filters: [Filter!], $pagination: Pagination, $sortings: [Sorting!]) {
|
|
237
|
+
elcclDailyCollectionReport(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
244
238
|
arrival_notice_name
|
|
245
239
|
bizplace_name
|
|
246
240
|
ended_at
|
|
@@ -255,7 +249,12 @@ class ElcclDailyCollectionReport extends connect(store)(localize(i18next)(PageVi
|
|
|
255
249
|
delivery_summary
|
|
256
250
|
}
|
|
257
251
|
}
|
|
258
|
-
|
|
252
|
+
`,
|
|
253
|
+
variables: {
|
|
254
|
+
filters: [...this.searchForm.queryFilters, { name: 'tzoffset', operator: 'custom', value: tzoffset }],
|
|
255
|
+
pagination: { page, limit },
|
|
256
|
+
sortings: sorters
|
|
257
|
+
}
|
|
259
258
|
})
|
|
260
259
|
|
|
261
260
|
this.data = {
|
|
@@ -7,7 +7,7 @@ import { connect } from 'pwa-helpers/connect-mixin'
|
|
|
7
7
|
|
|
8
8
|
import { i18next, localize } from '@things-factory/i18n-base'
|
|
9
9
|
import { client, PageView, store } from '@things-factory/shell'
|
|
10
|
-
import { flattenObject,
|
|
10
|
+
import { flattenObject, isMobileDevice } from '@things-factory/utils'
|
|
11
11
|
|
|
12
12
|
class ElcclDailyOrderInventoryReport extends connect(store)(localize(i18next)(PageView)) {
|
|
13
13
|
static get styles() {
|
|
@@ -261,33 +261,34 @@ class ElcclDailyOrderInventoryReport extends connect(store)(localize(i18next)(Pa
|
|
|
261
261
|
|
|
262
262
|
const response = await client.query({
|
|
263
263
|
query: gql`
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
})}) {
|
|
270
|
-
items{
|
|
271
|
-
bizplace {
|
|
272
|
-
name
|
|
273
|
-
}
|
|
274
|
-
bag
|
|
275
|
-
bagRunningTotal
|
|
276
|
-
basket
|
|
277
|
-
basketRunningTotal
|
|
278
|
-
carton
|
|
279
|
-
cartonRunningTotal
|
|
280
|
-
createdAt
|
|
281
|
-
doRefNo
|
|
282
|
-
orderNo
|
|
283
|
-
orderRefNo
|
|
284
|
-
pallet
|
|
285
|
-
palletRunningTotal
|
|
264
|
+
query elcclDailyOrderInventoryReport($filters: [Filter!], $pagination: Pagination, $sortings: [Sorting!]) {
|
|
265
|
+
elcclDailyOrderInventoryReport(filters: $filters, pagination: $pagination, sortings: $sortings) {
|
|
266
|
+
items {
|
|
267
|
+
bizplace {
|
|
268
|
+
name
|
|
286
269
|
}
|
|
287
|
-
|
|
270
|
+
bag
|
|
271
|
+
bagRunningTotal
|
|
272
|
+
basket
|
|
273
|
+
basketRunningTotal
|
|
274
|
+
carton
|
|
275
|
+
cartonRunningTotal
|
|
276
|
+
createdAt
|
|
277
|
+
doRefNo
|
|
278
|
+
orderNo
|
|
279
|
+
orderRefNo
|
|
280
|
+
pallet
|
|
281
|
+
palletRunningTotal
|
|
288
282
|
}
|
|
283
|
+
total
|
|
289
284
|
}
|
|
290
|
-
|
|
285
|
+
}
|
|
286
|
+
`,
|
|
287
|
+
variables: {
|
|
288
|
+
filters: [...filter, { name: 'tzoffset', operator: 'custom', value: tzoffset }],
|
|
289
|
+
pagination: { page, limit },
|
|
290
|
+
sortings: sorters
|
|
291
|
+
}
|
|
291
292
|
})
|
|
292
293
|
return {
|
|
293
294
|
total: response.data.elcclDailyOrderInventoryReport.total,
|