| | |
| | | public String Product; // 产品信息 |
| | | public String Request; // 委托事项 |
| | | public String RequestDetail; // 委托事项详细 |
| | | // public String ApproverID; // 审核人员员工编码 |
| | | public String ApproverID; // 审核人员员工编码 |
| | | } |
| | | |
| | | @HttpPost |
| | |
| | | List<String> inquiryNoList = new List<String>(); |
| | | List<String> conIDList = new List<String>(); |
| | | List<String> camNoList = new List<String>(); |
| | | // List<String> approverIDList = new List<String>(); |
| | | List<String> approverIDList = new List<String>(); |
| | | List<GeData> geDataListNew = new List<GeData>(); |
| | | for (GeData geData : geDataList) { |
| | | if (String.isBlank(geData.InquiryNo)) { |
| | |
| | | } else { |
| | | conIDList.add(geData.ContactId); |
| | | } |
| | | // if (String.isNotBlank(geData.ApproverID)) { |
| | | // approverIDList.add(geData.ApproverID); |
| | | // } |
| | | if (String.isNotBlank(geData.ApproverID)) { |
| | | approverIDList.add(geData.ApproverID); |
| | | } |
| | | if (String.isNotBlank(geData.Campaign)) { |
| | | camNoList.add(geData.Campaign); |
| | | } |
| | |
| | | } |
| | | } |
| | | //使用审核人员员工编码查询用户ID |
| | | // Map<string,String> ownerMap = new Map<string,String>(); |
| | | // List<User> ownerList = [select Id,Employee_No__c from User where Employee_No__c IN:approverIDList]; |
| | | // for(User temp : ownerList){ |
| | | // ownerMap.put(temp.Employee_No__c,temp.Id); |
| | | // } |
| | | Map<string,String> ownerMap = new Map<string,String>(); |
| | | if(approverIDList.size()>0){ |
| | | List<User> ownerList = [select Id,Employee_No__c from User where Employee_No__c IN:approverIDList]; |
| | | if (ownerList.size()>0){ |
| | | for(User temp : ownerList){ |
| | | ownerMap.put(temp.Employee_No__c,temp.Id); |
| | | } |
| | | } |
| | | } |
| | | |
| | | |
| | | |
| | | // 将XML各数据项更新到商品询问单对象中 |
| | | for (GeData geData : geDataListNew) { |
| | |
| | | inquiry.Request_Detail__c = geData.RequestDetail; //委托事项详细 |
| | | inquiry.Product1__c = geData.Product; //产品信息 |
| | | inquiry.ContactId__c = geData.ContactId; //统一用户ID |
| | | // inquiry.OwnerId = ownerMap.get(geData.ApproverID); //所有人 |
| | | |
| | | if (String.isNotBlank(ownerMap.get(geData.ApproverID))){ |
| | | inquiry.OwnerId = ownerMap.get(geData.ApproverID); //所有人 |
| | | } |
| | | |
| | | //委托事项取值后拆分 |
| | | List<String> requestList = geData.Request.split(';'); |
| | | String request1 = ''; |