diff --git a/dist.tar.gz b/dist.tar.gz index fb618187..e7c6410a 100644 Binary files a/dist.tar.gz and b/dist.tar.gz differ diff --git a/src/api/storage/receiving.ts b/src/api/storage/receiving.ts index cec39076..29b68a1e 100644 --- a/src/api/storage/receiving.ts +++ b/src/api/storage/receiving.ts @@ -230,7 +230,7 @@ export function completeReceiving(data: any): Promise { }) } -// 绑定货主到收货单(入参示例: { receiving_id, store_id }) +// 绑定货主到收货单 export function bindReceivingStore(data: any): Promise { return request({ url: '/system', @@ -242,4 +242,17 @@ export function bindReceivingStore(data: any): Promise { }, data: data }) +} + +export function bindDetailProduct(data: any): Promise { + return request({ + url: '/system', + method: 'post', + params: { + method: 'storage.receiving.bindDetailProduct', + v, + timestamp: new Date().getTime() + }, + data: data, + }) } \ No newline at end of file diff --git a/src/api/warehouse.ts b/src/api/warehouse.ts index 293ca00a..2a90ca3f 100644 --- a/src/api/warehouse.ts +++ b/src/api/warehouse.ts @@ -213,3 +213,87 @@ export function updateSpaceInfo(data:any){ isSystemApi: true } as any) } + +export function createRack(data: any) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'warehouse.createRack', + v: '1.0', + timestamp: new Date().getTime() + }, + data, + isSystemApi: true + } as any) +} + +export function getPickPath(data: any) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'warehouse.getPickPath', + v: '1.0', + timestamp: new Date().getTime() + }, + data, + isSystemApi: true + } as any) +} + +export function updateRackPosition(data: any) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'warehouse.updateRackPosition', + v: '1.0', + timestamp: new Date().getTime() + }, + data, + isSystemApi: true + } as any) +} + +export function recalculatePickPath(warehouse_id: any) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'warehouse.recalculatePickPath', + v: '1.0', + timestamp: new Date().getTime() + }, + data: { warehouse_id }, + isSystemApi: true + } as any) +} + +export function updateNeighbors(warehouse_id: any) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'warehouse.updateNeighbors', + v: '1.0', + timestamp: new Date().getTime() + }, + data: { warehouse_id }, + isSystemApi: true + } as any) +} + +export function getAreaRacks(area_id: any) { + return request({ + url: '/system', + method: 'post', + params: { + method: 'warehouse.getAreaRacks', + v: '1.0', + timestamp: new Date().getTime() + }, + data: { area_id }, + isSystemApi: true + } as any) +} diff --git a/src/layout/component/Navbar.vue b/src/layout/component/Navbar.vue index db553366..fe6c5cb9 100644 --- a/src/layout/component/Navbar.vue +++ b/src/layout/component/Navbar.vue @@ -63,7 +63,7 @@ {{ role.store_name }} | {{ role.real_name }} @@ -343,10 +343,18 @@ onMounted(() => { .text-warning { color: #e6a23c; } .text-success { color: #67c23a; } .user-dropdown { - .on { - background-color: #ecf5ff; - color: #409EFF; + :deep(.current-role) { + background-color: rgba(0, 0, 0, .025) !important; + color: #409EFF !important; font-weight: bold; + cursor: default; + } + + :deep(.other-role) { + &:hover { + background-color: transparent !important; + color: inherit !important; + } } } diff --git a/src/settings.ts b/src/settings.ts index 69e23e50..eac49ef0 100644 --- a/src/settings.ts +++ b/src/settings.ts @@ -29,5 +29,5 @@ export default { * @type {boolean} true | false * @description Whether expand the shortcut key area */ - shortcutExpanded: true + shortcutExpanded: false } diff --git a/src/views/stock/stock/component/add.vue b/src/views/stock/stock/component/add.vue index 2c633705..4d17dad7 100644 --- a/src/views/stock/stock/component/add.vue +++ b/src/views/stock/stock/component/add.vue @@ -343,7 +343,19 @@ watch(() => props.initialStore, (val) => { } }, { immediate: true }) -defineExpose({ formData }) +// Reset non-form fields if any or complex reset logic +const resetForm = () => { + lastItemCode.value = '' + if (formRef.value) { + formRef.value.resetFields() + } + formData.managementFlags = [] + formData.enable_box_spec = false + handleBoxSpecToggle(false) + ElMessage.info('表单已重置') +} + +defineExpose({ formData, resetForm }) const originalData = reactive({}) @@ -518,21 +530,6 @@ const handleSave = async () => { }) } -const resetForm = () => { - lastItemCode.value = '' - if (formRef.value) { - formRef.value.resetFields() - } - // Reset non-form fields if any or complex reset logic - formData.managementFlags = [] - formData.enable_box_spec = false - handleBoxSpecToggle(false) - - // Restore original data if needed (Vue 2 logic had originalData) - // Object.assign(formData, originalData) - ElMessage.info('表单已重置') -} - const handleCustomChange = (value: any) => { console.log('违禁品类型变更:', value) } diff --git a/src/views/storage/receiving/component/DetailsPanel.vue b/src/views/storage/receiving/component/DetailsPanel.vue index b95d01b7..10b7b500 100644 --- a/src/views/storage/receiving/component/DetailsPanel.vue +++ b/src/views/storage/receiving/component/DetailsPanel.vue @@ -10,24 +10,41 @@ :label="field.label" :prop="field.prop" > - + + + \ No newline at end of file diff --git a/src/views/warehouse/PathManagement.vue b/src/views/warehouse/PathManagement.vue new file mode 100644 index 00000000..b95d9975 --- /dev/null +++ b/src/views/warehouse/PathManagement.vue @@ -0,0 +1,448 @@ + + + + + \ No newline at end of file diff --git a/src/views/warehouse/RackPositionEditor.vue b/src/views/warehouse/RackPositionEditor.vue new file mode 100644 index 00000000..44e679f0 --- /dev/null +++ b/src/views/warehouse/RackPositionEditor.vue @@ -0,0 +1,653 @@ + + + + + \ No newline at end of file diff --git a/src/views/warehouse/WarehouseDialog.vue b/src/views/warehouse/WarehouseDialog.vue index 7f82a562..d2c5a1c8 100644 --- a/src/views/warehouse/WarehouseDialog.vue +++ b/src/views/warehouse/WarehouseDialog.vue @@ -3,6 +3,7 @@ title="添加仓库" v-model="internalVisible" width="600px" + align-center @close="handleClose" > - + diff --git a/src/views/warehouse/index.vue b/src/views/warehouse/index.vue index 552705e9..8a305064 100644 --- a/src/views/warehouse/index.vue +++ b/src/views/warehouse/index.vue @@ -27,18 +27,52 @@ @@ -91,6 +125,9 @@ import ZoneDialog from './ZoneDialog.vue' import WarehouseDialog from './WarehouseDialog.vue' import zoneInfo from './zoneInfo.vue' import spaceCard from './spaceCard.vue' +import PathManagement from './PathManagement.vue' +import RackPositionEditor from './RackPositionEditor.vue' +import AreaRacksList from './AreaRacksList.vue' import * as warehouseApi from '@/api/warehouse' // 仓库数据 @@ -102,6 +139,11 @@ const zoneData = ref(null) // 货架数据 const selectedRack = ref(null) +const selectedArea = ref(null) +const areaRackList = ref([]) + +// 右侧标签页状态 +const activeRightTab = ref('spaces') // 缩放控制 const scale = ref(1) @@ -163,11 +205,23 @@ const handleWarehouseSelect = async (warehouse: any) => { } // 选择仓库元素 -const handleZoneSelect = (zone: any) => { +const handleZoneSelect = async (zone: any) => { if (zone.type === 'rack') { selectedRack.value = zone + selectedArea.value = null + } else if (zone.type === 'area') { + selectedArea.value = zone + selectedRack.value = null + // 加载区域货架列表 + await loadAreaRacks(zone.id) + // 更新平面图显示 + if (zone.type !== 'pick_start') { + zoneData.value = zone + } } else { - selectedRack.value = null // 更新平面图显示 + selectedRack.value = null + selectedArea.value = null + // 更新平面图显示 if (zone.type !== 'pick_start') { zoneData.value = zone } @@ -276,6 +330,88 @@ const handleWarehouseDialogSuccess = async () => { await loadWarehouseList() } +// 加载区域货架列表 +const loadAreaRacks = async (areaId: number) => { + try { + const response: any = await warehouseApi.getAreaRacks(areaId) + if (response.code === 200) { + areaRackList.value = response.racks || [] + } + } catch (error) { + console.error('加载区域货架列表失败:', error) + } +} + +// 路径高亮处理 +const handlePathHighlight = (nodeData: any) => { + if (warehouseViewer.value) { + // 在平面图中高亮节点 + warehouseViewer.value.highlightNode?.(nodeData) + } +} + +// 路径显示处理 +const handlePathShow = (pathData: any[]) => { + if (warehouseViewer.value) { + // 在平面图中显示路径 + warehouseViewer.value.showPath?.(pathData) + } +} + +// 货架位置更新处理 +const handlePositionUpdate = async (rackId: number, position: any) => { + // 更新本地数据 + if (selectedRack.value?.id === rackId) { + Object.assign(selectedRack.value, position) + } + + // 刷新仓库数据 + await refreshCurrentWarehouse() + + // 刷新区域货架列表 + if (selectedArea.value?.id) { + await loadAreaRacks(selectedArea.value.id) + } +} + +// 货架位置预览处理 +const handlePositionPreview = (rackId: number, position: any) => { + if (warehouseViewer.value) { + // 在平面图中预览位置 + warehouseViewer.value.previewRackPosition?.(rackId, position) + } +} + +// 区域货架选择处理 +const handleAreaRackSelect = (rack: any) => { + selectedRack.value = rack + activeRightTab.value = 'spaces' // 切换到空间管理标签页 + + nextTick(() => { + if (warehouseViewer.value) { + // 在平面图中高亮货架 + warehouseViewer.value.highlightRack?.(rack) + } + }) +} + +// 区域货架编辑处理 +const handleAreaRackEdit = (rack: any) => { + selectedRack.value = rack + activeRightTab.value = 'position' // 切换到位置管理标签页 +} + +// 区域货架批量更新处理 +const handleAreaRackBatchUpdate = async (racks: any[]) => { + // 刷新仓库数据 + await refreshCurrentWarehouse() + + // 刷新区域货架列表 + if (selectedArea.value?.id) { + await loadAreaRacks(selectedArea.value.id) + } +} + onMounted(() => { loadWarehouseList() }) @@ -306,6 +442,23 @@ onMounted(() => { &.right-sidebar { flex-shrink: 0; width: 600px; + + .right-tabs { + height: 100%; + display: flex; + flex-direction: column; + + :deep(.el-tabs__content) { + flex: 1; + overflow-y: auto; + + .el-tab-pane { + display: flex; + flex-direction: column; + gap: 12px; + } + } + } } } diff --git a/src/需求文档.txt b/src/需求文档.txt index 040fbb64..215c706b 100644 --- a/src/需求文档.txt +++ b/src/需求文档.txt @@ -1,3 +1,1258 @@ +用户模块 + +user.info返回数据: +{ + "flag": "success", + "code": 200, + "message": "获取成功{\"device\":\"desktop\"}", + "success": true, + "data": { + "id": 3, + "status": 1, + "employees": [ + { + "id": 34, + "store_id": 1000028, + "store_name": "天豹云仓", + "is_primary": 1, + "real_name": "殷建铭", + "auth_end": "2099-12-26", + "role_type": "warehouse" + }, + { + "id": 33, + "store_id": 1000000, + "store_name": "测试货主1111", + "is_primary": 0, + "real_name": "殷建铭", + "auth_end": null, + "role_type": "store" + }, + { + "id": 31, + "store_id": 100000, + "store_name": "测试仓", + "is_primary": 0, + "real_name": "殷建铭", + "auth_end": "2099-11-08", + "role_type": "warehouse" + } + ], + "auth_end": "2099-12-26", + "employees_id": 34, + "employees_name": "殷建铭", + "loginIp": "188.253.4.44", + "store_id": 1000028, + "store_name": "天豹云仓", + "menus": [ + { + "path": "/auth/approve", + "component": "@/views/auth/approve", + "name": "Auth Approve", + "redirect": "", + "meta": { + "title": "成员加入审核", + "icon": null + }, + "hidden": true, + "alwaysShow": false, + "children": [] + }, + { + "path": "/order", + "component": "", + "name": "Order", + "redirect": "", + "meta": { + "title": "订单", + "icon": "" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "orderManagement", + "component": "@/views/order/index", + "name": "OrderManagement", + "redirect": "", + "meta": { + "title": "订单管理", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "orderSetting", + "component": "@/views/order/setting", + "name": "OrderSetting", + "redirect": null, + "meta": { + "title": "订单策略设置", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/stock", + "component": "Layout", + "name": "Stock", + "redirect": null, + "meta": { + "title": "商品", + "icon": "el-icon-s-goods" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "stock", + "component": "@/views/stock/index", + "name": "Stock Info", + "redirect": null, + "meta": { + "title": "商品资料", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "store_stock", + "component": "Layout", + "name": "Store Stock", + "redirect": null, + "meta": { + "title": "货主商品", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "combo_stock", + "component": "Layout", + "name": "Combo Stock", + "redirect": null, + "meta": { + "title": "组合商品", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/storage", + "component": "Layout", + "name": "Storage", + "redirect": null, + "meta": { + "title": "库存", + "icon": "el-icon-s-data" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "stock", + "component": "Layout", + "name": "Stock Storage", + "redirect": null, + "meta": { + "title": "商品库存", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "receiving", + "component": "@/views/storage/receiving", + "name": "Receiving", + "redirect": null, + "meta": { + "title": "收货列表", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "entry", + "component": "@/views/storage/entry", + "name": "Entry Order", + "redirect": null, + "meta": { + "title": "入库单", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "stockout", + "component": "@/views/storage/stockout", + "name": "Stock out", + "redirect": null, + "meta": { + "title": "出库单", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "inventory", + "component": "@/views/storage/inventory", + "name": "Inventory", + "redirect": null, + "meta": { + "title": "盘点", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "log", + "component": "Layout", + "name": "Commodity Inbound and Outbound Log", + "redirect": null, + "meta": { + "title": "商品出入库日志", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "exception", + "component": "Layout", + "name": "Exception", + "redirect": null, + "meta": { + "title": "异常处理", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/material", + "component": "Layout", + "name": "Material", + "redirect": null, + "meta": { + "title": "物料", + "icon": "el-icon-s-cooperation" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "materialInfo", + "component": "Layout", + "name": "Material Info", + "redirect": null, + "meta": { + "title": "物料资料", + "icon": "el-icon-info" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "materialStorage", + "component": "Layout", + "name": "materialStorage", + "redirect": null, + "meta": { + "title": "物料库存", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "log", + "component": "Layout", + "name": "Log", + "redirect": null, + "meta": { + "title": "物料出入库日志", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/warehouse", + "component": "Layout", + "name": "Warehouse", + "redirect": "/warehouse/warehouse", + "meta": { + "title": "仓位", + "icon": "el-icon-s-grid" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "warehouse", + "component": "@/views/warehouse/index", + "name": "WarehouseZone", + "redirect": null, + "meta": { + "title": "仓库区位", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/data", + "component": "Layout", + "name": "Data", + "redirect": null, + "meta": { + "title": "数据", + "icon": "el-icon-s-marketing" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "/store", + "component": "Layout", + "name": "Store", + "redirect": null, + "meta": { + "title": "货主", + "icon": "el-icon-s-custom" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "store", + "component": "@/views/store/index", + "name": "stores", + "redirect": null, + "meta": { + "title": "货主列表", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/express", + "component": "Layout", + "name": "Express", + "redirect": null, + "meta": { + "title": "物流", + "icon": "el-icon-truck" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "/finance", + "component": "Layout", + "name": "Finance", + "redirect": null, + "meta": { + "title": "财务", + "icon": "el-icon-s-finance" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "bill", + "component": "Layout", + "name": "Bill", + "redirect": null, + "meta": { + "title": "账单", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "daily", + "component": "Layout", + "name": "Daily", + "redirect": null, + "meta": { + "title": "流水", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "account", + "component": "Layout", + "name": "Account", + "redirect": null, + "meta": { + "title": "账户", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "statistics", + "component": "Layout", + "name": "Statistics", + "redirect": null, + "meta": { + "title": "统计", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "valuation", + "component": "Layout", + "name": "Valuation", + "redirect": null, + "meta": { + "title": "定价", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "receivable", + "component": "Layout", + "name": "Receivable", + "redirect": null, + "meta": { + "title": "应收", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "encoding", + "component": "Layout", + "name": "Encoding", + "redirect": null, + "meta": { + "title": "编码设置", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "video", + "component": "Layout", + "name": "Video", + "redirect": null, + "meta": { + "title": "视频监控", + "icon": "el-icon-video-camera-solid" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "/setting", + "component": "Layout", + "name": "Setting", + "redirect": null, + "meta": { + "title": "设置", + "icon": "el-icon-s-tools" + }, + "hidden": false, + "alwaysShow": false, + "children": [ + { + "path": "encoding", + "component": "Layout", + "name": "Encoding2", + "redirect": null, + "meta": { + "title": "仓库编码设置", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "printTemplate", + "component": "@/views/system/setting/printTemplate/index", + "name": "PrintTemplate", + "redirect": null, + "meta": { + "title": "打印模板设置", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "printStation", + "component": "@/views/system/print/station", + "name": "PrintStation", + "redirect": null, + "meta": { + "title": "打印台管理", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "account", + "component": "@/views/account/index", + "name": "userAccount", + "redirect": null, + "meta": { + "title": "账号管理", + "icon": "user" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "open", + "component": "Layout", + "name": "Open", + "redirect": null, + "meta": { + "title": "第三方开发接口", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "permission", + "component": "@/views/system/setting/permission/index", + "name": "Permission", + "redirect": null, + "meta": { + "title": "权限管理", + "icon": "setting" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "basicManagement", + "component": "@/views/system/setting/index", + "name": "BasicManagement", + "redirect": "/system/basicManagement/permission", + "meta": { + "title": "基础设置", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "StoreManagement", + "component": "@/views/system/setting/index", + "name": "StoreManagement", + "redirect": "/system/storeManagement/store", + "meta": { + "title": "主体设置", + "icon": null + }, + "hidden": false, + "alwaysShow": false, + "children": [] + }, + { + "path": "role", + "component": "@/views/system/setting/role/index", + "name": "Role", + "redirect": null, + "meta": { + "title": "角色管理", + "icon": "role" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ] + }, + { + "path": "/system", + "component": "Layout", + "name": "System", + "redirect": null, + "meta": { + "title": "系统", + "icon": "el-icon-s-tools" + }, + "hidden": false, + "alwaysShow": false, + "children": [] + } + ], + "permissions": [ + "dashboard.expressRatio", + "dashboard.storeBaseData", + "dashboard.auth", + "store.getStoreRoles", + "store.auditApply", + "warehouse.getWarehouseZones", + "warehouse.create", + "warehouse.getWarehouseTree", + "warehouse.detail", + "warehouse.update", + "warehouse.delete", + "warehouse.updateSpaceInfo", + "stock.saveWarehouseStock", + "stock.saveWarehouseStockBarcode", + "stock.bindItem", + "stock.unbindItem", + "index.ReferenceFile", + "warehouseExport", + "warehouseRecycle", + "stock.createWarehouseStock", + "stock.handleBatchDelete", + "stock.handleBatchChange", + "storage.receiving.create", + "storage.receiving.getReceivingDetail", + "storage.receiving.batchCancelReceiving", + "index.getCOSUploadConfig", + "index.getExpressList", + "index.tryAutoTranslateNewKeys", + "index.uploadSuccessNotify", + "order.getOrderModels", + "stock.warehouse.bindItem", + "stock.warehouse.createProhibited", + "stock.warehouse.createUnit", + "stock.warehouse.createWarehouseStock", + "stock.warehouse.deleteProhibited", + "stock.warehouse.deleteUnit", + "stock.warehouse.handleBatchChange", + "stock.warehouse.handleBatchDelete", + "stock.warehouse.saveWarehouseStock", + "stock.warehouse.saveWarehouseStockBarcode", + "stock.warehouse.unbindItem", + "storage.receiving.addItem", + "storage.receiving.removeItem", + "storage.receiving.saveReceiving", + "warehouse.createRack", + "warehouse.createRackWithSpaces", + "warehouse.recalculatePickPath", + "warehouse.updateNeighbors", + "warehouse.updateRackPosition", + "stock.getInfo", + "printer.bind", + "setting.permission.add", + "setting.permission.delete", + "setting.permission.update" + ], + "userRole": "customer", + "platform_code": "web", + "avatar": "" + }, + "timestamp": 1775464490 +} + + + +---------- +仓库模块 + +warehouse.getWarehouseZones 接口 + +返回数据: +{ + "flag": "success", + "code": 200, + "message": "获取成功", + "zones": [ + { + "id": 46, + "label": "分仓3", + "code": "02", + "length": 10000, + "width": 10000, + "height": 5000, + "areaCount": 0, + "rackCount": 0, + "totalSpaces": 0, + "createdAt": "2026-03-20T09:43:03.000Z" + }, + { + "id": 33, + "label": "分仓2", + "code": "WH2", + "length": 10000, + "width": 10000, + "height": 5000, + "areaCount": 0, + "rackCount": 0, + "totalSpaces": 0, + "createdAt": "2025-12-25T13:26:10.000Z" + }, + { + "id": 32, + "label": "分仓1", + "code": "WH2", + "length": 10000, + "width": 10000, + "height": 5000, + "areaCount": 0, + "rackCount": 0, + "totalSpaces": 0, + "createdAt": "2025-12-25T13:25:53.000Z" + }, + { + "id": 25, + "label": "主仓", + "code": "WH", + "length": 10000, + "width": 5000, + "height": 500, + "areaCount": 2, + "rackCount": 9, + "totalSpaces": 1898, + "createdAt": "2025-12-25T08:20:51.000Z" + } + ], + "timestamp": 1775459453 +} + +----- +warehouse.getWarehouseTree 接口 + +Params (1) +名称 类型 必填 说明 +warehouseId number 是 warehouseId 参数 + +返回数据: +{ + "flag": "success", + "code": 200, + "message": "获取成功", + "warehouseRoot": { + "id": 25, + "label": "WH - 主仓", + "type": "warehouse", + "code": "WH", + "name": "主仓", + "children": [ + { + "id": 41, + "label": "A3603 - E2", + "type": "area", + "code": "A3603", + "name": "E2", + "parentId": 25, + "children": [], + "data": { + "x": 500, + "y": 1000, + "z": 0, + "length": 500, + "width": 500, + "height": 300, + "rackColumns": 5, + "rackRows": 5, + "rackLevels": 2, + "direction": "north", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2026-03-05T08:38:49.000Z" + } + }, + { + "id": 26, + "label": "A4296 - E1", + "type": "area", + "code": "A4296", + "name": "E1", + "parentId": 25, + "children": [ + { + "id": 36, + "label": "E01 - E01", + "type": "rack", + "code": "E01", + "name": "E01", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 1500, + "z": 0, + "length": 7200, + "width": 120, + "height": 760, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "south", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T14:13:21.000Z" + } + }, + { + "id": 35, + "label": "E02 - E02", + "type": "rack", + "code": "E02", + "name": "E02", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 1380, + "z": 0, + "length": 7200, + "width": 120, + "height": 760, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "north", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T14:03:30.000Z" + } + }, + { + "id": 34, + "label": "E03 - E03", + "type": "rack", + "code": "E03", + "name": "E03", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 1000, + "z": 0, + "length": 7200, + "width": 120, + "height": 760, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "south", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T14:01:29.000Z" + } + }, + { + "id": 31, + "label": "E04 - E04", + "type": "rack", + "code": "E04", + "name": "E04", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 880, + "z": 0, + "length": 7200, + "width": 120, + "height": 760, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "north", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T08:55:49.000Z" + } + }, + { + "id": 30, + "label": "E05 - E05", + "type": "rack", + "code": "E05", + "name": "E05", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 500, + "z": 0, + "length": 7200, + "width": 120, + "height": 760, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "south", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T08:49:39.000Z" + } + }, + { + "id": 29, + "label": "E06 - E06", + "type": "rack", + "code": "E06", + "name": "E06", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 380, + "z": 0, + "length": 7200, + "width": 120, + "height": 760, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "north", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T08:30:51.000Z" + } + }, + { + "id": 27, + "label": "E07 - E07", + "type": "rack", + "code": "E07", + "name": "E07", + "parentId": 26, + "children": [], + "data": { + "x": 400, + "y": 0, + "z": 0, + "length": 7200, + "width": 120, + "height": 720, + "rackColumns": 30, + "rackRows": 4, + "rackLevels": 2, + "direction": "south", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T08:22:16.000Z" + } + }, + { + "id": 28, + "label": "E08 - E08", + "type": "rack", + "code": "E08", + "name": "E08", + "parentId": 26, + "children": [], + "data": { + "x": 0, + "y": 0, + "z": 0, + "length": 1680, + "width": 120, + "height": 500, + "rackColumns": 7, + "rackRows": 4, + "rackLevels": 2, + "direction": "east", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T08:25:21.000Z" + } + }, + { + "id": 37, + "label": "E09 - E09", + "type": "rack", + "code": "E09", + "name": "E09", + "parentId": 26, + "children": [], + "data": { + "x": 2000, + "y": 1740, + "z": 0, + "length": 4320, + "width": 60, + "height": 300, + "rackColumns": 27, + "rackRows": 3, + "rackLevels": 2, + "direction": "north", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T14:19:46.000Z" + } + } + ], + "data": { + "x": 1500, + "y": 0, + "z": 0, + "length": 7600, + "width": 1800, + "height": 300, + "rackColumns": 5, + "rackRows": 5, + "rackLevels": 2, + "direction": "north", + "color": "#3B82F6", + "isActive": true, + "createdAt": "2025-12-25T08:21:06.000Z" + } + } + ], + "data": { + "x": 0, + "y": 0, + "z": 0, + "length": 10000, + "width": 5000, + "height": 500, + "color": "#96ceb4", + "isActive": true, + "createdAt": "2025-12-25T08:20:51.000Z", + "storeInfo": null + } + }, + "timestamp": 1775459470 +} + +----- +warehouse.getChildren 接口 + +Params (1) +名称 类型 必填 说明 +zoneId number 是 zoneId 参数 + +----- +warehouse.create 接口 + +----- +warehouse.update 接口 + +Params (17) +名称 类型 必填 说明 +id number 是 id 参数 +aisles string 否 aisles 参数 +cell_height string 否 cell_height 参数 +cell_length string 否 cell_length 参数 +cell_width string 否 cell_width 参数 +direction string 否 direction 参数 +height number 否 height 参数 +length number 否 length 参数 +rack_columns string 否 rack_columns 参数 +rack_levels string 否 rack_levels 参数 +rack_rows string 否 rack_rows 参数 +width number 否 width 参数 +x number 否 x 参数 +y number 否 y 参数 +z number 否 z 参数 +zone_code string 否 zone_code 参数 +zone_name string 否 zone_name 参数 + +----- +warehouse.delete 接口 + +Params (1) +名称 类型 必填 说明 +id number 是 id 参数 + +----- +warehouse.detail 接口 + +Params (1) +名称 类型 必填 说明 +id number 是 id 参数 + +----- +warehouse.checkBarcodeUnique 接口 + +Params (2) +名称 类型 必填 说明 +barcode string 是 barcode 参数 +id number 是 id 参数 + +----- +warehouse.toggleActive 接口 + +Params (2) +名称 类型 必填 说明 +id number 是 id 参数 +isActive string 否 isActive 参数 + +----- +Params (1) +名称 类型 必填 说明 +id number 是 id 参数 + +----- +warehouse.createRack 接口 + +Params (15) +名称 类型 必填 说明 +height number 是 height 参数 +length number 是 length 参数 +rack_columns number 是 rack_columns 参数 +rack_levels number 是 rack_levels 参数 +rack_rows number 是 rack_rows 参数 +warehouse_id number 是 warehouse_id 参数 +width number 是 width 参数 +x number 是 x 参数 +y number 是 y 参数 +zone_code string 是 zone_code 参数 +zone_name string 是 zone_name 参数 +color string 否 color 参数 +direction string 否 direction 参数 +parent_id number 否 parent_id 参数 +z number 否 z 参数 + +----- +warehouse.getPickPath 接口 + +Params (4) +名称 类型 必填 说明 +warehouse_id number 是 warehouse_id 参数 +include_spaces string 否 include_spaces 参数 +limit number 否 limit 参数 +sort_by string 否 sort_by 参数 + +----- +warehouse.updateRackPosition 接口 + +Params (4) +名称 类型 必填 说明 +x number 是 x 参数 +y number 是 y 参数 +rack_id number 否 rack_id 参数 +z number 否 z 参数 + +----- +warehouse.recalculatePickPath 接口 + +Params (1) +名称 类型 必填 说明 +warehouse_id number 是 warehouse_id 参数 + +----- +warehouse.updateNeighbors 接口 + +Params (1) +名称 类型 必填 说明 +warehouse_id number 是 warehouse_id 参数 + +----- +warehouse.getAreaRacks 接口 + +Params (1) +名称 类型 必填 说明 +area_id number 是 area_id 参数 + +----- +warehouse.getSpacesByRack 接口 + +Params (1) +名称 类型 必填 说明 +id number 是 id 参数 + + +----- +warehouse.createRackWithSpaces 接口 + +Params (1) +名称 类型 必填 说明 +id number 是 id 参数 + +----- +warehouse.getSpaceInfo 接口 + +Params (1) +名称 类型 必填 说明 +id number 否 id 参数 + +----- +warehouse.updateSpaceInfo 接口 + +Params (6) +名称 类型 必填 说明 +id number 是 id 参数 +custom_barcode string 否 custom_barcode 参数 +custom_name string 否 custom_name 参数 +location_type_id number 否 location_type_id 参数 +pick_sequence string 否 pick_sequence 参数 +space_status string 否 space_status 参数 + + + + + + + + +------- 仓货签约模块 storeWarehouse.store.list diff --git a/日志.md b/日志.md index 680a4e85..266a14f5 100644 --- a/日志.md +++ b/日志.md @@ -206,3 +206,38 @@ stock获取回收站商品接口复用了商品信息接口stock.warehouse.list 完善接口、功能设计,排除故障接口,测试接口功能。 完善收货单、货主功能。 熟悉开源远程电脑项目billd-desk,准备学习开发相关功能应用。 + +----- +2026.4.4 +一、今日完成 +-修复权限管理PDA页面无法添加图标问题。 +-添加店铺仓库 API 功能和详情组件。 +-实现了用于管理店铺仓库操作的 API 功能,包括列表、签收、解绑、重命名以及配置奇门。 +-添加优化“货主”页面及其相关功能。 +-修复收货单图片不显示问题。 +- + +二、问题记录 +无 + +三、后续计划 +完善接口、功能设计,排除故障接口,测试接口功能。 +完善收货单、货主功能。 +熟悉开源远程电脑项目billd-desk,准备学习开发相关功能应用。 + +----- +2026.4.6 +一、今日完成 +-优化收货单页面及相关接口功能。 +-库位管理新增warehouse.getPickPath等接口和功能,优化页面相关框架。 +- 优化layout页面相关组件样式、功能使用逻辑。 +- 收货单新增货主绑定、商品关联功能。 +-优化收货单及其组件页面样式。 + +二、问题记录 +warehouse.update接口is_active未更新。 + +三、后续计划 +完善接口、功能设计,排除故障接口,测试接口功能。 +完善库位管理以及其他功能。 +熟悉开源远程电脑项目billd-desk,准备学习开发相关功能应用。