diff --git a/src/components/ScheduledRestockPopover.vue b/src/components/ScheduledRestockPopover.vue index eda57da..34fcae3 100644 --- a/src/components/ScheduledRestockPopover.vue +++ b/src/components/ScheduledRestockPopover.vue @@ -11,6 +11,7 @@ id="schedule-datetime" show-default-buttons hour-cycle="h23" + :min="DateTime.now().toISO()" :value="job.runTime ? getDateTime(job.runTime) : getDateTime(DateTime.now().toMillis())" @ionChange="changeJobRunTime($event)" /> diff --git a/src/locales/en.json b/src/locales/en.json index 716b09b..ef0e1ef 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -4,6 +4,7 @@ "Add to shipment":"Add to shipment", "Adjust": "Adjust", "Adjust Inventory": "Adjust Inventory", + "Adjust inventory": "Adjust inventory", "All": "All", "App": "App", "Apply": "Apply", @@ -68,6 +69,7 @@ "Facilities": "Facilities", "Facility ID": "Facility ID", "Facility Location": "Facility Location", + "Failed": "Failed", "Failed records": "Failed records", "Failed to add product to shipment": "Failed to add product to shipment", "Failed to save CSV mapping.": "Failed to save CSV mapping.", @@ -196,6 +198,7 @@ "Required": "Required", "Run once": "Run once", "Run now": "Run now", + "Running": "Running", "Running this job now will not replace this job. A copy of this job will be created and run immediately. You may not be able to reverse this action.": "Running this job now will not replace this job. A copy of this job will be created and run immediately. You may not be able to reverse this action.", "Safety stock": "Safety stock", "Save mapping": "Save mapping", @@ -217,6 +220,7 @@ "Schedule Inventory": "Schedule Inventory", "Scheduled inventory": "Scheduled inventory", "Scheduled product launch": "Scheduled product launch", + "Scheduled restock": "Scheduled restock", "Select": "Select", "Select mapping": "Select mapping", "Select SKU": "Select SKU", diff --git a/src/router/index.ts b/src/router/index.ts index b27cb1f..0a951cb 100644 --- a/src/router/index.ts +++ b/src/router/index.ts @@ -91,7 +91,7 @@ const routes: Array = [ beforeEnter: authGuard, }, { - path: '/adjust-inventory_history', + path: '/adjust-inventory-history', name: 'AdjustInventoryHistory', component: AdjustInventoryHistory, beforeEnter: authGuard, diff --git a/src/store/modules/product/actions.ts b/src/store/modules/product/actions.ts index ea9501b..c147602 100644 --- a/src/store/modules/product/actions.ts +++ b/src/store/modules/product/actions.ts @@ -64,10 +64,9 @@ const actions: ActionTree = { } } catch (error) { commit(types.PRODUCT_LIST_UPDATED, { products: [], total: 0 }); - } finally { - if (payload.viewIndex === 0) emitter.emit("dismissLoader"); } + if (payload.viewIndex === 0) emitter.emit("dismissLoader"); return resp; }, async clearProducts({ commit }) { diff --git a/src/store/modules/user/actions.ts b/src/store/modules/user/actions.ts index dcdab5d..b6dc390 100644 --- a/src/store/modules/user/actions.ts +++ b/src/store/modules/user/actions.ts @@ -119,6 +119,7 @@ const actions: ActionTree = { this.dispatch('order/updatePurchaseOrders', {parsed: {}, original: {}, unidentifiedItems: []}); this.dispatch('util/clearFacilities'); this.dispatch('util/clearProductStores'); + this.dispatch('util/clearStatusDesc'); // clearing field mappings and current mapping when the user logout commit(types.USER_FIELD_MAPPINGS_UPDATED, {}) commit(types.USER_CURRENT_FIELD_MAPPING_UPDATED, {id: '', mappingType: '', name: '', value: {}}) diff --git a/src/store/modules/util/actions.ts b/src/store/modules/util/actions.ts index 9b61563..2b96b7f 100644 --- a/src/store/modules/util/actions.ts +++ b/src/store/modules/util/actions.ts @@ -128,7 +128,7 @@ const actions: ActionTree = { commit(types.UTIL_PRODUCT_STORES_UPDATED, productStores); }, // Retrieves service status descriptions - async getServiceStatusDesc ({ commit }) { + async getServiceStatusDesc({ commit }) { try{ const resp = await UtilService.getServiceStatusDesc({ "inputFields": { @@ -147,6 +147,9 @@ const actions: ActionTree = { logger.error(err) } }, + async clearStatusDesc({ commit }) { + commit(types.UTIL_SERVICE_STATUS_DESC_CLEARED) + }, // Fetches shipment items by shipmentId async fetchShipmentItems({ commit }, shipmentId) { let shipmentItems = []; @@ -159,7 +162,7 @@ const actions: ActionTree = { throw resp.data } } catch (err) { - logger.error(err) + logger.error(err) } commit(types.UTIL_SHIPMENT_ITEMS_UPDATED, shipmentItems); }, diff --git a/src/store/modules/util/mutation-types.ts b/src/store/modules/util/mutation-types.ts index f31f606..d2d72d8 100644 --- a/src/store/modules/util/mutation-types.ts +++ b/src/store/modules/util/mutation-types.ts @@ -7,4 +7,5 @@ export const UTIL_PRODUCT_STORES_UPDATED = SN_UTIL + '/PRODUCT_STORES_UPDATED' export const UTIL_DATA_MANAGER_CONFIG_UPDATED = SN_UTIL + '/DATA_MANAGER_CONFIG_UPDATED' export const UTIL_EXACT_INVENTORY_TYPE_UPDATED = SN_UTIL + '/EXACT_INVENTORY_TYPE_UPDATED' export const UTIL_SERVICE_STATUS_DESC_UPDATED = SN_UTIL + '/SERVICE_STATUS_DESC_UPDATED' +export const UTIL_SERVICE_STATUS_DESC_CLEARED = SN_UTIL + '/SERVICE_STATUS_DESC_CLEARED' export const UTIL_SHIPMENT_ITEMS_UPDATED = SN_UTIL + '/SHIPMENT_ITEMS_UPDATED' \ No newline at end of file diff --git a/src/store/modules/util/mutations.ts b/src/store/modules/util/mutations.ts index a8c54db..bf2e5b4 100644 --- a/src/store/modules/util/mutations.ts +++ b/src/store/modules/util/mutations.ts @@ -31,6 +31,9 @@ const mutations: MutationTree = { state.statusDesc[status.statusId] = status.description; }) }, + [types.UTIL_SERVICE_STATUS_DESC_CLEARED] (state) { + state.statusDesc = {} + }, [types.UTIL_DATA_MANAGER_CONFIG_UPDATED] (state, payload) { state.configDetails = payload; } diff --git a/src/views/AdjustInventory.vue b/src/views/AdjustInventory.vue index aa90d6d..b3a14d9 100644 --- a/src/views/AdjustInventory.vue +++ b/src/views/AdjustInventory.vue @@ -60,7 +60,7 @@ - + {{ translate("Upload") }} @@ -94,9 +94,9 @@ - + {{ translate("Run once") }} @@ -171,9 +171,10 @@ export default defineComponent({ }, computed: { ...mapGetters({ + configDetails: 'util/getDataManagerConfig', fieldMappings: 'user/getFieldMappings', goodIdentificationTypes: 'util/getGoodIdentificationTypes', - configDetails: 'util/getDataManagerConfig' + instanceUrl: 'user/getInstanceUrl', }) }, mixins:[ parseFileMixin ], diff --git a/src/views/AdjustInventoryHistory.vue b/src/views/AdjustInventoryHistory.vue index ed95c29..9770482 100644 --- a/src/views/AdjustInventoryHistory.vue +++ b/src/views/AdjustInventoryHistory.vue @@ -44,7 +44,7 @@ {{ translate("Upload file") }} - + @@ -150,17 +150,17 @@ export default defineComponent ({ if(this.filteredDataManagerLogList) { await this.fetchDataResource(this.filteredDataManagerLogList) } - this.filterDataManagerLogs('ALL'); + this.filterDataManagerLogs("ALL"); this.isLoading = false; }, methods: { filterDataManagerLogs(id) { this.selectedFilter = id; - if (id === 'ALL') { + if (id === "ALL") { this.filteredDataManagerLogList = [...this.dataManagerLogList] - } else if (id === 'FAILED_LOGS') { + } else if (id === "FAILED_LOGS") { this.filteredDataManagerLogList = this.dataManagerLogList.filter(log => log.statusId === 'SERVICE_FAILED') - } else if (id === 'FAILED_RECORDS') { + } else if (id === "FAILED_RECORDS") { this.filteredDataManagerLogList = this.dataManagerLogList.filter(log => log.errorRecordContentId !== null) } }, diff --git a/src/views/InventoryReview.vue b/src/views/InventoryReview.vue index 6a4ced4..421ce3b 100644 --- a/src/views/InventoryReview.vue +++ b/src/views/InventoryReview.vue @@ -246,6 +246,7 @@ export default defineComponent({ const params = { "configId": this.exactInventoryType.configId } as any + const alert = await alertController.create({ header: translate("Reset inventory"), message: translate("Make sure all the data you have entered is correct."), diff --git a/src/views/SavedMappings.vue b/src/views/SavedMappings.vue index 8c498f5..2ba5234 100644 --- a/src/views/SavedMappings.vue +++ b/src/views/SavedMappings.vue @@ -33,7 +33,7 @@ - {{ translate("Scheduled restock") }} + {{ translate("Adjust inventory") }} {{ mapping.name }} diff --git a/src/views/ScheduledIncomingInventory.vue b/src/views/ScheduledIncomingInventory.vue index 4ff2cec..99022f7 100644 --- a/src/views/ScheduledIncomingInventory.vue +++ b/src/views/ScheduledIncomingInventory.vue @@ -15,14 +15,14 @@ -