ソースを参照

Merge remote-tracking branch 'origin/master'

[user3] 3 年 前
コミット
d989857db8
18 ファイル変更5046 行追加21 行削除
  1. 17 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralCostProjectMessageController.java
  2. 16 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageAllController.java
  3. 17 0
      src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageController.java
  4. 40 4
      src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java
  5. 1022 0
      src/main/java/com/jeeplus/modules/workreimbursement/service/WorkReimbursementNewService.java
  6. 21 11
      src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementController.java
  7. 263 0
      src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementNewController.java
  8. 20 0
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageAllDao.xml
  9. 20 0
      src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageDao.xml
  10. 2 1
      src/main/webapp/webpage/modules/ruralprojectrecords/cost/ruralCostProjectMessageList.jsp
  11. 9 0
      src/main/webapp/webpage/modules/ruralprojectrecords/record/projectReportRecordAudit.jsp
  12. 2 1
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/all/ruralProjectMessageAllList.jsp
  13. 2 1
      src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageList.jsp
  14. 900 0
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementCWNewAudit.jsp
  15. 545 0
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewAudit.jsp
  16. 932 0
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewFormAdd.jsp
  17. 1203 0
      src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewModifyApply.jsp
  18. 15 3
      src/main/webapp/webpage/modules/workreimbursement/workReimbursementList.jsp

+ 17 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralCostProjectMessageController.java

