diff --git a/src/api/FulfillmentAPI.ts b/src/api/FulfillmentAPI.ts index b7ddded..772d786 100644 --- a/src/api/FulfillmentAPI.ts +++ b/src/api/FulfillmentAPI.ts @@ -1,6 +1,17 @@ import { axios } from "timi-web-api"; import { withCurrentStoreId } from "@/utils/store"; -import type { FulfillmentActionRequest, FulfillmentPage, FulfillmentPageResult, FulfillmentPrepareStockRequest, FulfillmentRevokeRequest, OrderFulfillment, OrderFulfillmentCreateRequest } from "@/types/Fulfillment"; +import type { + FulfillmentActionRequest, + FulfillmentPage, + FulfillmentPageResult, + FulfillmentPrepareStockRequest, + FulfillmentRevokeRequest, + OrderFulfillment, + OrderFulfillmentCreateRequest, + QuickFulfillmentCreateRequest, + QuickFulfillmentSku, + QuickFulfillmentSourceOrder +} from "@/types/Fulfillment"; const URI = "/gao/order/fulfillment"; async function list(page: FulfillmentPage): Promise> { @@ -15,6 +26,15 @@ async function create(request: OrderFulfillmentCreateRequest): Promise { return await axios.post(`${URI}/create-and-verify`, request); } +async function quickSkuList(customerId: string): Promise { + return await axios.post(`${URI}/quick/sku-list`, { customerId }); +} +async function quickSourceOrderList(customerId: string, skuIdList: string[]): Promise { + return await axios.post(`${URI}/quick/source-order-list`, { customerId, skuIdList }); +} +async function quickCreate(request: QuickFulfillmentCreateRequest): Promise { + return await axios.post(`${URI}/quick/create`, request); +} async function prepareStock(request: FulfillmentPrepareStockRequest): Promise { return await axios.post(`${URI}/prepare-stock`, request); } @@ -31,4 +51,4 @@ async function revoke(request: FulfillmentRevokeRequest): Promise diff --git a/src/components/productSelector/ProductSelectPopup.vue b/src/components/productSelector/ProductSelectPopup.vue index 8926210..e5b622d 100644 --- a/src/components/productSelector/ProductSelectPopup.vue +++ b/src/components/productSelector/ProductSelectPopup.vue @@ -3,8 +3,10 @@ v-model="popupVisible" title="选择产品 SKU" height="80vh" - right-button-text="" - @left-button-click="close" + left-button-text="取消" + :right-button-text="props.selectionMode === 'multiple' ? '完成' : ''" + @left-button-click="cancelSelection" + @right-button-click="confirmSelection" >