门店增加可调节打印机声音

This commit is contained in:
苏尹岚
2020-04-21 14:08:19 +08:00
parent febda332ad
commit 2a1863c144
5 changed files with 42 additions and 3 deletions

View File

@@ -823,3 +823,21 @@ func TranslateStorePriceType(storePriceType int8) int8 {
}
return storePriceType
}
func TranslateSoundSize(vendorID, soundPercentage int) (soundSize string) {
if vendorID == model.VendorIDYiLianYun || vendorID == model.VendorIDFeiE {
if soundPercentage == 0 {
soundSize = "0"
}
if soundPercentage > 0 && soundPercentage <= 33 {
soundSize = "1"
}
if soundPercentage > 33 && soundPercentage <= 66 {
soundSize = "2"
}
if soundPercentage > 66 && soundPercentage <= 100 {
soundSize = "3"
}
}
return soundSize
}