门店评分

This commit is contained in:
Rosy-zhudan
2019-09-03 14:48:37 +08:00
parent b12d7dad77
commit ad1bcd36ff
5 changed files with 320 additions and 0 deletions

View File

@@ -0,0 +1,23 @@
package dao
import (
"time"
"git.rosy.net.cn/jx-callback/business/model"
)
func InsertStoreScore(storeID int, scores map[string]int) error {
storeScore := &model.StoreScore{CreatedAt: time.Now(), StoreID: storeID}
storeScore.StoreOpenTime = scores["storeOpenTime"]
storeScore.SaleSkuCount = scores["saleSkuCount"]
storeScore.AveragePickupTime = scores["averagePickupTime"]
storeScore.BadReviewOrder = scores["badReviewOrder"]
storeScore.UnfinishOrder = scores["unfinishOrder"]
storeScore.LackStockOrder = scores["lackStockOrder"]
storeScore.PromotionSku = scores["promotionSku"]
storeScore.FullVendor = scores["fullVendor"]
storeScore.StoreRange = scores["storeRange"]
storeScore.SaleSkuPrice = scores["saleSkuPrice"]
return CreateEntity(nil, storeScore)
}