@things-factory/operato-wms 3.7.9 → 3.7.10

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.
@@ -365,6 +365,8 @@ class ExecuteReverseKitting extends connect(store)(localize(i18next)(PageView))
365
365
  `,
366
366
  {
367
367
  backdrop: true,
368
+ escapable: false,
369
+ closable: false,
368
370
  size: 'large',
369
371
  title: record.palletId
370
372
  }
@@ -142,13 +142,16 @@ class PopupCombinationSets extends localize(i18next)(LitElement) {
142
142
  @click=${this._openIssueNote.bind(this)}
143
143
  label="${i18next.t('button.issue')}"
144
144
  ></mwc-button>
145
+ <mwc-button raised @click=${this._closePopup.bind(this)} label="${i18next.t('button.back')}"></mwc-button>
145
146
  </div>`
146
- : ''}
147
+ : html`<div class="button-container">
148
+ <mwc-button raised @click=${this._closePopup.bind(this)} label="${i18next.t('button.back')}"></mwc-button>
149
+ </div>`}
147
150
  `
148
151
  }
149
152
 
150
153
  async fetchReverseKittingOrder() {
151
- if (!this._orderNo) return
154
+ if (!this.orderNo) return
152
155
  const response = await client.query({
153
156
  query: gql`
154
157
  query executingReverseKittingOrder($name: String!) {
@@ -205,15 +208,30 @@ class PopupCombinationSets extends localize(i18next)(LitElement) {
205
208
  }
206
209
  }
207
210
  `,
208
- variables: { name: this._orderNo }
211
+ variables: { name: this.orderNo }
209
212
  })
210
213
 
211
214
  if (!response.errors) {
212
215
  const reverseKittingOrder = response.data.executingReverseKittingOrder
213
216
  const orderReverseKittings = reverseKittingOrder.orderReverseKittings
214
217
 
215
- this.data = {
216
- records: orderReverseKittings.map(orderReverseKitting => {
218
+ // this.data = {
219
+ // records: orderReverseKittings.map(orderReverseKitting => {
220
+ // const inventory = orderReverseKitting.inventory
221
+ // return {
222
+ // ...orderReverseKitting,
223
+ // batchId: inventory.batchId,
224
+ // palletId: inventory.palletId,
225
+ // location: inventory.location,
226
+ // product: inventory.product
227
+ // }
228
+ // })
229
+ // }
230
+
231
+ const previousOrderReverseKittingName = this.data.name
232
+ const matchedOrderReverseKitting = orderReverseKittings
233
+ .filter(item => item.name === previousOrderReverseKittingName)
234
+ .map(orderReverseKitting => {
217
235
  const inventory = orderReverseKitting.inventory
218
236
  return {
219
237
  ...orderReverseKitting,
@@ -223,7 +241,8 @@ class PopupCombinationSets extends localize(i18next)(LitElement) {
223
241
  product: inventory.product
224
242
  }
225
243
  })
226
- }
244
+
245
+ this.data = { ...matchedOrderReverseKitting[0] }
227
246
 
228
247
  this.getProductCombination()
229
248
  }
@@ -301,12 +320,19 @@ class PopupCombinationSets extends localize(i18next)(LitElement) {
301
320
  `,
302
321
  {
303
322
  backdrop: true,
323
+ escapable: false,
324
+ closable: false,
304
325
  size: 'large',
305
326
  title: i18next.t('title.reverse_kitting')
306
327
  }
307
328
  )
308
329
  }
309
330
 
331
+ _closePopup() {
332
+ this.dispatchEvent(new CustomEvent('order-reverse-kitting-data', { detail: {} }))
333
+ history.back()
334
+ }
335
+
310
336
  _showToast({ type, message }) {
311
337
  document.dispatchEvent(
312
338
  new CustomEvent('notify', {
@@ -130,13 +130,24 @@ class PopupReverseKittingTemplate extends localize(i18next)(LitElement) {
130
130
  ></data-grist>
131
131
  </div>
132
132
  <div class="button-container">
133
+ <mwc-button
134
+ raised
135
+ @click=${this._confirmInventory.bind(this)}
136
+ label="${i18next.t('button.confirm')}"
137
+ ></mwc-button>
133
138
  <mwc-button
134
139
  raised
135
140
  @click=${this._undoInventory.bind(this)}
136
141
  label="${i18next.t('button.undo')}"
137
142
  ></mwc-button>
138
143
  </div> `
139
- : ''}
144
+ : html`<div class="button-container">
145
+ <mwc-button
146
+ raised
147
+ @click=${this._confirmInventory.bind(this)}
148
+ label="${i18next.t('button.confirm')}"
149
+ ></mwc-button>
150
+ </div> `}
140
151
  `
141
152
  }
142
153
 
@@ -352,6 +363,11 @@ class PopupReverseKittingTemplate extends localize(i18next)(LitElement) {
352
363
  }
353
364
  }
354
365
 
366
+ _confirmInventory() {
367
+ this.dispatchEvent(new CustomEvent('updated', { detail: {} }))
368
+ history.back()
369
+ }
370
+
355
371
  _fillUpForm(form, data) {
356
372
  for (let key in data) {
357
373
  Array.from(form.querySelectorAll('input')).forEach(field => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@things-factory/operato-wms",
3
- "version": "3.7.9",
3
+ "version": "3.7.10",
4
4
  "main": "dist-server/index.js",
5
5
  "browser": "client/index.js",
6
6
  "things-factory": true,
@@ -71,7 +71,7 @@
71
71
  "@things-factory/print-ui": "^3.7.5",
72
72
  "@things-factory/product-base": "^3.7.8",
73
73
  "@things-factory/resource-ui": "^3.7.7",
74
- "@things-factory/sales-ui": "^3.7.9",
74
+ "@things-factory/sales-ui": "^3.7.10",
75
75
  "@things-factory/scene-chartjs": "^3.7.5",
76
76
  "@things-factory/scene-clock": "^3.7.5",
77
77
  "@things-factory/scene-clone": "^3.7.5",
@@ -102,11 +102,11 @@
102
102
  "@things-factory/system-ui": "^3.7.5",
103
103
  "@things-factory/transport-base": "^3.7.5",
104
104
  "@things-factory/tutorial-ui": "^3.7.5",
105
- "@things-factory/warehouse-base": "^3.7.9",
106
- "@things-factory/worksheet-base": "^3.7.9"
105
+ "@things-factory/warehouse-base": "^3.7.10",
106
+ "@things-factory/worksheet-base": "^3.7.10"
107
107
  },
108
108
  "devDependencies": {
109
109
  "@things-factory/builder": "^3.7.5"
110
110
  },
111
- "gitHead": "4d4b67315ce5f7a8a3e2cbc3206ff23b0f1d5f9d"
111
+ "gitHead": "dc4aa344ee524651b4e633c3647c85c8daad8eb6"
112
112
  }