Procházet zdrojové kódy

报销功能bug修复

user5 před 1 rokem
rodič
revize
3f3646aed2

+ 9 - 0
src/main/java/com/jeeplus/modules/workprojectnotify/entity/WorkProjectNotify.java

@@ -68,6 +68,7 @@ public class WorkProjectNotify extends DataEntity<WorkProjectNotify> {
 	private String typeLabel; // 类型label
 	private String auditUserName; // 审核人name
 	private String belongProject; // 所属系统
+	private String pageFlag; // 回跳页面判定
 
 	public WorkProjectNotify() {
 		super();
@@ -387,4 +388,12 @@ public class WorkProjectNotify extends DataEntity<WorkProjectNotify> {
 	public void setBelongProject(String belongProject) {
 		this.belongProject = belongProject;
 	}
+
+	public String getPageFlag() {
+		return pageFlag;
+	}
+
+	public void setPageFlag(String pageFlag) {
+		this.pageFlag = pageFlag;
+	}
 }

+ 1 - 0
src/main/java/com/jeeplus/modules/workprojectnotify/web/WorkProjectNotifyController.java

@@ -10037,6 +10037,7 @@ public class WorkProjectNotifyController extends BaseController {
 		}else if (workProjectNotify.getRemarks().contains("待审批") && !"1".equals(workProjectNotify.getStatus())) {
 			model.addAttribute("identification","workreimbursement");
 			model.addAttribute("identificationName","报销审核意见");
+			model.addAttribute("pageFlag",workProjectNotify.getPageFlag());
 						/*if (workReimbursement.getAct() != null && StringUtils.isNotBlank(workReimbursement.getAct().getTaskDefKey()) && "cw".equals(workReimbursement.getAct().getTaskDefKey())) {
 							return "modules/workreimbursement/new/workReimbursementCWNewAudit";
 						}*/

+ 9 - 0
src/main/java/com/jeeplus/modules/workreimbursement/entity/WorkReimbursement.java

@@ -77,6 +77,7 @@ public class WorkReimbursement extends ActEntity<WorkReimbursement> {
 	private String comment; // 意见
 	private String reimbursementType; // 报销类型
 	private String reimbursementTypeStr; // 报销类型Str
+	private String pageFlag; // 回调页面判定
 
 	public String getComment() {
 		return comment;
@@ -675,4 +676,12 @@ public class WorkReimbursement extends ActEntity<WorkReimbursement> {
 	public void setReimbursementTypeStr(String reimbursementTypeStr) {
 		this.reimbursementTypeStr = reimbursementTypeStr;
 	}
+
+	public String getPageFlag() {
+		return pageFlag;
+	}
+
+	public void setPageFlag(String pageFlag) {
+		this.pageFlag = pageFlag;
+	}
 }

+ 92 - 23
src/main/java/com/jeeplus/modules/workreimbursement/service/WorkReimbursementAllService.java

@@ -18,10 +18,12 @@ import com.jeeplus.modules.projectcontentinfo.service.ProjectReportDataService;
 import com.jeeplus.modules.projectrecord.dao.WorkProjectUserDao;
 import com.jeeplus.modules.projectrecord.entity.ProjectRecords;
 import com.jeeplus.modules.serialnum.service.SerialNumTplService;
+import com.jeeplus.modules.sys.entity.MainDictDetail;
 import com.jeeplus.modules.sys.entity.Office;
 import com.jeeplus.modules.sys.entity.User;
 import com.jeeplus.modules.sys.service.OfficeService;
 import com.jeeplus.modules.sys.service.WorkattachmentService;
+import com.jeeplus.modules.sys.utils.DictUtils;
 import com.jeeplus.modules.sys.utils.UserUtils;
 import com.jeeplus.modules.workactivity.dao.WorkActivityProcessDao;
 import com.jeeplus.modules.workactivity.entity.Activity;
@@ -59,6 +61,7 @@ import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 
+import java.text.SimpleDateFormat;
 import java.util.*;
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
@@ -133,6 +136,9 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
     public WorkReimbursement get(String id) {
         WorkReimbursement workReimbursement = super.get(id);
         if(null != workReimbursement){
+            //获取专业类型
+            List<MainDictDetail> certificateMajor = DictUtils.getMainDictList("invoiceReimbursementType");
+
             List<WorkAccount> workAccounts = workAccountDao.findList(new WorkAccount(workReimbursement));
             for (WorkAccount workAccount:workAccounts){
                 List<WorkAccountAudit> workAccountAudits = workAccountDao.findByWorkAccount(workAccount);
@@ -150,7 +156,33 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
                 }
             }
             workReimbursement.setWorkAccountList(workAccounts);
-            workReimbursement.setReimbursementVATTaxes(reimbursementVATTaxDao.findList(new ReimbursementVATTax(workReimbursement)));
+            List<ReimbursementVATTax> vatTaxDaoList = reimbursementVATTaxDao.findList(new ReimbursementVATTax(workReimbursement));
+            List<ReimbursementVATTax> vatTaxList = Lists.newArrayList();
+            List<ReimbursementVATTax> electronicInvoiceVATTaxesList = Lists.newArrayList();
+            for (ReimbursementVATTax vatTax : vatTaxDaoList) {
+                switch (vatTax.getReimbursementType()){
+                    case "0":
+                        vatTaxList.add(vatTax);
+                        break;
+                    case "1":
+                        SimpleDateFormat formatter = new SimpleDateFormat("yyyy-MM-dd");
+                        if(null != vatTax.getInvoiceDate()){
+                            String dateString = formatter.format(vatTax.getInvoiceDate());
+                            vatTax.setInvoiceDateStr(dateString);
+                        }
+                        for (MainDictDetail dictDetail : certificateMajor) {
+                            if(dictDetail.getValue().equals(vatTax.getInvoiceType())){
+                                vatTax.setInvoiceTypeStr(dictDetail.getLabel());
+                            }
+                        }
+
+                        electronicInvoiceVATTaxesList.add(vatTax);
+                        break;
+
+                }
+            }
+            workReimbursement.setReimbursementVATTaxes(vatTaxList);
+            workReimbursement.setReimbursementElectronicInvoiceVATTaxes(electronicInvoiceVATTaxesList);
             WorkClientAttachment workClientAttachment = new WorkClientAttachment();
             workClientAttachment.setAttachmentId(id);
             workClientAttachment.setAttachmentFlag(VarStr.attachmentFlag[1]);
@@ -161,6 +193,11 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
             if (workReimbursement!=null && StringUtils.isNotBlank(workReimbursement.getOfficeId())){
                 workReimbursement.setOfficeName(UserUtils.getOfficeById(workReimbursement.getOfficeId()).getName());
             }
+
+            WorkClientAttachment workClientInvoiceAttachment = new WorkClientAttachment();
+            workClientInvoiceAttachment.setAttachmentId(id);
+            workClientInvoiceAttachment.setAttachmentFlag("workInvoiceReimbursement");
+            workReimbursement.setWorkAttachmentInvoiceReimbursements(workattachmentService.getAttachmentList(workClientInvoiceAttachment));
             //暂存状态不操作流程
 		/*if(!"1".equals(workReimbursement.getStatus())){
             Map<String,Object> variables=null;
@@ -212,9 +249,12 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
             workReimbursement.setReimbursementBackList( workReimbursementBackDao.findList(workReimbursementBack));
         }
         //添加当前文件服务器类型
-        workReimbursement.setUploadMode(uploadMode);
-        //数据处理(如果为阿里云文件服务器,则对查看的路径进行处理)
-        workattachmentService.clientAttachmentManageOnUrl(workReimbursement.getWorkAttachments());
+        if(null != workReimbursement){
+            workReimbursement.setUploadMode(uploadMode);
+            //数据处理(如果为阿里云文件服务器,则对查看的路径进行处理)
+            workattachmentService.clientAttachmentManageOnUrl(workReimbursement.getWorkAttachments());
+            workattachmentService.clientAttachmentManageOnUrl(workReimbursement.getWorkAttachmentInvoiceReimbursements());
+        }
         return workReimbursement;
     }
 
@@ -627,8 +667,21 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
                     workAccountDao.delete(workAccount);
                 }
             }
+
+            if("0".equals(workReimbursement.getReimbursementType())){
+                for (ReimbursementVATTax reimbursementVATTax : workReimbursement.getReimbursementElectronicInvoiceVATTaxes()) {
+                    reimbursementVATTaxDao.delete(reimbursementVATTax);
+                }
+            }else if("1".equals(workReimbursement.getReimbursementType())){
+                for (ReimbursementVATTax reimbursementVATTax : workReimbursement.getReimbursementVATTaxes()) {
+                    reimbursementVATTaxDao.delete(reimbursementVATTax);
+                }
+            }
+
             for (ReimbursementVATTax reimbursementVATTax : workReimbursement.getReimbursementVATTaxes()) {
                 if (ReimbursementVATTax.DEL_FLAG_NORMAL.equals(reimbursementVATTax.getDelFlag())) {
+                    //普通报销 发票信息
+                    reimbursementVATTax.setReimbursementType("0");
                     reimbursementVATTax.setWorkReimbursement(workReimbursement);
                     if (StringUtils.isBlank(reimbursementVATTax.getId()) && StringUtils.isNotBlank(reimbursementVATTax.getInvoiceCode())) {
                         reimbursementVATTax.preInsert();
@@ -641,6 +694,24 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
                     reimbursementVATTaxDao.delete(reimbursementVATTax);
                 }
             }
+
+
+            for (ReimbursementVATTax reimbursementVATTax : workReimbursement.getReimbursementElectronicInvoiceVATTaxes()) {
+                //电子发票报销 发票信息
+                reimbursementVATTax.setReimbursementType("1");
+                if (ReimbursementVATTax.DEL_FLAG_NORMAL.equals(reimbursementVATTax.getDelFlag())) {
+                    reimbursementVATTax.setWorkReimbursement(workReimbursement);
+                    if (StringUtils.isBlank(reimbursementVATTax.getId()) && StringUtils.isNotBlank(reimbursementVATTax.getInvoiceNumber())) {
+                        reimbursementVATTax.preInsert();
+                        reimbursementVATTaxDao.insert(reimbursementVATTax);
+                    } else {
+                        reimbursementVATTax.preUpdate();
+                        reimbursementVATTaxDao.update(reimbursementVATTax);
+                    }
+                } else {
+                    reimbursementVATTaxDao.delete(reimbursementVATTax);
+                }
+            }
             //附件信息
             for (WorkClientAttachment workClientAttachment : workReimbursement.getWorkAttachments()) {
                 if (workClientAttachment.getId() == null) {
@@ -648,14 +719,12 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
                 }
                 if (WorkClientAttachment.DEL_FLAG_NORMAL.equals(workClientAttachment.getDelFlag())) {
                     workClientAttachment.setAttachmentId(workReimbursement.getId());
-                    workClientAttachment.setAttachmentFlag(VarStr.attachmentFlag[1]);
+                    workClientAttachment.setAttachmentFlag(workClientAttachment.getAttachmentFlag());
                     workClientAttachment.setAttachmentUser(UserUtils.getUser().getId());
                     if (StringUtils.isBlank(workClientAttachment.getId()) || "null".equals(workClientAttachment.getId())) {
-                        workClientAttachment.preInsert();
-                        workClientAttachmentDao.insert(workClientAttachment);
+                        workattachmentService.insertOnWorkClientAttachment(workClientAttachment);
                     } else {
-                        workClientAttachment.preUpdate();
-                        workClientAttachmentDao.update(workClientAttachment);
+                        workattachmentService.updateOnWorkClientAttachment(workClientAttachment);
                     }
                 } else {
                     workClientAttachmentDao.delete(workClientAttachment);
@@ -682,21 +751,21 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
                             workReimbursementBackDao.update(reimbursementBack);
                         }
                     }
-                   //增加还款明细
+                    //增加还款明细
 
-                   if(reimbursementBack.getMoney()!=null&&!"".equals(reimbursementBack.getMoney())&&!"0".equals(reimbursementBack.getMoney())){
-                       WorkRepay workRepay=new WorkRepay();
-                       workRepay.preInsert();
-                       workRepay.setWorkLoan(reimbursementBack.getWorkLoan());
-                       workRepay.setOfficeId(workReimbursement.getOfficeId());
-                       workRepay.setCompanyId(workReimbursement.getCompanyId());
-                       workRepay.setRepayDate(new Date());
-                       workRepay.setSource("1");
-                       workRepay.setStatus("2");
-                       workRepay.setMoney(reimbursementBack.getMoney());
-                       workRepay.setWorkReimbursement(workReimbursement);
-                       workRepayDao.insert(workRepay);
-                   }
+                    if(reimbursementBack.getMoney()!=null&&!"".equals(reimbursementBack.getMoney())&&!"0".equals(reimbursementBack.getMoney())){
+                        WorkRepay workRepay=new WorkRepay();
+                        workRepay.preInsert();
+                        workRepay.setWorkLoan(reimbursementBack.getWorkLoan());
+                        workRepay.setOfficeId(workReimbursement.getOfficeId());
+                        workRepay.setCompanyId(workReimbursement.getCompanyId());
+                        workRepay.setRepayDate(new Date());
+                        workRepay.setSource("1");
+                        workRepay.setStatus("2");
+                        workRepay.setMoney(reimbursementBack.getMoney());
+                        workRepay.setWorkReimbursement(workReimbursement);
+                        workRepayDao.insert(workRepay);
+                    }
 
                 }
 

+ 263 - 48
src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementAllController.java

@@ -39,11 +39,9 @@ import com.jeeplus.modules.workfullmanage.service.WorkFullManageService;
 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.ReimbursementVATTax;
-import com.jeeplus.modules.workreimbursement.entity.WorkAccount;
-import com.jeeplus.modules.workreimbursement.entity.WorkReimbursement;
-import com.jeeplus.modules.workreimbursement.entity.WorkReimbursementTypeInfo;
+import com.jeeplus.modules.workreimbursement.entity.*;
 import com.jeeplus.modules.workreimbursement.service.WorkReimbursementAllService;
+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.workreimbursement.utils.VarStr;
@@ -69,10 +67,9 @@ import javax.servlet.http.HttpServletResponse;
 import javax.validation.ConstraintViolationException;
 import java.io.UnsupportedEncodingException;
 import java.net.URLDecoder;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
+import java.time.LocalDate;
+import java.time.ZoneId;
+import java.util.*;
 
 /**
  * 财务报销Controller
@@ -128,6 +125,8 @@ public class WorkReimbursementAllController extends BaseController {
 	protected WorkProjectNotifyService workProjectNotifyService;
 	@Autowired
 	protected WorkReimbursementService workRService;
+	@Autowired
+	private WorkReimbursementNewService workReimbursementNewService;
 
 	@ModelAttribute
 	public WorkReimbursement get(@RequestParam(required=false) String id) {
@@ -161,6 +160,102 @@ public class WorkReimbursementAllController extends BaseController {
 		}
 		//workReimbursement.setOfficeId(UserUtils.getSelectOffice().getId());
 		Page<WorkReimbursement> page = workReimbursementService.findPage(new Page<WorkReimbursement>(request, response), workReimbursement);
+		List<WorkReimbursement> list = page.getList();
+
+		//查询所有和当前登陆人有关的项目的审核
+		WorkProjectNotify workProjectNotify = new WorkProjectNotify();
+		workProjectNotify.setUser(UserUtils.getUser());
+		workProjectNotify.setCompanyId(UserUtils.getSelectCompany().getId());
+		workProjectNotify.setRemarks("待审批");
+
+		List<String> typeList= jersey.repackaged.com.google.common.collect.Lists.newArrayList();
+		typeList.add("13");
+		typeList.add("102");
+		typeList.add("106");
+		typeList.add("107");
+		typeList.add("108");
+		typeList.add("109");
+		String types = org.apache.commons.lang3.StringUtils.join(typeList,',');
+		workProjectNotify.setTypes(types);
+		//添加发票对应编号
+		//workProjectNotify.setType("13");
+		//查询所有需要当前登录人进行处理的项目信息
+		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()) && "13".equals(notify.getType())){
+					info.setNotifyId(notify.getId());
+					if("待审批".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+						info.setNotifyFlag(1);
+					}
+					if("重新申请".equals(notify.getRemarks()) && !"1".equals(notify.getStatus())){
+						info.setNotifyFlag(2);
+					}
+					break;
+				}
+				//报告归档资料缺失说明修改权限处理
+				if(notify.getNotifyId().equals(info.getId()) && "102".equals(notify.getType())){
+					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;
+				}
+				//报告归档资料缺失说明修改权限处理
+				if(notify.getNotifyId().equals(info.getId()) && "106".equals(notify.getType())){
+					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;
+				}
+				//报告归档资料缺失说明修改权限处理
+				if(notify.getNotifyId().equals(info.getId()) && "107".equals(notify.getType())){
+					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;
+				}
+				//报告归档资料缺失说明修改权限处理
+				if(notify.getNotifyId().equals(info.getId()) && "108".equals(notify.getType())){
+					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;
+				}
+				//报告归档资料缺失说明修改权限处理
+				if(notify.getNotifyId().equals(info.getId()) && "109".equals(notify.getType())){
+					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;
+				}
+			}
+		}
 		model.addAttribute("page", page);
 		return "modules/workreimbursement/workReimbursementAllList";
 	}
@@ -196,7 +291,7 @@ public class WorkReimbursementAllController extends BaseController {
 	@RequestMapping(value = "form")
 	public String form(WorkReimbursement workReimbursement,Model model) {
 		workReimbursementService.isNotProject(workReimbursement);
-		String view = "workReimbursementFormAdd";
+		String view = "workReimbursementAllFormAdd";
 		Office office = UserUtils.getSelectOffice();
 		String tabId = request.getParameter("tabId");
 		//判断报销类型状态并添加报销类型信息数据
@@ -207,8 +302,17 @@ public class WorkReimbursementAllController extends BaseController {
 				workReimbursement.setTypeName(workReimbursementTypeInfo.getStandardDetail());
 			}
 		}
+
+		//获取历史修改记录
+		List<WorkReimbursementadminupdatehistory> adminUpdateReimbursementInfoById = workRService.getAdminUpdateReimbursementInfoById(workReimbursement.getId());
+		if(adminUpdateReimbursementInfoById.size()>0){
+			model.addAttribute("historyShow", "1");
+		}else{
+			model.addAttribute("historyShow", "");
+		}
+
 		if("1".equals(tabId)){
-			view = "workReimbursementFormDetail";
+			view = "workReimbursementAllFormDetail";
 		}else if("3".equals(tabId)){
 			ProcessInstance processInstance = actTaskService.getProcIns(workReimbursement.getProcessInstanceId());
 			if (processInstance!=null) {
@@ -264,19 +368,12 @@ public class WorkReimbursementAllController extends BaseController {
 				workReimbursement.setAchivesId(UserUtils.getBasicInfo().getId());
 			}
 		}
-		if(StringUtils.isNotBlank(workReimbursement.getProcessInstanceId())){
-			if(null == workReimbursement.getAct() || StringUtils.isBlank(workReimbursement.getAct().getProcInsId())){
-				Act act = new Act();
-				act.setProcInsId(workReimbursement.getProcessInstanceId());
-				workReimbursement.setAct(act);
-			}
-			WorkProjectNotify workProjectNotify = workProjectNotifyService.getByProcessInstanceId(workReimbursement.getProcessInstanceId());
-			if(null != workProjectNotify && StringUtils.isNotBlank(workProjectNotify.getNotifyType())){
-				model.addAttribute("projectNotifyType", workProjectNotify.getNotifyType());
-			}
+		if (StringUtils.isNotBlank(workReimbursement.getCreateBy().getId())){
+			User user=UserUtils.get(workReimbursement.getCreateBy().getId());
+			workReimbursement.setCreateBy(user);
 		}
 		model.addAttribute("workReimbursement", workReimbursement);
-		return "modules/workreimbursement/"+view;
+		return "modules/workreimbursement/all/"+view;
 	}
 
 	/**
@@ -322,27 +419,78 @@ public class WorkReimbursementAllController extends BaseController {
 		}
 		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 = workReimbursementService.save(workReimbursement, variables,processInstanceId);
-			if (StringUtils.isNotBlank(str)){
-				addMessage(redirectAttributes, "报销申请提交失败:"+str);
-			}else {
-				addMessage(redirectAttributes, "报销申请已经提交");
+		//获取当前登陆人信息
+		User loginUser = UserUtils.getUser();
+		//如果当前登陆人是管理员,则进行管理员修改
+		if(loginUser.isAdmin()){
+			//进行管理员修改
+			workRService.updateAdminWorkReimbursement(workReimbursement);
+		}else{
+			//状态设置为审核中
+			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 = "报销类型未选择";
 
-		} catch (Exception e) {
-			logger.info("Exception e:"+e);
-			addMessage(redirectAttributes, "报销申请提交失败!");
-			addMessage(redirectAttributes, "系统内部错误");
+				LocalDate reimburseLocalDate = LocalDate.of(2024, 2, 21);
+
+				Date reimburseAuditDate = Date.from(reimburseLocalDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
+
+				Date nowDate = new Date();
+
+				// 调用compareTo()方法进行比较
+				int reimburseResult = -1;
+				if(StringUtils.isNotBlank(workReimbursement.getId())){
+					reimburseResult = workReimbursement.getCreateDate().compareTo(reimburseAuditDate);
+				}else{
+					reimburseResult = nowDate.compareTo(reimburseAuditDate);
+				}
+
+				LocalDate localDate = LocalDate.of(2024, 1, 20);
+
+				Date auditDate = Date.from(localDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
+				// 调用compareTo()方法进行比较
+				int result = nowDate.compareTo(auditDate);
+				//判定当前数据已经在数据库存在并且发起时间是在特定日期之后,并且部门是工程四部
+				//如果当前登录人为工程四部,且当前时间在2024-01-20之前
+				if(StringUtils.isNotBlank(workReimbursement.getId()) && result > 0 && null != loginUser.getOffice() && "10de4a17d3484ba58135364bd53b88de".equals(loginUser.getOffice().getId())){
+					str = workReimbursementNewService.specificInvoiceReimbursementSave(workReimbursement, variables,processInstanceId);
+				}else{
+					if(result > 0 && null != loginUser.getOffice() && "10de4a17d3484ba58135364bd53b88de".equals(loginUser.getOffice().getId())){
+						str = workReimbursementNewService.specificInvoiceReimbursementSave(workReimbursement, variables,processInstanceId);
+					} else {
+						if("0".equals(workReimbursement.getReimbursementType())){
+							if(reimburseResult>0){
+								str = workReimbursementNewService.saveReimburseThree(workReimbursement, variables,processInstanceId);
+							}else{
+								str = workReimbursementNewService.save(workReimbursement, variables,processInstanceId);
+							}
+						}else if("1".equals(workReimbursement.getReimbursementType())){
+							if(reimburseResult>0){
+								str = workReimbursementNewService.electronicInvoiceReimbursementThreeSave(workReimbursement, variables,processInstanceId);
+							}else{
+								str = workReimbursementNewService.electronicInvoiceReimbursementSave(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/workReimbursementAll/?repage";
 //		return "modules/workreimbursement/reimbursementTodoList";
@@ -360,22 +508,62 @@ public class WorkReimbursementAllController extends BaseController {
 			// 对不同环节的业务逻辑进行操作
 			String taskDefKey = workReimbursement.getAct().getTaskDefKey();
 			List<User> users = null;
+
+			LocalDate reimburseLocalDate = LocalDate.of(2024, 2, 21);
+
+			Date reimburseAuditDate = Date.from(reimburseLocalDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
+
+			// 调用compareTo()方法进行比较
+			int reimburseResult = workReimbursement.getCreateDate().compareTo(reimburseAuditDate);
+
+			LocalDate localDate = LocalDate.of(2024, 1, 20);
+
+			Date auditDate = Date.from(localDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
+
+			Date nowDate = new Date();
+			// 调用compareTo()方法进行比较
+			int result = nowDate.compareTo(auditDate);
+			//判定当前数据已经在数据库存在并且发起时间是在特定日期之后,并且部门是工程四部
+			//如果当前登录人为工程四部,且当前时间在2024-01-20之前
+
 			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 ("fgld".equals(taskDefKey)){
+
+
+				if(StringUtils.isNotBlank(workReimbursement.getId()) && result > 0 && "10de4a17d3484ba58135364bd53b88de".equals(workReimbursement.getOfficeId())){
+					users = UserUtils.getByRoleActivityEnname("dzfpbxshybxsd",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+
+				}
+			}else  if ("cw".equals(taskDefKey)){
 				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),3);
 				if (users==null )
-					users = UserUtils.getByRoleActivityEnname("cwzg", 3, workReimbursement.getOfficeId(), "8", workReimbursement.getCreateBy());
-			}*/else  if ("cw".equals(taskDefKey)){
+					users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
+				if("0".equals(workReimbursement.getReimbursementType())){
+					if(reimburseResult>0){
+						users = UserUtils.getByRoleActivityEnname("dzfpbxshybxsd",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+					}else{
+						users = UserUtils.getByRoleActivityEnname("zjbfzribvf",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+					}
+				}else if ("1".equals(workReimbursement.getReimbursementType())){
+					users = UserUtils.getByRoleActivityEnname("dzfpbxshybxsd",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 ("fpglys".equals(taskDefKey) || "dzfpbxshybxsd".equals(taskDefKey)){
+				users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),3);
+				if(reimburseResult>0){
+					users = UserUtils.getByRoleActivityEnname("zjbfzribvf",3,workReimbursement.getOfficeId(),"8",workReimbursement.getCreateBy());
+				}
+				if (users==null )
+					users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),1);
 			}/*else  if ("zjl".equals(taskDefKey)){
-				*//*users = UserUtils.getByProssType(workReimbursement.getProcessInstanceId(),5);
+			 *//*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);
@@ -388,11 +576,36 @@ public class WorkReimbursementAllController extends BaseController {
 			}*/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)){
+			String flag = workReimbursement.getAct().getFlag();
+			if ("yes".equals(flag) &&(users==null || users.size()==0)){
 				addMessage(redirectAttributes, "审批失败,审批人为空,请联系管理员!");
 			}else {
-				String str = workReimbursementService.auditSave(workReimbursement,users);
+				String str = "";
+
+
+				if(StringUtils.isNotBlank(workReimbursement.getId()) && result > 0 && "10de4a17d3484ba58135364bd53b88de".equals(workReimbursement.getOfficeId())){
+					str = workReimbursementNewService.auditSpecificSave(workReimbursement,users);
+				}else{
+					if(result > 0 && "10de4a17d3484ba58135364bd53b88de".equals(workReimbursement.getOfficeId())){
+						str = workReimbursementNewService.auditSpecificSave(workReimbursement,users);
+					} else {
+						if("0".equals(workReimbursement.getReimbursementType())){
+							if(reimburseResult>0){
+								str = workReimbursementNewService.auditSaveThree(workReimbursement,users);
+							}else{
+								str = workReimbursementNewService.auditSave(workReimbursement,users);
+							}
+						}else if ("1".equals(workReimbursement.getReimbursementType())){
+							if(reimburseResult>0){
+								str = workReimbursementNewService.electronicInvoiceReimbursementThreeAuditSave(workReimbursement,users);
+							}else{
+								str = workReimbursementNewService.electronicInvoiceReimbursementAuditSave(workReimbursement,users);
+							}
+						}
+					}
+				}
+
+
 				addMessage(redirectAttributes, str);
 			}
 		}catch (Exception e){
@@ -401,8 +614,10 @@ public class WorkReimbursementAllController extends BaseController {
 		}
 		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/workReimbursementAll/?repage";
+			return "redirect:" + adminPath +"/workreimbursement/workReimbursementAll/?repage";
 		}
 	}
 

+ 28 - 5
src/main/java/com/jeeplus/modules/workreimbursement/web/WorkReimbursementController.java

@@ -472,11 +472,23 @@ public class WorkReimbursementController extends BaseController {
 			workReimbursement.setCreateOffice(UserUtils.getSelectOffice().getId());
 			String str = "报销类型未选择";
 
-			LocalDate localDate = LocalDate.of(2024, 1, 20);
+			LocalDate reimburseLocalDate = LocalDate.of(2024, 2, 21);
 
-			Date auditDate = Date.from(localDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
+			Date reimburseAuditDate = Date.from(reimburseLocalDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
 
 			Date nowDate = new Date();
+
+			// 调用compareTo()方法进行比较
+			int reimburseResult = -1;
+			if(StringUtils.isNotBlank(workReimbursement.getId())){
+				reimburseResult = workReimbursement.getCreateDate().compareTo(reimburseAuditDate);
+			}else{
+				reimburseResult = nowDate.compareTo(reimburseAuditDate);
+			}
+
+			LocalDate localDate = LocalDate.of(2024, 1, 20);
+
+			Date auditDate = Date.from(localDate.atStartOfDay().atZone(ZoneId.systemDefault()).toInstant());
 			// 调用compareTo()方法进行比较
 			int result = nowDate.compareTo(auditDate);
 			//判定当前数据已经在数据库存在并且发起时间是在特定日期之后,并且部门是工程四部
@@ -489,9 +501,17 @@ public class WorkReimbursementController extends BaseController {
 					str = workReimbursementNewService.specificInvoiceReimbursementSave(workReimbursement, variables,processInstanceId);
 				} else {
 					if("0".equals(workReimbursement.getReimbursementType())){
-						str = workReimbursementService.save(workReimbursement, variables,processInstanceId);
+						if(reimburseResult>0){
+							str = workReimbursementNewService.saveReimburseThree(workReimbursement, variables,processInstanceId);
+						}else{
+							str = workReimbursementNewService.save(workReimbursement, variables,processInstanceId);
+						}
 					}else if("1".equals(workReimbursement.getReimbursementType())){
-						str = workReimbursementNewService.electronicInvoiceReimbursementSave(workReimbursement, variables,processInstanceId);
+						if(reimburseResult>0){
+							str = workReimbursementNewService.electronicInvoiceReimbursementThreeSave(workReimbursement, variables,processInstanceId);
+						}else{
+							str = workReimbursementNewService.electronicInvoiceReimbursementSave(workReimbursement, variables,processInstanceId);
+						}
 					}
 				}
 			}
@@ -1144,12 +1164,14 @@ public class WorkReimbursementController extends BaseController {
 				if(null != invoiceNumber){
 					map.put("flag",true);
 					map.put("message","发票号:" + map.get("InvoiceNumber").toString() + " 已发起或完成报销,请勿重复报销");
+					return map;
 				}else{
 					map.put("flag",false);
 				}
 			}else{
 				map.put("flag",true);
 				map.put("message","上传的数电发票格式错误,请确认后重新上传");
+				return map;
 
 			}
 
@@ -1159,13 +1181,14 @@ public class WorkReimbursementController extends BaseController {
 			}else{
 				map.put("flag",true);
 				map.put("message","上传的数电发票购买方不是“江苏兴光项目管理有限公司”,无法进行报销");
-
+				return map;
 			}
 
 		} catch (Exception e) {
 			e.printStackTrace();
 			map.put("flag",true);
 			map.put("message","上传的数电发票格式错误,请确认后重新上传");
+			return map;
 		} finally {
 			//删除本地文件
 			if (!file.isDirectory()) {

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

@@ -390,6 +390,9 @@ public class WorkReimbursementNewController extends BaseController {
 		}else if (StringUtils.isNotBlank(workReimbursement.getHome()) && "notifyList".equals(workReimbursement.getHome())){
 			return "redirect:" + Global.getAdminPath() + "/workprojectnotify/workProjectNotify/list/?repage";
 		} else {
+			if(StringUtils.isNotBlank(workReimbursement.getPageFlag()) && "all".equals(workReimbursement.getPageFlag())){
+				return "redirect:"+Global.getAdminPath()+"/workreimbursement/workReimbursementAll/?repage";
+			}
 			return "redirect:" + Global.getAdminPath() + "/workreimbursement/workReimbursement/?repage";
 		}
 	}

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 1680 - 0
src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllFormAdd.jsp


+ 908 - 0
src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllFormDetail.jsp

@@ -0,0 +1,908 @@
+<%@ 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;
+        $(document).ready(function() {
+
+            var reimbursementTypeRadio = '${workReimbursement.reimbursementType}';//后端获取值
+            if(undefined == reimbursementTypeRadio || null == reimbursementTypeRadio || '' == reimbursementTypeRadio || reimbursementTypeRadio == "0"){
+                $(".count2").hide();
+                $(".count1").show();
+            }else{
+                $(".count1").hide();
+                $(".count2").show();
+            }
+
+            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");
+            }
+            var state=${isShow};
+            if (state =='0'){
+                $(".isShow").hide();
+            }else {
+                $(".isShow").show();
+            }
+            if($("#backmoney").val()==null||$("#backmoney").val()==''){
+                $("#backmoney").val('0');
+            }
+            validateForm = $("#inputForm").validate({
+                submitHandler: function(form){
+                    loading('正在提交,请稍等...');
+                    form.submit();
+                },
+                rules:{
+                    number:{
+                        required:true
+                    },
+                },
+                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);
+                    }
+                }
+            });
+            $("#attachment_btn").click(function () {
+                $("#attachment_file").click();
+            });
+
+            var invoiceVATTaxes = $("#reimbursementElectronicInvoiceVATTaxes tr").length;
+            var reimbursementElectronicInvoiceVATTaxesMoneys = "";
+            var reimbursementElectronicInvoiceVATTaxesTaxAmount = "";
+            var reimbursementElectronicInvoiceVATTaxesSumMoney = "";
+            for(var i = 0;i < invoiceVATTaxes;i++){
+                var moneys = $("#reimbursementElectronicInvoiceVATTaxes tr").eq(i).find("td").eq(5).find("input").eq(0).val();
+                var taxAmount = $("#reimbursementElectronicInvoiceVATTaxes tr").eq(i).find("td").eq(6).find("input").eq(0).val();
+                var rsumMoney = $("#reimbursementElectronicInvoiceVATTaxes tr").eq(i).find("td").eq(7).find("input").eq(0).val();
+
+                if (moneys!=undefined && !isNaN(moneys)){
+                    if(reimbursementElectronicInvoiceVATTaxesMoneys==""){
+                        reimbursementElectronicInvoiceVATTaxesMoneys = parseFloat(moneys).toFixed(2);
+                    }else {
+                        reimbursementElectronicInvoiceVATTaxesMoneys = (parseFloat(reimbursementElectronicInvoiceVATTaxesMoneys) + parseFloat(moneys)).toFixed(2);
+                    }
+                }
+                if (taxAmount!=undefined && !isNaN(taxAmount)){
+                    if(reimbursementElectronicInvoiceVATTaxesTaxAmount==""){
+                        reimbursementElectronicInvoiceVATTaxesTaxAmount = parseFloat(taxAmount).toFixed(2);
+                    }else {
+                        reimbursementElectronicInvoiceVATTaxesTaxAmount = (parseFloat(reimbursementElectronicInvoiceVATTaxesTaxAmount) + parseFloat(taxAmount)).toFixed(2);
+                    }
+                }
+                if (rsumMoney!=undefined && !isNaN(rsumMoney)){
+                    if(reimbursementElectronicInvoiceVATTaxesSumMoney==""){
+                        reimbursementElectronicInvoiceVATTaxesSumMoney = parseFloat(rsumMoney).toFixed(2);
+                    }else {
+                        reimbursementElectronicInvoiceVATTaxesSumMoney = (parseFloat(reimbursementElectronicInvoiceVATTaxesSumMoney) + parseFloat(rsumMoney)).toFixed(2);
+                    }
+                }
+            }
+            $("#reimbursementElectronicInvoiceVATTaxesMoneys").val(reimbursementElectronicInvoiceVATTaxesMoneys);
+            $("#reimbursementElectronicInvoiceVATTaxesTaxAmount").val(reimbursementElectronicInvoiceVATTaxesTaxAmount);
+            $("#reimbursementElectronicInvoiceVATTaxesSumMoney").val(reimbursementElectronicInvoiceVATTaxesSumMoney);
+
+
+
+        });
+
+    </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" action="${ctx}/workreimbursement/workReimbursement/save" method="post" class="form-horizontal" >
+<form:hidden path="ext"/>
+<%--<sys:message content="${message}"/>--%>
+    <div class="form-group layui-row first ">
+        <div class="form-group-label">
+            <div style="float: right">
+                <c:if test="${not empty historyShow}">
+                        <a href="javascript:void(0)" style='background-color: #FFB800' onclick="openDialogView('历史调整信息', '${ctx}/workReimbursementNew/workReimbursementNew/historyReimbursementInfo?id=${workReimbursement.id}','1100px', '35%','','关闭')" class="layui-btn layui-btn-sm" >历史调整信息</a>
+                </c:if>
+            </div>
+            <h2>基础信息</h2>
+        </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 htmlEscape="false" style="background-color: #f1f1f1"  readonly="true" class="form-control layui-input" value = "${workReimbursement.reimbursementTypeStr}"/>
+            </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" style="background-color: #f1f1f1"  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"><span class="require-item">*</span>报销人:</label>
+            <div class="layui-input-block">
+                <form:input path="submitterName" readonly="true" cssStyle="background-color: #f1f1f1" 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">
+                <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" cssStyle="background-color: #f1f1f1" readonly="true" 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">
+                        <c:if test="${not empty workAccount.workAccountAuditList}">
+                            <c:forEach items="${workAccount.workAccountAuditList}" var="workAccountAudit" varStatus="index">
+                                <c:if test="${index.index==0}">
+                                    <tr>
+                                        <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:if>
+                                <c:if test="${index.index!=0}">
+                                    <tr>
+                                        <td class="hide">
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+                                        <td>
+                                        </td>
+
+                                    </tr>
+                                </c:if>
+
+                            </c:forEach>
+                        </c:if>
+                        <c:if test="${empty workAccount.workAccountAuditList}">
+                            <tr>
+                                <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:if>
+
+                    </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 count1">
+        <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 count2">
+        <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="200px"><font color="red">*</font>发票类型</th>
+                    <th width="200px"><font color="red">*</font>发票项目名</th>
+                    <th width="200px"><font color="red">*</font>发票号</th>
+                    <th width="200px"><font color="red">*</font>开票日期</th>
+                    <th width="200px"><font color="red">*</font>开票单位</th>
+                    <th width="200px"><font color="red">*</font>金额</th>
+                    <th width="200px"><font color="red">*</font>税额</th>
+                    <th width="200px"><font color="red">*</font>价税合计</th>
+                    <th width="200px">备注</th>
+                </tr>
+                </thead>
+                <tbody id="reimbursementElectronicInvoiceVATTaxes">
+                <c:if test="${not empty workReimbursement.reimbursementElectronicInvoiceVATTaxes}">
+                    <c:forEach items="${workReimbursement.reimbursementElectronicInvoiceVATTaxes}" var="reimbursementElectronicInvoiceVATTaxes" varStatus="index">
+                        <tr id="reimbursementElectronicInvoiceVATTaxes${index.index}">
+                                <%--发票类型--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_invoiceType" onmouseover="this.title=this.value" readOnly="true" maxlength="30" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].invoiceType" type="text" value="${reimbursementElectronicInvoiceVATTaxes.invoiceTypeStr}" onmouseover="this.title=this.value"  class="form-control "/>
+                            </td>
+                                <%--发票项目名--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_invoiceProjectName" onmouseover="this.title=this.value" readOnly="true" maxlength="500" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].invoiceProjectName" type="text" value="${reimbursementElectronicInvoiceVATTaxes.invoiceProjectName}" placeholder="请输入发票项目名"  class="form-control "/>
+                            </td>
+                                <%--发票号--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_invoiceNumber" onmouseover="this.title=this.value" readOnly="true" maxlength="30" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].invoiceNumber" type="text" value="${reimbursementElectronicInvoiceVATTaxes.invoiceNumber}" onmouseover="this.title=this.value" placeholder="请输入发票号"  class="form-control "/>
+                            </td>
+                                <%--开票日期--%>
+                            <td>
+                                <input lay-verify="date" placeholder="yyyy-MM-dd HH:mm:ss" readonly autocomplete="off" onmouseover="this.title=this.value" readOnly="true" id="reimbursementElectronicInvoiceVATTaxes${index.index}_invoiceDate" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].invoiceDate" type="text" value="${reimbursementElectronicInvoiceVATTaxes.invoiceDateStr}"  onmouseover="this.title=this.value" class="form-control datetime"/>
+                            </td>
+                                <%--开票单位--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_invoiceUnit" onmouseover="this.title=this.value" readOnly="true" maxlength="30" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].invoiceUnit" type="text" value="${reimbursementElectronicInvoiceVATTaxes.invoiceUnit}"  placeholder="请输入开票单位"  onmouseover="this.title=this.value" class="form-control "/>
+                            </td>
+                                <%--金额--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_money" onmouseover="this.title=this.value" readOnly="true" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].money" type="text" maxlength="32" value="${reimbursementElectronicInvoiceVATTaxes.money}"  placeholder="请输入金额"  onmouseover="this.title=this.value" class="form-control "/>
+                            </td>
+                                <%--税额--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_taxAmount" onmouseover="this.title=this.value" readOnly="true" name="reimbursementElectronicInvoiceVATTaxes[${index.index}].taxAmount" type="text" maxlength="32" value="${reimbursementElectronicInvoiceVATTaxes.taxAmount}"  placeholder="请输入税额"  onmouseover="this.title=this.value" class="form-control "/>
+                            </td>
+                                <%--合计价税--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_sumMoney" onmouseover="this.title=this.value" readOnly="true"  name="reimbursementElectronicInvoiceVATTaxes[${index.index}].sumMoney" type="text" maxlength="32" value="${reimbursementElectronicInvoiceVATTaxes.sumMoney}"  onmouseover="this.title=this.value" class="form-control"/>
+                            </td>
+                                <%--备注--%>
+                            <td>
+                                <input id="reimbursementElectronicInvoiceVATTaxes${index.index}_remarks" onmouseover="this.title=this.value" readOnly="true"  name="reimbursementElectronicInvoiceVATTaxes[${index.index}].remarks" type="text" maxlength="255" value="${reimbursementElectronicInvoiceVATTaxes.remarks}"    class="form-control input"/>
+                            </td>
+                        </tr>
+                    </c:forEach>
+                </c:if>
+                </tbody>
+            </table>
+            <table id="contentTable4" class="table table-bordered table-condensed can-edit no-bottom-margin">
+                <thead>
+                <tr >
+                    <td width="200px" style="vertical-align:middle;text-align: center;"><label>费用汇总(元):</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="reimbursementElectronicInvoiceVATTaxesMoneys" name="reimbursementElectronicInvoiceVATTaxesMoneys" readonly="true" class="form-control layui-input" value=""/>
+                    </td>
+                    <td width="200px">
+                        <input htmlEscape="false" style="border: 0px; font-weight: bold;" id="reimbursementElectronicInvoiceVATTaxesTaxAmount" name="reimbursementElectronicInvoiceVATTaxesTaxAmount" readonly="true" class="form-control layui-input" value=""/>
+                    </td>
+                    <td width="200px">
+                        <input htmlEscape="false" style="border: 0px; font-weight: bold;" id="reimbursementElectronicInvoiceVATTaxesSumMoney" name="reimbursementElectronicInvoiceVATTaxesSumMoney" readonly="true" class="form-control layui-input" value=""/>
+                    </td>
+                    <td width="200px"></td>
+                </tr>
+                </thead>
+            </table>
+        </div>
+    </div>
+
+    <div class="form-group layui-row count2">
+        <input id="attachment_InvoiceReimbursement_file" type="file" multiple="multiple" style="display: none;" onChange="if(this.value)insertTitleInvoiceReimbursement(this.value);"/>
+        <span id="attachment_title"></span>
+        <div class="layui-item layui-col-xs12" style="padding:0 16px;">
+            <table id="listAttachment" 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_InvoiceReimbursement">
+                <c:forEach items="${workReimbursement.workAttachmentInvoiceReimbursements}" 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="${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 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>
+                                            </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>
+                                                <c:choose>
+                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'xml')}">
+                                                        <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: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: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">
+        <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 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>
+                                                <c:choose>
+                                                    <c:when test="${fn:containsIgnoreCase(workClientAttachment.attachmentName,'xml')}">
+                                                        <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: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: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>${projectNotifyType}审批流程</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 class="form-group layui-row page-end"></div>
+</form:form>
+    </div>
+</div>
+</body>
+</html>