@@ -129,6 +129,20 @@ public class RuralCostProjectMessageController extends BaseController {
         if(UserUtils.isManager()){
             model.addAttribute("flag","1");
         }
+        String oldSubmitMoney = "";
+        //判断是否选择紧急项目
+        if(StringUtils.isNotBlank(projectRecords.getSubmitMoney())){
+            switch (projectRecords.getSubmitMoney()){
+                case "3":
+                    oldSubmitMoney = projectRecords.getSubmitMoney();
+                    projectRecords.setSubmitMoney("1");
+                    projectRecords.setEmergencyProject("1");
+                    break;
+                case "1":
+                    projectRecords.setEmergencyProject("0");
+                    break;
+            }
+        }
         //进行查询之后进行任何操作,返回还是查询之后的数据页面
         if (StringUtils.isNotBlank(projectRecords.getToflag())){
             if (projectRecords.getToflag().equals("1")){
@@ -167,6 +181,9 @@ public class RuralCostProjectMessageController extends BaseController {
                 }
             }
         }
+        if(StringUtils.isNotBlank(oldSubmitMoney)){
+            projectRecords.setSubmitMoney(oldSubmitMoney);
+        }
         model.addAttribute("beginDate", projectRecords.getBeginDate());
         model.addAttribute("endDate", projectRecords.getEndDate());
         model.addAttribute("reportSwitch", BaseController.REPORTSWITCH);

+ 16 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageAllController.java

@@ -90,6 +90,20 @@ public class RuralProjectMessageAllController extends BaseController {
         if(UserUtils.isManager()){
             model.addAttribute("flag","1");
         }
+        String oldSubmitMoney = "";
+        //判断是否选择紧急项目
+        if(StringUtils.isNotBlank(projectRecords.getSubmitMoney())){
+            switch (projectRecords.getSubmitMoney()){
+                case "3":
+                    oldSubmitMoney = projectRecords.getSubmitMoney();
+                    projectRecords.setSubmitMoney("1");
+                    projectRecords.setEmergencyProject("1");
+                    break;
+                case "1":
+                    projectRecords.setEmergencyProject("0");
+                    break;
+            }
+        }
         //进行查询之后进行任何操作,返回还是查询之后的数据页面
         if (StringUtils.isNotBlank(projectRecords.getToflag())){
             request.getSession().removeAttribute("searchRuralProjectRecordsAll");
@@ -117,6 +131,8 @@ public class RuralProjectMessageAllController extends BaseController {
             if(null != projectRecords.getWorkContractInfo().getClient()){
                 model.addAttribute("workContractInfoClientName", projectRecords.getWorkContractInfo().getClient().getName());
             }
+        }if(StringUtils.isNotBlank(oldSubmitMoney)){
+            projectRecords.setSubmitMoney(oldSubmitMoney);
         }
         model.addAttribute("beginDate", projectRecords.getBeginDate());
         model.addAttribute("endDate", projectRecords.getEndDate());

+ 17 - 0
src/main/java/com/jeeplus/modules/ruralprojectrecords/web/RuralProjectMessageController.java

@@ -142,6 +142,20 @@ public class RuralProjectMessageController extends BaseController {
         if(UserUtils.isManager()){
             model.addAttribute("flag","1");
         }
+        String oldSubmitMoney = "";
+        //判断是否选择紧急项目
+        if(StringUtils.isNotBlank(projectRecords.getSubmitMoney())){
+            switch (projectRecords.getSubmitMoney()){
+                case "3":
+                    oldSubmitMoney = projectRecords.getSubmitMoney();
+                    projectRecords.setSubmitMoney("1");
+                    projectRecords.setEmergencyProject("1");
+                    break;
+                case "1":
+                    projectRecords.setEmergencyProject("0");
+                    break;
+            }
+        }
         //进行查询之后进行任何操作,返回还是查询之后的数据页面
         if (StringUtils.isNotBlank(projectRecords.getToflag())){
             request.getSession().removeAttribute("searchRuralProjectRecordList");
@@ -163,6 +177,9 @@ public class RuralProjectMessageController extends BaseController {
                 model.addAttribute("workContractInfoClientName", projectRecords.getWorkContractInfo().getClient().getName());
             }
         }
+        if(StringUtils.isNotBlank(oldSubmitMoney)){
+            projectRecords.setSubmitMoney(oldSubmitMoney);
+        }
         model.addAttribute("beginDate", projectRecords.getBeginDate());
         model.addAttribute("endDate", projectRecords.getEndDate());
         model.addAttribute("reportSwitch", BaseController.REPORTSWITCH);

+ 40 - 4
src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java

@@ -3,7 +3,6 @@
  */
 package com.jeeplus.modules.workprojectnotify.web;
 
-import com.alibaba.fastjson.JSON;
 import com.google.common.collect.Lists;
 import com.jeeplus.common.config.Global;
 import com.jeeplus.common.persistence.Page;
@@ -47,7 +46,6 @@ import com.jeeplus.modules.projectFilingBatch.dao.ProjectFilingBatchProInfoDao;
 import com.jeeplus.modules.projectFilingBatch.dao.ProjectFilingbatchRelationDao;
 import com.jeeplus.modules.projectFilingBatch.entity.ProjectFilingBatch;
 import com.jeeplus.modules.projectFilingBatch.entity.ProjectFilingBatchProInfo;
-import com.jeeplus.modules.projectFilingBatch.entity.ProjectFilingBatchTree;
 import com.jeeplus.modules.projectFilingBatch.entity.ProjectFilingbatchRelation;
 import com.jeeplus.modules.projectFilingBatch.service.ProjectFilingBatchService;
 import com.jeeplus.modules.projectcontentinfo.entity.*;
@@ -217,12 +215,10 @@ import com.jeeplus.modules.workstockcontract.entity.WorkStockContract;
 import com.jeeplus.modules.workstockcontract.service.WorkStockContractService;
 import com.jeeplus.modules.workvisa.entity.WorkVisa;
 import com.jeeplus.modules.workvisa.service.WorkVisaService;
-import net.sf.json.JSONArray;
 import org.activiti.engine.HistoryService;
 import org.activiti.engine.history.HistoricProcessInstance;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
-import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
 import org.springframework.ui.Model;
@@ -1137,6 +1133,46 @@ public class WorkProjectNotifyController extends BaseController {
 						return "modules/workreimbursement/workReimbursementFormDetail";
 					}
 
+				}else if (workProjectNotify.getType().equals("102")) {    //新报销
+					WorkReimbursement workReimbursement = workReimbursementService.get(workProjectNotify.getNotifyId());
+					//判断报销类型状态并添加报销类型信息数据
+					if(StringUtils.isNotBlank(workReimbursement.getType())){
+						WorkReimbursementTypeInfo workReimbursementTypeInfo = workReimbursementTypeService.get(workReimbursement.getType());
+						workReimbursement.setWorkReimbursementTypeInfo(workReimbursementTypeInfo);
+						if(StringUtils.isNotBlank(workReimbursementTypeInfo.getStandardDetail())){
+							workReimbursement.setTypeName(workReimbursementTypeInfo.getStandardDetail());
+						}
+					}
+					workReimbursement.setAct(getByAct(workReimbursement.getProcessInstanceId()));
+					if(StringUtils.isNotBlank(workProjectNotify.getHome())){
+						workReimbursement.setHome(workProjectNotify.getHome());
+					}else{
+						workReimbursement.setHome("home");
+					}
+					model.addAttribute("workReimbursement", workReimbursement);
+					String param=UserUtils.getSysParam("check_subjects",UserUtils.getUser());
+					if("是".equals(param)){
+						model.addAttribute("isShow", '1');
+					}else{
+						model.addAttribute("isShow", '0');
+					}
+					if (workProjectNotify.getRemarks().contains("待通知") || "view".equals(workProjectNotify.getView())) {
+						return "modules/workreimbursement/workReimbursementFormDetail";
+					}else if (workProjectNotify.getRemarks().contains("待审批") && !"1".equals(workProjectNotify.getStatus())) {
+						model.addAttribute("identification","workreimbursement");
+						model.addAttribute("identificationName","报销审核意见");
+						if (workReimbursement.getAct() != null && StringUtils.isNotBlank(workReimbursement.getAct().getTaskDefKey()) && "cw".equals(workReimbursement.getAct().getTaskDefKey())) {
+							return "modules/workreimbursement/new/workReimbursementCWNewAudit";
+						}
+						return "modules/workreimbursement/new/workReimbursementNewAudit";
+					} else if (workProjectNotify.getRemarks().contains("重新申请") && !"1".equals(workProjectNotify.getStatus())) {
+						User user=UserUtils.getUser();
+						model.addAttribute("user", user);
+						return "modules/workreimbursement/new/workReimbursementNewModifyApply";
+					} else {
+						return "modules/workreimbursement/workReimbursementFormDetail";
+					}
+
 				} else if (workProjectNotify.getType().equals("16")) {    //合同管理
 					WorkContractInfo workContractInfo = workContractInfoService.get(workProjectNotify.getNotifyId());
 					if(StringUtils.isNotBlank(workContractInfo.getChargeCriterion())){

ファイルの差分が大きいため隠しています
+ 1022 - 0
src/main/java/com/jeeplus/modules/workreimbursement/service/WorkReimbursementNewService.java


+ 21 - 11
src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementController.java

@@ -3,7 +3,6 @@
  */
 package com.jeeplus.modules.workreimbursement.web;
 
-import com.google.common.base.Strings;
 import com.google.common.collect.Lists;
 import com.google.common.collect.Maps;
 import com.jeeplus.common.config.Global;
@@ -30,19 +29,12 @@ import com.jeeplus.modules.sysmtree.entity.SysMtree;
 import com.jeeplus.modules.sysmtree.service.SysMtreeService;
 import com.jeeplus.modules.workactivity.entity.Activity;
 import com.jeeplus.modules.workactivity.service.ActivityService;
-import com.jeeplus.modules.workbidproject.service.WorkBidProjectService;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientAttachment;
 import com.jeeplus.modules.workclientinfo.entity.WorkClientInfo;
 import com.jeeplus.modules.workclientinfo.service.WorkClientInfoService;
-import com.jeeplus.modules.workcontractinfo.entity.WorkContractInfo;
-import com.jeeplus.modules.workcontractinfo.service.WorkContractInfoService;
-import com.jeeplus.modules.workfullmanage.service.WorkFullManageService;
 import com.jeeplus.modules.projectrecord.dao.WorkProjectUserDao;
-import com.jeeplus.modules.workinvoice.entity.WorkInvoice;
 import com.jeeplus.modules.workprojectnotify.entity.WorkProjectNotify;
 import com.jeeplus.modules.workprojectnotify.service.WorkProjectNotifyService;
-import com.jeeplus.modules.workreimbursement.entity.WorkAccount;
-import com.jeeplus.modules.workreimbursement.entity.WorkAccountAudit;
 import com.jeeplus.modules.workreimbursement.entity.WorkReimbursement;
 import com.jeeplus.modules.workreimbursement.entity.WorkReimbursementTypeInfo;
 import com.jeeplus.modules.workreimbursement.service.WorkReimbursementService;
@@ -50,14 +42,12 @@ import com.jeeplus.modules.workreimbursement.service.WorkReimbursementTypeServic
 import com.jeeplus.modules.workreimbursement.utils.VarStr;
 import com.jeeplus.modules.workreimbursementback.entity.WorkReimbursementBack;
 import com.jeeplus.modules.workreimbursementback.service.WorkReimbursementBackService;
-import com.jeeplus.modules.workstaff.entity.WorkStaffBasicInfo;
 import com.jeeplus.modules.worksupplier.entity.WorkSupplier;
 import com.jeeplus.modules.worksupplier.service.WorkSupplierService;
 import org.activiti.engine.RuntimeService;
 import org.activiti.engine.TaskService;
 import org.activiti.engine.runtime.ProcessInstance;
 import org.activiti.engine.task.Task;
-import org.apache.poi.hssf.record.TableRecord;
 import org.apache.shiro.authz.annotation.RequiresPermissions;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Controller;
@@ -72,7 +62,6 @@ import javax.servlet.http.HttpServletResponse;
 import javax.validation.ConstraintViolationException;
 import java.io.UnsupportedEncodingException;
 import java.net.URLDecoder;
-import java.text.ParseException;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
@@ -168,6 +157,11 @@ public class WorkReimbursementController extends BaseController {
 		//查询所有需要当前登录人进行处理的项目信息
 		List<WorkProjectNotify> notifyList = workProjectNotifyService.findList(workProjectNotify);
 
+		//添加发票对应编号
+		workProjectNotify.setType("102");
+		//查询所有需要当前登录人进行处理的项目信息
+		List<WorkProjectNotify> newNotifyList = workProjectNotifyService.findList(workProjectNotify);
+
 		for (WorkReimbursement info: list) {
 			for (WorkProjectNotify notify: notifyList) {
 				if(notify.getNotifyId().equals(info.getId())){
@@ -175,6 +169,22 @@ public class WorkReimbursementController extends BaseController {
 					if("待审批".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
 						info.setNotifyFlag(1);
 					}
+					if("重新申请".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+						info.setNotifyFlag(2);
+					}
+					break;
+				}
+			}
+			//报告归档资料缺失说明修改权限处理
+			for (WorkProjectNotify notify: newNotifyList) {
+				if(notify.getNotifyId().equals(info.getId())){
+					info.setNotifyId(notify.getId());
+					if("重新申请".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+						info.setNotifyFlag(4);
+					}
+					if("待审批".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+						info.setNotifyFlag(3);
+					}
 					break;
 				}
 			}

+ 263 - 0
src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementNewController.java

@@ -0,0 +1,263 @@
+/**
+ * Copyright &copy; 2015-2020 <a href="http://www.jeeplus.org/">JeePlus</a> All rights reserved.
+ */
+package com.jeeplus.modules.workreimbursement.web;
+
+import com.google.common.collect.Maps;
+import com.jeeplus.common.config.Global;
+import com.jeeplus.common.utils.StringUtils;
+import com.jeeplus.common.web.BaseController;
+import com.jeeplus.modules.act.entity.Act;
+import com.jeeplus.modules.act.service.ActTaskService;
+import com.jeeplus.modules.sys.entity.Office;
+import com.jeeplus.modules.sys.entity.User;
+import com.jeeplus.modules.sys.utils.UserUtils;
+import com.jeeplus.modules.workprojectnotify.service.WorkProjectNotifyService;
+import com.jeeplus.modules.workreimbursement.entity.WorkReimbursement;
+import com.jeeplus.modules.workreimbursement.entity.WorkReimbursementTypeInfo;
+import com.jeeplus.modules.workreimbursement.service.WorkReimbursementNewService;
+import com.jeeplus.modules.workreimbursement.service.WorkReimbursementService;
+import com.jeeplus.modules.workreimbursement.service.WorkReimbursementTypeService;
+import com.jeeplus.modules.workreimbursementback.entity.WorkReimbursementBack;
+import com.jeeplus.modules.workreimbursementback.service.WorkReimbursementBackService;
+import org.activiti.engine.RuntimeService;
+import org.activiti.engine.TaskService;
+import org.activiti.engine.runtime.ProcessInstance;
+import org.activiti.engine.task.Task;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Controller;
+import org.springframework.ui.Model;
+import org.springframework.web.bind.annotation.*;
+import org.springframework.web.servlet.mvc.support.RedirectAttributes;
+
+import javax.servlet.http.HttpServletRequest;
+import java.util.List;
+import java.util.Map;
+
+/**
+ * 财务报销新Controller
+ * @author 徐滕
+ * @version 2021-07-22
+ */
+@Controller
+@RequestMapping(value = "${adminPath}/workReimbursementNew/workReimbursementNew")
+public class WorkReimbursementNewController extends BaseController {
+
+	@Autowired
+	private WorkReimbursementService workReimbursementService;
+	@Autowired
+	private WorkReimbursementNewService workReimbursementNewService;
+
+	@Autowired
+	protected RuntimeService runtimeService;
+
+	@Autowired
+	protected TaskService taskService;
+
+	@Autowired
+	private ActTaskService actTaskService;
+
+	@Autowired
+	private HttpServletRequest request;
+	@Autowired
+	private WorkReimbursementBackService workReimbursementBackService;
+	@Autowired
+	private WorkReimbursementTypeService workReimbursementTypeService;
+	@Autowired
+	protected WorkProjectNotifyService workProjectNotifyService;
+
+	@ModelAttribute
+	public WorkReimbursement get(@RequestParam(required=false) String id) {
+
+		WorkReimbursement entity = null;
+		if (StringUtils.isNotBlank(id)){
+			entity = workReimbursementService.get(id);
+		}
+		if (entity == null){
+			entity = new WorkReimbursement();
+		}
+		return entity;
+	}
+
+	/**
+	 * 查看,增加,编辑报销单表单页面
+	 */
+	@RequestMapping(value = "form")
+	public String form(WorkReimbursement workReimbursement,Model model) {
+		workReimbursementService.isNotProject(workReimbursement);
+		String view = "workReimbursementNewFormAdd";
+		Office office = UserUtils.getSelectOffice();
+		String tabId = request.getParameter("tabId");
+		//判断报销类型状态并添加报销类型信息数据
+		if(StringUtils.isNotBlank(workReimbursement.getType())){
+			WorkReimbursementTypeInfo workReimbursementTypeInfo = workReimbursementTypeService.get(workReimbursement.getType());
+			workReimbursement.setWorkReimbursementTypeInfo(workReimbursementTypeInfo);
+			if(StringUtils.isNotBlank(workReimbursementTypeInfo.getStandardDetail())){
+				workReimbursement.setTypeName(workReimbursementTypeInfo.getStandardDetail());
+			}
+		}
+		if("1".equals(tabId)){
+			view = "workReimbursementFormDetail";
+		}else if("3".equals(tabId)){
+			ProcessInstance processInstance = actTaskService.getProcIns(workReimbursement.getProcessInstanceId());
+			if (processInstance!=null) {
+				Task taskInfok = actTaskService.getCurrentTaskInfo(processInstance);
+				Act act = new Act();
+				act.setTaskId(taskInfok.getId());
+				act.setTaskName(taskInfok.getName());
+				act.setTaskDefKey(taskInfok.getTaskDefinitionKey());
+				act.setProcDefId(taskInfok.getProcessDefinitionId());
+				act.setProcInsId(taskInfok.getProcessInstanceId());
+				act.setTask(taskInfok);
+				workReimbursement.setAct(act);
+				view = "workReimbursementNewModifyApply";
+			}
+		}
+		// 环节编号
+		String taskDefKey = workReimbursement.getAct().getTaskDefKey();
+		if (StringUtils.isNotBlank(taskDefKey) && ("bmzr".equals(taskDefKey) ||
+				"fgld".equals(taskDefKey)
+				 || "zjl".equals(taskDefKey)
+				|| taskDefKey.contains("cwzj")|| taskDefKey.contains("cn") || taskDefKey.contains("task"))){
+			view = "workReimbursementAudit";
+		}else  if (StringUtils.isNotBlank(taskDefKey) && "cw".equals(taskDefKey)){
+			view = "workReimbursementCWAudit";
+		}else if (StringUtils.isNotBlank(taskDefKey) && !taskDefKey.equals("modifyApply")){
+			view = "workReimbursementAudit";
+		}
+		String param=UserUtils.getSysParam("check_subjects",UserUtils.getUser());
+		if("是".equals(param)){
+			model.addAttribute("isShow", '1');
+		}else{
+			model.addAttribute("isShow", '0');
+		}
+		if (workReimbursement!=null && StringUtils.isBlank(workReimbursement.getSubmitterId())){
+			workReimbursement.setSubmitterId(UserUtils.getUser().getId());
+			workReimbursement.setSubmitterName(UserUtils.getUser().getName());
+			if(UserUtils.getBasicInfo()!=null){
+				workReimbursement.setBankCard(UserUtils.getBasicInfo().getBankCard());
+			}
+		}
+		if (workReimbursement!=null && workReimbursement.getCreateBy()==null){
+			workReimbursement.setCreateBy(UserUtils.getUser());
+			workReimbursement.setUserName(UserUtils.getUser().getName());
+		}
+		if (workReimbursement!=null && StringUtils.isBlank(workReimbursement.getOfficeId())){
+			workReimbursement.setOfficeId(office.getId());
+			workReimbursement.setOfficeName(office.getTopCompany());
+		}
+		if ("workReimbursementNewFormAdd".equals(view)&&"0".equals(tabId)){
+			if(UserUtils.getBasicInfo()!=null && StringUtils.isNotBlank(UserUtils.getBasicInfo().getId())) {
+				List<WorkReimbursementBack> backList = workReimbursementBackService.findLoanList(UserUtils.getBasicInfo().getId());
+				workReimbursement.setReimbursementBackList(backList);
+				workReimbursement.setAchivesId(UserUtils.getBasicInfo().getId());
+			}
+		}
+		if (StringUtils.isNotBlank(workReimbursement.getCreateBy().getId())){
+			User user=UserUtils.get(workReimbursement.getCreateBy().getId());
+			workReimbursement.setCreateBy(user);
+		}
+
+		model.addAttribute("workReimbursement", workReimbursement);
+		return "modules/workreimbursement/new/"+view;
+	}
+
+	/**
+	 * 保存提交报销单
+	 * 启动流程
+	 */
+	@RequestMapping(value = "save")
+	public String save(WorkReimbursement workReimbursement,
+					   Model model,
+					   RedirectAttributes redirectAttributes) throws Exception{
+		if (!beanValidator(model, workReimbursement)){
+			return form(workReimbursement, model);
+		}
+		User user = workReimbursement.getCreateBy();
+		String sta = workReimbursement.getStatus();
+		//状态设置为审核中
+		workReimbursement.setStatus("2");
+		String processInstanceId ="";
+		if (user!=null && StringUtils.isNotBlank(user.getId()) && StringUtils.isNotBlank(sta) && "3".equals(sta)){
+			processInstanceId = workReimbursementService.get(workReimbursement.getId()).getProcessInstanceId();
+		}
+		try {
+			Map<String, Object> variables = Maps.newHashMap();
+			workReimbursement.setCompanyId(UserUtils.getSelectCompany().getId());
+			workReimbursement.setCreateOffice(UserUtils.getSelectOffice().getId());
+			String str = workReimbursementNewService.save(workReimbursement, variables,processInstanceId);
+			if (StringUtils.isNotBlank(str)){
+				addMessage(redirectAttributes, "报销申请提交失败:"+str);
+			}else {
+				addMessage(redirectAttributes, "报销申请已经提交");
+			}
+
+		} catch (Exception e) {
+			logger.info("Exception e:"+e);
+			addMessage(redirectAttributes, "报销申请提交失败!");
+			addMessage(redirectAttributes, "系统内部错误");
+		}
+		return "redirect:" + adminPath +"/workreimbursement/workReimbursement/?repage";
+	}
+
+	/**
+	 * 工单执行(完成任务)
+	 * @param model
+	 * @return
+	 */
+	@RequestMapping(value = "saveAudit")
+	public String saveAudit(WorkReimbursement workReimbursement, Model model,
+							RedirectAttributes redirectAttributes) {
+		try {
+			// 对不同环节的业务逻辑进行操作
+			String taskDefKey = workReimbursement.getAct().getTaskDefKey();
+			List<User> users = null;
+			if ("bmzr".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),2);
+				if (users==null )
+					//users = UserUtils.getByRoleActivityEnname("fgld",2,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+					users = UserUtils.getByRoleActivityEnname("cwzg", 3, workReimbursement.getOfficeId(), "8", workReimbursement.getCreateBy());
+			}else  if ("cw".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),3);
+				if (users==null )
+					users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
+				users = UserUtils.getByRoleActivityEnname("zjbfzribvf",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+			}else  if ("gsld".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),3);
+				if (users==null )
+					users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
+				//users = UserUtils.getByRoleActivityEnname("zjl",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+			}/*else  if ("zjl".equals(taskDefKey)){
+				*//*users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),5);
+				if (users==null )
+					users = UserUtils.getByRoleActivityEnname("cwfgld",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());*//*
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
+			}*//*else if ("cwzj".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),6);
+				if (users==null )
+					users = UserUtils.getByRoleActivityEnname("cn",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+			}else if ("cn".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
+			}*/else if ("modifyApply".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
+			}
+            String flag = workReimbursement.getAct().getFlag();
+            if ("yes".equals(flag) &&(users==null || users.size()==0)){
+				addMessage(redirectAttributes, "审批失败,审批人为空,请联系管理员!");
+			}else {
+				String str = workReimbursementNewService.auditSave(workReimbursement,users);
+				addMessage(redirectAttributes, str);
+			}
+		}catch (Exception e){
+			logger.info("Exception e:"+e);
+			addMessage(redirectAttributes, "审批失败");
+		}
+		if (StringUtils.isNotBlank(workReimbursement.getHome()) && "home".equals(workReimbursement.getHome())) {
+			return "redirect:" + Global.getAdminPath() + "/home/?repage";
+		}else if (StringUtils.isNotBlank(workReimbursement.getHome()) && "notifyList".equals(workReimbursement.getHome())){
+			return "redirect:" + Global.getAdminPath() + "/workprojectnotify/workProjectNotify/list/?repage";
+		} else {
+			return "redirect:" + Global.getAdminPath() + "/workreimbursement/workReimbursement/?repage";
+		}
+	}
+}

+ 20 - 0
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageAllDao.xml

@@ -204,6 +204,16 @@
 			<if test="endDate !=null">
 				AND a.create_date &lt; #{endDate}
 			</if>
+			<if test="emergencyProject !=null and emergencyProject != ''">
+				<choose>
+					<when test="emergencyProject == 0">
+						AND (a.emergency_project = #{emergencyProject} or a.emergency_project is null)
+					</when>
+					<otherwise>
+						AND a.emergency_project = #{emergencyProject}
+					</otherwise>
+				</choose>
+			</if>
 			<!--<if test="createBy != null and createBy.id !=null and createBy.id !=''">
 				AND a.create_by = #{createBy.id}
  			</if>-->
@@ -382,6 +392,16 @@
 			<if test="endDate !=null">
 				AND a.create_date &lt; #{endDate}
 			</if>
+			<if test="emergencyProject !=null and emergencyProject != ''">
+				<choose>
+					<when test="emergencyProject == 0">
+						AND (a.emergency_project = #{emergencyProject} or a.emergency_project is null)
+					</when>
+					<otherwise>
+						AND a.emergency_project = #{emergencyProject}
+					</otherwise>
+				</choose>
+			</if>
 			<!--<if test="createBy != null and createBy.id !=null and createBy.id !=''">
 				AND a.create_by = #{createBy.id}
 			</if>-->

+ 20 - 0
src/main/resources/mappings/modules/ruralprojectrecords/RuralProjectMessageDao.xml

@@ -435,6 +435,16 @@
             <if test="endDate !=null">
                 AND a.create_date &lt; #{endDate}
             </if>
+            <if test="emergencyProject !=null and emergencyProject != ''">
+				<choose>
+					<when test="emergencyProject == 0">
+						AND (a.emergency_project = #{emergencyProject} or a.emergency_project is null)
+					</when>
+					<otherwise>
+						AND a.emergency_project = #{emergencyProject}
+					</otherwise>
+				</choose>
+            </if>
 			<!--<if test="createBy != null and createBy.id !=null and createBy.id !=''">
 				AND a.create_by = #{createBy.id}
  			</if>-->
@@ -608,6 +618,16 @@
             <if test="endDate !=null">
                 AND a.create_date &lt; #{endDate}
             </if>
+			<if test="emergencyProject !=null and emergencyProject != ''">
+				<choose>
+					<when test="emergencyProject == 0">
+						AND (a.emergency_project = #{emergencyProject} or a.emergency_project is null)
+					</when>
+					<otherwise>
+						AND a.emergency_project = #{emergencyProject}
+					</otherwise>
+				</choose>
+			</if>
 			<!--<if test="createBy != null and createBy.id !=null and createBy.id !=''">
 				AND a.create_by = #{createBy.id}
 			</if>-->

+ 2 - 1
src/main/webapp/webpage/modules/ruralprojectrecords/cost/ruralCostProjectMessageList.jsp

@@ -595,7 +595,8 @@
 								<form:select path="submitMoney" class="form-control simple-select">
 									<form:option value="" label=""/>
 									<form:option value="2" label="A级"/>
-									<form:option value="1" label="B级"/>
+									<form:option value="3" label="B级紧急"/>
+									<form:option value="1" label="B级非紧急"/>
 								</form:select>
 							</div>
 						</div>

+ 9 - 0
src/main/webapp/webpage/modules/ruralprojectrecords/record/projectReportRecordAudit.jsp

@@ -81,6 +81,15 @@
 				$(id).removeAttr("class","hide");
 
 			})
+			if ("${projectReportData.contractCategory}" !=null){
+				if("${projectReportData.contractCategory}"=='1'){
+					$("#contractFee").parent().parent().hide();
+					$("#contractRate").parent().parent().show();
+				}else if("${projectReportData.contractCategory}"=='0'){
+					$("#contractFee").parent().parent().show();
+					$("#contractRate").parent().parent().hide();
+				}
+			}
         });
 	</script>
 </head>

+ 2 - 1
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/all/ruralProjectMessageAllList.jsp

@@ -696,7 +696,8 @@
 								<form:select path="submitMoney" class="form-control simple-select">
 									<form:option value="" label=""/>
 									<form:option value="2" label="A级"/>
-									<form:option value="1" label="B级"/>
+									<form:option value="3" label="B级紧急"/>
+									<form:option value="1" label="B级非紧急"/>
 								</form:select>
 							</div>
 						</div>

+ 2 - 1
src/main/webapp/webpage/modules/ruralprojectrecords/ruralporjectmessage/ruralProjectMessageList.jsp

@@ -593,7 +593,8 @@
 								<form:select path="submitMoney" class="form-control simple-select">
 									<form:option value="" label=""/>
 									<form:option value="2" label="A级"/>
-									<form:option value="1" label="B级"/>
+									<form:option value="3" label="B级紧急"/>
+									<form:option value="1" label="B级非紧急"/>
 								</form:select>
 							</div>
 						</div>

+ 900 - 0
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementCWNewAudit.jsp

@@ -0,0 +1,900 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+    <title>报销审核</title>
+    <meta name="decorator" content="default"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script type="text/javascript">
+        var validateForm;
+        var state;//考核科目显示隐藏
+        function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+            if(validateForm.form()){
+                var ss= document.getElementById("iframe").contentWindow.document.getElementById("opinion").value
+                $("#opinion").val(ss);
+                if(obj == 1){
+                    $('#flag').val('yes');
+                    var idx1 = $("#contentTable tbody").length;
+                    /*for(var i = 0;i < idx1; i++){
+                        var idx2 = $("#workAccountList"+i+" tr").length;
+                        var financialSubjectss = $("#workAccountList"+i+"_financialSubjectss").val();
+                        var financialSubjects = $("#workAccountList"+i+"_financialSubjects").val();
+                        var moneyAbstract = $("#workAccountList"+i+"_moneyAbstract").val();
+                        var totalMoney = $("#workAccountList"+i+"_money").val();
+                            if(financialSubjectss==null || financialSubjectss==''|| financialSubjectss == undefined){
+                                if(financialSubjects==null || financialSubjects==''|| financialSubjects == undefined){
+                                    parent.layer.msg("财务科目为空!", {icon: 5});
+                                    return false;
+                                }
+                            }
+                        if(moneyAbstract==null || moneyAbstract==''|| moneyAbstract == undefined){
+                            parent.layer.msg("报销费用摘要不能为空!", {icon: 5});
+                            return false;
+                        }
+                        var auditMoney = "0.00";
+                        for(var j = 0;j < idx2; j++){
+                            var checkSubjects = $("#workAccountList"+i+"_audit"+j+"_checkSubjects").val();
+                            var money = $("#workAccountList"+i+"_audit"+j+"_money").val();
+                            var u8Subjects = $("#workAccountList"+i+"_audit"+j+"_u8Subjects").val();
+                            if(state=='1'){
+                            if (checkSubjects==null || checkSubjects=='' || checkSubjects == undefined){
+                                parent.layer.msg("考核科目不能为空!", {icon: 5});
+                                return false;
+                            }
+                            }
+                            if (money==null || money==''|| money == undefined){
+                                parent.layer.msg("考核金额不能为空!", {icon: 5});
+                                return false;
+                            }
+                            if (u8Subjects==null || u8Subjects==''|| u8Subjects == undefined){
+                                parent.layer.msg("U8科目不能为空!", {icon: 5});
+                                return false;
+                            }
+                            auditMoney = (parseFloat(auditMoney) + parseFloat(money)).toFixed(2);
+                        }
+                        var s = parseFloat(totalMoney) - parseFloat(auditMoney);
+                        if (s<0){
+                            parent.layer.msg("考核金额不能超过报销金额,请确认输入!", {icon: 5});
+                            return false;
+                        }
+                        if(parseFloat($("#backmoneys").val())<0){
+                            parent.layer.msg("实际报销总额不能为负数,请确认输入!", {icon: 5});
+                            return false;
+                        }
+                    }*/
+                }else{
+                    $('#flag').val('no');
+                }
+                $("#inputForm").submit();
+                return true;
+            }else {
+                parent.layer.msg("信息未填写完整!", {icon: 5});
+            }
+
+            return false;
+        }
+        $(document).ready(function() {
+            layui.use('form', function () {
+                var form = layui.form;
+                form.render();
+            });
+            if (${workReimbursement.ext == 0}){
+                $(".td1").removeClass("hide");
+                $(".project_reimbursement_div").show();
+                $(".not_project_reimbursement_div").hide();
+            }else {
+                $(".td1").addClass("hide");
+                $(".project_reimbursement_div").hide();
+                $(".not_project_reimbursement_div").show();
+            }
+            if (${workReimbursement.isPublic =='0'}){
+                $(".isPublic").addClass("hide");
+            }else {
+                $(".isPublic").removeClass("hide");
+            }
+            state=${isShow};
+            if (state =='0'){
+                $(".isShow").hide();
+            }else {
+                $(".isShow").show();
+            }
+            if($("#backmoney").val()==null||$("#backmoney").val()==''){
+                $("#backmoney").val('0');
+            }
+            $("#name").focus();
+            validateForm = $("#inputForm").validate({
+                submitHandler: function(form){
+                    loading('正在提交,请稍等...');
+                    form.submit();
+                },
+                errorContainer: "#messageBox",
+                errorPlacement: function(error, element) {
+                    $("#messageBox").text("输入有误,请先更正。");
+                    if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+                        error.appendTo(element.parent().parent());
+                    } else {
+                        error.insertAfter(element);
+                    }
+                }
+            });
+        });
+
+        function getEntity(form) {
+            var result = {};
+            $(form).find("[data-field]").each(function() {
+                var field = $(this).attr("data-field");
+                var val;
+
+                if ($(this).attr('type') == 'checkbox') {
+                    val = $(this).prop('checked');
+                } else if ($(this).attr('type') == 'radio') {
+                    val = $(this).prop('checked');
+                } else {
+                    val = $(this).val();
+                }
+                // 获取单个属性的值,并扩展到result对象里面
+                getField(field.split('.'), val, result);
+            });
+            return result;
+        }
+
+        function getField(fieldNames, value, result) {
+            if (fieldNames.length > 1) {
+                for (var i = 0; i < fieldNames.length - 1; i++) {
+                    if (result[fieldNames[i]] == undefined) {
+                        result[fieldNames[i]] = {}
+                    }
+                    result = result[fieldNames[i]];
+                }
+                result[fieldNames[fieldNames.length - 1]] = value;
+            } else {
+                result[fieldNames[0]] = value;
+            }
+        }
+
+        function addRow(list, idx, tpl, row){
+            var size = list.replace("#workAccountList","");
+            var idx1 = $("#workAccountList"+size+" tr").length;
+            tpl = tpl.replace("workAccountList[0]","workAccountList["+size+"]");
+            tpl = tpl.replace("workAccountList[0]","workAccountList["+size+"]");
+            tpl = tpl.replace("workAccountAuditList[0]","workAccountAuditList["+idx1+"]");
+            tpl = tpl.replace("workAccountAuditList[0]","workAccountAuditList["+idx1+"]");
+            tpl = tpl.replace("workAccountAuditList[0]","workAccountAuditList["+idx1+"]");
+            tpl = tpl.replace("workAccountAuditList[0]","workAccountAuditList["+idx1+"]");
+            tpl = tpl.replace(/\audit0/g,"audit"+idx1);
+            tpl = tpl.replace(/\workAccountList0/g,"workAccountList"+size);
+            var ext = $("#ext").val();
+            if(ext == 0){
+                tpl = tpl.replace("not_project_reimbursement_div","not_project_reimbursement_div\" style=\"display:none;\"");
+                tpl = tpl.replace("project_reimbursement_div\" style=\"display:none;\"","project_reimbursement_div");
+            }else {
+                tpl = tpl.replace("project_reimbursement_div","project_reimbursement_div\" style=\"display:none;\"");
+                tpl = tpl.replace("not_project_reimbursement_div\" style=\"display:none;\"","not_project_reimbursement_div\"");
+            }
+            bornTemplete(list, idx, tpl, row, idx1);
+        }
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+            if (state =='0'){
+                $(".isShow").hide();
+            }else {
+                $(".isShow").show();
+            }
+        }
+        function delRow(obj){
+            $(obj).parent().parent().remove();
+            getMoney();
+        }
+
+        function getMoney(){
+            var money = 0;
+            $(".checkMoney").each(function () {
+               if($(this).val()!=undefined && isNumber($(this).val())){
+                   money = (parseFloat(money) + parseFloat($(this).val())).toFixed(2);
+               }
+            })
+            $("#checkMoneys").val(formatNumber(money,2));
+            $("#sumcheckMoneys").val(money);
+            var a = parseFloat($("#backmoney").val());
+            var backmoneys=(parseFloat(money)-  parseFloat($("#backmoney").val())).toFixed(2);
+            if(isNaN(backmoneys)){
+                $("#backmoneys").val("");
+                $("#sumbackmoneys").val("");
+            }else{
+                $("#backmoneys").val(formatNumber(backmoneys,2));
+                $("#sumbackmoneys").val(backmoneys);
+            }
+        }
+        function isNumber(val){
+            if(val === "" || val ==null){
+                return false;
+            }
+            var regPos = /^\d+(\.\d+)?$/; //非负浮点数
+            var regNeg = /^(-(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*)))$/; //负浮点数
+            if(regPos.test(val) || regNeg.test(val)){
+                return true;
+            }else{
+                return false;
+            }
+        }
+        //财务格式
+        function formatNumber(num, precision, separator) {
+            var parts;
+            if (!isNaN(parseFloat(num)) && isFinite(num)) {
+                num = Number(num);
+                num = (typeof precision !== 'undefined' ? num.toFixed(precision) : num).toString();
+                parts = num.split('.');
+                parts[0] = parts[0].toString().replace(/(\d)(?=(\d{3})+(?!\d))/g, '$1' + (separator || ','));
+                return parts.join('.');
+            }
+            return NaN;
+        }
+    </script>
+    <style>
+        /*超过5个汉字,调整label的长度,以下是配套的*/
+        .layui-item .layui-form-label{
+            width:90px;
+        }
+        .form-group .layui-item .layui-input-block,
+        .query .layui-input-block {
+            margin-left: 116px;
+        }
+    </style>
+</head>
+<body>
+<div class="single-form">
+    <div class="container view-form">
+        <form:form id="inputForm" modelAttribute="workReimbursement" enctype="multipart/form-data" action="${ctx}/workReimbursementNew/workReimbursementNew/saveAudit" method="post" class="form-horizontal layui-form">
+        <form:hidden path="id"/>
+        <form:hidden path="home"/>
+        <form:hidden path="ext"/>
+        <form:hidden path="act.taskId"/>
+        <form:hidden path="act.taskName"/>
+        <form:hidden path="act.taskDefKey"/>
+        <form:hidden path="act.procInsId"/>
+        <form:hidden path="act.procDefId"/>
+        <form:hidden id="flag" path="act.flag"/>
+         <input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
+            <div class="form-group layui-row first ">
+                <div class="form-group-label"><h2>基础信息</h2></div>
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">报销人:</label>
+                    <div class="layui-input-block">
+                        <form:input path="submitterName" htmlEscape="false"  id="submitterName"  class="form-control layui-input" value = "${workReimbursement.submitterName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">报销编号:</label>
+                    <div class="layui-input-block">
+                        <div class="input-group">
+                            <input htmlEscape="false"  readonly="true"  class="form-control layui-input" value="${workReimbursement.number}"/>
+                            <span class="input-group-btn">
+                        <label class="form-status"><c:choose><c:when test="${not empty workReimbursement.status}">${fns:getDictLabel(workReimbursement.status, 'audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                     </span>
+                        </div>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">所属部门:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value = "${workReimbursement.officeName}"/>
+                    </div>
+                </div>
+                <%--<div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">银行卡号:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false" readonly="true"  class="form-control layui-input" value = "${workReimbursement.bankCard}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">报销类型:</label>
+                    <div class="layui-input-block">
+                        <input readonly="true" htmlEscape="false" class="form-control layui-input"
+                               value="<c:choose><c:when test="${workReimbursement.ext == 0}">项目报销</c:when><c:otherwise>非项目报销</c:otherwise></c:choose>"/>
+                    </div>
+                </div>
+
+                <div class="layui-item layui-col-sm6 td1">
+                    <label class="layui-form-label">报销项目:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.project.projectName}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">报销类别:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.typeName}"/>
+                    </div>
+                </div>
+                    &lt;%&ndash;<div class="layui-item layui-col-sm6 td1">
+                        <label class="layui-form-label">项目负责人:</label>
+                        <div class="layui-input-block">
+                            <input htmlEscape="false"  readonly="true"  class="form-control layui-input" value="${workReimbursement.projectMasterName}"/>
+                        </div>
+                    </div>&ndash;%&gt;
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label double-line">是否对公报销:</label>
+                    <div class="layui-input-block">
+                        <input readonly="true" htmlEscape="false" class="form-control layui-input"
+                               value="<c:choose><c:when test="${workReimbursement.isPublic == '0'}">否</c:when><c:otherwise>是</c:otherwise></c:choose>"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 isPublic">
+                    <label class="layui-form-label">公司名称:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.comname}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 isPublic">
+                    <label class="layui-form-label">开户行:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.bank}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 isPublic">
+                    <label class="layui-form-label">银行账号:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.bankNo}"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">报销人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.submitterName}"/>
+                    </div>
+                </div>--%>
+
+                <div class="layui-item layui-col-sm6">
+                    <label class="layui-form-label">报销日期:</label>
+                    <div class="layui-input-block">
+                        <input readonly="readonly" class="form-control layui-input" value="<fmt:formatDate value="${workReimbursement.submitterDate}" pattern="yyyy-MM-dd"/>"/>
+                    </div>
+                </div>
+                <div class="layui-item layui-col-sm6 with-textarea">
+                    <label class="layui-form-label ">备注:</label>
+                    <div class="layui-input-block">
+                        <form:textarea path="remarks" htmlEscape="false" rows="4"  maxlength="255" value="${workReimbursement.remarks}"  class="form-control "/>
+                    </div>
+                </div>
+            </div>
+            <%--<div class="form-group layui-row">
+                <div class="form-group-label"><h2>借款明细</h2></div>
+                <div class="layui-item layui-col-xs12 form-table-container" >
+                    <table id="contentTable3" class="table table-bordered table-condensed can-edit no-bottom-margin">
+                        <thead>
+                        <tr>
+                            <th width="190px">借款日期</th>
+                            <th width="190px">借款类型</th>
+                            <th width="190px">借款项目</th>
+                            <th width="190px">借款金额</th>
+                            <th width="180px">未还金额</th>
+                            <th width="100px">本次还款</th>
+                            <th width="120px">借款编号</th>
+                        </tr>
+                        </thead>
+                        <tbody id="reimbursementBackList">
+                        <c:if test="${not empty workReimbursement.reimbursementBackList}">
+                            <c:forEach items="${workReimbursement.reimbursementBackList}" var="reimbursementBack" varStatus="index">
+                                <tr id="reimbursementBackList${index.index}">
+                                    <td class="hide">
+                                        <input id="reimbursementBackList${index.index}_id" name="reimbursementBackList[${index.index}].id" type="hidden" value="${reimbursementBack.id}"/>
+                                        <input id="reimbursementBackList${index.index}_workLoanId" name="reimbursementBackList[${index.index}].workLoan.id" type="hidden" value="${reimbursementBack.workLoan.id}"/>
+                                        <input id="reimbursementBackList${index.index}_delFlag" name="reimbursementBackList[${index.index}].delFlag" type="hidden" value="0"/>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_1"   type="text" maxlength="20"  readonly="true" class=" form-control layui-input"
+                                               value="<fmt:formatDate value="${reimbursementBack.workLoan.loanDate}" pattern="yyyy-MM-dd"/>"/>
+                                        </input>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_2"  readonly="true" type="text" value="${reimbursementBack.workLoan.type}"   class="form-control"/>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_3"  readonly="true" type="text" value="${reimbursementBack.workLoan.projectRecords.projectName}"   class="form-control"/>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_4"  readonly="true" type="text" value="${reimbursementBack.workLoan.money}"   class="form-control"/>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_5"  readonly="true" type="text" value="${reimbursementBack.workLoan.notRepay}"   class="form-control"/>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_6" readonly="true"  name="reimbursementBackList[${index.index}].money" type="text" value="${reimbursementBack.money}"   class="form-control number "/>
+                                    </td>
+                                    <td>
+                                        <input id="reimbursementBackList${index.index}_7"  readonly="true" type="text" value="${reimbursementBack.workLoan.num}"   class="form-control"/>
+                                    </td>
+                                </tr>
+                            </c:forEach>
+                        </c:if>
+                        </tbody>
+                    </table>
+                    <table id="contentMoneys1" class="table table-bordered table-condensed can-edit summary">
+                        <tr>
+                            <td  style="width:190px;vertical-align:middle;text-align: center;"><label><font color="red">*</font>合计</label></td>
+                            <td  width="190px" style="vertical-align:middle;text-align: center;">
+                                -
+                            </td >
+                            <td  width="190px" style="vertical-align:middle;text-align: center;">
+                                -
+                            </td>
+                            <td  width="190px" style="vertical-align:middle;text-align: center;">
+                                -
+                            </td>
+                            <td width="180px" style="vertical-align:middle;text-align: center;">
+                                -
+                            </td>
+                            <td width="100px" style="vertical-align:middle;text-align: center;">
+                                <input  id="backmoney" value="${workReimbursement.backmoney}" name="backmoney" htmlEscape="false" readonly="true"   maxlength="12"  class="form-control "/>
+                            </td>
+                            <td  width="120px" style="vertical-align:middle;text-align: center;">
+                                -
+                            </td>
+                        </tr>
+                    </table>
+                </div>
+            </div>--%>
+        <%--<div class="form-group layui-row">
+            <div class="form-group-label"><h2>报销详情</h2></div>
+            <div class="layui-item layui-col-xs12 form-table-container" >
+                <table id="contentTable" class="table table-bordered table-condensed no-bottom-margin can-edit">
+                    <thead>
+                    <tr>
+                        <th width="150px"><span class="require-item">*</span>财务科目</th>
+                        <th><span class="require-item">*</span>报销费用摘要</th>
+                        <th width="150px"><font color="red">*</font>发票类型</th>
+                        <th width="150px">报销费用(元)</th>
+                        <th width="80px">备注</th>
+                        <th width="150px"><span class="require-item">*</span>U8科目</th>
+                        <th width="150px" class="isShow"><span class="require-item">*</span>考核科目</th>
+                        <th width="120px"><span class="require-item">*</span>考核金额(元)</th>
+                        <th width="80px">操作</th>
+                    </tr>
+                    </thead>
+                    <c:if test="${not empty workReimbursement.workAccountList}">
+                    <c:forEach items="${workReimbursement.workAccountList}" var="workAccount" varStatus="index">
+                    <tbody id="workAccountList${index.index}">
+                    <tr id="workAccountList${index.index}_audit0">
+                        <td class="hide">
+                            <input id="workAccountList${index.index}_id" name="workAccountList[${index.index}].id" type="hidden" value="${workAccount.id}"/>
+                            <input id="workAccountList${index.index}_delFlag" name="workAccountList[${index.index}].delFlag" type="hidden" value="0"/>
+                            <input id="workAccountList${index.index}_money" name="workAccountList[${index.index}].money" type="hidden" value="${workAccount.money}"/>
+                        </td>
+                        <td>
+                            <div class="project_reimbursement_div">
+                                <form:select id="workAccountList${index.index}_financialSubjects" path="workAccountList[${index.index}].financialSubjects" class="form-control ">
+                                    <form:option value="" label=""/>
+                                    <form:options items="${fns:getMainDictList('project_reimbursement')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+                                </form:select>
+                            </div>
+                            <div class="not_project_reimbursement_div" style="display:none;">
+                                <form:select id="workAccountList${index.index}_financialSubjectss" path="workAccountList[${index.index}].financialSubjectss" class="form-control ">
+                                    <form:option value="" label=""/>
+                                    <form:options items="${fns:getMainDictList('not_project_reimbursement')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+                                </form:select>
+                            </div>
+                        </td>
+                        <td>
+                            <input id="workAccountList${index.index}_moneyAbstract"  name="workAccountList[${index.index}].moneyAbstract"  type="text" value="${workAccount.moneyAbstract}"    class="form-control "/>
+                        </td>
+                        <td style="text-align: center; vertical-align:middle;">
+                                ${workAccount.invoiceType}
+                        </td>
+                        <td style="text-align: center; vertical-align:middle;">
+                            <fmt:formatNumber value="${workAccount.money}" pattern="#,#00.00"/>
+                        </td>
+                        <td style="text-align: center; vertical-align:middle;" title="${workAccount.remarks}">
+                                ${workAccount.remarks}
+                        </td>
+                        <td>
+                            <form:select id="workAccountList${index.index}_audit0_u8Subjects" path="workAccountList[${index.index}].workAccountAuditList[0].u8Subjects" class="form-control ">
+                                <form:option value="" label=""/>
+                                <form:options items="${fns:getMainDictList('u8_subjects')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+                            </form:select>
+                        </td>
+                        <td class="isShow">
+                            <form:select id="workAccountList${index.index}_audit0_checkSubjects" path="workAccountList[${index.index}].workAccountAuditList[0].checkSubjects" class="form-control ">
+                                <form:option value="" label=""/>
+                                <form:options items="${fns:getMainDictList('check_subjects')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+                            </form:select>
+                        </td>
+                        <td>
+                            <input id="workAccountList${index.index}_audit0_money" onchange="getMoney()" name="workAccountList[${index.index}].workAccountAuditList[0].checkMoney" type="text" value="${workAccount.workAccountAuditList[0].checkMoney}"  maxlength="10"  class="form-control number checkMoney"/>
+                            <input id="workAccountList${index.index}_audit0_id" name="workAccountList[${index.index}].workAccountAuditList[0].id" type="hidden" value="${workAccount.workAccountAuditList[0].id}"/>
+                        </td>
+                        <td  class="text-center op-td" >
+                            <span class="op-btn op-btn-add" onclick="addRow('#workAccountList${index.index}', workAccountListRowIdx, workAccountAuditListTpl);workAccountListRowIdx=workAccountListRowIdx+1;" title="新增"><i class="fa fa-plus"></i>&nbsp;新增</span>
+                        </td>
+                    </tr>
+                    </tbody>
+                    </c:forEach>
+
+                    </c:if>
+                </table>
+                <table id="contentMoneys" class="table table-bordered table-condensed can-edit summary">
+                    <tr>
+                        <td width="150px" style="vertical-align:middle;text-align: center;"><label><font color="red">*</font>总报销费用(元):</label></td>
+                        <td>
+                            <input htmlEscape="false" id="moneys"  readonly="true" class="form-control layui-input" value="<fmt:formatNumber value="${workReimbursement.money}" pattern="#,#00.00"/>"/>
+                            <input htmlEscape="false" id="summoney" name="money" type="hidden"  readonly="true" class="form-control layui-input" value="${workReimbursement.money}"/>
+                        </td>
+                        <td width="150px" style="vertical-align:middle;text-align: center;"><label><font color="red">*</font>考核金额总额(元):</label></td>
+                        <td >
+                            <input htmlEscape="false" id="checkMoneys"  readonly="true" class="form-control layui-input"/>
+                            <input htmlEscape="false" id="sumcheckMoneys" name="checkMoneys" type="hidden"  readonly="true" class="form-control layui-input" value="${workReimbursement.checkMoneys}"/>
+                        </td>
+                        <td width="150px" style="vertical-align:middle;text-align: center;"><label><font color="red">*</font>实际报销费用(元):</label></td>
+                        <td >
+                            <input htmlEscape="false" id="backmoneys"  readonly="true" class="form-control layui-input"/>
+                            <input htmlEscape="false" id="sumbackmoneys" name="backmoneys" type="hidden"  readonly="true" class="form-control layui-input" value="${workReimbursement.backmoneys}"/>
+                        </td>
+                    </tr>
+                </table>
+                <script type="text/template" id="workAccountAuditListTpl">//<!--
+                                    <tr id="workAccountList0_audit0">
+                                        <td class="hide">
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+											<form:select id="workAccountList0_audit0_u8Subjects" path="workAccountList[0].workAccountAuditList[0].u8Subjects" class="form-control ">
+												<form:option value="" label=""/>
+												<form:options items="${fns:getMainDictList('u8_subjects')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+											</form:select>
+										</td>
+										<td class="isShow">
+											<form:select id="workAccountList0_audit0_checkSubjects" path="workAccountList[0].workAccountAuditList[0].checkSubjects" class="form-control ">
+												<form:option value="" label=""/>
+												<form:options items="${fns:getMainDictList('check_subjects')}" itemLabel="label" itemValue="value" htmlEscape="false"/>
+											</form:select>
+										</td>
+										<td>
+										<input id="workAccountList0_audit0_money" onchange="getMoney()" name="workAccountList[0].workAccountAuditList[0].checkMoney" type="text" value="${workAccount.workAccountAuditList[0].checkMoney}"    class="form-control number checkMoney"/>
+										</td>
+
+										<td class="text-center op-td" >
+										    <span class="op-btn op-btn-delete" onclick="delRow(this, '#workAccountList0')" title="删除"><i class="glyphicon glyphicon-remove"></i>&nbsp;删除</span>
+										</td>
+                                    </tr>//-->
+                </script>
+                <script type="text/javascript">
+                    var workAccountListRowIdx = 0, workAccountAuditListTpl = $("#workAccountAuditListTpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
+                </script>
+            </div>
+        </div>--%>
+            <div class="form-group layui-row">
+                <div class="form-group-label"><h2>报销详情</h2></div>
+                <div class="layui-table-body layui-item layui-col-xs12 form-table-container"  style="padding:0px">
+                    <table id="contentTable" class="table table-bordered table-condensed can-edit no-bottom-margin details">
+                        <thead>
+                        <tr>
+                            <th width="200px">报销人</th>
+                            <th width="200px">报销部门</th>
+                            <th width="200px">报销项目</th>
+                            <th width="200px">报告号</th>
+                            <th width="200px">报销类型</th>
+                            <th width="200px">费用(元)</th>
+                            <th width="200px">收据张数</th>
+                            <th width="200px">出差天数</th>
+                            <th width="200px">内容</th>
+                        </tr>
+                        </thead>
+                        <tbody id="workAccountList">
+                        <c:if test="${not empty workReimbursement.workAccountList}">
+                            <c:forEach items="${workReimbursement.workAccountList}" var="workAccount" varStatus="index">
+                                <tr id="workAccountList${index.index}">
+                                    <td class="hide">
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle">
+                                            ${workAccount.reimbursementName}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle">
+                                            ${workAccount.officeId}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle" title="${workAccount.project.projectName}">
+                                            ${workAccount.project.projectName}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle" title="${workAccount.projectReportNumber}">
+                                            ${workAccount.projectReportNumber}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle" title="${workAccount.typeName}">
+                                            ${workAccount.typeName}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle">
+                                        <fmt:formatNumber value="${workAccount.money}" pattern="#,#00.00"/>
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle" title="${workAccount.bills}">
+                                            ${workAccount.bills}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle" title="${workAccount.evectionNumber}">
+                                            ${workAccount.evectionNumber}
+                                    </td>
+                                    <td style="text-align: center; vertical-align: middle" title="${workAccount.remarks}">
+                                            ${workAccount.remarks}
+                                    </td>
+                                </tr>
+                            </c:forEach>
+
+                        </c:if>
+                        </tbody>
+                    </table>
+                    <table id="contentMoneys" class="table table-bordered table-condensed can-edit no-bottom-margin details">
+                        <thead>
+                        <tr style="border: 0px">
+                            <td width="200px" style="vertical-align:middle;text-align: center;background-color: #ffffff;"><label>总报销费用(元):</label></td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                            <td width="200px" style="border: 0px;font-weight: bold;text-align: center;background-color: #ffffff;">
+                                <fmt:formatNumber value="${workReimbursement.money}" pattern="#,#00.00"/>
+                            </td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                            <td width="200px" style="background-color: #ffffff;"></td>
+                        </tr>
+                        </thead>
+                    </table>
+                </div>
+            </div>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>专用发票信息</h2></div>
+            <div class="layui-item layui-col-xs12 form-table-container" >
+                <table id="contentTable2" class="table table-bordered table-condensed no-bottom-margin details">
+                    <thead>
+                    <tr>
+                        <th width="300px">发票代码</th>
+                        <th width="200px">发票号</th>
+                        <th width="200px">金额</th>
+                        <th width="200px">税额</th>
+                        <th width="200px">价税合计</th>
+                    </tr>
+                    </thead>
+                    <tbody id="reimbursementVATTaxes">
+                    <c:if test="${not empty workReimbursement.reimbursementVATTaxes}">
+                        <c:forEach items="${workReimbursement.reimbursementVATTaxes}" var="reimbursementVATTaxe" varStatus="index">
+                            <tr>
+                                <td class="hide">
+                                </td>
+                                <td>
+                                        ${reimbursementVATTaxe.invoiceCode}
+                                </td>
+
+                                <td>
+                                        ${reimbursementVATTaxe.invoiceNumber}
+                                </td>
+                                <td>
+                                        ${reimbursementVATTaxe.money}
+                                </td>
+                                <td>
+                                        ${reimbursementVATTaxe.taxAmount}
+                                </td>
+                                <td>
+                                        ${reimbursementVATTaxe.sumMoney}
+                                </td>
+                            </tr>
+                        </c:forEach>
+                    </c:if>
+                    </tbody>
+                </table>
+            </div>
+        </div>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>相关附件</h2></div>
+            <div class="layui-item layui-col-xs12 form-table-container" >
+                <table id="upTable" class="table table-bordered table-condensed details">
+                    <thead>
+                    <tr>
+                            <%-- <th>序号</th>--%>
+                        <th>文件预览</th>
+                        <th>上传人</th>
+                        <th>上传时间</th>
+                        <th width="150px">操作</th>
+                    </tr>
+                    </thead>
+                    <tbody id="file_attachment">
+                    <c:forEach items="${workReimbursement.workAttachments}" var = "workClientAttachment" varStatus="status">
+                        <tr>
+                                <%-- <td>${status.index + 1}</td>--%>
+                            <c:choose>
+                                <c:when test="${workReimbursement.uploadMode == 2}">
+                                    <c:choose>
+                                        <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+                                            <td><img src="${workClientAttachment.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+                                        </c:when>
+                                        <c:otherwise>
+                                            <c:choose>
+                                                <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+                                                    <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+                                                </c:when>
+                                                <c:otherwise>
+                                                    <c:choose>
+                                                        <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                            <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                        </c:when>
+                                                        <c:otherwise>
+                                                            <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                        </c:otherwise>
+                                                    </c:choose>
+                                                </c:otherwise>
+                                            </c:choose>
+                                        </c:otherwise>
+                                    </c:choose>
+                                </c:when>
+                                <c:otherwise>
+                                    <c:choose>
+                                        <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+                                            <td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+                                        </c:when>
+                                        <c:otherwise>
+                                            <c:choose>
+                                                <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+                                                    <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+                                                </c:when>
+                                                <c:otherwise>
+                                                    <c:choose>
+                                                        <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                            <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                        </c:when>
+                                                        <c:otherwise>
+                                                            <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                        </c:otherwise>
+                                                    </c:choose>
+                                                </c:otherwise>
+                                            </c:choose>
+                                        </c:otherwise>
+                                    </c:choose>
+                                </c:otherwise>
+                            </c:choose>
+
+                            <td>${workClientAttachment.createBy.name}</td>
+                            <td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+                            <td class="op-td">
+                                <div class="op-btn-box" >
+                                        <%--附件下载删除--%>
+                                    <c:choose>
+                                        <c:when test="${workReimbursement.uploadMode == 2}">
+                                            <c:choose>
+                                                <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+                                                    <a href="${workClientAttachment.temporaryUrl}" target="_blank" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+                                                </c:when>
+                                                <c:otherwise>
+                                                    <a href="${workClientAttachment.temporaryUrl}" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+                                                </c:otherwise>
+                                            </c:choose>
+                                        </c:when>
+                                        <c:otherwise>
+                                            <a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent('${workClientAttachment.url}');" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+                                        </c:otherwise>
+                                    </c:choose>
+                                    <c:if test="${workClientAttachment.collectFlag != 1}">
+                                        <a href="javascript:void(0)" onclick="collectingAccessory(this,'${ctx}/projectAccessory/projectAccessory/saveCollectAccessory','${workClientAttachment.url}','${workClientAttachment.createBy.id}','${workClientAttachment.fileSize}')" class="op-btn op-btn-delete"  style="background-color: #FFB800"><i class="layui-icon layui-icon-rate"></i>&nbsp;收藏</a>
+                                    </c:if>
+                                    <%--<c:if test="${workClientAttachment.createBy.id eq fns:getUser().id}">
+                                        <a href="javascript:void(0)" onclick="deleteFileFromAliyun(this,'${ctx}/sys/workattachment/deleteFileFromAliyun?url=${workClientAttachment.url}&id=${workClientAttachment.id}&type=2','addFile')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>
+                                    </c:if>--%>
+                                </div>
+                            </td>
+                        </tr>
+                    </c:forEach>
+                    </tbody>
+                </table>
+            </div>
+        </div>
+<%--            <div class="form-group layui-row">--%>
+<%--                <div class="form-group-label"><h2>审批意见</h2></div>--%>
+<%--                <div class="layui-item layui-col-sm8 lw6 with-textarea">--%>
+<%--                    <div class="layui-input-block" style="margin-left:10px;position: relative">--%>
+<%--                        <form:textarea placeholder="请输入意见:" path="act.comment" id="opinion" class="form-control" rows="4" cssStyle="height: 200px;" maxlength="127" />--%>
+<%--                        <a id="clearOpinon" class="layui-btn" style="position: absolute;bottom: 10px;right: 20px;">清空</a>--%>
+<%--                        <input type="file" name="upload_files" style="display: none;">--%>
+<%--                    </div>--%>
+<%--                </div>--%>
+<%--                <div class="layui-item layui-col-sm4 lw6 with-textarea">--%>
+<%--                    <div class="layui-input-block" style="margin-left:10px;">--%>
+<%--                        <div style="padding: 5px 0px;"><input type="checkbox" lay-filter="raopinion" name="sh" value="同意" title="同意" style="cursor:pointer" class="apen"/></div>--%>
+<%--                        <div style="padding: 5px 0px;"><input type="checkbox" lay-filter="raopinion" name="sh" value="不同意" title="不同意" style="cursor:pointer" class="apen"/></div>--%>
+<%--                        <div style="padding: 5px 0px;"><input type="checkbox" lay-filter="raopinion" name="sh" value="请领导审核" title="请领导审核" style="cursor:pointer" class="apen"/></div>--%>
+<%--                        <div style="padding: 5px 0px;">--%>
+<%--                            <form:select path="act.comment" id="auditOpinion" lay-filter="opinion" lay-verify="opinion" class="form-control simple-select">--%>
+<%--                                <form:option value=""/>--%>
+<%--                                <form:options items="${fns:getMainDictListOnProjectAdvent('audit_opinion_template')}" itemLabel="label" itemValue="label" htmlEscape="false"/>--%>
+<%--                            </form:select>--%>
+<%--                        </div>--%>
+<%--                    </div>--%>
+<%--                </div>--%>
+<%--            </div>--%>
+<%--        <div class="form-group layui-row">--%>
+<%--            <div class="form-group-label"><h2>审批意见</h2></div>--%>
+<%--            <div class="layui-item layui-col-xs12 with-textarea" >--%>
+<%--                <label class="layui-form-label">审批意见:</label>--%>
+<%--                <div class="layui-input-block">--%>
+<%--                    <form:textarea path="act.comment" class="form-control" rows="4" maxlength="127" />--%>
+<%--                    <input type="file" name="upload_files" style="display: none;">--%>
+<%--                </div>--%>
+<%--            </div>--%>
+<%--        </div>--%>
+
+            <div class="form-group layui-row page-end"></div>
+        </form:form>
+        <div class="form-group-label">
+            <div style="float: right"> <a href="javascript:void(0)" style='background-color: #FFB800' onclick="openDialogre('个人模板列表', '${ctx}/auditTemplate/auditTemplate/templateList?identification=${identification}&name=${identificationName}','80%', '70%','','关闭')" class="nav-btn layui-btn layui-btn-sm" ><i class="fa fa-file-excel-o"></i> 审核意见模板列表</a></div>
+            <h2>审批意见</h2>
+        </div>
+        <iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>审批流程</h2></div>
+            <div class="layui-item layui-col-xs12 form-table-container" >
+                <act:flowChart procInsId="${workReimbursement.act.procInsId}"/>
+                <act:histoicFlow procInsId="${workReimbursement.act.procInsId}"/>
+            </div>
+        </div>
+    </div>
+</div>
+<script>
+    function f1(row) {
+        // window.parent.document.getElementById('opinion').value = row;
+        $("#opinion").val(row)
+    }
+    function openDialogre(title,url,width,height,target,buttons) {
+        if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+            width = 'auto';
+            height = 'auto';
+        } else {//如果是PC端,根据用户设置的width和height显示。
+        }
+        var split = buttons.split(",");
+        top.layer.open({
+            type: 2,
+            area: [width, height],
+            title: title,
+            maxmin: true, //开启最大化最小化按钮
+            skin: 'three-btns',
+            content: url,
+            btn: split,
+            btn1: function(index, layero){
+                top.layer.close(index)
+                document.getElementById('iframe').contentWindow.location.reload();
+            }
+        });
+    }
+</script>
+</body>
+</html>
+

