|
@@ -466,7 +466,7 @@ func ClueImportSync(this *biservice.ClueImportReq) (string, int) {
|
|
defer ClueImportLock.Unlock()
|
|
defer ClueImportLock.Unlock()
|
|
result, status, dataArr, countOpen, countAdd, countPrivate := "", 1, []map[string]interface{}{}, 0, 0, 0
|
|
result, status, dataArr, countOpen, countAdd, countPrivate := "", 1, []map[string]interface{}{}, 0, 0, 0
|
|
phoneRegexp := regexp.MustCompile(`^1[0-9]{10}$`)
|
|
phoneRegexp := regexp.MustCompile(`^1[0-9]{10}$`)
|
|
- nowTime := time.Now().Format(date.Date_Full_Layout)
|
|
|
|
|
|
+ nowTime, counts := time.Now().Format(date.Date_Full_Layout), 0
|
|
data := JyBiTidb.Find("dwd_f_crm_bulk_import", map[string]interface{}{"PCBH": this.Pcbh}, "", "", -1, -1)
|
|
data := JyBiTidb.Find("dwd_f_crm_bulk_import", map[string]interface{}{"PCBH": this.Pcbh}, "", "", -1, -1)
|
|
if data != nil && len(*data) > 0 {
|
|
if data != nil && len(*data) > 0 {
|
|
for k, v := range *data {
|
|
for k, v := range *data {
|
|
@@ -487,13 +487,15 @@ func ClueImportSync(this *biservice.ClueImportReq) (string, int) {
|
|
}
|
|
}
|
|
if phone == "" {
|
|
if phone == "" {
|
|
isOks = false
|
|
isOks = false
|
|
- result += "第" + fmt.Sprint(k+2) + "行,“联系方式为空”"
|
|
|
|
|
|
+ counts++
|
|
|
|
+ result += fmt.Sprint(counts) + ".第" + fmt.Sprint(k+2) + "行,“联系方式为空”"
|
|
} else {
|
|
} else {
|
|
if !phoneRegexp.MatchString(phone) {
|
|
if !phoneRegexp.MatchString(phone) {
|
|
if !isOks {
|
|
if !isOks {
|
|
result += ",“联系方式格式有误”"
|
|
result += ",“联系方式格式有误”"
|
|
} else {
|
|
} else {
|
|
- result += "第" + fmt.Sprint(k+2) + "行,“联系方式格式有误”"
|
|
|
|
|
|
+ counts++
|
|
|
|
+ result += fmt.Sprint(counts) + ".第" + fmt.Sprint(k+2) + "行,“联系方式格式有误”"
|
|
}
|
|
}
|
|
isOks = false
|
|
isOks = false
|
|
} else {
|
|
} else {
|
|
@@ -506,7 +508,8 @@ func ClueImportSync(this *biservice.ClueImportReq) (string, int) {
|
|
if !isOks {
|
|
if !isOks {
|
|
result += ",“该线索已归属域外”"
|
|
result += ",“该线索已归属域外”"
|
|
} else {
|
|
} else {
|
|
- result += "第" + fmt.Sprint(k+2) + "行,“该线索已归属域外”"
|
|
|
|
|
|
+ counts++
|
|
|
|
+ result += fmt.Sprint(counts) + ".第" + fmt.Sprint(k+2) + "行,“该线索已归属域外”"
|
|
}
|
|
}
|
|
isOks = false
|
|
isOks = false
|
|
} else {
|
|
} else {
|
|
@@ -534,7 +537,8 @@ func ClueImportSync(this *biservice.ClueImportReq) (string, int) {
|
|
if !isOks {
|
|
if !isOks {
|
|
result += ",“销售线索来源为空”"
|
|
result += ",“销售线索来源为空”"
|
|
} else {
|
|
} else {
|
|
- result += "第" + fmt.Sprint(k+2) + "行,“销售线索来源为空”"
|
|
|
|
|
|
+ counts++
|
|
|
|
+ result += fmt.Sprint(counts) + ".第" + fmt.Sprint(k+2) + "行,“销售线索来源为空”"
|
|
}
|
|
}
|
|
isOks = false
|
|
isOks = false
|
|
} else {
|
|
} else {
|
|
@@ -543,7 +547,8 @@ func ClueImportSync(this *biservice.ClueImportReq) (string, int) {
|
|
if !isOks {
|
|
if !isOks {
|
|
result += ",“销售线索来源不存在”"
|
|
result += ",“销售线索来源不存在”"
|
|
} else {
|
|
} else {
|
|
- result += "第" + fmt.Sprint(k+2) + "行,“销售线索来源不存在”"
|
|
|
|
|
|
+ counts++
|
|
|
|
+ result += fmt.Sprint(counts) + ".第" + fmt.Sprint(k+2) + "行,“销售线索来源不存在”"
|
|
}
|
|
}
|
|
isOks = false
|
|
isOks = false
|
|
} else {
|
|
} else {
|