Kaynağa Gözat

feat:不活跃用户不定位时间

wangchuanjin 1 yıl önce
ebeveyn
işleme
83c85fa9b2

+ 2 - 2
pushsubscribe/push/config.json

@@ -65,11 +65,11 @@
 		"keyword4":{
 			"color":"#44BEF3"
 		},
-		"url":"/swordfish/newhistorypush?f=push&t=%s&pushtime=%d&advertcode=%s"
+		"url":"/swordfish/newhistorypush?f=push&t=%s&pushtime=%s&advertcode=%s"
 	},
 	"appMsg":{
 		"title":"您订阅的招投标信息有更新!",
-		"url":"/jyapp/swordfish/historypush?f=push&t=%s&pushtime=%d"
+		"url":"/jyapp/swordfish/historypush?f=push&t=%s&pushtime=%s"
 	},
 	"timeoutWarn":"http://172.17.4.195:19281/_send/_mail?program=pushsubscribe_push&to=wangchuanjin@topnet.net.cn&title=订阅推送程序报警&body=放入通道超时",
 	"noMsgTip":{

+ 2 - 2
pushsubscribe/push/job/pushjob.go

@@ -181,7 +181,7 @@ func (p *PushJob) doPush(pusher Pusher, taskType int, u *UserInfo, sl *SortList,
 			"descriptAppend": descriptAppend,
 			"type":           "bid",
 			"userId":         u.Id,
-			"url":            "/jyapp/free/sess/" + Se.EncodeString(u.Id+",_id,"+strconv.Itoa(int(now.Unix()))+",") + "__" + Se.EncodeString(fmt.Sprintf(Config.AppMsg.Url, "free", pushParam.PushDate)),
+			"url":            "/jyapp/free/sess/" + Se.EncodeString(u.Id+",_id,"+strconv.Itoa(int(now.Unix()))+",") + "__" + Se.EncodeString(fmt.Sprintf(Config.AppMsg.Url, "free", util.If(u.SubPushInactive == 1, "", fmt.Sprint(pushParam.PushDate)).(string))),
 			"otherPushId":    u.Opushid,
 			"jgPushId":       u.Jpushid, //极光-推送id
 		})
@@ -235,7 +235,7 @@ func (p *PushJob) sendWeixin(k *UserInfo, pushParam *PushParam) bool {
 		OpenId:   k.S_m_openid,
 		TplId:    Config.WxTplMsg.Id,
 		TmplData: tmplData,
-		Url:      Config.WxDomain + "/front/sess/" + Se.EncodeString(k.Id+",_id,"+strconv.Itoa(int(time.Now().Unix()))+",") + "__" + Se.EncodeString(fmt.Sprintf(Config.WxTplMsg.Url, "free", pushParam.PushDate, "")),
+		Url:      Config.WxDomain + "/front/sess/" + Se.EncodeString(k.Id+",_id,"+strconv.Itoa(int(time.Now().Unix()))+",") + "__" + Se.EncodeString(fmt.Sprintf(Config.WxTplMsg.Url, "free", util.If(k.SubPushInactive == 1, "", fmt.Sprint(pushParam.PushDate)).(string), "")),
 	})
 	return ok
 }