Commit 36ae2380 by ilal

提交

parent 8c6b4b0c
...@@ -1480,26 +1480,31 @@ public class CrmController { ...@@ -1480,26 +1480,31 @@ public class CrmController {
crmClientData.insert(); crmClientData.insert();
Integer cid = crmClientData.getId(); Integer cid = crmClientData.getId();
CrmClientContacts contacts = new CrmClientContacts(); if(linkname != null && linkcellphone != null) {
contacts.setName(linkname); CrmClientContacts contacts = new CrmClientContacts();
contacts.setCellphone(linkcellphone); contacts.setName(linkname);
contacts.setCompany(linkcompany); contacts.setCellphone(linkcellphone);
if (linkgender == "女") contacts.setCompany(linkcompany);
contacts.setGender(0); if (("女").equals(linkgender))
else if (linkgender == "男") contacts.setGender(0);
contacts.setGender(1); else if (("男").equals(linkgender))
else contacts.setGender(1);
contacts.setGender(null); else
contacts.setPosition(linkposition); contacts.setGender(null);
contacts.setTelephone(linktelephone); contacts.setPosition(linkposition);
contacts.setEmail(linkemail); contacts.setTelephone(linktelephone);
contacts.setAddress(linkaddress); contacts.setEmail(linkemail);
if (!(linkname == null && linkcellphone == null && linkcompany == null && linkgender == null contacts.setAddress(linkaddress);
&& linkposition == null && linktelephone == null && linkemail == null && linkaddress == null)) { if (!(linkname == null && linkcellphone == null && linkcompany == null && linkgender == null
contacts.setCid(cid); && linkposition == null && linktelephone == null && linkemail == null && linkaddress == null)) {
contacts.insert(); contacts.setCid(cid);
contacts.insert();
}
} }
} }
return ResultUtil.success("导入成功"); return ResultUtil.success("导入成功");
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment