Commit 32b298ac by hcy

可买库存扣锁库数量

parent b22b9fa7
Showing with 1 additions and 1 deletions
...@@ -262,7 +262,7 @@ func (ls *LyService) GetStock(sku model.LySku) (stock int64) { ...@@ -262,7 +262,7 @@ func (ls *LyService) GetStock(sku model.LySku) (stock int64) {
} }
//这里还有一个逻辑 //这里还有一个逻辑
//如果是寄售的数据(source=12),获取的库存还要减去锁库的库存 //如果是寄售的数据(source=12),获取的库存还要减去锁库的库存
if sku.Source == 12 || php2go.InArray(sku.Canal, []string{"L0018319", "L0013521", "L0018562"}) { if sku.Source == 12 || php2go.InArray(sku.Canal, []string{"L0018319", "L0013521", "L0018562", "L0017764", "L0003270", "L0012413", "L0013521"}) {
//获取锁库库存 //获取锁库库存
redisCon := gredis.Conn("search_r") redisCon := gredis.Conn("search_r")
stockStr, _ := redis.String(redisCon.Do("HGET", "sku_lock_stock", sku.GoodsId)) stockStr, _ := redis.String(redisCon.Do("HGET", "sku_lock_stock", sku.GoodsId))
......
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