Release/test 合并上生产 #2

Merged
admin merged 736 commits from release/test into main 2026-09-17 11:50:56 +08:00
4 changed files with 22 additions and 1 deletions
Showing only changes of commit 462d02efd5 - Show all commits
@@ -96,3 +96,10 @@ export async function updateFbaAppointment(appointmentNo: string, payload: Updat
)
return unwrapApiResponse(response)
}
export async function updateInboundPlan(planNo: string, payload: { customerId: string; overseasWarehouseId: string; warehouseCode?: string; warehouseName?: string; version: number }) {
const response = await overseasHttp.put<ApiEnvelope<InboundOrderSummaryDto>, ApiEnvelope<InboundOrderSummaryDto>>(
`/platform/v1/last-leg/inbound-plans/${encodeURIComponent(planNo)}`, payload,
)
return unwrapApiResponse(response)
}
@@ -116,6 +116,10 @@ export async function listInventoryBalances(query: InventoryBalanceQuery) {
return normalizeOverseasPage(unwrapApiResponse(response))
}
export async function downloadInventoryBalances(query: Partial<InventoryBalanceQuery>) {
return overseasHttp.get('/platform/v1/last-leg/inventory/balances/export', { params: query, responseType: 'blob' })
}
export async function getInventorySummary(query: InventoryBalanceQuery) {
const response = await overseasHttp.get<ApiEnvelope<InventoryDashboardDto>, ApiEnvelope<InventoryDashboardDto>>(
'/platform/v1/last-leg/inventory/summary', { params: params({ ...query, page: 1, size: 200 }) },
@@ -159,3 +163,7 @@ export async function listInventoryLedger(query: InventoryLedgerQuery) {
)
return normalizeOverseasPage(unwrapApiResponse(response))
}
export async function downloadInventoryLedger(query: Partial<InventoryLedgerQuery>) {
return overseasHttp.get('/platform/v1/last-leg/inventory/ledger/export', { params: query, responseType: 'blob' })
}
@@ -187,6 +187,10 @@ export async function getLastMileOrder(orderId: string) {
return unwrapApiResponse(response)
}
export async function downloadLastMileOrders(query: Partial<LastMileOrderQuery>) {
return overseasHttp.get('/platform/v1/last-leg/orders/export', { params: query, responseType: 'blob' })
}
export async function createLastMileOrderFee(orderId: string, payload: CreateLastMileFeePayload) {
const response = await overseasHttp.post<ApiEnvelope<LastMileFeeDto>, ApiEnvelope<LastMileFeeDto>>(
`/platform/v1/last-leg/orders/${encodeURIComponent(orderId)}/fees`, payload,
@@ -12,7 +12,7 @@ import ListPageLayout from '@/shared/components/ListPageLayout.vue'
import LoadErrorState from '@/shared/components/LoadErrorState.vue'
import OperationErrorToast from '@/shared/components/OperationErrorToast.vue'
import QueryToolbar, { type QueryField, type QueryModel } from '@/shared/components/QueryToolbar.vue'
import { convertLastMileOrderToInboundPlan, listLastMileOrders, setLastMileOrderDetained, transferLastMileOrders } from '../api/lastMileOrders'
import { convertLastMileOrderToInboundPlan, listLastMileOrders, setLastMileOrderDetained, transferLastMileOrders, downloadLastMileOrders } from '../api/lastMileOrders'
import { useAccessPreviewStore } from '@/core/access/accessPreview'
import { overseasWarehousePermissions as permission } from '../permissions'
import { toLastMileOrderListItem } from '../lastMilePresentation'
@@ -28,6 +28,8 @@ const pageSize = ref(10)
const total = ref(0)
const selectedRows = ref<LastMileOrderListItem[]>([])
const actionLoading = ref(false)
const exportLoading = ref(false)
async function exportOrders() { exportLoading.value = true; try { const blob = await downloadLastMileOrders(filters.value); const url = URL.createObjectURL(blob as Blob); const a = document.createElement('a'); a.href = url; a.download = '尾程订单.csv'; a.click(); URL.revokeObjectURL(url) } finally { exportLoading.value = false } }
const actionError = ref<ApiErrorDetails | null>(null)
const transferOpen = ref(false)
const detainedOpen = ref(false)