1
This commit is contained in:
@@ -408,6 +408,20 @@ func PrintStoreStatus(param map[string]string, setting *model.PrintSettingObj) s
|
|||||||
textMsgValue = make([]interface{}, 0, 0)
|
textMsgValue = make([]interface{}, 0, 0)
|
||||||
)
|
)
|
||||||
|
|
||||||
|
switch utils.Str2Int(param[model.StoreStatusPrint]) {
|
||||||
|
case -9:
|
||||||
|
printVoiceMsg += `<sound>%s</sound>`
|
||||||
|
printVoiceValue = append(printVoiceValue, model.LoseTokenVoice)
|
||||||
|
textMsg += `<center><b>门店丢失授权通知</b></center><br>`
|
||||||
|
textMsg += `<center><b>门店:%s</b></center><br>`
|
||||||
|
textMsg += `<center><b>平台:%s</b></center><br>`
|
||||||
|
textMsg += `<center><b>下线时间:%s</b></center><br>`
|
||||||
|
textMsg += `<center><b>授权丢失,将无法继续打压订单!!!!</b></center><br>`
|
||||||
|
textMsgValue = append(textMsgValue, param[model.StoreNamePrint], param[model.VendorNamePrint], utils.Time2DateStr(time.Now()))
|
||||||
|
voice := strings.Replace(fmt.Sprintf(strings.Replace(printVoiceMsg, "\n", "", -1), printVoiceValue...), "\\n", "\r\n", -1)
|
||||||
|
msg := strings.Replace(fmt.Sprintf(strings.Replace(textMsg, "\n", "", -1), textMsgValue...), "\\n", "\r\n", -1)
|
||||||
|
return voice + msg
|
||||||
|
default:
|
||||||
// 离线打印文本开启
|
// 离线打印文本开启
|
||||||
if setting.PickingSetting.BusinessOffLine == model.SettingOpen {
|
if setting.PickingSetting.BusinessOffLine == model.SettingOpen {
|
||||||
textMsg += `<center><b>门店下线通知</b></center><br>`
|
textMsg += `<center><b>门店下线通知</b></center><br>`
|
||||||
@@ -426,6 +440,7 @@ func PrintStoreStatus(param map[string]string, setting *model.PrintSettingObj) s
|
|||||||
|
|
||||||
return voice + msg
|
return voice + msg
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// SyntheticSpeech 合成语音 (美团xxx号订单)
|
// SyntheticSpeech 合成语音 (美团xxx号订单)
|
||||||
func SyntheticSpeech(printVoiceMsg string, printVoiceValue []interface{}, param map[string]string) (string, []interface{}) {
|
func SyntheticSpeech(printVoiceMsg string, printVoiceValue []interface{}, param map[string]string) (string, []interface{}) {
|
||||||
|
|||||||
Reference in New Issue
Block a user