客户商机导入 __K9C0HmAjnqJZgTI2sjd 16 2048 1536 rollback 1628430923968 客户商机导入 0 348 203 142 34 customer 1628430944668 地址 0 101 302 142 34 address false 1628430945107 客户类型 0 252 303 142 34 type false (function(){ var doc=getCurrentDocument() var type = doc.getItemValueAsString(@quot;type@quot;); if(type == @quot;直接客户@quot;){ return @quot;01@quot;; } if(type == @quot;经销客户@quot;){ return @quot;02@quot;; } if(type == @quot;合作伙伴@quot;){ return @quot;03@quot;; } if(type == @quot;供应商@quot;){ return @quot;04@quot;; } })() (function(){ var doc=getCurrentDocument() var type = doc.getItemValueAsString(@quot;type@quot;); println(@quot;type-----@gt;: @quot; + type ); if(type == @quot;01@quot;) ; else if(type == @quot;02@quot;) ; else if(type == @quot;03@quot;) ; else if(type == @quot;04@quot;) ; else return @quot;导入失败,“客户类型”无对应值,请下载正确模板导入@quot;; customerId = getId(); println(@quot;id2-----@gt;: @quot; + customerId ) ; var name = getItemValueAsString(@quot;name@quot;); println(@quot;name-----@gt;: @quot; + name ) ; var belongerid = getWebUser().getId(); println(@quot;belongerid-----@gt;: @quot; + belongerid ) ; //插入表 var process = getDocumentProcess(); var formProcess = getFormProcess(); var subform = formProcess.doView(@quot;__xyiP8yV2DWw6GjvyWaJ@quot;); //客户跟进人表单Id var doc = process.doNew(subform,getWebUser(),createParamsTable()); doc.addStringItem(@quot;customerid@quot;,customerId); //客户id doc.addStringItem(@quot;customerName@quot;,name); //客户名称 doc.addStringItem(@quot;belongerid@quot;,belongerid); //跟进人 process.doCreate(doc); println(@quot;将 @quot; + name + @quot; 分配给 @quot; + belongerid ); })() 1628430945519 代称 0 252 101 142 34 nickname false 1628430945875 等级 0 402 101 142 34 level false (function(){ var doc=getCurrentDocument() var level = doc.getItemValueAsString(@quot;level@quot;); if(level==@quot;普通用户@quot;){ return @quot;01@quot;; } if(level==@quot;重点客户@quot;){ return @quot;02@quot;; } if(level==@quot;年度合作客户@quot;){ return @quot;03@quot;; } })() (function(){ var doc=getCurrentDocument() var level = doc.getItemValueAsString(@quot;level@quot;); println(@quot;导入level-----@gt;: @quot; + level ); if(level == @quot;01@quot;) ; else if(level == @quot;02@quot;) ; else if(level == @quot;03@quot;) ; else return @quot;导入失败,“等级”无对应值,请下载正确模板导入@quot;; })() 1628430946272 描述 0 553 101 142 34 note false 1628430946637 所属行业 0 702 102 142 34 industryid false (function(){ var doc=getCurrentDocument() var industryid = doc.getItemValueAsString(@quot;industryid@quot;); if(industryid == @quot;保安行业@quot;){ return @quot;01@quot;; } if(industryid == @quot;大型活动相关行业@quot;){ return @quot;02@quot;; } if(industryid == @quot;监管行业@quot;){ return @quot;08@quot;; } if(industryid == @quot;其他行业@quot;){ return @quot;09@quot;; } })() (function(){ var doc=getCurrentDocument() var industryid = doc.getItemValueAsString(@quot;industryid@quot;); println(@quot;industryid-----@gt;: @quot; + industryid ); if(industryid == @quot;01@quot;) ; else if(industryid == @quot;02@quot;) ; else if(industryid == @quot;08@quot;) ; else if(industryid == @quot;09@quot;) ; else return @quot;导入失败,“所属行业”无对应值,请下载正确模板导入@quot;; })() 1628430947016 客户名称 0 102 101 142 34 name true 1628430923968 1628430947016 false false 102;101;301;201 1628431063719 1628430923968 1628430945519 false false 252;101;348;203 1628431071971 1628430923968 1628430945875 false false 402;101;348;203 1628431074536 1628430923968 1628430946272 false false 553;101;348;203 1628431076916 1628430923968 1628430946637 false false 702;102;348;203 1628431079213 1628430923968 1628430944668 false false 101;302;348;203 1628431081506 1628430923968 1628430945107 false false 252;303;348;203 1628431084612 1628488592774 客户来源 0 401 302 142 34 source false (function(){ return @quot;2@quot;; })() 1628430923968 1628488592774 false false 401;302;348;203 1628488619391 ]]> /uploads/exceltemplate/客户商机导入1.xlsx