From a8ab7472eeb55e6349b23534f60ac4a9575b252f Mon Sep 17 00:00:00 2001 From: liuzhao Date: Thu, 22 Nov 2018 17:49:12 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E7=BB=8F=E9=94=80=E5=95=86?= =?UTF-8?q?=E8=B4=A6=E6=88=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DistributorAccountImport.jsp | 6 +- .../DistributorAccountImportInfo.jsp | 75 +++++++++++++++ .../DistributorInfoIBatchmportInfo.jsp | 92 ++++++++++++++++++- 3 files changed, 169 insertions(+), 4 deletions(-) create mode 100644 WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImportInfo.jsp diff --git a/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImport.jsp b/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImport.jsp index 28becd4e0..1969eacb3 100644 --- a/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImport.jsp +++ b/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImport.jsp @@ -15,7 +15,7 @@ //0、是否展示 1、 权限控制 2、 展示类型 3、按钮显示名称 4、按钮解释文字 5、按钮触发事件代码 6、 7、 8、 9、图标,CSS层叠样式 10、风格 String sButtons[][] = { //{"true","All","Button","新增","新增","newRecord()","","","","btn_icon_add",""}, - //{"true","","Button","详情","详情","viewAndEdit()","","","","btn_icon_detail",""}, + {"true","","Button","修改","修改","viewAndEdit()","","","","btn_icon_detail",""}, {"true","","Button","导入Excel","导入Excel","importExcel()","","","","btn_icon_import"}, {"true","","Button","模版下载","模版下载","DistributorDownload()","","","","btn_icon_down",""}, {"true","","Button","删除","删除","if(confirm('确实要删除吗?'))as_delete(0,'alert(getRowCount(0))')","","","","btn_icon_delete",""}, @@ -34,8 +34,8 @@ AsControl.OpenView(sUrl,'','_self',''); } function viewAndEdit(){ - var sUrl = ""; - var sPara = getItemValue(0,getRow(0),'SerialNo'); + var sUrl = "/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImportInfo.jsp"; + var sPara = getItemValue(0,getRow(0),'ID'); if(typeof(sPara)=="undefined" || sPara.length==0 ){ alert("参数不能为空!"); return ; diff --git a/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImportInfo.jsp b/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImportInfo.jsp new file mode 100644 index 000000000..3698c8d86 --- /dev/null +++ b/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorAccountImportInfo.jsp @@ -0,0 +1,75 @@ +<%@ page contentType="text/html; charset=GBK"%> +<%@ include file="/Frame/resources/include/include_begin_info.jspf"%><% + /* + Author: undefined 2018-11-22 + Content: 示例详情页面 + History Log: + */ + String sPrevUrl = CurPage.getParameter("PrevUrl"); + if(sPrevUrl == null) sPrevUrl = ""; + + String sTempletNo = "DistributorAccountImportInfo";//--模板号-- + ASObjectModel doTemp = new ASObjectModel(sTempletNo); + //doTemp.setColTips("", "测试"); + ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request); + dwTemp.Style = "2";//freeform + //dwTemp.ReadOnly = "-2";//只读模式 + dwTemp.genHTMLObjectWindow(CurPage.getParameter("SerialNo")); + + String sButtons[][] = { + {"true","All","Button","保存","保存所有修改","as_save(0)","","","",""}, + {"true","All","Button","返回","返回列表","returnList()","","","","btn_icon_return"} + //{String.valueOf(!com.amarsoft.are.lang.StringX.isSpace(sPrevUrl)),"All","Button","返回","返回列表","returnList()","","","",""} + }; + sButtonPosition = "north"; +%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%> + +<%@ include file="/Frame/resources/include/include_end.jspf"%> \ No newline at end of file diff --git a/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorInfoIBatchmportInfo.jsp b/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorInfoIBatchmportInfo.jsp index 2c3e1d884..ded00d864 100644 --- a/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorInfoIBatchmportInfo.jsp +++ b/WebContent/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorInfoIBatchmportInfo.jsp @@ -8,7 +8,7 @@ String sPrevUrl = CurPage.getParameter("PrevUrl"); if(sPrevUrl == null) sPrevUrl = ""; - String sTempletNo = "DistributorInfoIBatchmportInfo";//--模板号-- + String sTempletNo = "DistributorInfoImportInfoNew";//--模板号-- ASObjectModel doTemp = new ASObjectModel(sTempletNo); //doTemp.setColTips("", "测试"); ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request); @@ -27,5 +27,95 @@ function returnList(){ AsControl.OpenView("/Tenwa/Lease/DistributorManage/DistributorApproval/DistributorInfoIBatchmportList.jsp", "","_self",""); } + //请选择经销商名称 + function selectcompany(){ + AsDialog.OpenSelector("SelectCompany","","dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.6) + "px",function(sReturn){ + if(!sReturn||sReturn=="_CANCEL_"){ + alert(getHtmlMessage('1'));//请选择一条信息! + return; + } + sReturn = sReturn.split("@");//"@"表示了向页面添加数据时的连续性 + setItemValue(0,getRow(),"SUBSIDIARY_COMPANY",sReturn[0]);//向页面的框中添加数据 + },"请选择经销商"); + } + var province="";//定义一个全局变量 + // 选择省份 + function selectProvinceCode(){ + AsDialog.OpenSelector("selectProvinceCode","","dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px", + function(sReturn){ + if(!sReturn||sReturn=="_CANCEL_"||sReturn==""){ + //alert(getHtmlMessage('1'));//请选择一条信息! + return; + } + sReturn = sReturn.split("@"); +// alert(sReturn[1]); + setItemValue(0,0,"provinces",sReturn[1]); + province=sReturn[0]; + setItemValue(0,0,"DISTRIBUTOR_ADDRESSNAME",""); + setItemValue(0,0,"DISTRIBUTOR_ADDRESS",""); + setCertType(); + },"请选择省份",''); + } + // 选择市区 + function selectCityCode(){ + //alert("参数:"+province); + if(province=="" || province==null){ + alert("请先选择省份。"); + return; + }else{ + AsDialog.OpenSelector("selectCityCode","province,"+province,"dialogWidth=" + parseInt(window.screen.width * 0.4) + "px dialogHeight=" + parseInt(window.screen.height * 0.5) + "px", + function(sReturn){ + + if(!sReturn||sReturn=="_CANCEL_"||sReturn==""){ + //alert(getHtmlMessage('1'));//请选择一条信息! + return; + } + sReturn = sReturn.split("@"); + setItemValue(0,0,"DISTRIBUTOR_ADDRESS",sReturn[0]);//地区区号 + setItemValue(0,0,"DISTRIBUTOR_ADDRESSNAME",sReturn[1]);//地区 + },"请选择地区",''); + } + } + //组织机构验证码的的校验 + function Checkfield(){ + var businessLicenseNo = getItemValue(0,getRow(0),"BUSINESS_LICENSE_NO"); + if(businessLicenseNo==""){ + //alert("组织机构代码不能为空!"); + return true; + } + if(checkORGRight(businessLicenseNo)){ + return true; + }else{ + setErrorTips("BUSINESS_LICENSE_NO","组织机构代码格式不正确!"); + //AsDebug.alert("提示","组织机构代码格式不正确!"); + return false; + } + } + //校验经销商编号是否唯一 + function Uniquenesscheck(){ + var DISTRIBUTOR_CODING = getItemValue(0,0,'DISTRIBUTOR_CODING'); + var sReturnInfo = RunJavaMethodTrans("com.tenwa.customer.controller.group.CustomerGroupCompanyController","distributor_basic","DISTRIBUTOR_CODING="+DISTRIBUTOR_CODING); + if("false" ==sReturnInfo){ + AsDebug.alert("提示","经销商编码已存在,请重新输入!!!"); + return false; + }else{ + return true; + } + } + function checktel(){ + var LINKMAN_TEL = getItemValue(0,getRow(0),"LINKMAN_TEL"); + if(LINKMAN_TEL==""){ + return true; + } + var phone = /^[1][3,4,5,7,8][0-9]{9}$/; + if(phone.test(LINKMAN_TEL)){ + setErrorTips("LINKMAN_TEL",""); + return true; + }else{ + setErrorTips("LINKMAN_TEL","手机号格式不正确!"); + //alert("手机号格式不正确!"); + return false; + } + } <%@ include file="/Frame/resources/include/include_end.jspf"%> \ No newline at end of file