From e6b7593ab3157fcc63460639ebd0e7937e7592f2 Mon Sep 17 00:00:00 2001 From: zhangqian <zhangqian@123.com> Date: 星期二, 02 七月 2024 15:31:02 +0800 Subject: [PATCH] 新建仓库的默认位置名称为仓库名 --- controllers/warehouse.go | 4 ++-- controllers/location.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/controllers/location.go b/controllers/location.go index ecd21c0..5a4a3f9 100644 --- a/controllers/location.go +++ b/controllers/location.go @@ -40,7 +40,7 @@ } params.JointName = first.JointName + "/" + params.Name if first.WarehouseId != 0 { - params.WarehouseId = first.Id + params.WarehouseId = first.WarehouseId } else { //鏍规嵁浠撳簱缂╁啓鏌ヨ浠撳簱 houseCode := strings.Split(first.JointName, "/")[0] diff --git a/controllers/warehouse.go b/controllers/warehouse.go index f9b54c9..14d63c3 100644 --- a/controllers/warehouse.go +++ b/controllers/warehouse.go @@ -55,8 +55,8 @@ } //鍒涘缓榛樿浣嶇疆 location := &models.Location{ - Name: "榛樿浣嶇疆", - JointName: params.Code + "/榛樿浣嶇疆", + Name: params.Name, + JointName: params.Name, Type: constvar.LocationTypeInternal, ReplenishLocation: true, ParentId: id, -- Gitblit v1.8.0