|
|
@ -2705,7 +2705,6 @@ func (impl *BalanceServiceImplement) PublishMpsPlan(user *global.User, version s |
|
|
|
|
|
|
|
// 查找当前周MDS发布的版本数据
|
|
|
|
mdsVersion := fmt.Sprintf("%d.%02d", year, week) |
|
|
|
fmt.Println("mdsVersion:", mdsVersion) |
|
|
|
demandHeadList, err := dao_CustDemandVerHead.Select([]grmi.Predicate{meta.CustDemandVerHead_VersionId.NewPredicate(grmi.Equal, mdsVersion)}, nil) |
|
|
|
if err != nil { |
|
|
|
return grmi.NewBusinessError("查询全局发布需求数据失败, error:" + err.Error()) |
|
|
@ -2816,10 +2815,10 @@ func (impl *BalanceServiceImplement) PublishMpsPlan(user *global.User, version s |
|
|
|
_ = session.Rollback() |
|
|
|
return grmi.NewBusinessError("取消前一个发布计划失败, 错误:" + err.Error()) |
|
|
|
} |
|
|
|
//utils.EmailSendStruct["planOrderVersion_cancel"].SeyChannels(utils.ChannelsInfo{
|
|
|
|
// Key: utils.ValueToString(prePlanOrderVersion.PlanOrderId, ""),
|
|
|
|
// Info: *prePlanOrderVersion,
|
|
|
|
//})
|
|
|
|
utils.EmailSendStruct["planOrderVersion_cancel"].SeyChannels(utils.ChannelsInfo{ |
|
|
|
Key: utils.ValueToString(prePlanOrderVersion.PlanOrderId, ""), |
|
|
|
Info: *prePlanOrderVersion, |
|
|
|
}) |
|
|
|
} else { |
|
|
|
log, _ := logger.NewLogger(user.UserId, "Balance") |
|
|
|
log.Error("前一半发布计划已取消, 前一半计划ID:" + prePlanOrderVersion.PlanOrderId) |
|
|
@ -2960,10 +2959,10 @@ func (impl *BalanceServiceImplement) PublishMpsPlan(user *global.User, version s |
|
|
|
return grmi.NewBusinessError("写入外购需求数据失败, 错误:" + err.Error()) |
|
|
|
} |
|
|
|
|
|
|
|
//utils.EmailSendStruct["planOrderVersion_publish"].SeyChannels(utils.ChannelsInfo{
|
|
|
|
// Key: utils.ValueToString(data_PlanOrderVersion.PlanOrderId, ""),
|
|
|
|
// Info: data_PlanOrderVersion,
|
|
|
|
//})
|
|
|
|
utils.EmailSendStruct["planOrderVersion_publish"].SeyChannels(utils.ChannelsInfo{ |
|
|
|
Key: utils.ValueToString(data_PlanOrderVersion.PlanOrderId, ""), |
|
|
|
Info: data_PlanOrderVersion, |
|
|
|
}) |
|
|
|
|
|
|
|
// 已经发布
|
|
|
|
for index, _ := range demandHeadList { |
|
|
|