|
@@ -70,7 +70,7 @@ func (this *SaleClueService) Add(ctx context.Context) int64 {
|
|
|
//线索
|
|
|
args = append(args, this.PositionId, this.EntId, this.EntUserId, this.ClueName, this.CluesSource, this.Summary, this.EmployInfoId, 0, nowtime, this.CreateName)
|
|
|
//任务
|
|
|
- argsTask = append(argsTask, this.EntId, this.ClueName+"的跟进任务", 1, this.PositionId, 1, nowtime, 1, 0, qu.If(this.FollowUpTime == 0, nil, nextFollowTime))
|
|
|
+ argsTask = append(argsTask, this.EntId, this.ClueName+"的跟进任务", 1, this.PositionId, 1, nowtime, 1, 0, qu.If(this.FollowUpTime == 0, nil, nextFollowTime), nil, nil)
|
|
|
clueId, taskId = Save(ctx, args, argsTask, argsTaskTeam, this.EmployInfoId, 0, this.PositionId, this.CreateName, transferArr)
|
|
|
if clueId < 0 {
|
|
|
return -1
|
|
@@ -79,7 +79,8 @@ func (this *SaleClueService) Add(ctx context.Context) int64 {
|
|
|
//线索
|
|
|
args = append(args, this.PositionId, this.EntId, this.EntUserId, this.ClueName, this.CluesSource, this.Summary, this.EmployInfoId, 0, time.Now().Format(date.Date_Full_Layout), this.CreateName)
|
|
|
//任务
|
|
|
- argsTask = append(argsTask, this.EntId, this.ClueName+"的跟进任务", 1, this.PositionId, 2, nowtime, 1, 0, qu.If(this.FollowUpTime == 0, nil, nextFollowTime))
|
|
|
+
|
|
|
+ argsTask = append(argsTask, this.EntId, this.ClueName+"的跟进任务", 1, this.PositionId, 2, nowtime, 1, 0, qu.If(this.FollowUpTime == 0, nil, nextFollowTime), nil, nil)
|
|
|
//任务团队
|
|
|
argsTaskTeam = append(argsTaskTeam, this.PositionId, this.EntUserId, this.CreateName, 1, nowtime)
|
|
|
//存库
|
|
@@ -117,7 +118,7 @@ taskTransferMap 自办的map
|
|
|
transferArr 转办的用户职位id
|
|
|
*/
|
|
|
func TaskAdd(tx *sql.Tx, args, taskTeamArgs []interface{}, transferArr []int64, positionId int64) int64 {
|
|
|
- fields := []string{"ent_id", "name", "source", "create_person", "status", "create_time", "create_way", "join_task_vehicle", "next_follow_time", "source_id"}
|
|
|
+ fields := []string{"ent_id", "name", "source", "create_person", "status", "create_time", "create_way", "join_task_vehicle", "next_follow_time", "tpl_id", "current_stage", "source_id"}
|
|
|
_, id := cm.CrmMysql.InsertBatchByTx(tx, entity.TASK, fields, args)
|
|
|
teamId, transferId := int64(0), int64(0)
|
|
|
if len(taskTeamArgs) > 0 {
|