Selaa lähdekoodia

Merge branch 'dev_v1.5.15_wh' of jianyu/datatools into feature/v1.5.15

王浩 11 kuukautta sitten
vanhempi
commit
9deae8bc8d
2 muutettua tiedostoa jossa 3 lisäystä ja 2 poistoa
  1. 0 1
      clueSync/job.go
  2. 3 1
      clueSync/jobutil.go

+ 0 - 1
clueSync/job.go

@@ -269,7 +269,6 @@ func FormatData(data map[string]interface{}, item string) (bool, bool) {
 			if batch_import != "" && item == "users" { //有导入批次号还是新用户,不执行
 			if batch_import != "" && item == "users" { //有导入批次号还是新用户,不执行
 				return true, true
 				return true, true
 			}
 			}
-			//oks = UpdateClue(*uCount, saleData, item, userId, uId, top_cluetype, sub_cluetype, topname, subname, cluename, name, saleName, phone, position, department, departments, industry, follow_project_area, role, seatNumber, level, position_id, source, sourceCode, remark, keyword, belong_to, isGroup, isCommerce, pIsOk, "")
 			oks = UpdateClue(*uCount, saleData, item, userId, uId, top_cluetype, sub_cluetype, topname, subname, cluename, name, saleName, phone, position, department, departments, industry, follow_project_area, role, seatNumber, level, position_id, source, sourceCode, remark, keyword, belong_to, isGroup, isCommerce, pIsOk)
 			oks = UpdateClue(*uCount, saleData, item, userId, uId, top_cluetype, sub_cluetype, topname, subname, cluename, name, saleName, phone, position, department, departments, industry, follow_project_area, role, seatNumber, level, position_id, source, sourceCode, remark, keyword, belong_to, isGroup, isCommerce, pIsOk)
 		} else { //不存在走新增
 		} else { //不存在走新增
 			oks = SaveClue(item, userId, uId, top_cluetype, sub_cluetype, topname, subname, cluename, name, saleName, phone, position, department, departments, industry, follow_project_area, role, seatNumber, position_id, source, sourceCode, remark, keyword, belong_to, isGroup, isCommerce, isFreeze, "")
 			oks = SaveClue(item, userId, uId, top_cluetype, sub_cluetype, topname, subname, cluename, name, saleName, phone, position, department, departments, industry, follow_project_area, role, seatNumber, position_id, source, sourceCode, remark, keyword, belong_to, isGroup, isCommerce, isFreeze, "")

+ 3 - 1
clueSync/jobutil.go

@@ -1159,10 +1159,12 @@ func autoDraw(mode, cluename, phone string, isGroup, isCommerce int) (positionId
 					positionId = common.Int64All((*cdata)[0]["position_id"])
 					positionId = common.Int64All((*cdata)[0]["position_id"])
 					noticePositionId = positionId
 					noticePositionId = positionId
 					seatNumber = common.ObjToString((*cdata)[0]["seatNumber"])
 					seatNumber = common.ObjToString((*cdata)[0]["seatNumber"])
+					assign_type := common.IntAll(v["assign_type"])
+					role_id := common.IntAll(v["role_id"])
 					for _, v := range *pdata {
 					for _, v := range *pdata {
 						resign := common.IntAll(v["resign"])
 						resign := common.IntAll(v["resign"])
 						if positionId == common.Int64All(v["position_id"]) {
 						if positionId == common.Int64All(v["position_id"]) {
-							if resign == 0 {
+							if resign == 0 && (assign_type == 1 || role_id == 8) {
 								if FindUpperLimit(gconv.String(positionId), mode, true) {
 								if FindUpperLimit(gconv.String(positionId), mode, true) {
 									isFreeze = true
 									isFreeze = true
 									positionId = 0
 									positionId = 0