+ 545 - 0
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewAudit.jsp

@@ -0,0 +1,545 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>报销审核</title>
+	<meta name="decorator" content="default"/>
+	<script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+	<link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+	<script type="text/javascript">
+		var validateForm;
+		function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+		  if(validateForm.form()){
+			  var ss= document.getElementById("iframe").contentWindow.document.getElementById("opinion").value
+			  $("#opinion").val(ss);
+		      if(obj == 1){
+                  $('#flag').val('yes');
+              }else{
+                  $('#flag').val('no');
+              }
+			  $("#inputForm").submit();
+			  return true;
+		  }else {
+              parent.layer.msg("信息未填写完整!", {icon: 5});
+          }
+
+		  return false;
+		}
+		$(document).ready(function() {
+			layui.use('form', function () {
+				var form = layui.form;
+				form.render();
+			});
+            if (${workReimbursement.ext == 0}){
+                $(".td1").removeClass("hide");
+                $(".project_reimbursement_div").show();
+                $(".not_project_reimbursement_div").hide();
+            }else {
+                $(".td1").addClass("hide");
+                $(".project_reimbursement_div").hide();
+                $(".not_project_reimbursement_div").show();
+            }
+            if (${workReimbursement.isPublic =='0'}){
+                $(".isPublic").addClass("hide");
+            }else {
+                $(".isPublic").removeClass("hide");
+            }
+			$("#name").focus();
+			validateForm = $("#inputForm").validate({
+				submitHandler: function(form){
+					loading('正在提交,请稍等...');
+					form.submit();
+				},
+				errorContainer: "#messageBox",
+				errorPlacement: function(error, element) {
+					$("#messageBox").text("输入有误,请先更正。");
+					if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+						error.appendTo(element.parent().parent());
+					} else {
+						error.insertAfter(element);
+					}
+				}
+			});
+		});
+	</script>
+	<style>
+		/*超过5个汉字,调整label的长度,以下是配套的*/
+		.layui-item .layui-form-label{
+			width:90px;
+		}
+		.form-group .layui-item .layui-input-block,
+		.query .layui-input-block {
+			margin-left: 116px;
+		}
+	</style>
+</head>
+<body>
+<div class="single-form">
+	<div class="container view-form">
+	<form:form id="inputForm" modelAttribute="workReimbursement" enctype="multipart/form-data" action="${ctx}/workReimbursementNew/workReimbursementNew/saveAudit" method="post" class="form-horizontal layui-form">
+		<form:hidden path="id"/>
+		<form:hidden path="home"/>
+		<form:hidden path="act.taskId"/>
+		<form:hidden path="act.taskName"/>
+		<form:hidden path="act.taskDefKey"/>
+		<form:hidden path="act.procInsId"/>
+		<form:hidden path="act.procDefId"/>
+		<form:hidden id="flag" path="act.flag"/>
+		<input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
+		<div class="form-group layui-row first ">
+			<div class="form-group-label"><h2>基础信息</h2></div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报销人:</label>
+				<div class="layui-input-block">
+					<form:input path="submitterName" cssStyle="background-color: #f1f1f1" htmlEscape="false" readonly="true"  id="submitterName"  class="form-control layui-input" value = "${workReimbursement.submitterName}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报销编号:</label>
+				<div class="layui-input-block">
+					<div class="input-group">
+						<input htmlEscape="false" style="background-color: #f1f1f1" readonly="true"  class="form-control layui-input" value="${workReimbursement.number}"/>
+						<span class="input-group-btn">
+                        <label class="form-status"><c:choose><c:when test="${not empty workReimbursement.status}">${fns:getDictLabel(workReimbursement.status, 'audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                     </span>
+					</div>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">所属部门:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value = "${workReimbursement.officeName}"/>
+				</div>
+			</div>
+			<%--<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">银行卡号:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false" readonly="true"  class="form-control layui-input" value = "${workReimbursement.bankCard}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报销类型:</label>
+				<div class="layui-input-block">
+					<input readonly="true" htmlEscape="false" class="form-control layui-input"
+						   value="<c:choose><c:when test="${workReimbursement.ext == 0}">项目报销</c:when><c:otherwise>非项目报销</c:otherwise></c:choose>"/>
+				</div>
+			</div>
+
+			<div class="layui-item layui-col-sm6 td1">
+				<label class="layui-form-label">报销项目:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.project.projectName}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报销类别:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.typeName}"/>
+				</div>
+			</div>
+				&lt;%&ndash;<div class="layui-item layui-col-sm6 td1">
+                    <label class="layui-form-label">项目负责人:</label>
+                    <div class="layui-input-block">
+                        <input htmlEscape="false"  readonly="true"  class="form-control layui-input" value="${workReimbursement.projectMasterName}"/>
+                    </div>
+                </div>&ndash;%&gt;
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label double-line">是否对公报销:</label>
+				<div class="layui-input-block">
+					<input readonly="true" htmlEscape="false" class="form-control layui-input"
+						   value="<c:choose><c:when test="${workReimbursement.isPublic == '0'}">否</c:when><c:otherwise>是</c:otherwise></c:choose>"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6 isPublic">
+				<label class="layui-form-label">公司名称:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.comname}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6 isPublic">
+				<label class="layui-form-label">开户行:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.bank}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6 isPublic">
+				<label class="layui-form-label">银行账号:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.bankNo}"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报销人:</label>
+				<div class="layui-input-block">
+					<input htmlEscape="false"  readonly="true" class="form-control layui-input" value="${workReimbursement.submitterName}"/>
+				</div>
+			</div>--%>
+
+			<div class="layui-item layui-col-sm6">
+				<label class="layui-form-label">报销日期:</label>
+				<div class="layui-input-block">
+					<input readonly="readonly" style="background-color: #f1f1f1" class="form-control layui-input" value="<fmt:formatDate value="${workReimbursement.submitterDate}" pattern="yyyy-MM-dd"/>"/>
+				</div>
+			</div>
+			<div class="layui-item layui-col-sm6 with-textarea">
+				<label class="layui-form-label ">备注:</label>
+				<div class="layui-input-block">
+					<form:textarea path="remarks" placeholder="请输入备注" htmlEscape="false" rows="4"  maxlength="255" value="${workReimbursement.remarks}"  class="form-control "/>
+				</div>
+			</div>
+		</div>
+		<%--<div class="form-group layui-row">
+			<div class="form-group-label"><h2>借款明细</h2></div>
+			<div class="layui-item layui-col-xs12 form-table-container" >
+				<table id="contentTable3" class="table table-bordered table-condensed can-edit no-bottom-margin">
+					<thead>
+					<tr>
+						<th width="190px">借款日期</th>
+						<th width="190px">借款类型</th>
+						<th width="190px">借款项目</th>
+						<th width="190px">借款金额</th>
+						<th width="180px">未还金额</th>
+						<th width="100px">本次还款</th>
+						<th width="120px">借款编号</th>
+					</tr>
+					</thead>
+					<tbody id="reimbursementBackList">
+					<c:if test="${not empty workReimbursement.reimbursementBackList}">
+						<c:forEach items="${workReimbursement.reimbursementBackList}" var="reimbursementBack" varStatus="index">
+							<tr id="reimbursementBackList${index.index}">
+								<td class="hide">
+									<input id="reimbursementBackList${index.index}_id" name="reimbursementBackList[${index.index}].id" type="hidden" value="${reimbursementBack.id}"/>
+									<input id="reimbursementBackList${index.index}_workLoanId" name="reimbursementBackList[${index.index}].workLoan.id" type="hidden" value="${reimbursementBack.workLoan.id}"/>
+									<input id="reimbursementBackList${index.index}_delFlag" name="reimbursementBackList[${index.index}].delFlag" type="hidden" value="0"/>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_1"   type="text" maxlength="20"  readonly="true" class=" form-control layui-input"
+										   value="<fmt:formatDate value="${reimbursementBack.workLoan.loanDate}" pattern="yyyy-MM-dd"/>"/>
+									</input>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_2"  readonly="true" type="text" value="${reimbursementBack.workLoan.type}"   class="form-control"/>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_3"  readonly="true" type="text" value="${reimbursementBack.workLoan.projectRecords.projectName}"   class="form-control"/>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_4"  readonly="true" type="text" value="${reimbursementBack.workLoan.money}"   class="form-control"/>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_5"  readonly="true" type="text" value="${reimbursementBack.workLoan.notRepay}"   class="form-control"/>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_6" readonly="true"  name="reimbursementBackList[${index.index}].money" type="text" value="${reimbursementBack.money}"   class="form-control number "/>
+								</td>
+								<td>
+									<input id="reimbursementBackList${index.index}_7"  readonly="true" type="text" value="${reimbursementBack.workLoan.num}"   class="form-control"/>
+								</td>
+							</tr>
+						</c:forEach>
+					</c:if>
+					</tbody>
+				</table>
+				<table id="contentMoneys1" class="table table-bordered table-condensed can-edit summary">
+					<tr>
+						<td  style="width:190px;vertical-align:middle;text-align: center;"><label><font color="red">*</font>合计</label></td>
+						<td  width="190px" style="vertical-align:middle;text-align: center;">
+							-
+						</td >
+						<td  width="190px" style="vertical-align:middle;text-align: center;">
+							-
+						</td>
+						<td  width="190px" style="vertical-align:middle;text-align: center;">
+							-
+						</td>
+						<td width="180px" style="vertical-align:middle;text-align: center;">
+							-
+						</td>
+						<td width="100px" style="vertical-align:middle;text-align: center;">
+							<input  id="backmoney" value="${workReimbursement.backmoney}" name="backmoney" htmlEscape="false" readonly="true"   maxlength="12"  class="form-control "/>
+						</td>
+						<td  width="120px" style="vertical-align:middle;text-align: center;">
+							-
+						</td>
+					</tr>
+				</table>
+			</div>
+		</div>--%>
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>报销详情</h2></div>
+			<div class="layui-table-body layui-item layui-col-xs12 form-table-container"  style="padding:0px">
+				<table id="contentTable" class="table table-bordered table-condensed can-edit no-bottom-margin details">
+					<thead>
+					<tr>
+						<th width="200px">报销人</th>
+						<th width="200px">报销部门</th>
+						<th width="200px">报销类型</th>
+						<th width="200px">报销项目</th>
+						<th width="200px">报告号</th>
+						<th width="200px">费用(元)</th>
+						<th width="200px">收据张数</th>
+						<th width="200px">出差天数</th>
+						<th width="200px">内容</th>
+					</tr>
+					</thead>
+					<tbody id="workAccountList">
+					<c:if test="${not empty workReimbursement.workAccountList}">
+						<c:forEach items="${workReimbursement.workAccountList}" var="workAccount" varStatus="index">
+							<tr id="workAccountList${index.index}">
+								<td class="hide">
+								</td>
+								<td style="text-align: center; vertical-align: middle">
+										${workAccount.reimbursementName}
+								</td>
+								<td style="text-align: center; vertical-align: middle">
+										${workAccount.officeId}
+								</td>
+								<td style="text-align: center; vertical-align: middle" title="${workAccount.typeName}">
+										${workAccount.typeName}
+								</td>
+								<td style="text-align: center; vertical-align: middle" title="${workAccount.project.projectName}">
+										${workAccount.project.projectName}
+								</td>
+								<td style="text-align: center; vertical-align: middle" title="${workAccount.projectReportNumber}">
+										${workAccount.projectReportNumber}
+								</td>
+
+								<td style="text-align: center; vertical-align: middle">
+									<fmt:formatNumber value="${workAccount.money}" pattern="#,#00.00"/>
+								</td>
+								<td style="text-align: center; vertical-align: middle" title="${workAccount.bills}">
+										${workAccount.bills}
+								</td>
+								<td style="text-align: center; vertical-align: middle" title="${workAccount.evectionNumber}">
+										${workAccount.evectionNumber}
+								</td>
+								<td style="text-align: center; vertical-align: middle" title="${workAccount.remarks}">
+										${workAccount.remarks}
+								</td>
+							</tr>
+						</c:forEach>
+
+					</c:if>
+					</tbody>
+				</table>
+				<table id="contentMoneys" class="table table-bordered table-condensed can-edit no-bottom-margin details">
+					<thead>
+					<tr style="border: 0px">
+						<td width="200px" style="vertical-align:middle;text-align: center;background-color: #ffffff;"><label>总报销费用(元):</label></td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+						<td width="200px" style="border: 0px;font-weight: bold;text-align: center;background-color: #ffffff;">
+							<fmt:formatNumber value="${workReimbursement.money}" pattern="#,#00.00"/>
+						</td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+						<td width="200px" style="background-color: #ffffff;"></td>
+					</tr>
+					</thead>
+				</table>
+			</div>
+		</div>
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>专用发票信息</h2></div>
+			<div class="layui-item layui-col-xs12 form-table-container" >
+				<table id="contentTable2" class="table table-bordered table-condensed no-bottom-margin details">
+					<thead>
+					<tr>
+						<th width="300px">发票代码</th>
+						<th width="200px">发票号</th>
+						<th width="200px">金额</th>
+						<th width="200px">税额</th>
+						<th width="200px">价税合计</th>
+					</tr>
+					</thead>
+					<tbody id="reimbursementVATTaxes">
+					<c:if test="${not empty workReimbursement.reimbursementVATTaxes}">
+						<c:forEach items="${workReimbursement.reimbursementVATTaxes}" var="reimbursementVATTaxe" varStatus="index">
+							<tr>
+								<td class="hide">
+								</td>
+								<td>
+										${reimbursementVATTaxe.invoiceCode}
+								</td>
+
+								<td>
+										${reimbursementVATTaxe.invoiceNumber}
+								</td>
+								<td>
+										${reimbursementVATTaxe.money}
+								</td>
+								<td>
+										${reimbursementVATTaxe.taxAmount}
+								</td>
+								<td>
+										${reimbursementVATTaxe.sumMoney}
+								</td>
+							</tr>
+						</c:forEach>
+					</c:if>
+					</tbody>
+				</table>
+			</div>
+		</div>
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>相关附件</h2></div>
+			<div class="layui-item layui-col-xs12 form-table-container" >
+				<table id="upTable" class="table table-bordered table-condensed details">
+					<thead>
+					<tr>
+							<%-- <th>序号</th>--%>
+						<th>文件预览</th>
+						<th>上传人</th>
+						<th>上传时间</th>
+						<th width="150px">操作</th>
+					</tr>
+					</thead>
+					<tbody id="file_attachment">
+						<c:forEach items="${workReimbursement.workAttachments}" var = "workClientAttachment" varStatus="status">
+							<tr>
+									<%-- <td>${status.index + 1}</td>--%>
+								<c:choose>
+									<c:when test="${workReimbursement.uploadMode == 2}">
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+												<td><img src="${workClientAttachment.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+											</c:when>
+											<c:otherwise>
+												<c:choose>
+													<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+														<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+													</c:when>
+													<c:otherwise>
+														<c:choose>
+															<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+															</c:when>
+															<c:otherwise>
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</c:otherwise>
+										</c:choose>
+									</c:when>
+									<c:otherwise>
+										<c:choose>
+											<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+														   or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+												<td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+											</c:when>
+											<c:otherwise>
+												<c:choose>
+													<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+														<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+													</c:when>
+													<c:otherwise>
+														<c:choose>
+															<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+															</c:when>
+															<c:otherwise>
+																<td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+															</c:otherwise>
+														</c:choose>
+													</c:otherwise>
+												</c:choose>
+											</c:otherwise>
+										</c:choose>
+									</c:otherwise>
+								</c:choose>
+
+								<td>${workClientAttachment.createBy.name}</td>
+								<td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+								<td class="op-td">
+									<div class="op-btn-box" >
+											<%--附件下载删除--%>
+										<c:choose>
+											<c:when test="${workReimbursement.uploadMode == 2}">
+												<c:choose>
+													<c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+														<a href="${workClientAttachment.temporaryUrl}" target="_blank" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+													</c:when>
+													<c:otherwise>
+														<a href="${workClientAttachment.temporaryUrl}" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+													</c:otherwise>
+												</c:choose>
+											</c:when>
+											<c:otherwise>
+												<a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent('${workClientAttachment.url}');" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+											</c:otherwise>
+										</c:choose>
+										<c:if test="${workClientAttachment.collectFlag != 1}">
+											<a href="javascript:void(0)" onclick="collectingAccessory(this,'${ctx}/projectAccessory/projectAccessory/saveCollectAccessory','${workClientAttachment.url}','${workClientAttachment.createBy.id}','${workClientAttachment.fileSize}')" class="op-btn op-btn-delete"  style="background-color: #FFB800"><i class="layui-icon layui-icon-rate"></i>&nbsp;收藏</a>
+										</c:if>
+									</div>
+								</td>
+							</tr>
+						</c:forEach>
+					</tbody>
+				</table>
+			</div>
+		</div>
+		<div class="form-group layui-row page-end"></div>
+	</form:form>
+		<div class="form-group-label">
+			<div style="float: right"> <a href="javascript:void(0)" style='background-color: #FFB800' onclick="openDialogre('个人模板列表', '${ctx}/auditTemplate/auditTemplate/templateList?identification=${identification}&name=${identificationName}','80%', '70%','','关闭')" class="nav-btn layui-btn layui-btn-sm" ><i class="fa fa-file-excel-o"></i> 审核意见模板列表</a></div>
+			<h2>审批意见</h2>
+		</div>
+		<iframe id="iframe" src="${ctx}/auditTemplate/auditTemplate/iframeView?identification=${identification}" name="listresult" frameborder="0" align="left" width="100%" height="300" scrolling="value"></iframe>
+		<div class="form-group layui-row">
+			<div class="form-group-label"><h2>审批流程</h2></div>
+			<div class="layui-item layui-col-xs12 form-table-container" >
+				<act:flowChart procInsId="${workReimbursement.act.procInsId}"/>
+				<act:histoicFlow procInsId="${workReimbursement.act.procInsId}"/>
+			</div>
+		</div>
+</div>
+</div>
+<script>
+	function f1(row) {
+		// window.parent.document.getElementById('opinion').value = row;
+		$("#opinion").val(row)
+	}
+	function openDialogre(title,url,width,height,target,buttons) {
+		if (navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)) {//如果是移动端,就使用自适应大小弹窗
+			width = 'auto';
+			height = 'auto';
+		} else {//如果是PC端,根据用户设置的width和height显示。
+		}
+		var split = buttons.split(",");
+		top.layer.open({
+			type: 2,
+			area: [width, height],
+			title: title,
+			maxmin: true, //开启最大化最小化按钮
+			skin: 'three-btns',
+			content: url,
+			btn: split,
+			btn1: function(index, layero){
+				top.layer.close(index)
+				document.getElementById('iframe').contentWindow.location.reload();
+			}
+		});
+	}
+
+</script>
+</body>
+</html>
+

