221 lines
10 KiB
Plaintext
221 lines
10 KiB
Plaintext
<%@page import="com.sipai.entity.sparepart.SparePartCommString"%>
|
||
<%@ page language="java" pageEncoding="UTF-8"%>
|
||
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c"%>
|
||
<%request.setAttribute("DEPARTMENT", SparePartCommString.PURCHASE_DEPARTMENT); %>
|
||
<%-- <%request.setAttribute("PASS", SparePartCommString.STATUS_PASS); %>
|
||
<%request.setAttribute("REJECT", SparePartCommString.STATUS_REJECT); %>
|
||
<%request.setAttribute("SUBMIT", SparePartCommString.STATUS_SUBMIT); %> --%>
|
||
<style type="text/css">
|
||
.select2-container .select2-selection--single{
|
||
height:34px;
|
||
line-height: 34px;
|
||
}
|
||
.select2-selection__arrow{
|
||
margin-top:3px;
|
||
}
|
||
</style>
|
||
<script type="text/javascript">
|
||
//流程审核文件上传所需参数
|
||
var masterId_process = '${subscribe.id}';//业务Id
|
||
var tbName_process = 'TB_Process_UploadFile'; //数据表
|
||
var nameSpace_process ='ProcessUploadFile';//保存文件夹
|
||
var status = 'view';//有删除权限
|
||
|
||
$(function(){
|
||
//初始化文件显示
|
||
getFileList_process();
|
||
$('#table_SubscribeDetail').bootstrapTable({ // 对应table标签的id
|
||
url: ext.contextPath + '/sparepart/subscribe/getSubscribeDetailList.do', // 获取表格数据的url
|
||
cache: false, // 设置为 false 禁用 AJAX 数据缓存, 默认为true
|
||
striped: true, //表格显示条纹,默认为false
|
||
pagination: true, // 在表格底部显示分页组件,默认false
|
||
pageList: [10, 20,50], // 设置页面可以显示的数据条数
|
||
pageSize: 5, // 页面数据条数
|
||
pageNumber: 1, // 首页页码
|
||
sidePagination: 'server', // 设置为服务器端分页
|
||
queryParams: function (params) { // 请求服务器数据时发送的参数,可以在这里添加额外的查询参数,返回false则终止请求
|
||
return {
|
||
rows: params.limit, // 每页要显示的数据条数
|
||
page: params.offset/params.limit+1, // 每页显示数据的开始页码
|
||
sort: params.sort, // 要排序的字段
|
||
order: params.order,
|
||
pid:'${subscribe.id}',
|
||
}
|
||
},
|
||
sortName: 'id', // 要排序的字段
|
||
sortOrder: 'desc', // 排序规则
|
||
columns: [
|
||
/* {
|
||
checkbox: true, // 显示一个勾选框
|
||
}, */{
|
||
field: 'detailGoodsName', // 返回json数据中的name
|
||
title: '物品名称', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},{
|
||
field: 'detailGoodsModel', // 返回json数据中的name
|
||
title: '规格型号', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},{
|
||
field: 'goods.unit', // 返回json数据中的name
|
||
title: '单位', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle' // 上下居中
|
||
},{
|
||
field: 'brand', // 返回json数据中的name
|
||
title: '品牌', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle' // 上下居中
|
||
},{
|
||
field: 'manufacturer', // 返回json数据中的name
|
||
title: '生产厂家', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},{
|
||
field: 'number', // 返回json数据中的name
|
||
title: '数量', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},{
|
||
field: 'price', // 返回json数据中的name
|
||
title: '单价/元', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},{
|
||
field: 'totalMoney', // 返回json数据中的name
|
||
title: '合计/元', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle' // 上下居中
|
||
},{
|
||
field: 'planArrivalTime', // 返回json数据中的name
|
||
title: '计划到货时间', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中,
|
||
},{
|
||
field: 'planArrivalPlace', // 返回json数据中的name
|
||
title: '计划到货地点', // 表格表头显示文字
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},{
|
||
field: 'purpose', // 返回json数据中的name
|
||
title: '用途', // 表格表头显示文字
|
||
width: '20%',
|
||
align: 'center', // 左右居中
|
||
valign: 'middle', // 上下居中
|
||
},
|
||
],
|
||
onLoadSuccess: function(){ //加载成功时执行
|
||
adjustBootstrapTableView("table_SubscribeDetail");
|
||
},
|
||
onLoadError: function(){ //加载失败时执行
|
||
console.info("加载数据失败");
|
||
}
|
||
|
||
});
|
||
|
||
//显示流程详情
|
||
var id = '${subscribe.id}';
|
||
$.post(ext.contextPath + '/sparepart/subscribe/showSubscribeView.do', {id:id,inModal:'inModal'} , function(data) {
|
||
$("#showView").html(data);
|
||
});
|
||
})
|
||
|
||
|
||
</script>
|
||
<div class="modal fade" id="subModal">
|
||
<div class="modal-dialog modal-xlg">
|
||
<div class="modal-content">
|
||
<div class="modal-header">
|
||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||
<span aria-hidden="true">×</span></button>
|
||
<h4 class="modal-title">申购单</h4>
|
||
</div>
|
||
<div class="modal-body">
|
||
<div class="row">
|
||
<div class="col-md-7 col-xs-12">
|
||
<!-- 新增界面formid强制为subForm -->
|
||
<form class="form-horizontal" id="subForm" enctype="multipart/form-data" >
|
||
<!-- 界面提醒div强制id为alertDiv -->
|
||
<div id="alertDiv"></div>
|
||
<div class="form-group">
|
||
<label class="col-sm-3 control-label">所属厂区:</label>
|
||
<div class="col-sm-3">
|
||
<p class="form-control-static" >${subscribe.company.name}</p>
|
||
</div>
|
||
<label class="col-sm-3 control-label">申购单号:</label>
|
||
<div class="col-sm-3">
|
||
<p class="form-control-static" >${subscribe.id}</p>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label class="col-sm-3 control-label">申购日期:</label>
|
||
<div class="col-sm-3">
|
||
<p class="form-control-static" >${subscribe.subscribeDate.substring(0,10)}</p>
|
||
</div>
|
||
<label class="col-sm-3 control-label">申购部门:</label>
|
||
<div class="col-sm-3" >
|
||
<p class="form-control-static" >
|
||
<c:choose>
|
||
<c:when test="${!empty subscribe.dept.name}">
|
||
${subscribe.dept.name}
|
||
</c:when>
|
||
<c:otherwise>
|
||
${subscribe.company.name}
|
||
</c:otherwise>
|
||
</c:choose></p>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label class="col-sm-3 control-label">申购人:</label>
|
||
<div class="col-sm-3" >
|
||
<p class="form-control-static" >${subscribe.subscribeManName}</p>
|
||
</div>
|
||
<label class="col-sm-3 control-label">审核人:</label>
|
||
<div class="col-sm-3" >
|
||
<p class="form-control-static" >${subscribe.subscribeAuditName}</p>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label class="col-sm-3 control-label">总金额:</label>
|
||
<div class="col-sm-3">
|
||
<p class="form-control-static" >
|
||
<c:if test="${not empty subscribe.totalMoney}">${subscribe.totalMoney}元</c:if>
|
||
</p>
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label class="col-sm-3 control-label">备注</label>
|
||
<div class="col-sm-9" style="margin-top:8px;text-align:center">
|
||
${subscribe.remark}
|
||
</div>
|
||
</div>
|
||
<div class="form-group">
|
||
<label class="col-sm-3 control-label">文件附件:</label>
|
||
</div>
|
||
<!-- 文件上传,显示 -->
|
||
<div class="file-border" id="fileArea">
|
||
</div>
|
||
</form>
|
||
<div class="box box-primary" >
|
||
<div class="box-header with-border">
|
||
<h3 class="box-title">申购明细</h3>
|
||
</div>
|
||
<div class="box-body ">
|
||
<table id="table_SubscribeDetail"></table>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="col-md-5 col-xs-12" id="showView">
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="modal-footer">
|
||
<button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
|
||
</div>
|
||
</div>
|
||
<!-- /.modal-content -->
|
||
</div>
|
||
<!-- /.modal-dialog -->
|
||
</div>
|