Przeglądaj źródła

Merge remote-tracking branch 'origin/master'

蔡德晨 5 lat temu
rodzic
commit
47503bd65f

+ 16 - 3
src/main/java/com/jeeplus/modules/projectrecord/service/ProjectRecordsService.java

@@ -36,6 +36,7 @@ import com.jeeplus.modules.workactivity.service.WorkActivityProcessService;
 import com.jeeplus.modules.workactivitymenu.entity.WorkActivityMenu;
 import com.jeeplus.modules.workactivitymenu.service.WorkActivityMenuService;
 import com.jeeplus.modules.workclientinfo.dao.WorkClientAttachmentDao;
+import com.jeeplus.modules.workclientinfo.dao.WorkClientInfoDao;
 import com.jeeplus.modules.workclientinfo.dao.WorkClientLinkmanDao;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientAttachment;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientInfo;
@@ -57,6 +58,7 @@ import org.activiti.engine.history.HistoricTaskInstanceQuery;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.apache.commons.lang3.StringUtils;
 import org.java_websocket.WebSocket;
+import org.openxmlformats.schemas.drawingml.x2006.main.CTOfficeArtExtension;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Propagation;
@@ -229,17 +231,24 @@ public class ProjectRecordsService extends CrudService<ProjectRecordsDao, Projec
 		long t1 = System.currentTimeMillis();
 
 		WorkContractInfo workContractInfo = null;
+		WorkClientInfo workClientInfo = new WorkClientInfo();
 		Office company= new Office();
 		Office office =  new Office();
         if(StringUtils.isNotBlank((projectRecords.getWorkContractInfo().getId()))){
             //有合同状态
 			workContractInfo = workContractInfoDao.get(projectRecords.getWorkContractInfo().getId());
 			company.setId(workContractInfo.getCompanyId());
-			projectRecords.setCompany(company);
 			office.setId(workContractInfo.getChargeCompany());
-			projectRecords.setOffice(office);
+        }else{
+        	//无合同
+			WorkClientLinkman workClientLinkman = projectRecords.getWorkClientLinkmanList().get(0);
+			workClientInfo = workClientInfoService.get(workClientLinkman.getClientId());
+			company.setId(workClientInfo.getCompanyId());
+			office.setId(workClientInfo.getOfficeId());
+		}
+		projectRecords.setCompany(company);
+		projectRecords.setOffice(office);
 
-        }
         Integer oldStatus = projectRecords.getProjectStatus();
         projectRecords.setProjectStatus(projectStatus.getValue());
         User createBy = projectRecords.getCreateBy();