+ 932 - 0
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewFormAdd.jsp

@@ -0,0 +1,932 @@
+<%@ page contentType="text/html;charset=UTF-8" %>
+<%@ include file="/webpage/include/taglib.jsp"%>
+<html>
+<head>
+	<title>报销单管理</title>
+	<meta name="decorator" content="default"/>
+    <script type="text/javascript" src="${ctxStatic}/layui/layui.js"></script>
+    <link rel='stylesheet' type="text/css" href="${ctxStatic}/layui/css/layui.css"/>
+    <script src="${ctxStatic}/common/html/js/script.js"></script>
+    <script type="text/javascript">
+        var validateForm;
+        var count = 0;
+        $(document).ready(function() {
+            layui.use(['form', 'layer'], function () {
+                var form = layui.form;
+            })
+            if($("#submitterDate").val()==null || $("#submitterDate").val()==''){
+                $("#submitterDate").val(getNowFormatDate());
+            }
+            $("input[name='isPublic']").on('ifChecked', function(event){
+                var radioVal = $(this).val();
+                if(radioVal == 1){
+                    $(".isPublic").removeClass("hide");
+                    $("#comname").removeClass("judgment");
+                    $("#bank").removeClass("judgment");
+                    $("#bankNo").removeClass("judgment");
+                    $("#reimbursementBackList tr").each(function () {
+                        $(this).remove();
+                        $("#backmoney").val("0.00");
+                    })
+                }else{
+                    $(".isPublic").addClass("hide");
+                    $("#comname").addClass("judgment");
+                    $("#bank").addClass("judgment");
+                    $("#bankNo").addClass("judgment");
+                    getLoan($("#achivesId").val());
+                }
+            });
+            if("${workReimbursement.isPublic}" == "1"){
+                $("#isPublic1").iCheck('check')
+                $(".isPublic").removeClass("hide");
+            }else{
+                $("#isPublic").iCheck('check')
+                $(".isPublic").addClass("hide");
+            }
+            validateForm = $("#inputForm").validate({
+                submitHandler: function(form){
+                    loading('正在提交,请稍等...');
+                    form.submit();
+                },
+                rules:{
+                },
+                messages:{
+                },
+                errorContainer: "#messageBox",
+                errorPlacement: function(error, element) {
+                    $("#messageBox").text("输入有误,请先更正。");
+                    if (element.is(":checkbox")||element.is(":radio")||element.parent().is(".input-append")){
+                        error.appendTo(element.parent().parent());
+                    } else {
+                        error.insertAfter(element);
+                    }
+                }
+            });
+            laydate.render({
+                elem: '#submitterDate', //目标元素。由于laydate.js封装了一个轻量级的选择器引擎,因此elem还允许你传入class、tag但必须按照这种方式 '#id .class'
+                event: 'focus', //响应事件。如果没有传入event,则按照默认的click
+                type : 'date'
+                , trigger: 'click'
+            });
+            $("#attachment_btn").click(function () {
+                $("#attachment_file").click();
+            });
+            // getRandom();
+
+        });
+
+        function doSubmit(obj){//回调函数,在编辑和保存动作时,供openDialog调用提交表单。
+
+            var trlen = $("#workAccountList tr").length;
+            var tdlen = $("#workAccountList tr td").length;
+            var trArr = [];
+            for(var i = 0;i < trlen;i++){
+                var tableMap = {};
+                tableMap["flag"] = $("#workAccountList tr").eq(i).find("td").eq(0).text();
+                tableMap["typeId"] = $("#workAccountList tr").eq(i).find("td").eq(1).text();
+                tableMap["money"] = $("#workAccountList tr").eq(i).find("td").eq(3).text();
+                tableMap["detail"] = $("#workAccountList tr").eq(i).find("td").eq(4).text();
+                tableMap["submitterId"] = $("#workAccountList tr").eq(i).find("td").eq(5).text();
+                tableMap["officeId"] = $("#workAccountList tr").eq(i).find("td").eq(6).text();
+                tableMap["billNumber"] = $("#workAccountList tr").eq(i).find("td").eq(7).text();
+                tableMap["payMode"] = $("#workAccountList tr").eq(i).find("td").eq(8).text();
+                tableMap["travelDays"] = $("#workAccountList tr").eq(i).find("td").eq(9).text();
+                trArr.push(tableMap);
+            }
+            if(obj == 2){
+                $("#inputForm").attr("action","${ctx}/workreimbursement/workReimbursement/store");
+            }else{
+                var flags=judgment();
+                var idArr = $("#workAccountList tr:visible");
+                if(idArr.length<1){
+                    parent.layer.msg("请添加报销详情!", {icon: 5});
+                    flags= false;
+                }
+                if (flags){
+                    $("#inputForm").attr("action","${ctx}/workReimbursementNew/workReimbursementNew/save");
+                }else{
+                    return flags;
+                }
+            }
+            if(validateForm.form()){
+                var total=0 //价税合计总额
+                var specialTotal=0;
+                $("#reimbursementVATTaxes tr:visible .sumMoney").each(function () {
+                    total= parseFloat($(this).val()) +total;
+                });
+
+                var falt=0;
+
+                var size = $("#reimbursementBackList tr").length;
+                for (var i = 0;i<size;i++){
+                    var backmoney = $("#reimbursementBackList"+i+"_6").val();
+                    var notRepay = $("#reimbursementBackList"+i+"_5").val();
+                    if(backmoney!=''){
+                        if (backmoney!=undefined && isNumber(backmoney)){
+                            if(parseFloat(backmoney)>parseFloat(notRepay)){
+                                parent.layer.msg("还款金额不能大于未还款金额!", {icon: 5});
+                                return false;
+                            }
+                        }
+                    }
+                }
+              $("#inputForm").submit();
+                return true;
+            }else {
+                parent.layer.msg("信息未填写完整!", {icon: 5});
+            }
+            return false;
+        }
+
+        function deleteRow(obj,index){
+            $(obj).parent().parent().remove();
+            str[index] = " ";
+            mon[index] = 0;
+            countMoney();
+        }
+        function countMoney(){
+            var m = 0;
+           $.each(mon,function (index,item) {
+                m += Number(item);
+           });
+           $("#mont").val(m);
+        }
+
+        function getLoan(id){
+            $.ajax({
+                type:'post',
+                url:'${ctx}/workreimbursementback/workReimbursementBack/getLoan',
+                data:{
+                    "id":id
+                },
+                success:function(data){
+                    var idx1 = $("#reimbursementBackList tr").length;
+                    for(var i=0;i<data.length;i++){
+                        addRowRecord('#reimbursementBackList', reimbursementBackIdx, reimbursementBackTpl,data[i]);
+
+                    }
+                }
+            });
+        }
+        function selectUserInfo(id) {
+            if( $("#achivesId").val()!=id){
+                $("#reimbursementBackList tr").each(function () {
+                    $(this).remove();
+                    $("#backmoney").val("0.00");
+                })
+                if($('#isPublic').is(':checked')) {
+                    getLoan(id);
+                }
+
+                $.ajax({
+                    type:'post',
+                    data:{
+                        "id":id
+                    },
+                    url:'${ctx}/workregularapply/workRegularApply/userInfo',
+                    success:function(data){
+                        $("#bankCard").val(data.bankCard);
+                        $("#achivesId").val(id);
+                        $("#officeId").val(data.office.id);
+                        $("#officeName").val(data.office.name);
+                        $("#projectId").val("");
+                        $("#projectName").val("");
+
+                    }
+                });
+            }
+
+        }
+        function getNowFormatDate() {
+            var date = new Date();
+            var seperator1 = "-";
+            var seperator2 = ":";
+            var month = date.getMonth() + 1;
+            var strDate = date.getDate();
+                month = (month < 10)?"0"+month:month;
+                strDate = (strDate < 10)?"0"+strDate:strDate;
+            var currentdate = date.getFullYear() + seperator1 + month + seperator1 + strDate;
+            return currentdate;
+        }
+
+        function getRandom(){
+            var GetRandomn = 1;
+            //js生成时间戳
+            var timestamp=new Date().getTime();
+            //获取随机范围内数值的函数
+            function GetRandom(n){
+                //由随机数+时间戳+1组成
+                GetRandomn=Math.floor(Math.random()*n+timestamp+1);
+            }
+            //开始调用,获得一个1-100的随机数
+            GetRandom("30");
+            if(!$("#numberFlag").val()){
+                $("#number").val(GetRandomn)
+            }
+        }
+
+        function addRow(list, idx, tpl, row,flag){
+            var data;
+            if (flag){
+                data = ${fns:toJson(workReimbursement.createBy)};
+            }
+            var idx1 = $("#workAccountList tr").length;
+            if(list == '#workAccountList'){
+
+                tpl = tpl.replace("workAccountList[0].financialSubjects","workAccountList["+idx1+"].financialSubjects");
+                tpl = tpl.replace("workAccountList[0].financialSubjectss","workAccountList["+idx1+"].financialSubjectss");
+                tpl = tpl.replace("not_project_reimbursement_div","not_project_reimbursement_div\" style=\"display:none;\"");
+                tpl = tpl.replace("project_reimbursement_div\" style=\"display:none;\"","project_reimbursement_div");
+                bornTemplete(list, idx, tpl, row, idx1);
+                //将报销人和部门自动赋值
+                // if (idx==0 && flag){
+                    var id="#workAccountList"+idx1+"_reimbursementNameId";
+                    var idName="#workAccountList"+idx1+"_reimbursementNameName";
+                    var idOffice="#workAccountList"+idx1+"_reimbursementNameofficeId";
+                    $(id).val(data.id);
+                    $(idName).val(data.name);
+                    $(idOffice).val(data.office.name);
+                // }
+            }
+            var idx2 = $("#reimbursementVATTaxes tr").length;
+            if(list == '#reimbursementVATTaxes'){
+                bornTemplete(list, idx, tpl, row, idx2);
+            }
+        }
+        function bornTemplete(list, idx, tpl, row, idx1){
+            $(list).append(Mustache.render(tpl, {
+                idx: idx, delBtn: true, row: row,
+                order:idx1 + 1
+            }));
+            $(list+idx).find("select").each(function(){
+                $(this).val($(this).attr("data-value"));
+            });
+            $(list+idx).find("input[type='checkbox'], input[type='radio']").each(function(){
+                var ss = $(this).attr("data-value").split(',');
+                for (var i=0; i<ss.length; i++){
+                    if($(this).val() == ss[i]){
+                        $(this).attr("checked","checked");
+                    }
+                }
+            });
+        }
+        function delRow(obj, prefix){
+            var id = $(prefix+"_id");
+            var workAccountmoney= $(prefix+"_money").val();
+            var money = $("#moneys").val();
+            if (isNumber(workAccountmoney)){
+                if(money==""){
+                    money = parseFloat(workAccountmoney).toFixed(2);
+                }else {
+                    money = (parseFloat(money) - parseFloat(workAccountmoney)).toFixed(2);
+                }
+            }
+            if(money>=0){
+                count++;
+                $("#moneys").val(money);
+                var delFlag = $(prefix+"_delFlag");
+                if (id.val() == ""){
+                    delFlag.val("1");
+                    $(obj).parent().parent().remove();
+                }else if(delFlag.val() == "0"){
+                    delFlag.val("1");
+                    $(obj).html("&divide;").attr("title", "撤回删除");
+                    $(obj).parent().parent().addClass("error");
+                    $(obj).parent().parent().addClass("hide");
+                }else if(delFlag.val() == "1"){
+                    delFlag.val("0");
+                    $(obj).html("&times;").attr("title", "删除");
+                    $(obj).parent().parent().removeClass("error");
+                }
+            }else{
+                parent.layer.msg('删除失败',{icon:2});
+            }
+
+        }
+        function delRowA(obj, prefix){
+            var id = $(prefix+"_id");
+            var delFlag = $(prefix+"_delFlag");
+            if (id.val() == ""){
+                delFlag.val("1");
+                $(obj).parent().parent().remove();
+            }else if(delFlag.val() == "0"){
+                delFlag.val("1");
+                $(obj).html("&divide;").attr("title", "撤销删除");
+                $(obj).parent().parent().addClass("error");
+                $(obj).parent().parent().addClass("hide");
+            }else if(delFlag.val() == "1"){
+                delFlag.val("0");
+                $(obj).html("&times;").attr("title", "删除");
+                $(obj).parent().parent().removeClass("error");
+            }
+        }
+        function urlRedict(file,attach){
+            parent.layer.confirm('确定删除吗?', {
+                btn: ['确认', '取消'] //可以无限个按钮
+            }, function(index, layero){
+                var index1 = parent.layer.load(0, {shade: false});
+                $.post("${ctx}/workfullmanage/workFullManage/deleteFile",
+                    {"file":file,"attach":attach},
+                    function(result){
+                        var d = JSON.parse(result);
+                        if(d.str){
+                            location.reload();
+                            parent.layer.msg("删除成功!!!",{icon:6});
+                            parent.layer.close(index1);
+                            parent.layer.close(index);
+                        }
+                    });
+            }, function(index){
+                parent.layer.close(index)
+            });
+
+        }
+        function insertTitle(tValue){
+            var list = "${workReimbursement.workAttachments}";
+            var size = (list.split('url')).length-1;
+            var files = $("#attachment_file")[0].files;            for(var i = 0;i<files.length;i++) {                var file = files[i];
+            var attachmentId = "";
+            var attachmentFlag = "6";
+            console.log(file);
+            var timestamp=new Date().getTime();
+
+            var storeAs = "wrkReimbursement";
+            var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+            var divId = "_attachment";
+            $("#addFile"+divId).show();
+            multipartUploadWithSts(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,size);}
+        }
+        function insertTitleCollection(tValue){
+            var list = "${workReimbursement.workAttachments}";
+            var size = (list.split('url')).length-1;
+            var files = tValue;
+            for(var i = 0;i<files.length;i++) {
+                var file = files[i];
+                var attachmentId = "";
+                var attachmentFlag = "6";
+                console.log(file);
+                var timestamp=new Date().getTime();
+                var storeAs = "wrkReimbursement";
+                var uploadPath="http://gangwan-app.oss-cn-hangzhou.aliyuncs.com/"+storeAs;/*将这段字符串存到数据库即可*/
+                var divId = "_attachment";
+                $("#addFile"+divId).show();
+                multipartUploadWithStsCollection(storeAs, file,attachmentId,attachmentFlag,uploadPath,divId,size);
+            }
+        }
+
+        function getMoney(value){
+            var money = "0.00";
+            //方法一使用id选择器进行计算。
+            //获取输入的数字
+            //自动计算出结果并填充在相应的输入框中
+            var size = $("#workAccountList tr").length+count;
+            for (var i = 0;i<size;i++){
+                var workAccountmoney = $("#workAccountList"+i+"_money").val();
+                var delFlag = $("#workAccountList"+i+"_delFlag").val();
+                if (workAccountmoney!=undefined && isNumber(workAccountmoney) && delFlag==0){
+                    if(money==""){
+                        money = parseFloat(workAccountmoney).toFixed(2);
+                    }else {
+                        money = (parseFloat(money) + parseFloat(workAccountmoney)).toFixed(2);
+                    }
+                }
+            }
+                $("#moneys").val(money);
+        }
+        function getMoneyVATT(index){
+            var money = "0.00";
+            //方法一使用id选择器进行计算。
+            //获取输入的数字
+            //自动计算出结果并填充在相应的输入框中
+            var workmoney = $("#reimbursementVATTaxes"+index+"_money").val();
+            if(parseFloat(workmoney)<0){
+                workmoney=0;
+                $("#reimbursementVATTaxes"+index+"_money").val(0);
+            }
+            if(workmoney==undefined||!isNumber(workmoney)||workmoney==''){
+                workmoney=0;
+            }
+            var taxAmount = $("#reimbursementVATTaxes"+index+"_taxAmount").val();
+            if(parseFloat(taxAmount)<0){
+                taxAmount=0;
+                $("#reimbursementVATTaxes"+index+"_taxAmount").val(0);
+            }
+            if(taxAmount==undefined||!isNumber(taxAmount)||taxAmount==''){
+                taxAmount=0;
+            }
+            if (workmoney!=undefined && isNumber(workmoney) ){
+                money = (parseFloat(taxAmount) + parseFloat(workmoney)).toFixed(2);
+            }
+            $("#reimbursementVATTaxes"+index+"_sumMoney").val(money);
+        }
+
+        function getBackMoney(value){
+            var money = "0.00";
+            var size = $("#reimbursementBackList tr").length;
+            for (var i = 0;i<size;i++){
+                var backmoney = $("#reimbursementBackList"+i+"_6").val();
+                var notRepay = $("#reimbursementBackList"+i+"_5").val();
+                if (backmoney!=undefined && isNumber(backmoney)){
+                    if(money==""){
+                        money = parseFloat(backmoney).toFixed(2);
+                    }else {
+                        money = (parseFloat(money) + parseFloat(backmoney)).toFixed(2);
+                    }
+                }
+            }
+                $("#backmoney").val(money);
+        }
+
+        function isNumber(val){
+            if(val === "" || val ==null){
+                return false;
+            }
+            var regPos = /^\d+(\.\d+)?$/; //非负浮点数
+            var regNeg = /^(-(([0-9]+\.[0-9]*[1-9][0-9]*)|([0-9]*[1-9][0-9]*\.[0-9]+)|([0-9]*[1-9][0-9]*)))$/; //负浮点数
+            if(regPos.test(val) || regNeg.test(val)){
+                return true;
+            }else{
+                return false;
+            }
+        }
+        function setParentInfo(parentId){
+            return ;
+        }
+        function setPids(pIds,id){
+            $.ajax({
+                url:"${ctx}/reimbursementType/reimbursementType/projectCharge",
+                dataType:"json",
+                data:{pids:pIds},
+                success:function (data) {
+                    var pid=data;
+                    var sid="#"+id+"Name"
+                    if(data==1){
+                        $(sid).parent().parent().parent().parent().find("td").eq(4).find("input").eq(1).val(pid);
+                        $(sid).parent().parent().parent().parent().find("td").eq(4).find("input").eq(2).val("'90%','90%'");
+                    }else {
+                        $(sid).parent().parent().parent().parent().find("td").eq(4).find("input").eq(1).val(pid);
+                        $(sid).parent().parent().parent().parent().find("td").eq(4).find("input").eq(2).val("'50%','50%'");
+                    }
+                }
+            })
+        }
+    </script>
+    <style>
+        /*超过5个汉字,调整label的长度,以下是配套的*/
+        .layui-item .layui-form-label{
+            width:90px;
+        }
+        .form-group .layui-item .layui-input-block,
+        .query .layui-input-block {
+            margin-left: 116px;
+        }
+        #workAccountList td{
+            padding-left: 0px;
+            padding-right: 0px;
+        }
+    </style>
+</head>
+<body>
+<div class="single-form">
+<div class="container">
+    <form:form id="inputForm" modelAttribute="workReimbursement" action="${ctx}/workReimbursementNew/workReimbursementNew/save" method="post" class="form-horizontal layui-form" >
+        <form:hidden path="id"/>
+        <form:hidden path="achivesId"/>
+        <form:hidden path="submitterId"/>
+        <input type="hidden" id="numberFlag" value="${workReimbursement.number}" />
+        <input id="wId" type="hidden" value="${workReimbursement.id}">
+        <div class="form-group layui-row first">
+            <div class="form-group-label"><h2>基础信息</h2></div>
+            <div class="layui-item layui-col-sm6">
+                <label class="layui-form-label">经办人:</label>
+                <div class="layui-input-block with-icon">
+                    <div class="input-group">
+                        <form:input path="submitterName" htmlEscape="false" readonly="true" class="form-control layui-input" value = "${workReimbursement.submitterName}"/>
+                    </div>
+                </div>
+            </div>
+            <div class="layui-item layui-col-sm6">
+                <label class="layui-form-label">报销编号:</label>
+                <div class="layui-input-block">
+                    <div class="input-group">
+                        <form:input path="number" id="number" htmlEscape="false"  readonly="true"  class="form-control layui-input"/>
+                        <span class="input-group-btn">
+                            <label class="form-status"><c:choose><c:when test="${not empty workReimbursement.status}">${fns:getDictLabel(workReimbursement.status, 'audit_state', '')}</c:when><c:otherwise>新添</c:otherwise></c:choose></label>
+                         </span>
+                    </div>
+                </div>
+            </div>
+            <div class="layui-item layui-col-sm6">
+                <label class="layui-form-label">所属部门:</label>
+                <div class="layui-input-block">
+                    <form:input path="officeName" htmlEscape="false"  readonly="true" id="officeName"  class="form-control judgment layui-input" value = "${workReimbursement.officeName}"/>
+                    <input type="hidden" id="officeId" name="officeId" value="${workReimbursement.officeId}">
+                </div>
+            </div>
+
+            <div class="layui-item layui-col-sm6">
+                <label class="layui-form-label"><span class="require-item">*</span>报销日期:</label>
+                <div class="layui-input-block">
+                    <input id="submitterDate" name="submitterDate" type="text" readonly="true" maxlength="20" class="laydate-icondate form-control layer-date judgment layui-input laydate-icon"
+                           style="background-color: #fff" placeholder="请选择报销日期" value="<fmt:formatDate value="${submitterDate.submitterDate}" pattern="yyyy-MM-dd"/>"/>
+                </div>
+            </div>
+            <div class="layui-item layui-col-sm6 with-textarea">
+                <label class="layui-form-label ">备注:</label>
+                <div class="layui-input-block">
+                    <form:textarea path="remarks" placeholder="请输入内容" htmlEscape="false" rows="4"  maxlength="255" value="${workReimbursement.remarks}"  class="form-control "/>
+                </div>
+            </div>
+        </div>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>报销详情</h2></div>
+            <div class="layui-item nav-btns">
+                <a class="nav-btn nav-btn-add" onclick="addRow('#workAccountList', workAccountListRowIdx, workAccountListTpl,'',true);workAccountListRowIdx = workAccountListRowIdx + 1;" title="新增"><i class="fa fa-plus"></i>&nbsp;新增</a>
+            </div>
+            <div class="layui-table-body layui-item layui-col-xs12 form-table-container"  style="padding:0px">
+                <table id="contentTable" class="table table-bordered table-condensed can-edit no-bottom-margin details">
+                    <thead>
+                    <tr>
+                        <%--<th width="60px">编号</th>--%>
+                        <th width="200px"><font color="red">*</font>报销人</th>
+                        <th width="200px">报销部门</th>
+                        <th width="200px"><font color="red">*</font>报销类型</th>
+                        <th width="200px"><font color="red">*</font>报销项目</th>
+                        <th width="200px">报告号</th>
+                        <th width="200px"><font color="red">*</font>费用(元)</th>
+                        <th width="200px">收据张数</th>
+                        <th width="200px">出差天数</th>
+                        <th width="200px">内容</th>
+                        <th width="100px">操作</th>
+                    </tr>
+                    </thead>
+                    <tbody id="workAccountList">
+                    <c:if test="${not empty workReimbursement.workAccountList}">
+                        <c:forEach items="${workReimbursement.workAccountList}" var="workAccount" varStatus="index">
+                            <tr id="workAccountList${index.index}">
+                                <td class="hide">
+                                    <input id="workAccountList${index.index}_id" name="workAccountList[${index.index}].id" type="hidden" value="${workAccount.id}"/>
+                                    <input id="workAccountList${index.index}_projectRadio" name="workAccountList[${index.index}].projectRadio" type="hidden" value="${workAccount.projectRadio}"/>
+                                    <input id="workAccountList${index.index}_delFlag" name="workAccountList[${index.index}].delFlag" type="hidden" value="0"/>
+                                </td>
+                                <td>
+                                    <div class="project_reimbursement_div"  style="width: 200px">
+                                        <sys:reimburtreeselectUser id="workAccountList${index.index}_reimbursementName" name="workAccountList[${index.index}].reimbursementName" value="${projectRecords.leaderIds}" labelName="reimbursementNameName" labelValue="${workAccount.reimbursementName}"
+                                                                   title="用户" url="/sys/office/treeDataAll?type=3" cssClass="form-control  layui-input" allowClear="true" notAllowSelectParent="true"/>
+                                    </div>
+                                </td>
+                                <td>
+                                    <input id="workAccountList${index.index}_reimbursementNameofficeId"  name="workAccountList[${index.index}].officeId" maxlength="32" type="text" value="${workAccount.officeId}" readonly="readonly"  class="form-control judgment"/>
+                                </td>
+                                <td style="text-align:center;">
+                                    <div class="project_reimbursement_div"  style="width: 200px">
+                                        <sys:treeselectAccessoryNoParent id="workAccountList${index.index}_type" name="workAccountList[${index.index}].type" value="${workAccount.type}" labelName="workAccountList[${index.index}].typeName" labelValue="${workAccount.typeName}"
+                                                                         title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control judgment  layui-input" allowClear="true" notAllowSelectParent="true"/>
+                                    </div>
+                                </td>
+
+                                <td>
+                                    <div class="not_project_reimbursement_div"  style="width: 200px">
+                                        <sys:reimburselectReproject url="${ctx}/workreimbursement/workReimbursement/selectReproject" id="workAccountList${index.index}_project" name="workAccountList[${index.index}].project.id"  value="${workAccount.project.id}"  title="选择报销项目" labelName="workAccountList[${index.index}].project.projectName"
+                                                                    labelValue="${workAccount.project.projectName}" extId="${workAccount.projectRadio}" cssClass="form-control judgment layui-input" fieldLabels="工程" fieldKeys="projectName" searchLabel="工程名称" searchKey="projectName" />
+                                    </div>
+                                </td>
+                                <td>
+                                    <input id="workAccountList${index.index}_projectReportNumber"  name="workAccountList[${index.index}].projectReportNumber" type="text" value="${workAccount.projectReportNumber}" maxlength="32" readonly="readonly"  class="form-control"/>
+                                </td>
+
+
+                                <td>
+                                    <input id="workAccountList${index.index}_money" onchange="getMoney(this.value)" name="workAccountList[${index.index}].money" type="text" value="${workAccount.money}"  placeholder="请输入金额" maxlength="10"  class="form-control number judgment"/>
+                                </td>
+                                <td style="text-align:center;">
+                                    <input id="workAccountList${index.index}_bills"  name="workAccountList[${index.index}].bills" type="text" value="${workAccount.bills}" maxlength="32" placeholder="请输入单据张数"  class="form-control number"/>
+                                </td>
+                                <td style="text-align:center;">
+                                    <input id="workAccountList${index.index}_evectionNumber"  name="workAccountList[${index.index}].evectionNumber" type="text" value="${workAccount.evectionNumber}" maxlength="32" placeholder="请输入出差天数"  class="form-control number"/>
+                                </td>
+                                <td>
+                                    <input id="workAccountList${index.index}_remarks" name="workAccountList[${index.index}].remarks" type="text" value="${workAccount.remarks}" maxlength="32" placeholder="请输入备注"  class="form-control"/>
+                                </td>
+
+                                <td class="text-center op-td" >
+                                    <span class="op-btn op-btn-delete" onclick="delRow(this, '#workAccountList${index.index}')" title="删除"><i class="glyphicon glyphicon-remove"></i>&nbsp;删除</span>
+                                </td>
+                            </tr>
+                        </c:forEach>
+                    </c:if>
+                    </tbody>
+                </table>
+                <table id="contentMoneys" class="table table-bordered table-condensed can-edit no-bottom-margin details">
+                    <thead>
+                        <tr style="border: 0px">
+                            <td width="200px" style="vertical-align:middle;text-align: center;"><label><font color="red">*</font>总报销费用(元):</label></td>
+                            <td width="200px"></td>
+                            <td width="200px"></td>
+                            <td width="200px"></td>
+                            <td width="200px"></td>
+                            <td width="200px" style="border: 0px">
+                                <input htmlEscape="false" style="border: 0px; font-weight: bold;" id="moneys" name="money" readonly="true" class="form-control layui-input" value="${workReimbursement.money}"/>
+                            </td>
+                            <td width="200px"></td>
+                            <td width="200px"></td>
+                            <td width="200px"></td>
+                            <td width="100px"></td>
+                        </tr>
+                    </thead>
+                </table>
+                <script type="text/template" id="workAccountListTpl">//<!--
+                    <tr id="workAccountList{{idx}}">
+                        <td class="hide">
+                            <input id="workAccountList{{idx}}_id" name="workAccountList[{{idx}}].id" type="hidden" value="{{row.id}}"/>
+                            <input id="workAccountList{{idx}}_projectRadio"  name="workAccountList[{{idx}}].projectRadio" type="hidden" value="{{row.projectRadio}}"/>
+                            <input id="workAccountList{{idx}}_delFlag" name="workAccountList[{{idx}}].delFlag" type="hidden" value="0"/>
+                        </td>
+                        <%--<td>
+                            <div style="width: 60px">
+                                <input readonly="readonly" style="text-align: center"  value="{{idx}}" type="text" class="form-control contentDetail"/>
+                            </div>
+                        </td>--%>
+                        <td>
+                            <div class="project_reimbursement_div"  style="width: 200px">
+                                <sys:reimburtreeselectUser id="workAccountList{{idx}}_reimbursementName" name="workAccountList[{{idx}}].reimbursementName" value="${projectRecords.leaderIds}" labelName="workAccountList[{{idx}}].name" labelValue="{{row.reimbursementName}}"
+                                    title="用户" url="/sys/office/treeDataAll?type=3" cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="true"/>
+                            </div>
+                        </td>
+                        <td>
+                            <div class="not_project_reimbursement_div"  style="width: 200px">
+                                <input id="workAccountList{{idx}}_reimbursementNameofficeId"  type="text" value="{{row.officeId}}" maxlength="32" readonly="readonly"  class="form-control"/>
+                            </div>
+                        </td>
+                        <td style="text-align:center;">
+                            <div class="project_reimbursement_div"  style="width: 200px">
+                                <sys:treeselectAccessoryNoParent id="workAccountList{{idx}}_type" name="workAccountList[{{idx}}].type" value="${workReimbursement.workReimbursementTypeInfo.id}" labelName="workAccountList[{{idx}}].typeName" labelValue="${workReimbursement.workReimbursementTypeInfo.standardDetail}"
+                                     title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control judgment layui-input" allowClear="true" notAllowSelectParent="true"/>
+                            </div>
+                        </td>
+                        <td>
+                            <div class="not_project_reimbursement_div"  style="width: 200px">
+                                <sys:reimburselectReproject url="${ctx}/workreimbursement/workReimbursement/selectReproject" id="workAccountList{{idx}}_project" name="workAccountList[{{idx}}].project.id"  value="${workReimbursement.project.id}"  title="选择报销项目" labelName="workAccountList[{{idx}}].project.projectName"
+                                       labelValue="{{row.projectName}}" extId="" area="" cssClass="form-control judgment layui-input"  fieldLabels="工程" fieldKeys="projectName" searchLabel="工程名称" searchKey="projectName" ></sys:reimburselectReproject>
+                            </div>
+                        </td>
+                        <td>
+                            <input id="workAccountList{{idx}}_projectReportNumber"  name="workAccountList[{{idx}}].projectReportNumber" type="text" value="{{row.projectReportNumber}}" maxlength="32" readonly="readonly"  class="form-control"/>
+                        </td>
+
+                        <td>
+                            <input id="workAccountList{{idx}}_money" onchange="getMoney(this.value)" name="workAccountList[{{idx}}].money" type="text" value="{{row.money}}"  placeholder="请输入费用" maxlength="10" class="form-control number judgment"/>
+                        </td>
+                        <td style="text-align:center;">
+                            <input id="workAccountList{{idx}}_bills"  name="workAccountList[{{idx}}].bills" type="text" value="{{row.bills}}" maxlength="3" placeholder="请输入单据张数"  class="form-control number"/>
+                        </td>
+                        <td style="text-align:center;">
+                            <input id="workAccountList{{idx}}_evectionNumber"  name="workAccountList[{{idx}}].evectionNumber" type="text" value="{{row.evectionNumber}}" maxlength="3" placeholder="请输入出差天数"  class="form-control number"/>
+                        </td>
+                        <td>
+                            <input id="workAccountList{{idx}}_remarks" name="workAccountList[{{idx}}].remarks" type="text" value="{{row.remarks}}"  placeholder="请输入内容" maxlength="32" class="form-control "/>
+                        </td>
+
+                        <td class="text-center op-td" >
+                            {{#delBtn}}<span class="op-btn op-btn-delete" onclick="delRow(this, '#workAccountList{{idx}}')" title="删除"><i class="glyphicon glyphicon-remove"></i>&nbsp;删除</span>{{/delBtn}}
+                        </td>
+                    </tr>//-->
+                </script>
+            </div>
+        </div>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>专用发票信息</h2></div>
+            <div class="layui-item nav-btns">
+                <a class="nav-btn nav-btn-add" onclick="addRow('#reimbursementVATTaxes', reimbursementVATTaxesRowIdx, reimbursementVATTaxesTpl);reimbursementVATTaxesRowIdx = reimbursementVATTaxesRowIdx + 1;" title="新增"><i class="fa fa-plus"></i>&nbsp;新增</a>
+            </div>
+            <div class="layui-item layui-col-xs12 form-table-container">
+                <table id="contentTable2" class="table table-bordered table-condensed can-edit">
+                    <thead>
+                    <tr>
+                        <th width="300px">发票代码</th>
+                        <th width="200px">发票号</th>
+                        <th width="200px">金额</th>
+                        <th width="200px">税额</th>
+                        <th width="200px">价税合计</th>
+                        <th width="150px">操作</th>
+                    </tr>
+                    </thead>
+                    <tbody id="reimbursementVATTaxes">
+                    <c:if test="${not empty workReimbursement.reimbursementVATTaxes}">
+                        <c:forEach items="${workReimbursement.reimbursementVATTaxes}" var="reimbursementVATTaxes" varStatus="index">
+                            <tr id="reimbursementVATTaxes${index.index}">
+                                <td class="hide">
+                                    <input id="reimbursementVATTaxes${index.index}_id" name="reimbursementVATTaxes[${index.index}].id" type="hidden" value="${reimbursementVATTaxes.id}"/>
+                                    <input id="reimbursementVATTaxes${index.index}_delFlag" name="reimbursementVATTaxes[${index.index}].delFlag" type="hidden" value="0"/>
+                                </td>
+                                <td>
+                                    <input id="reimbursementVATTaxes${index.index}_invoiceCode" maxlength="10" minlength="10" name="reimbursementVATTaxes[${index.index}].invoiceCode" type="text" maxlength="32" value="${reimbursementVATTaxes.invoiceCode}"  placeholder="请输入发票代码"  class="form-control  number"/>
+                                </td>
+
+                                <td>
+                                    <input id="reimbursementVATTaxes${index.index}_invoiceNumber" maxlength="8" minlength="8" name="reimbursementVATTaxes[${index.index}].invoiceNumber" type="text" maxlength="32" value="${reimbursementVATTaxes.invoiceNumber}"  placeholder="请输入发票号"  class="form-control number "/>
+                                </td>
+                                <td>
+                                    <input id="reimbursementVATTaxes${index.index}_money" onchange="getMoneyVATT(${index.index})" name="reimbursementVATTaxes[${index.index}].money" type="text" maxlength="32" value="${reimbursementVATTaxes.money}"  placeholder="请输入金额"  class="form-control number "/>
+                                </td>
+                                <td>
+                                    <input id="reimbursementVATTaxes${index.index}_taxAmount" onchange="getMoneyVATT(${index.index})" name="reimbursementVATTaxes[${index.index}].taxAmount" type="text" maxlength="32" value="${reimbursementVATTaxes.taxAmount}"  placeholder="请输入税额"  class="form-control number "/>
+                                </td>
+                                <td>
+                                    <input id="reimbursementVATTaxes${index.index}_sumMoney" readOnly="true"  name="reimbursementVATTaxes[${index.index}].sumMoney" type="text" maxlength="32" value="${reimbursementVATTaxes.sumMoney}"    class="form-control number  sumMoney"/>
+                                </td>
+                                <td class="text-center op-td">
+                                    <span class="op-btn op-btn-delete" onclick="delRowA(this, '#reimbursementVATTaxes${index.index}')" title="删除"><i class="glyphicon glyphicon-remove"></i>&nbsp;删除</span>
+                                </td>
+                            </tr>
+                        </c:forEach>
+                    </c:if>
+                    </tbody>
+                </table>
+                <script type="text/template" id="reimbursementVATTaxesTpl">//<!--
+                                    <tr id="reimbursementVATTaxes{{idx}}">
+                                        <td class="hide">
+                                            <input id="reimbursementVATTaxes{{idx}}_id" name="reimbursementVATTaxes[{{idx}}].id" type="hidden" value="{{row.id}}"/>
+                                            <input id="reimbursementVATTaxes{{idx}}_delFlag" name="reimbursementVATTaxes[{{idx}}].delFlag" type="hidden" value="0"/>
+                                        </td>
+                                        <td>
+                                            <input id="reimbursementVATTaxes{{idx}}_invoiceCode"  maxlength="10" minlength="10" name="reimbursementVATTaxes[{{idx}}].invoiceCode" type="text" value="{{row.invoiceCode}}" maxlength="32" placeholder="请输入发票代码"  class="form-control number "/>
+                                        </td>
+
+                                        <td>
+                                            <input id="reimbursementVATTaxes{{idx}}_invoiceNumber" maxlength="8" minlength="8" name="reimbursementVATTaxes[{{idx}}].invoiceNumber" type="text" value="{{row.invoiceNumber}}" maxlength="32" placeholder="请输入发票号"  class="form-control number "/>
+                                        </td>
+                                         <td>
+                                            <input id="reimbursementVATTaxes{{idx}}_money" onchange="getMoneyVATT({{idx}})" name="reimbursementVATTaxes[{{idx}}].money" type="text" value="{{row.money}}" maxlength="32" placeholder="请输入金额"  class="form-control number "/>
+                                        </td>
+                                        <td>
+                                            <input id="reimbursementVATTaxes{{idx}}_taxAmount"  onchange="getMoneyVATT({{idx}})"name="reimbursementVATTaxes[{{idx}}].taxAmount" type="text" value="{{row.taxAmount}}" maxlength="32" placeholder="请输入税额"  class="form-control number "/>
+                                        </td>
+                                         <td>
+                                            <input id="reimbursementVATTaxes{{idx}}_sumMoney" readOnly="true"  name="reimbursementVATTaxes[{{idx}}].sumMoney" type="text" value="{{row.sumMoney}}" maxlength="32"  class="form-control number  sumMoney"/>
+                                        </td>
+                                        <td class="text-center op-td">
+                                            {{#delBtn}}<span class="op-btn op-btn-delete" onclick="delRowA(this, '#reimbursementVATTaxes{{idx}}')" title="删除"><i class="glyphicon glyphicon-remove"></i>&nbsp;删除</span>{{/delBtn}}
+                                        </td>
+                                    </tr>//-->
+                </script>
+                <script type="text/javascript">
+                    var workAccountListRowIdx = 0, workAccountListTpl = $("#workAccountListTpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
+                    var reimbursementVATTaxesRowIdx = 0, reimbursementVATTaxesTpl = $("#reimbursementVATTaxesTpl").html().replace(/(\/\/\<!\-\-)|(\/\/\-\->)/g,"");
+                    if($("#id").val()){
+                        workAccountListRowIdx = ${fn:length(workReimbursement.workAccountList)};
+                        reimbursementVATTaxesRowIdx = ${fn:length(workReimbursement.reimbursementVATTaxes)};
+                    }
+                    $(document).ready(function() {
+                        <%--var data = ${fns:toJson(workReimbursement.createBy)};--%>
+                        <%--addRow('#workAccountList', workAccountListRowIdx, workAccountListTpl,data,true );--%>
+                        /*var data = ${fns:toJson(workReimbursement.reimbursementVATTaxes)};
+                    for (var i=0; i<data.length; i++){
+                        addRow('#reimbursementVATTaxes', reimbursementVATTaxesRowIdx, reimbursementVATTaxesTpl, data[i]);
+                        reimbursementVATTaxesRowIdx = reimbursementVATTaxesRowIdx + 1;
+                    }*/
+                    });
+                </script>
+            </div>
+        </div>
+        <div class="form-group layui-row">
+            <div class="form-group-label"><h2>报销附件信息</h2></div>
+            <div class="layui-item nav-btns">
+                <a id="attachment_btn" class="nav-btn nav-btn-add" title="添加附件"><i class="fa fa-plus"></i>&nbsp;添加附件</a>
+                <sys:collectSelect  id="linkman" url="${ctx}/workclientinfo/workClientInfo/linkmanList"
+                                    name="linkman.id"  title="选择资料库"
+                                    cssClass="form-control judgment" fieldLabels="资料库" fieldKeys="name"
+                                    searchLabel="资料库" searchKey="fileName"></sys:collectSelect>
+            </div>
+            <div id="addFile_attachment" style="display: none" class="upload-progress">
+                <span id="fileName_attachment" ></span>
+                <b><span id="baifenbi_attachment" ></span></b>
+                <div class="progress">
+                    <div id="jindutiao_attachment" class="progress-bar" style="width: 0%" aria-valuenow="0">
+                    </div>
+                </div>
+            </div>
+            <input id="attachment_file" type="file" name="attachment_file" multiple="multiple" style="display: none;" onChange="if(this.value)insertTitle(this.value);"/>
+            <span id="attachment_title"></span>
+            <div class="layui-item layui-col-xs12" style="padding:0 16px;">
+                <table id="upTable" class="table table-bordered table-condensed details">
+                    <thead>
+                    <tr>
+                            <%-- <th>序号</th>--%>
+                        <th>文件预览</th>
+                        <th>上传人</th>
+                        <th>上传时间</th>
+                        <th width="200px">操作</th>
+                    </tr>
+                    </thead>
+                    <tbody id="file_attachment">
+                    <c:forEach items="${workReimbursement.workAttachments}" var = "workClientAttachment" varStatus="status">
+                        <tr>
+                                <%-- <td>${status.index + 1}</td>--%>
+                        <c:choose>
+                            <c:when test="${workReimbursement.uploadMode == 2}">
+                                <c:choose>
+                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+                                        <td><img src="${workClientAttachment.temporaryUrl}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.temporaryUrl}','90%','90%')" alt="${workClientAttachment.attachmentName}">
+                                    </c:when>
+                                    <c:otherwise>
+                                        <c:choose>
+                                            <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+                                                <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',1)">${workClientAttachment.attachmentName}</a></td>
+                                            </c:when>
+                                            <c:otherwise>
+                                                <c:choose>
+                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                    </c:when>
+                                                    <c:otherwise>
+                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.temporaryUrl}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                    </c:otherwise>
+                                                </c:choose>
+                                            </c:otherwise>
+                                        </c:choose>
+                                    </c:otherwise>
+                                </c:choose>
+                            </c:when>
+                            <c:otherwise>
+                                <c:choose>
+                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpg')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'png')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'gif')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'bmp')
+                                               or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jpeg')}">
+                                        <td><img src="${workClientAttachment.url}" width="50" height="50" onclick="openDialogView('预览','${ctx}/sys/picturepreview/picturePreview?url=${workClientAttachment.url}','90%','90%')" alt="${workClientAttachment.attachmentName}"></td>
+                                    </c:when>
+                                    <c:otherwise>
+                                        <c:choose>
+                                            <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+                                                <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',1)">${workClientAttachment.attachmentName}</a></td>
+                                            </c:when>
+                                            <c:otherwise>
+                                                <c:choose>
+                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'rar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'zip')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'jar')
+                                                       or fn:containsIgnoreCase(workClientAttachment.attachmentName,'7z')}">
+                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',3)">${workClientAttachment.attachmentName}</a></td>
+                                                    </c:when>
+                                                    <c:otherwise>
+                                                        <td><a class="attention-info" href="javascript:void(0)" onclick="openPreview('${workClientAttachment.url}',2)">${workClientAttachment.attachmentName}</a></td>
+                                                    </c:otherwise>
+                                                </c:choose>
+                                            </c:otherwise>
+                                        </c:choose>
+                                    </c:otherwise>
+                                </c:choose>
+                            </c:otherwise>
+                        </c:choose>
+
+
+                            <td>${workClientAttachment.createBy.name}</td>
+                            <td><fmt:formatDate value="${workClientAttachment.createDate}" type="both"/></td>
+                            <td class="op-td">
+                                <div class="op-btn-box" >
+                                        <%--附件下载删除--%>
+                                    <c:choose>
+                                        <c:when test="${workReimbursement.uploadMode == 2}">
+                                            <c:choose>
+                                                <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'pdf')}">
+                                                    <a href="${workClientAttachment.temporaryUrl}" target="_blank" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+                                                </c:when>
+                                                <c:otherwise>
+                                                    <a href="${workClientAttachment.temporaryUrl}" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+                                                </c:otherwise>
+                                            </c:choose>
+                                        </c:when>
+                                        <c:otherwise>
+                                            <a href="javascript:location.href='${ctx}/workfullmanage/workFullManage/downLoadAttach?file='+encodeURIComponent('${workClientAttachment.url}');" class="op-btn op-btn-download"><i class="fa fa-download"></i>&nbsp;下载</a>
+                                        </c:otherwise>
+                                    </c:choose>
+                                    <c:if test="${workClientAttachment.collectFlag != 1}">
+                                        <a href="javascript:void(0)" onclick="collectingAccessory(this,'${ctx}/projectAccessory/projectAccessory/saveCollectAccessory','${workClientAttachment.url}','${workClientAttachment.createBy.id}','${workClientAttachment.fileSize}')" class="op-btn op-btn-delete"   style="background-color: #FFB800"><i class="layui-icon layui-icon-rate"></i>&nbsp;收藏</a>
+                                    </c:if>
+                                    <c:if test="${workClientAttachment.createBy.id eq fns:getUser().id}">
+                                        <a href="javascript:void(0)" onclick="deleteFileFromAliyun(this,'${ctx}/sys/workattachment/deleteFileFromAliyun?url=${workClientAttachment.url}&id=${workClientAttachment.id}&type=2','addFile')" class="op-btn op-btn-delete" ><i class="fa fa-trash"></i>&nbsp;删除</a>
+                                    </c:if>
+
+                                </div>
+                            </td>
+                        </tr>
+                    </c:forEach>
+                    </tbody>
+                </table>
+            </div>
+        </div>
+        <div class="form-group layui-row page-end"></div>
+    </form:form>
+</div>
+</div>
+</body>
+</html>

ファイルの差分が大きいため隠しています
+ 1203 - 0
src/main/webapp/webpage/modules/workreimbursement/new/workReimbursementNewModifyApply.jsp


+ 15 - 3
src/main/webapp/webpage/modules/workreimbursement/workReimbursementList.jsp

@@ -283,14 +283,24 @@
                         {
                             xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
                         }
+                        if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 3)
+                        {
+                            xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
+                        }
                         if(d.cancancel != undefined && d.cancancel == "1")
                             xml += "<a href=\"${ctx}/workreimbursement/workReimbursement/cancelInvalidate?id=" + d.id + "\" onclick=\"return confirmx('确认要强制撤回?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\"> 撤回</a>";
                         if(d.canedit1 != undefined && d.canedit1 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogre('修改报销单', '${ctx}/workreimbursement/workReimbursement/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
+                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogre('修改报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
                         if(d.canedit2 != undefined && d.canedit2 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursement/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                            //判断是什么流程(新旧流程)
+                            if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 2){
+                                xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursement/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                            }else if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 4){
+                                xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" >修改</a>";
+                            }
+
                         if(d.canedit3 != undefined && d.canedit3 == "1")
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreplay('重新申请报销单', '${ctx}/workreimbursement/workReimbursement/form?id=" + d.id + "&tabId=4','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改</a>";
+                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreplay('重新申请报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id=" + d.id + "&tabId=4','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 修改</a>";
                         if(d.candelete != undefined && d.candelete == "1")
                             xml +="<a href=\"${ctx}/workreimbursement/workReimbursement/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该报销单吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\"> 删除</a>";
 
@@ -309,6 +319,8 @@
                     ,"realnumber":"${workReimbursement.number}"
                     ,"number":"${workReimbursement.number}"
                     ,"taskName":"${workReimbursement.taskName}"
+                    ,"notifyFlag":"${workReimbursement.notifyFlag}"
+                    ,"notifyId":"${workReimbursement.notifyId}"
                     ,"submitterName":"<c:out value="${fns:getUserById(workReimbursement.submitterId).name}" escapeXml="true"/>"
                     ,"handleName":"<c:out value="${fns:getUserById(workReimbursement.handleId).name}" escapeXml="true"/>"
                     ,"officeId":"${fns:getOfficeById(workReimbursement.officeId).name}"