Rozdílová data souboru nebyla zobrazena, protože soubor je příliš velký
+ 1954 - 0
src/main/webapp/webpage/modules/workreimbursement/all/workReimbursementAllModifyApply.jsp


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

@@ -134,6 +134,7 @@
 		<form:hidden id="flag" path="act.flag"/>
 		<input type="hidden" id="opinion" name="act.comment" value="" maxlength="255">
 		<input type="hidden" id="reimbursementType" name="reimbursementType" value="${workReimbursement.reimbursementType}"/>
+		<input type="hidden" id="pageFlag" name="pageFlag" value="${pageFlag}"/>
 		<div class="form-group layui-row first ">
 			<div class="form-group-label"><h2>基础信息</h2></div>
 

+ 68 - 4
src/main/webapp/webpage/modules/workreimbursement/workReimbursementAllList.jsp

@@ -267,18 +267,26 @@
                 ,{align:'center',title:"操作",width:130,templet:function(d){
                         ////对操作进行初始化
                         var xml = "<div class=\"layui-btn-group\">";
+                        if(d.notifyFlag != undefined && d.notifyFlag !=null && "" != d.notifyFlag && d.notifyFlag == 1)
+                        {
+                            xml+="<a href=\"#\" onclick=\"notifyDialogre('报销审批', '${ctx}/workprojectnotify/workProjectNotify/form?id=" + d.notifyId +"&home=reimbursement&pageFlag=all','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&pageFlag=all','95%', '95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\" > 审批</a>";
+                        }
                         if(d.cancancel != undefined && d.cancancel == "1")
                             xml += "<a href=\"${ctx}/workreimbursement/workReimbursementAll/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}/workReimbursementNew/workReimbursementNew/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}/workreimbursement/workReimbursementAll/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}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "&tabId=3','"+ d.id +"','95%','95%')\" class=\"layui-btn layui-btn-xs layui-bg-green\">修改</a>";
+                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreModify('修改报销单', '${ctx}/workreimbursement/workReimbursementAll/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}/workReimbursementNew/workReimbursementNew/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}/workreimbursement/workReimbursementAll/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/workReimbursementAll/delete?id=" + d.id + "\" onclick=\"return confirmx('确认要删除该报销单吗?', this.href)\"   class=\"layui-btn layui-btn-xs layui-bg-red\">删除</a>";
                         if(<%=admin%> && d.status == "5"){
-                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreAdminModify('管理员修改报销单', '${ctx}/workReimbursementNew/workReimbursementNew/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
+                            xml +="<a href=\"javascript:void(0)\" onclick=\"openDialogreAdminModify('管理员修改报销单', '${ctx}/workreimbursement/workReimbursementAll/form?id="+ d.id + "','95%','95%')\" class=\"layui-btn layui-btn-xs  layui-bg-green\" > 修改</a>";
                         }
                         xml+="</div>"
                         return xml;
@@ -293,6 +301,8 @@
                     ,"id":"${workReimbursement.id}"
                     ,"submitterId":"${index.index+1}"
                     ,"realnumber":"${workReimbursement.number}"
+                    ,"notifyFlag":"${workReimbursement.notifyFlag}"
+                    ,"notifyId":"${workReimbursement.notifyId}"
                     ,"number":"${workReimbursement.number}"
                     ,"taskName":"${workReimbursement.taskName}"
                     ,"reimbursementType":"${workReimbursement.reimbursementType}"
@@ -614,6 +624,60 @@
 
     }
 
+
+    function notifyDialogre(title,url,width,height,target){
+        if(navigator.userAgent.match(/(iPhone|iPod|Android|ios)/i)){//如果是移动端,就使用自适应大小弹窗
+            width='auto';
+            height='auto';
+        }else{//如果是PC端,根据用户设置的width和height显示。
+
+        }
+        top.layer.open({
+            type: 2,
+            area: [width, height],
+            title: title,
+            skin:"three-btns",
+            maxmin: true, //开启最大化最小化按钮
+            content: url ,
+            btn: ['通过','驳回','关闭'],
+            btn1: function(index, layero){
+                var body = top.layer.getChildFrame('body', index);
+                var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+                var inputForm = body.find('#inputForm');
+                var top_iframe;
+                if(target){
+                    top_iframe = target;//如果指定了iframe,则在改frame中跳转
+                }else{
+                    top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+                }
+                inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+                if(iframeWin.contentWindow.doSubmit(1) ){
+                    top.layer.close(index);//关闭对话框。
+                    setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+                }
+            },
+            btn2:function(index,layero){
+                var body = top.layer.getChildFrame('body', index);
+                var iframeWin = layero.find('iframe')[0]; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+                var inputForm = body.find('#inputForm');
+                var top_iframe;
+                if(target){
+                    top_iframe = target;//如果指定了iframe,则在改frame中跳转
+                }else{
+                    top_iframe = top.getActiveTab().attr("name");//获取当前active的tab的iframe
+                }
+                inputForm.attr("target",top_iframe);//表单提交成功后,从服务器返回的url在当前tab中展示
+                if(iframeWin.contentWindow.doSubmit(2) ){
+                    top.layer.close(index);//关闭对话框。
+                    setTimeout(function(){top.layer.close(index)}, 100);//延时0.1秒,对应360 7.1版本bug
+                }
+                return false;
+            },
+            btn3: function(index){
+            }
+        });
+
+    }
 </script>
 </body>
 </html>