From 07b34de1769ea983030a3cc885579aa911cee402 Mon Sep 17 00:00:00 2001 From: amansinghbais Date: Thu, 7 Dec 2023 14:24:17 +0530 Subject: [PATCH 1/3] Improved: create button text to be dynamic based on facility type (#68) --- src/locales/en.json | 4 ++++ src/views/CreateFacility.vue | 8 ++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/locales/en.json b/src/locales/en.json index adb64cbc..c4449f29 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -40,7 +40,11 @@ "Configure the order fulfillment capacity of your facility.": "Configure the order fulfillment capacity of your facility.", "Consumed Order Limit": "Consumed Order Limit", "Create login credentials": "Create login credentials", + "Create Outlet Store": "Create Outlet Store", + "Create Outlet Warehouse": "Create Outlet Warehouse", + "Create Retail Store": "Create Retail Store", "Create store": "Create store", + "Create Warehouse": "Create Warehouse", "Custom": "Custom", "Custom fulfillment capacity": "Custom fulfillment capacity", "Custom mapping": "Custom mapping", diff --git a/src/views/CreateFacility.vue b/src/views/CreateFacility.vue index 92dec0f3..c972b920 100644 --- a/src/views/CreateFacility.vue +++ b/src/views/CreateFacility.vue @@ -15,7 +15,7 @@ {{ translate("Type") }} - + {{ type.description }} @@ -48,7 +48,7 @@
- {{ translate("Create store") }} + {{ facilityTypes[selectedFacilityTypeId] ? translate(`Create ${facilityTypes[selectedFacilityTypeId]?.description}`) : translate("Create store") }}
@@ -72,6 +72,8 @@ import { IonList, IonNote, IonPage, + IonSelect, + IonSelectOption, IonText, IonTitle, IonToolbar, @@ -103,6 +105,8 @@ export default defineComponent({ IonList, IonNote, IonPage, + IonSelect, + IonSelectOption, IonText, IonTitle, IonToolbar, From 9ec7e58ecdf1369a87782ba5b5720de354b3d99a Mon Sep 17 00:00:00 2001 From: amansinghbais Date: Fri, 8 Dec 2023 15:14:58 +0530 Subject: [PATCH 2/3] Improved: code to display facilityTypeId if description is not given (#68) --- src/locales/en.json | 1 - src/views/CreateFacility.vue | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/locales/en.json b/src/locales/en.json index 4795b628..c627bb4f 100644 --- a/src/locales/en.json +++ b/src/locales/en.json @@ -43,7 +43,6 @@ "Create Outlet Store": "Create Outlet Store", "Create Outlet Warehouse": "Create Outlet Warehouse", "Create Retail Store": "Create Retail Store", - "Create store": "Create store", "Create Warehouse": "Create Warehouse", "Custom": "Custom", "Custom fulfillment capacity": "Custom fulfillment capacity", diff --git a/src/views/CreateFacility.vue b/src/views/CreateFacility.vue index 81da2c9a..24d783af 100644 --- a/src/views/CreateFacility.vue +++ b/src/views/CreateFacility.vue @@ -17,7 +17,7 @@ {{ translate("Type") }} - {{ type.description }} + {{ type?.description ? type.description : facilityTypeId }}
@@ -48,7 +48,7 @@
- {{ facilityTypes[selectedFacilityTypeId] ? translate(`Create ${facilityTypes[selectedFacilityTypeId]?.description}`) : translate("Create store") }} + {{ facilityTypes[selectedFacilityTypeId]?.description ? translate(`Create ${facilityTypes[selectedFacilityTypeId].description}`) : translate(`Create ${selectedFacilityTypeId}`) }}
From 1f297664f23958d80d046163513d1f8c4f352a87 Mon Sep 17 00:00:00 2001 From: amansinghbais Date: Fri, 8 Dec 2023 15:35:15 +0530 Subject: [PATCH 3/3] Improved: code for unnecessary optional check (#68) --- src/views/CreateFacility.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/CreateFacility.vue b/src/views/CreateFacility.vue index 24d783af..40625e28 100644 --- a/src/views/CreateFacility.vue +++ b/src/views/CreateFacility.vue @@ -17,7 +17,7 @@ {{ translate("Type") }} - {{ type?.description ? type.description : facilityTypeId }} + {{ type.description ? type.description : facilityTypeId }}