diff --git a/src/services/ProductStoreService.ts b/src/services/ProductStoreService.ts index 12d49bd..ca5d2f3 100644 --- a/src/services/ProductStoreService.ts +++ b/src/services/ProductStoreService.ts @@ -43,12 +43,12 @@ const fetchProductStoresFacilityCount = async (payload: any): Promise => { const updateProductStore = async (payload: any): Promise => { return api({ url: `productStores/${payload.productStoreId}`, - method: "post", + method: "put", data: payload }); } -const updateDBICCountries = async (payload: any): Promise => { +const addDBICCountries = async (payload: any): Promise => { return api({ url: "countries/dbic", method: "post", @@ -100,6 +100,6 @@ export const ProductStoreService = { fetchProductStoresFacilityCount, updateCompany, updateCurrentStoreSettings, - updateDBICCountries, + addDBICCountries, updateProductStore } \ No newline at end of file diff --git a/src/store/modules/util/actions.ts b/src/store/modules/util/actions.ts index b31c91e..1439e17 100644 --- a/src/store/modules/util/actions.ts +++ b/src/store/modules/util/actions.ts @@ -29,7 +29,7 @@ const actions: ActionTree = { let countries = [] as any; try { - const resp = await UtilService.fetchDBICCountries({ geoIdTo: "DBIC", pageSize: 200 }) + const resp = await UtilService.fetchDBICCountries({toGeoId: "DBIC", pageSize: 200 }) if(!hasError(resp)) { countries = resp.data; } else { @@ -47,7 +47,7 @@ const actions: ActionTree = { let operatingCountries = [] as any; try { - const resp = await UtilService.fetchOperatingCountries({ pageSize: 200 }) + const resp = await UtilService.fetchOperatingCountries({ pageSize: 300, geoTypeEnumId: 'GEOT_COUNTRY' }) if(!hasError(resp)) { operatingCountries = resp.data; } else { diff --git a/src/views/CreateProductStore.vue b/src/views/CreateProductStore.vue index 21e8dd1..cc9533f 100644 --- a/src/views/CreateProductStore.vue +++ b/src/views/CreateProductStore.vue @@ -118,9 +118,9 @@ async function manageConfigurations() { const productStoreId = resp.data.productStoreId; if(!dbicCountriesCount.value) { - const responses = await Promise.allSettled(selectedCountries.value.map((country: any) => ProductStoreService.updateDBICCountries({ + const responses = await Promise.allSettled(selectedCountries.value.map((country: any) => ProductStoreService.addDBICCountries({ geoId: country.geoId, - geoIdTo: "DBIC", + toGeoId: "DBIC", geoAssocTypeId: "GROUP_MEMBER" })) ) diff --git a/src/views/ProductStoreDetails.vue b/src/views/ProductStoreDetails.vue index d020ff5..7b89782 100644 --- a/src/views/ProductStoreDetails.vue +++ b/src/views/ProductStoreDetails.vue @@ -312,11 +312,11 @@ - {{ translate("Delivery method") }} + {{ translate("Delivery method") }} - + {{ shipmentMethod.description ? shipmentMethod.description : shipmentMethod.shipmentMethodTypeId }}