ソースを参照

Merge branch 'dev/v1.5.2_wjh' of jianyu/datatools into feature/v1.5.2

wangjianghan 1 年間 前
コミット
b65b3d81a3
1 ファイル変更22 行追加0 行削除
  1. 22 0
      clueSync/sendMail.go

+ 22 - 0
clueSync/sendMail.go

@@ -293,6 +293,28 @@ func OrderCreateFail(posid int64, bname string) {
 	sendInfo(toMail, toCc, title, content)
 }
 
+// @Author jianghan
+// @Description 非集团公司线索分配失败
+// @Date 2024/5/11
+func AssFail(posid int64, ent, iname string) {
+	title := "您跟进的非集团公司线上线索分配失败"
+	content := "您的私海线索已达到私海线索上限**条(不包含成交客户),导致您正在跟进的非集团公司“%s”产生的新线索“%s”无法进入您的私海,请及时将无需跟进的线索退回公海,退回后联系您的电销经理将此线索再划转至您的私海。"
+
+	toMail := ""
+	toCc := ""
+	content = fmt.Sprintf(content, LimitSize, ent, iname)
+	info := Mysql.SelectBySql(selfMail, posid)
+	if info != nil && len(*info) > 0 {
+		toMail = common.ObjToString((*info)[0]["mail"])
+	}
+	if toMail == "" {
+		log.Println("未查询到邮箱地址, position id: ", posid)
+		return
+	}
+	toCc = getCc(posid)
+	sendInfo(toMail, toCc, title, content)
+}
+
 // @Author jianghan
 // @Description 发邮件
 // @Date 2024/5/8