@@ -396,6 +405,10 @@ public class ProjectRecordsService extends CrudService<ProjectRecordsDao, Projec
 	 */
 	public void queryLinkmanInfos(ProjectRecords projectRecords) {
 		List<WorkClientLinkman> clientLinkmanList = workClientLinkmanDao.queryProjectLinkmans(projectRecords.getId(), 1);
+		for(WorkClientLinkman linkman :clientLinkmanList){
+			WorkClientInfo clientInfo = workClientInfoService.get(linkman.getClientId().getId());
+			linkman.setClientId(clientInfo);
+		}
 		projectRecords.setWorkClientLinkmanList(clientLinkmanList);
 		List<WorkClientLinkman> constructionLinkmanList = workClientLinkmanDao.queryProjectLinkmans(projectRecords.getId(), 0);
 		projectRecords.setWorkConstructionLinkmanList(constructionLinkmanList);

+ 10 - 5
src/main/java/com/jeeplus/modules/projectrecord/web/ProjectRecordsController.java

@@ -590,21 +590,26 @@ public class ProjectRecordsController extends BaseController {
      */
     @RequestMapping(value = "linkManSave")
     @ResponseBody
-    public WorkClientLinkman linkManSave(WorkClientInfo workClientInfo,
+    public Object linkManSave(WorkClientInfo workClientInfo,
                                                Model model, RedirectAttributes redirectAttributes,
                                                HttpServletRequest request
     ) throws Exception{
-        WorkClientLinkman linkman = new WorkClientLinkman();
+    	Map<String,Object> map = new HashMap<>();
         try {
             //保存当前人的公司
             workClientInfo.setCompanyId(UserUtils.getSelectCompany().getId());
             workClientInfo.setOfficeId(UserUtils.getSelectOffice().getId());
             workClientInfoService.save(workClientInfo);//保存
-
-            linkman = workClientInfo.getWorkClientLinkmanList().get(0);
+			WorkClientLinkman linkman = workClientInfo.getWorkClientLinkmanList().get(0);
+			map.put("id",linkman.getId());
+			map.put("clientId",workClientInfo.getId());
+			map.put("clientName",workClientInfo.getName());
+			map.put("linkName",linkman.getName());
+			map.put("linkMobile",linkman.getLinkMobile());
+			map.put("linkPhone",linkman.getLinkPhone());
         }catch (Exception e){
             e.printStackTrace();
         }
-        return  linkman;
+		return map;
     }
 }

+ 2 - 0
src/main/java/com/jeeplus/modules/workstaff/dao/WorkStaffBasicInfoDao.java

@@ -51,4 +51,6 @@ public interface WorkStaffBasicInfoDao extends CrudDao<WorkStaffBasicInfo> {
     List<WorkStaffBasicInfo> findByName(String name);
 
     int updateWorkStaffBasicInfo(WorkStaffBasicInfo workStaffBasicInfo);
+
+    WorkStaffBasicInfo getByAchieveId(String achieveId);
 }

+ 8 - 2
src/main/java/com/jeeplus/modules/workstaff/service/WorkStaffBasicInfoService.java

@@ -41,6 +41,7 @@ import com.jeeplus.modules.workrelationship.dao.WorkRelationshipDao;
 import com.jeeplus.modules.workrelationship.entity.WorkRelationship;
 import com.jeeplus.modules.workstaff.dao.WorkStaffAchivesDao;
 import com.jeeplus.modules.workstaff.entity.WorkStaffEducation;
+import com.jeeplus.modules.workstaff.entity.WorkStaffExperience;
 import com.jeeplus.modules.workstaffachiveslog.dao.WorkStaffAchivesLogDao;
 import com.jeeplus.modules.workstaffachiveslog.entity.WorkStaffAchivesLog;
 import com.jeeplus.modules.workstaffachiveslog.service.WorkStaffAchivesLogService;
@@ -191,13 +192,13 @@ public class WorkStaffBasicInfoService extends CrudService<WorkStaffBasicInfoDao
 	}
 
     /**
-     * 我的信息-用户维护教育信息,
+     * 我的信息-用户维护档案信息,
      * @param workStaffBasicInfo
      * @param request
      * @throws IOException
      */
     @Transactional(readOnly = false)
-    public void saveAchieveDirectly(WorkStaffBasicInfo workStaffBasicInfo,HttpServletRequest request) throws IOException {
+    public void updateAchieveDirectly(WorkStaffBasicInfo workStaffBasicInfo,HttpServletRequest request) throws IOException {
         String baseId = workStaffBasicInfo.getId();
         workStaffBasicInfo.setId(workStaffBasicInfo.getAchiveId());
         this.saveAchive(workStaffBasicInfo,request);
@@ -205,6 +206,7 @@ public class WorkStaffBasicInfoService extends CrudService<WorkStaffBasicInfoDao
         workStaffBasicInfo.setId(baseId);
         super.save(workStaffBasicInfo);
         this.saveDetails(workStaffBasicInfo,false);
+
     }
     public void preSave(WorkStaffBasicInfo workStaffBasicInfo, HttpServletRequest request) throws IOException {
         if(workStaffBasicInfo.getCompany()==null){
@@ -843,4 +845,8 @@ public class WorkStaffBasicInfoService extends CrudService<WorkStaffBasicInfoDao
         workStaffAchivesDao.updateWorkStaffAchieves(workStaffBasicInfo);
     }
 
+    public WorkStaffBasicInfo getBasicInfoByAchiveId(String achiveId){
+        return workStaffBasicInfoDao.getByAchieveId(achiveId);
+    }
+
 }

+ 7 - 2
src/main/java/com/jeeplus/modules/workstaff/web/WorkStaffBasicInfoController.java

@@ -34,6 +34,7 @@ import com.jeeplus.modules.workstaffachiveslog.dao.WorkStaffAchivesLogDao;
 import com.jeeplus.modules.workstaffachiveslog.entity.WorkStaffAchivesLog;
 import com.jeeplus.modules.workstaffachiveslog.service.WorkStaffAchivesLogService;
 import net.sf.json.JSONObject;
+import netscape.security.UserTarget;
 import org.apache.shiro.authz.annotation.Logical;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
@@ -530,15 +531,19 @@ public class WorkStaffBasicInfoController extends BaseController {
 	}
 
 	/**
-	 * 我的信息-直接保存员工信息
+	 * 我的信息-直接修改员工信息
 	 */
 	@RequestMapping(value = "saveAchiveModifyDirectly")
 	public String saveAchiveModifyDirectly(WorkStaffBasicInfo workStaffBasicInfo, Model model, RedirectAttributes redirectAttributes,HttpServletRequest request) throws Exception{
 		if (!beanValidator(model, workStaffBasicInfo)){
 			return form(workStaffBasicInfo, model,false);
 		}
-		workStaffBasicInfoService.saveAchieveDirectly(workStaffBasicInfo,request);
+		workStaffBasicInfo.setIsNewRecord(false);
+		WorkStaffBasicInfo t = workStaffBasicInfoService.getBasicInfoByAchiveId(workStaffBasicInfo.getId());//从数据库取出记录的值
+		MyBeanUtils.copyBeanNotNull2Bean(workStaffBasicInfo, t);//将编辑表单中的非NULL值覆盖数据库记录中的值
+		workStaffBasicInfoService.updateAchieveDirectly(workStaffBasicInfo,request);
 		addMessage(redirectAttributes, "保存员工档案信息成功");
+
 		return "redirect:"+Global.getAdminPath()+"/sys/user/info?repage";
 	}
 

+ 2 - 0
src/main/resources/mappings/modules/workstaff/WorkStaffAchivesDao.xml

@@ -772,6 +772,8 @@
 		FROM work_staff_achives a
 		<include refid="workStaffBasicInfoJoins"/>
 		WHERE a.user_id = #{userId} and a.company_id=#{company.id} and a.status not in ('离职','退休')
+		order by a.create_date desc
+		limit 1
 	</select>
 	<select id="getJob" resultType="WorkStaffBasicInfo" >
 		SELECT

+ 22 - 1
src/main/resources/mappings/modules/workstaff/WorkStaffBasicInfoDao.xml

@@ -517,10 +517,31 @@
 				phone = #{phone},
 			</if>
 			<if test="remarks != null and remarks != ''">
-				remarks = #{remarks}
+				remarks = #{remarks},
+			</if>
+			<if test="address != null and address != ''">
+				address = #{address},
+			</if>
+			<if test="household != null and household != ''">
+				household = #{household},
+			</if>
+			<if test="politics != null and politics != ''">
+				politics = #{politics},
+			</if>
+			<if test="marriage != null and marriage != ''">
+				marriage = #{marriage},
+			</if>
+			<if test="ts != null and ts != ''">
+				ts = #{ts}
 			</if>
 		</set>
 		where user_id = #{userId}
 	</update>
 
+	<select id="getByAchieveId" parameterType="String" resultType="WorkStaffBasicInfo">
+		select w.*
+		from work_staff_basic_info w left join work_staff_achives a
+		on w.user_id = a.user_id
+		where a.id = #{achieveId}
+	</select>
 </mapper>

+ 67 - 58
src/main/webapp/webpage/modules/projectrecord/projectRecordsForm.jsp

@@ -5,7 +5,7 @@
     <title>项目管理</title>
     <meta name="decorator" content="default"/>
     <script type="text/javascript" src="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.js"></script>
-    <script type="text/javascript" src="${ctxStatic}/static/iCheck/icheck.min.js"></script>
+    <script type="text/javascript" src="${ctxStatic}/iCheck/icheck.min.js"></script>
     <link rel='stylesheet' type="text/css" href="${ctxStatic}/helloweba_editable-select/jquery.editable-select.min.css"/>
     <style>
         #projectDesc-error{
@@ -263,51 +263,56 @@
                     var $document = iframeWin.contentWindow.document;
 
                     formSubmit2($document,formId,index);
+
                 },
                 cancel: function(index){
                 }
             });
 
