Commit b2f05158 by mushishixian

修复

parent b6898f49
......@@ -86,6 +86,7 @@ func UpdateBomItem(bomId, bomItemId int) (err error) {
defer client.Stop()
//直接模糊匹配
goodsMapList, err := getUpdateGoodsData(bomId, bomItems, where.DeliveryType, where.Sort, client, true)
//fmt.Println(goodsMapList)
if err != nil {
return
}
......
......@@ -34,9 +34,6 @@ func BatchSaveMatchings(bomId int, matchingList []model.BomItemMatching) (err er
tableName := "lie_bom_item_matching_" + tableEnd
//批量更新每一条记录之前,要去批量更新item表的item_status
for _, matching := range matchingList {
//if k == 1 || k == 2 || k == 3 {
// time.Sleep(2 * time.Second)
//}
//先去数据库查询是否存在该记录,有的话修改,没有就新增
var match model.BomItemMatching
model.Db.Table(tableName).Where("bom_item_id = ?", matching.BomItemID).First(&match)
......
......@@ -27,6 +27,7 @@ func Setup() {
}
Db.SingularTable(true)
//Db.LogMode(true)
Db.DB().SetMaxIdleConns(10)
Db.DB().SetMaxOpenConns(100)
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment