diff --git a/src/api/beforehand_order_cart_info.ts b/src/api/beforehand_order_cart_info.ts index 95a507ec1..71ce995d9 100644 --- a/src/api/beforehand_order_cart_info.ts +++ b/src/api/beforehand_order_cart_info.ts @@ -57,4 +57,9 @@ export function apiBeforehandOrderCartInfoFix(params: any) { url: '/beforehand_order_cart_info/beforehandordercartinfo/fix', params }) +} + +// 同步商品价格 +export function apiBeforehandOrderCartInfoSyncPrice(params: any) { + return request.get({ url: '/beforehand_order_cart_info/beforehandordercartinfo/syncPrice', params }) } \ No newline at end of file diff --git a/src/views/inventory_transfer/warehousing.vue b/src/views/inventory_transfer/warehousing.vue index 203a1b2f0..b977f5b38 100644 --- a/src/views/inventory_transfer/warehousing.vue +++ b/src/views/inventory_transfer/warehousing.vue @@ -13,7 +13,7 @@ + @change="changeStore" style="width: 300px"> @@ -21,7 +21,7 @@ + @change="changeWarehouse" style="width: 300px"> @@ -81,7 +81,8 @@ - + @@ -106,6 +107,8 @@ const popupRef = shallowRef>() const mode = ref('add') const store_id = ref(0) // 门店id + const warehouse_id = ref(0) //仓库id + const is_warehouse = ref(0) //是否仓库 // 表单数据 const formData = reactive({ @@ -146,6 +149,17 @@ showProduct.value = false } + const changeStore = (e : any) => { + store_id.value = e + resetUserId() + } + + const changeWarehouse = (e : any) => { + warehouse_id.value = e + is_warehouse.value = 1 + resetUserId() + } + const storeloading = ref(false) const storeList = ref([]) const remoteMethodStore = (e = '') => { @@ -191,7 +205,7 @@ expiration_date: item.expiration_date } }) - const data = { product_arr,...formData } + const data = { product_arr, ...formData } await formRef.value?.validate() mode.value == 'edit' ? await apiInventoryTransferEdit(data) @@ -209,7 +223,7 @@ } } } - + const getDetail = async (row : Record) => { const data = await apiInventoryTransferDetail({ id: row.id @@ -217,6 +231,11 @@ setFormData(data) } + const productModalKey = ref(0) + const resetUserId = () => { + productModalKey.value++ + } + defineExpose({ open, setFormData, diff --git a/src/views/order/beforehand_order/component/orderCartInfo.vue b/src/views/order/beforehand_order/component/orderCartInfo.vue index 85db97859..7a32d423f 100644 --- a/src/views/order/beforehand_order/component/orderCartInfo.vue +++ b/src/views/order/beforehand_order/component/orderCartInfo.vue @@ -12,6 +12,7 @@ 查询 + 同步价格 { }) } +const syncPrice = async() => { + await apiBeforehandOrderCartInfoSyncPrice({ + bhoid: formData.value.id + }) + getLists() +} + onMounted(() => { queryParams.bhoid = route.query.id formData.value.id = route.query.id diff --git a/src/views/order/store_order/index.vue b/src/views/order/store_order/index.vue index 383aae052..9f31b4131 100644 --- a/src/views/order/store_order/index.vue +++ b/src/views/order/store_order/index.vue @@ -88,7 +88,13 @@ placeholder="请选择订单类型" @change="resetPage" > + + + + + + diff --git a/src/views/warehouse/product_import.vue b/src/views/warehouse/product_import.vue index 1672be40f..d0ad20961 100644 --- a/src/views/warehouse/product_import.vue +++ b/src/views/warehouse/product_import.vue @@ -1,29 +1,16 @@ + onMounted(() => { + getLists() + }) + \ No newline at end of file