-            function formSubmit2($document, inputForm, index) {
-                var validateForm = $($document.getElementById(inputForm)).validate({
-                    submitHandler: function (form) {
-                        loading('正在提交,请稍等...');
-                        form.submit();
-                    },
-                    errorContainer: "#messageBox",
-                    errorPlacement: function (error, element) {
-                        $($document.getElementById("#messageBox")).text("输入有误,请先更正。");
-                        if (element.is(":checkbox") || element.is(":radio") || element.parent().is(".input-append")) {
-                            error.appendTo(element.parent().parent());
-                        } else {
-                            error.insertAfter(element);
+
+        }
+
+        function formSubmit2($document,inputForm,index){
+            var validateForm = $($document.getElementById(inputForm)).validate({
+                submitHandler: function(form){
+                    loading('正在提交,请稍等...');
+                    form.submit();
+                },
+                errorContainer: "#messageBox",
+                errorPlacement: function(error, element) {
+                    $($document.getElementById("#messageBox")).text("输入有误,请先更正。");
+                    if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+                        error.appendTo(element.parent().parent());
+                    } else {
+                        error.insertAfter(element);
+                    }
+                }
+            });
+            if(validateForm.form()){
+                $($document.getElementById(inputForm)).ajaxSubmit({
+                    success:function(data) {
+                        var d = data;
+                        if(d.msg == "false"){
+                            parent.layer.msg("保存客户信息异常!",{icon:2});
+                            return false;
                         }
+                        console.log("-------success-----");
+                        addRow('#workClientLinkmanList', workClientLinkmanRowIdx, workClientLinkmanTpl);workClientLinkmanRowIdx = workClientLinkmanRowIdx + 1;
+                        var row = workClientLinkmanRowIdx - 1 ;
+
+                        $("#"+"workClientLinkmanList"+row+"_id").val(d.id);
+                        $("#"+"workClientLinkmanList"+row+"_clientId_id").val(d.clientId);
+                        $("#"+"workClientLinkmanList"+row+"_clientName").val(d.clientName);
+                        $("#"+"workClientLinkmanList"+row+"_name").val(d.linkName);
+                        $("#"+"workClientLinkmanList"+row+"_linkMobile").val(d.linkMobile);
+                        $("#"+"workClientLinkmanList"+row+"_linkPhone").val(d.linkPhone);
+                        $("#contractClientName").val(d.clientName);
+                        parent.layer.msg(d.str,{icon:1});
+                        top.layer.close(index)
                     }
                 });
-                if (validateForm.form()) {
-                    $($document.getElementById(inputForm)).ajaxSubmit({
-                        success: function (data) {
-                            var d = data;
-                            if (d.msg == "false") {
-                                parent.layer.msg("保存客户信息异常!", {icon: 2});
-                                return false;
-                            }
-                            addRow('#workClientLinkmanList', workClientLinkmanRowIdx, workClientLinkmanRowIdx);
-                            workClientLinkmanRowIdx = workClientLinkmanRowIdx + 1;
-                            var row = workClientLinkmanRowIdx - 1;
-                            $("#" + "workClientLinkmanList" + row + "_id").val(d.id);
-                            $("#" + "workClientLinkmanList" + row + "_office").val(d.office);
-                            $("#" + "workClientLinkmanList" + row + "_name").val(d.name);
-                            $("#" + "workClientLinkmanList" + row + "_linkPhone").val(d.linkPhone);
-                            $("#" + "workClientLinkmanList" + row + "_linkMobile").val(d.linkMobile);
-                            parent.layer.msg(d.str, {icon: 1});
-                            top.layer.close(index)
-                        }
-                    });
-                }
             }
         }
-
     </script>
 </head>
 <body>
@@ -319,16 +324,18 @@
             <form:hidden path="workContractInfo.client.id" id="contractClientId" value="${workContractInfo.client.id}"/>
 
             <div class="form-group layui-row first">
-                <div class="form-group-label"><h2>项目合同信息</h2></div>
-                <div class="layui-item layui-col-sm6 lw7">
-                    <label class="layui-form-label">合同情况:</label>
-                    <div class="layui-input-block">
-                        <input type="radio" class="i-checks" name="ext" checked id="ext" value="0">
-                        <label for="ext">有合同</label>
-                        <input type="radio" class="i-checks" name="ext" id="ext1" value="1">
-                        <label for="ext1">无合同</label>
-                    </div>
-                </div>
+               <div class="form-group layui-row">
+                   <div class="form-group-label"><h2>项目合同信息</h2></div>
+                   <div class="layui-item layui-col-sm6 lw7">
+                       <label class="layui-form-label">合同情况:</label>
+                       <div class="layui-input-block">
+                           <input type="radio" class="i-checks" name="ext" checked id="ext" value="0">
+                           <label for="ext">有合同</label>
+                           <input type="radio" class="i-checks" name="ext" id="ext1" value="1">
+                           <label for="ext1">无合同</label>
+                       </div>
+                   </div>
+               </div>
                 <div id="divv">
                     <div class="layui-item layui-col-sm12 lw7" id="d1">
                         <label class="layui-form-label"><span class="require-item">*</span>选择合同:</label>
@@ -349,17 +356,17 @@
                             <input htmlEscape="false"  readonly="true" id="contractPrice"  class="form-control layui-input" value="${projectRecords.workContractInfo.contractPrice}" onchange="formatNum(this);"/>
                         </div>
                     </div>
-                    <div class="layui-item layui-col-sm6 lw7">
-                        <label class="layui-form-label">主委托方:</label>
-                        <div class="layui-input-block">
-                            <input htmlEscape="false"  readonly="true" id="contractClientName" name="workContractInfo.client.name" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
-                        </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">主委托方:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" id="contractClientName" name="workContractInfo.client.name" class="form-control layui-input" value="${projectRecords.workContractInfo.client.name}"/>
                     </div>
-                    <div class="layui-item layui-col-sm6 lw7">
-                        <label class="layui-form-label">工程分类:</label>
-                        <div class="layui-input-block">
-                            <input htmlEscape="false"  readonly="true" id="constructionProjectType"  class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>
-                        </div>
+                </div>
+                <div class="layui-item layui-col-sm6 lw7">
+                    <label class="layui-form-label">工程分类:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" id="constructionProjectType"  class="form-control layui-input" value="${projectRecords.workContractInfo.constructionProjectTypeStr}"/>
                     </div>
                 </div>
             </div>
@@ -492,10 +499,11 @@
                                 <tr id="workClientInfoList${index.index}">
                                     <td class="hide">
                                         <input id="workClientLinkmanList${index.index}_id" name="workClientLinkmanList[${index.index}].id" type="hidden" value="${casePeopleNorm.id}" class="clientInfoId"/>
+                                        <input id="workClientLinkmanList${index.index}_clientId_id" name="workClientLinkmanList[${index.index}].clientId.id" type="hidden" value="${casePeopleNorm.clientId.id}" class="clientInfoId"/>
                                         <input id="workClientLinkmanList${index.index}_delFlag" name="workClientLinkmanList[${index.index}].delFlag" type="hidden" value="0"/>
                                     </td>
                                     <td>
-                                        <input id="workClientLinkmanList${index.index}_office" name="workClientLinkmanList[${index.index}].office" type="text" value="${casePeopleNorm.office}" readonly="true"   class="form-control "/>
+                                        <input id="workClientLinkmanList${index.index}_clientName" name="workClientLinkmanList[${index.index}].clientId.name" type="text" value="${casePeopleNorm.clientId.name}" readonly="true"   class="form-control "/>
                                     </td>
                                     <td>
                                         <input id="workClientLinkmanList${index.index}_name" name="workClientLinkmanList[${index.index}].name" type="text" value="${casePeopleNorm.name}" readonly="true"   class="form-control "/>
@@ -518,10 +526,11 @@
             <tr id="workClientLinkmanList{{idx}}">
                 <td class="hide">
                     <input id="workClientLinkmanList{{idx}}_id" name="workClientLinkmanList[{{idx}}].id" type="hidden" value="{{row.id}}"/>
+                    <input id="workClientLinkmanList{{idx}}_clientId_id" name="workClientLinkmanList[{{idx}}].clientId.id" type="hidden" value="{{row.clientId.id}}"/>
                     <input id="workClientLinkmanList{{idx}}_delFlag" name="workClientLinkmanList[{{idx}}].delFlag" type="hidden" value="0"/>
                 </td>
                 <td>
-                    <input id="workClientLinkmanList{{idx}}_office" name="workClientLinkmanList[{{idx}}].office" type="text" value="{{row.office}}"    class="form-control "/>
+                    <input id="workClientLinkmanList{{idx}}_clientName" name="workClientLinkmanList[{{idx}}].clientId.name" type="text" value="{{row.clientId.name}}"    class="form-control "/>
                 </td>
                 <td>
                     <input id="workClientLinkmanList{{idx}}_name" name="workClientLinkmanList[{{idx}}].name" type="text" value="{{row.name}}"    class="form-control required"/>

+ 30 - 36
src/main/webapp/webpage/modules/sys/userInfo.jsp

@@ -199,45 +199,39 @@
             });
         }
         function openDialog2(title,url,width,height,target) {
-            $.ajax({
-                type:'post',
-                url:'${ctx}/workstaff/workStaffBasicInfo/getApply',
-                success:function(data) {
-                    if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
-                        width = 'auto';
-                        height = 'auto';
-                    } else {//如果是PC端,根据用户设置的width和height显示。
+            if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+                width = 'auto';
+                height = 'auto';
+            } else {//如果是PC端,根据用户设置的width和height显示。
 
+            }
+            top.layer.open({
+                type: 2,
+                area: [width, height],
+                title: title,
+                maxmin: true, //开启最大化最小化按钮
+                content: url,
+                btn: ["提交","关闭"],
+                btn1: function(index, layero){
+                    var body = top.layer.getChildFrame('body', index);
+                    var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+                    var inputForm = body.find('#inputForm');
+                    var top_iframe;
+                    if(target){
+                        top_iframe = target;//如果指定了iframe,则在改frame中跳转
+                    }else{
+                        top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
                     }
-                    top.layer.open({
-                        type: 2,
-                        area: [width, height],
-                        title: title,
-                        maxmin: true, //开启最大化最小化按钮
-                        content: url,
-                        btn: ["提交","关闭"],
-                        btn1: function(index, layero){
-                            var body = top.layer.getChildFrame('body', index);
-                            var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
-                            var inputForm = body.find('#inputForm');
-                            var top_iframe;
-                            if(target){
-                                top_iframe = target;//如果指定了iframe,则在改frame中跳转
-                            }else{
-                                top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
-                            }
-                            inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+                    inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
 
-                            if(iframeWin.contentWindow.doSubmit(index) ){
-                                // top.layer.close(index);//关闭对话框。
-                                setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
-                            }
-                            return false;
-                        },
-                        btn2: function (index) {
+                    if(iframeWin.contentWindow.doSubmit(index) ){
+                        // top.layer.close(index);//关闭对话框。
+                        setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+                    }
+                    return false;
+                },
+                btn2: function (index) {
 
-                        }
-                    });
                 }
             });
         }
@@ -684,7 +678,7 @@
                                             </thead>
                                             <tbody id="educationList">
                                             <c:forEach items="${workStaffBasicInfo.educationList}" var="education" varStatus="varStatus">
-                                                <tr>
+                                                <tr id="${education.id}">
                                                     <td>
                                                             ${education.school}
                                                     </td>

+ 11 - 9
src/main/webapp/webpage/modules/workclientinfo/workClientInfoForm.jsp

@@ -148,14 +148,17 @@
                 $("#inputForm").validate().element($("#uscCode"));
             }
 
-            var arr="${workClientInfo.clientType}".split(',');
-            $('#clientType').selectpicker('val',arr);
+            <%--var arr="${workClientInfo.clientType}".split(',');--%>
+            // $('#clientType').selectpicker('val',arr);
 
             //模糊查询
             $("#name").on("keyup",function () {
-                var keyword = $(this).val();
+                var keyword = $(this).val().trim();
                 if (keyword != null && "" !== keyword) {
-                    fuzzyQuery(keyword);
+                    setTimeout(function(){
+                        fuzzyQuery(keyword);
+                    }, 1500);//延时1秒,
+
                 }
             });
         });
