Prechádzať zdrojové kódy

报销申请(列表)

[user3] 4 rokov pred
rodič
commit
a5532b1ae6

+ 11 - 0
src/main/java/com/jeeplus/modules/workreimbursement/service/WorkReimbursementAllService.java

@@ -13,6 +13,8 @@ import com.jeeplus.modules.act.entity.Act;
 import com.jeeplus.modules.act.service.ActTaskService;
 import com.jeeplus.modules.act.utils.ActUtils;
 import com.jeeplus.modules.act.utils.ProcessDefCache;
+import com.jeeplus.modules.projectcontentinfo.entity.ProjectReportData;
+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;
@@ -121,6 +123,8 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
     @Autowired
     private WorkLoanDao workLoanDao;
     @Autowired
+    private ProjectReportDataService projectReportDataService;
+    @Autowired
     private HistoicFlowUtil histoicFlowUtil;
 
     private static byte[] SYN_BYTE = new byte[0];
@@ -212,6 +216,7 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
     public List<WorkReimbursement> findList(WorkReimbursement workReimbursement) {
         List<WorkReimbursement> list = super.findList(workReimbursement);
         List<WorkReimbursement> lists = new ArrayList<>();
+
         /*for (WorkReimbursement reimbursement:list){
             ProjectRecords records = reimbursement.getProject();
             if (records!=null && StringUtils.isNotBlank(records.getId())){
@@ -249,6 +254,12 @@ public class WorkReimbursementAllService extends CrudService<WorkReimbursementDa
                     project.setProjectName(workAccount.getReimburseRemarks());
                     info.setProject(project);
                 }
+                //查询项目报告信息
+                if (StringUtils.isNotBlank(info.getWorkAccount().getProject().getId())){
+                    ProjectReportData projectReportData = projectReportDataService.getReportDataByProjectId(info.getWorkAccount().getProject().getId());
+                    info.setProjectName(projectReportData.getNumber());
+                }
+                info.setBusinessTypeName(workAccount.getTypeName());
             }
             /*if(StringUtils.isNotBlank(info.getProcessInstanceId())){
                 String taskName = histoicFlowUtil.histoicFlow(info.getProcessInstanceId());

+ 0 - 2
src/main/java/com/jeeplus/modules/workreimbursement/service/WorkReimbursementService.java

@@ -270,8 +270,6 @@ public class WorkReimbursementService extends CrudService<WorkReimbursementDao,
                     project.setProjectName(workAccount.getReimburseRemarks());
                     info.setProject(project);
                 }
-//                //查询项目
-//                info.setProject(projectRecordsService.get(info.getWorkAccount().getProject().getId()));
                 //查询项目报告信息
                 if (StringUtils.isNotBlank(info.getWorkAccount().getProject().getId())){
                     ProjectReportData projectReportData = projectReportDataService.getReportDataByProjectId(info.getWorkAccount().getProject().getId());

+ 69 - 34
src/main/webapp/WEB-INF/tags/sys/reimburselectReproject.tag

@@ -23,42 +23,77 @@
 	var extid=$("#${id}extId").val();
 	var area=$("#${id}area").val();
 	if (extid!=null && extid != ''){
-		top.layer.open({
-			type: 2,
-			area: ['80%','80%'],
-			title:"${title}",
-			name:'friend',
-			skin:"two-btns",
-			content: encodeURI("${url}?userId="+userId+"&fieldLabels=${fieldLabels}&fieldKeys=${fieldKeys}&url=${url}&searchLabel=${searchLabel}&searchKey=${searchKey}&extid="+extid),
-			btn: ['确定', '关闭'],
-			yes: function(index, layero){
-				var iframeWin = layero.find('iframe')[0].contentWindow; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
-				var item = iframeWin.getSelectedItem();
-				console.log(item);
-				if(item == "-1"){
-					return;
+		if(extid == '1'){
+			top.layer.open({
+				type: 2,
+				area: ['80%','80%'],
+				title:"${title}",
+				name:'friend',
+				skin:"two-btns",
+				content: encodeURI("${url}?userId="+userId+"&fieldLabels=${fieldLabels}&fieldKeys=${fieldKeys}&url=${url}&searchLabel=${searchLabel}&searchKey=${searchKey}&extid="+extid),
+				btn: ['确定', '关闭'],
+				yes: function(index, layero){
+					var iframeWin = layero.find('iframe')[0].contentWindow; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var item = iframeWin.getSelectedItem();
+					console.log(item);
+					if(item == "-1"){
+						return;
+					}
+					var items = item.split('_item_');
+					console.log(items)
+					//判断是否选择报销项目
+					if(items[0] == 1){
+						$("#${id}Radio").val(items[0]);
+						$("#${id}Id").val(items[1]);
+						$("#${id}Name").val(items[2]);
+						$("#${id}ReportNumber").val(items[3]);
+					}else{
+						$("#${id}Radio").val(items[0]);
+						$("#${id}Name").val(items[1]);
+						$("#${id}ReportNumber").val("");
+					}
+					top.layer.close(index);//关闭对话框。
+					//setValue(item.split('_item_')[0]);
+				},
+				cancel: function(index){
 				}
-				var items = item.split('_item_');
-				console.log(items)
-				//判断是否选择报销项目
-				if(items[0] == 1){
-					$("#${id}Radio").val(items[0]);
-					$("#${id}Id").val(items[1]);
-					$("#${id}Name").val(items[2]);
-					$("#${id}ReportNumber").val(items[3]);
-				}else{
-					$("#${id}Radio").val(items[0]);
-					$("#${id}Name").val(items[1]);
-					$("#${id}ReportNumber").val("");
+			});
+		}else if (extid=="2"){
+			top.layer.open({
+				type: 2,
+				area: ['50%','50%'],
+				title:"${title}",
+				name:'friend',
+				skin:"two-btns",
+				content: encodeURI("${url}?userId="+userId+"&fieldLabels=${fieldLabels}&fieldKeys=${fieldKeys}&url=${url}&searchLabel=${searchLabel}&searchKey=${searchKey}&extid="+extid),
+				btn: ['确定', '关闭'],
+				yes: function(index, layero){
+					var iframeWin = layero.find('iframe')[0].contentWindow; //得到iframe页的窗口对象,执行iframe页的方法:iframeWin.method();
+					var item = iframeWin.getSelectedItem();
+					console.log(item);
+					if(item == "-1"){
+						return;
+					}
+					var items = item.split('_item_');
+					console.log(items)
+					//判断是否选择报销项目
+					if(items[0] == 1){
+						$("#${id}Radio").val(items[0]);
+						$("#${id}Id").val(items[1]);
+						$("#${id}Name").val(items[2]);
+						$("#${id}ReportNumber").val(items[3]);
+					}else{
+						$("#${id}Radio").val(items[0]);
+						$("#${id}Name").val(items[1]);
+						$("#${id}ReportNumber").val("");
+					}
+					top.layer.close(index);//关闭对话框。
+					//setValue(item.split('_item_')[0]);
+				},
+				cancel: function(index){
 				}
-				top.layer.close(index);//关闭对话框。
-				//setValue(item.split('_item_')[0]);
-			},
-			cancel: function(index){
-			}
-		});
-	// }else{
-	// 	top.layer.msg("请先选择报销类型", {icon: 0});
+			});
+		}
 	}
 
 };

+ 2 - 2
src/main/webapp/webpage/modules/sys/gridselectcallprojectOnReimbur.jsp

@@ -116,10 +116,10 @@
 						<div style="    clear:both;"></div>
 					</div>
 					<div id="td4" class="commonQuery">
-						<div class="layui-item layui-col-sm6">
+						<div class="layui-item layui-col-sm12 with-textarea">
 							<label class="layui-form-label"><span class="require-item">*</span>报销详情:</label>
 							<div class="layui-input-block">
-								<input type="text" id="reimburseRemarks" name="reimburseRemarks" value="" htmlEscape="false" class="form-control required layui-input" maxlength="255">
+								<textarea  id="reimburseRemarks" name="reimburseRemarks" style="width: 100%" rows="7" class="form-control required" maxlength="255"></textarea>
 							</div>
 						</div>
 					</div>

+ 25 - 0
src/main/webapp/webpage/modules/workreimbursement/workReimbursementAllList.jsp

@@ -116,6 +116,23 @@
                                                 title="部门" url="/sys/office/treeDataAll?type=2" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="true"/>
                             </div>
                         </div>
+                        <div class="layui-item query athird">
+                            <label class="layui-form-label">报销类别:</label>
+                            <div class="layui-input-block with-icon">
+                                <sys:treeselectAccessory id="type" name="businessType" value="${workReimbursement.businessTypeName}" labelName="businessTypeName" labelValue="${workReimbursement.businessTypeName}"
+                                                         cssStyle="background-color:#fff" title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control  layui-input" allowClear="true" notAllowSelectParent="true"/>
+
+                                    <%--                                <sys:treeselect id="officeId" name="officeId" value="${workReimbursement.officeId}" labelName="officeName" labelValue="${workReimbursement.officeName}"--%>
+                                    <%--                                                title="部门" url="/sys/office/treeDataAll?type=2" cssClass="form-control layui-input" allowClear="true" notAllowSelectParent="true"  cssStyle="background-color:#fff"/>--%>
+                            </div>
+                        </div>
+                        <div class="layui-item query athird">
+                            <label class="layui-form-label">报告号:</label>
+                            <div class="layui-input-block with-icon">
+                                <input id="projectName" placeholder="请输入报告号" name="projectName" type="text" maxlength="20" class="form-control layui-input" value="${workReimbursement.projectName}"/>
+                                </input>
+                            </div>
+                        </div>
                         <div style="clear:both;"></div>
                     </div>
                 </form:form>
@@ -159,6 +176,9 @@
                             "<span title=" + d.realnumber + ">" + d.number + "</span></a>";
                         return xml;
                     }}
+                ,{field:'businessTypeName',align:'center', title: '报销类别', width:100,templet:function(d){
+                        return "<span title='"+ d.businessTypeName +"'>" + d.businessTypeName + "</span>";
+                    }}
                 ,{field:'projectId', align:'center',title: '报销项目', minWidth:150,templet:function(d){
                         if(1 == d.showView && d.showView != undefined){
                             return "<a class=\"attention-info\" title=\"" + d.projectId + "\" href=\"javascript:void(0);\" onclick=\"openDialogView('查看项目', '${ctx}/ruralProject/ruralProjectView/view?id=" + d.proId +"','95%', '95%')\">" + d.projectId + "</a>";
@@ -167,6 +187,9 @@
                         }
                     // return "<span title='"+ d.projectId +"'>" + d.projectId + "</span>";
                     }}
+                ,{field:'projectNumber',align:'center', title: '报告号', width:100,templet:function(d){
+                        return "<span title='"+ d.projectNumber +"'>" + d.projectNumber + "</span>";
+                    }}
                 ,{field:'handleName',align:'center', title: '经办人', width:100,templet:function(d){
                         return "<span title='"+ d.handleName +"'>" + d.handleName + "</span>";
                     }}
@@ -268,6 +291,8 @@
                     <shiro:hasPermission name="ruralProject:ruralProjectView:reimbursementAllView">
                     ,"showView":1
                     </shiro:hasPermission>
+                    ,"businessTypeName":"${workReimbursement.businessTypeName}"
+                    ,"projectNumber":"${workReimbursement.projectName}"
                 }
                 </c:forEach>
                 </c:if>

+ 6 - 6
src/main/webapp/webpage/modules/workreimbursement/workReimbursementFormAdd.jsp

@@ -680,8 +680,8 @@
                         <%--<th width="60px">编号</th>--%>
                         <th width="200px"><font color="red">*</font>报销人</th>
                         <th width="200px">报销部门</th>
-                        <th width="200px">报销类型</th>
-                        <th width="200px">报销项目</th>
+                        <th width="200px"><font color="red">*</font>报销类型</th>
+                        <th width="200px"><font color="red">*</font>报销项目</th>
                         <th width="200px">报告号</th>
                         <th width="200px"><font color="red">*</font>费用(元)</th>
                         <th width="200px">收据张数</th>
@@ -717,14 +717,14 @@
                                 <td style="text-align:center;">
                                     <div class="project_reimbursement_div"  style="width: 200px">
                                         <sys:treeselectAccessoryNoParent id="workAccountList${index.index}_type" name="workAccountList[${index.index}].type" value="${workAccount.type}" labelName="workAccountList[${index.index}].typeName" labelValue="${workAccount.typeName}"
-                                                                         title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control  layui-input" allowClear="true" notAllowSelectParent="true"/>
+                                                                         title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control required  layui-input" allowClear="true" notAllowSelectParent="true"/>
                                     </div>
                                 </td>
 
                                 <td>
                                     <div class="not_project_reimbursement_div"  style="width: 200px">
                                         <sys:reimburselectReproject url="${ctx}/workreimbursement/workReimbursement/selectReproject" id="workAccountList${index.index}_project" name="workAccountList[${index.index}].project.id"  value="${workAccount.project.id}"  title="选择报销项目" labelName="workAccountList[${index.index}].project.projectName"
-                                                                    labelValue="${workAccount.project.projectName}" extId="${workAccount.projectRadio}" cssClass="form-control layui-input" fieldLabels="工程" fieldKeys="projectName" searchLabel="工程名称" searchKey="projectName" />
+                                                                    labelValue="${workAccount.project.projectName}" extId="${workAccount.projectRadio}" cssClass="form-control required layui-input" fieldLabels="工程" fieldKeys="projectName" searchLabel="工程名称" searchKey="projectName" />
                                     </div>
                                 </td>
                                 <td>
@@ -797,13 +797,13 @@
                         <td style="text-align:center;">
                             <div class="project_reimbursement_div"  style="width: 200px">
                                 <sys:treeselectAccessoryNoParent id="workAccountList{{idx}}_type" name="workAccountList[{{idx}}].type" value="${workReimbursement.workReimbursementTypeInfo.id}" labelName="workAccountList[{{idx}}].typeName" labelValue="${workReimbursement.workReimbursementTypeInfo.standardDetail}"
-                                     title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control  layui-input" allowClear="true" notAllowSelectParent="true"/>
+                                     title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control required layui-input" allowClear="true" notAllowSelectParent="true"/>
                             </div>
                         </td>
                         <td>
                             <div class="not_project_reimbursement_div"  style="width: 200px">
                                 <sys:reimburselectReproject url="${ctx}/workreimbursement/workReimbursement/selectReproject" id="workAccountList{{idx}}_project" name="workAccountList[{{idx}}].project.id"  value="${workReimbursement.project.id}"  title="选择报销项目" labelName="workAccountList[{{idx}}].project.projectName"
-                                       labelValue="{{row.projectName}}" extId="" area="" cssClass="form-control layui-input"  fieldLabels="工程" fieldKeys="projectName" searchLabel="工程名称" searchKey="projectName" ></sys:reimburselectReproject>
+                                       labelValue="{{row.projectName}}" extId="" area="" cssClass="form-control required layui-input"  fieldLabels="工程" fieldKeys="projectName" searchLabel="工程名称" searchKey="projectName" ></sys:reimburselectReproject>
                             </div>
                         </td>
                         <td>

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

@@ -784,8 +784,8 @@
                 <tr>
                     <th width="200px"><font color="red">*</font>报销人</th>
                     <th width="200px">报销部门</th>
-                    <th width="200px">报销类型</th>
-                    <th width="200px">报销项目</th>
+                    <th width="200px"><font color="red">*</font>报销类型</th>
+                    <th width="200px"><font color="red">*</font>报销项目</th>
                     <th width="200px">报告号</th>
                     <th width="200px"><font color="red">*</font>费用(元)</th>
                     <th width="200px">收据张数</th>
@@ -895,7 +895,7 @@
                         <td style="text-align:center;">
                             <div class="project_reimbursement_div"  style="width: 200px">
                                 <sys:treeselectAccessoryNoParent id="workAccountList{{idx}}_type" name="workAccountList[{{idx}}].type" value="${workReimbursement.workReimbursementTypeInfo.id}" labelName="workAccountList[{{idx}}].typeName" labelValue="${workReimbursement.workReimbursementTypeInfo.standardDetail}"
-                                     title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control  layui-input" allowClear="true" notAllowSelectParent="true"/>
+                                     title="报销类别" url="/reimbursementType/reimbursementType/treeData" extId=""  cssClass="form-control required layui-input" allowClear="true" notAllowSelectParent="true"/>
                             </div>
                         </td>
                         <td>