清单初步
parent
776b09f886
commit
4385896bcd
|
@ -9,7 +9,7 @@
|
|||
<form class="form-horizontal m" id="form-delivery-add">
|
||||
<div class="col-xs-6">
|
||||
<div class="form-group">
|
||||
<label class="col-sm-4 control-label is-required">关联合同id:</label>
|
||||
<label class="col-sm-4 control-label is-required">关联合同:</label>
|
||||
<div class="col-sm-8">
|
||||
<select name="orderId" class="form-control" required>
|
||||
|
||||
|
|
|
@ -97,6 +97,14 @@
|
|||
field: 'orderId',
|
||||
title: '关联合同id'
|
||||
},
|
||||
{
|
||||
field: 'orderCode',
|
||||
title: '关联合同编号'
|
||||
},
|
||||
{
|
||||
field: 'orderName',
|
||||
title: '关联合同名称'
|
||||
},
|
||||
{
|
||||
field: 'deliveryCode',
|
||||
title: '发货单号'
|
||||
|
|
|
@ -1,51 +1,96 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||
<head>
|
||||
<th:block th:include="include :: header('发货清单列表')" />
|
||||
</head>
|
||||
<body>
|
||||
<body class="gray-bg">
|
||||
<div class="col-sm-12 select-table table-striped" th:deliveryId="${deliveryId}">
|
||||
<input id="uploadInput" type="hidden">
|
||||
<div class="btn-group-sm" id="toolbar" role="group">
|
||||
<a class="btn btn-success" onclick="downloadTem()" shiro:hasPermission="manage:delivery:add">
|
||||
<i class="fa fa-download"></i> 下载模板
|
||||
</a>
|
||||
<a class="btn btn-primary" shiro:hasPermission="manage:delivery:edit" id="upload">
|
||||
<i class="fa fa-upload"></i> 导入清单
|
||||
</a>
|
||||
|
||||
</div>
|
||||
<table id="bootstrap-table"></table>
|
||||
</div>
|
||||
<th:block th:include="include :: footer" />
|
||||
|
||||
|
||||
<script>
|
||||
var prefix=ctx+'sip/list'
|
||||
$(function() {
|
||||
var options = {
|
||||
url: prefix + "/list",
|
||||
showSearch:false,
|
||||
showColumns:false,
|
||||
showToggle:false,
|
||||
showPageGo:true,
|
||||
params:{
|
||||
deliveryId:''
|
||||
},
|
||||
columns: [{
|
||||
checkbox: true
|
||||
checkbox: false,
|
||||
},
|
||||
{
|
||||
field: 'id',
|
||||
title: '主键,自增',
|
||||
visible: false
|
||||
},
|
||||
{
|
||||
field: 'orderCode',
|
||||
title: '合同编号'
|
||||
},
|
||||
{
|
||||
field: 'productCode',
|
||||
title: '产品编码'
|
||||
},
|
||||
{
|
||||
field: 'orderId',
|
||||
title: '关联合同id'
|
||||
},
|
||||
{
|
||||
field: 'deliveryCode',
|
||||
title: '发货单号'
|
||||
},
|
||||
{
|
||||
field: 'deliveryDate',
|
||||
title: '发货日期'
|
||||
},
|
||||
{
|
||||
field: 'deliveryType',
|
||||
title: '发货方式',
|
||||
formatter: function(value, row, index) {
|
||||
return $.table.selectDictLabel(deliveryTypeDatas, value);
|
||||
}
|
||||
},
|
||||
{
|
||||
field: 'deliveryStatus',
|
||||
title: '发货状态',
|
||||
formatter: function(value, row, index) {
|
||||
return $.table.selectDictLabel(deliveryStatusDatas, value);
|
||||
}
|
||||
field: 'serialNumber',
|
||||
title: '产品序列号'
|
||||
},
|
||||
{
|
||||
field: 'remark',
|
||||
title: '备注'
|
||||
},
|
||||
]
|
||||
};
|
||||
$.table.init(options);
|
||||
});
|
||||
function downloadTem(){
|
||||
$.modal.loading("正在下载,请稍候...");
|
||||
$.post( prefix + "/export", {deliveryId:-1,productCode:'',serialNumber:''}, function(result) {
|
||||
if (result.code == web_status.SUCCESS) {
|
||||
window.location.href = ctx + "common/download?fileName=" + encodeURI(result.msg) + "&delete=" + true;
|
||||
} else if (result.code == web_status.WARNING) {
|
||||
$.modal.alertWarning(result.msg)
|
||||
} else {
|
||||
$.modal.alertError(result.msg);
|
||||
}
|
||||
$.modal.closeLoading();
|
||||
})
|
||||
|
||||
}
|
||||
function importList(){
|
||||
|
||||
}
|
||||
// layui.use('upload',function(){
|
||||
// var upload = layui.upload;
|
||||
// // 渲染
|
||||
// upload.render({
|
||||
// elem: '#uploadInput',
|
||||
// url:prefix+'/importData', // 此处配置你自己的上传接口即可
|
||||
// auto: true,
|
||||
// // multiple: true,',
|
||||
// done: function(res){
|
||||
// layer.msg('上传成功');
|
||||
// console.log(res)
|
||||
// }
|
||||
// });
|
||||
// });
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
Loading…
Reference in New Issue