- don't check weixin exist after login in.

This commit is contained in:
gazebo
2018-09-21 15:35:02 +08:00
parent edd5bfed26
commit 4192e9c635
8 changed files with 69 additions and 50 deletions

View File

@@ -99,3 +99,11 @@ func IntMap2List(intMap map[int]int) []int {
}
return retVal
}
// 计算SKU价格unitPrice为一斤的单价specQuality为质量单位为克
func CaculateSkuPrice(unitPrice int, specQuality float32, specUnit string) int {
if strings.ToLower(specUnit) == "kg" {
specQuality *= 1000
}
return int(math.Round(float64(float32(unitPrice) * specQuality / 500)))
}