@@ -355,7 +358,7 @@
                 <div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>客户性质:</label>
                     <div class="layui-input-block">
-                        <form:select path="companyType" class="form-control selectpicker required layui-input" id="companyType">
+                        <form:select path="companyType" class="form-control simple-select required" id="companyType">
                             <form:option value="" label="--请选择客户性质--"/>
                             <form:options items="${fns:getMainDictList('company_type')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
 
@@ -372,7 +375,7 @@
                 <div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>所在行业:</label>
                     <div class="layui-input-block">
-                        <form:select path="companyIndustry" class="form-control selectpicker required layui-input">
+                        <form:select path="companyIndustry" class="form-control simple-select required">
                             <form:option value="" label="--请选择行业--"/>
                             <form:options items="${fns:getMainDictList('company_industry')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
                         </form:select>
@@ -408,9 +411,8 @@
                 </div>
                 <div class="layui-item layui-col-sm6 lw7">
                     <label class="layui-form-label"><span class="require-item">*</span>客户类型:</label>
-                    <div class="layui-input-block width-icon">
-
-                        <form:select path="clientType" class="form-control selectpicker required layui-input">
+                    <div class="layui-input-block">
+                        <form:select path="clientType" class="form-control simple-select required">
                             <form:option value="" label="--请选择客户类型--"/>
                             <form:options items="${fns:getMainDictList('client_type')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
                         </form:select>

+ 2 - 2
src/main/webapp/webpage/modules/workcontractinfo/workContractInfoFormEdit.jsp

@@ -300,8 +300,8 @@
                         $("#clientId").val(d.id);
                         $("#clientName").val(d.name);
                         addRow('#workClientInfoList', workClientInfoListRowIdx, workClientInfoListTpl);workClientInfoListRowIdx = workClientInfoListRowIdx + 1;
-                        console.log("---------"+data.companyType+"---------"+data.companyIndustry+"---------"+data.areaName);
-                        console.log("---------"+workClientInfoListRowIdx+"---------"+workClientInfoListTpl);
+                        // console.log("---------"+data.companyType+"---------"+data.companyIndustry+"---------"+data.areaName);
+                        // console.log("---------"+workClientInfoListRowIdx+"---------"+workClientInfoListTpl);
                         var row = workClientInfoListRowIdx - 1 ;
                         $("#"+"workClientInfoList"+row+"_id").val(d.id);
                         $("#"+"workClientInfoList"+row+"_name").val(d.name);

Plik diff jest za duży
+ 1082 - 1080
src/main/webapp/webpage/modules/workstaff/workStaffBasicDetailModifyDirectly.jsp