Compare commits
No commits in common. "ce54a3df8b6c9a47ac7e9bb59938d9d61b093179" and "57b8f6d237f5787437367ec2a1463c0e3a05c4b9" have entirely different histories.
ce54a3df8b
...
57b8f6d237
|
|
@ -144,8 +144,8 @@
|
||||||
<div class="col-xs-12">
|
<div class="col-xs-12">
|
||||||
<!-- <button type="button" class="btn btn-white btn-sm" onclick="addRow()"><i class="fa fa-plus"> 增加</i></button>-->
|
<!-- <button type="button" class="btn btn-white btn-sm" onclick="addRow()"><i class="fa fa-plus"> 增加</i></button>-->
|
||||||
<button type="button" class="btn btn-white btn-sm" onclick="sub.delRow()"><i class="fa fa-minus"> 删除</i></button>
|
<button type="button" class="btn btn-white btn-sm" onclick="sub.delRow()"><i class="fa fa-minus"> 删除</i></button>
|
||||||
<button type="button" class="btn btn-white btn-sm" onclick="downloadTem()"><i class="fa fa-download"> 下载模板</i></button>
|
<button type="button" class="btn btn-white btn-sm" onclick="importList()"><i class="fa fa-download"> 导入</i></button>
|
||||||
<button type="button" class="btn btn-white btn-sm" onclick="importList()"><i class="fa fa-upload"> 导入</i></button>
|
|
||||||
<div class="col-sm-12 select-table table-striped">
|
<div class="col-sm-12 select-table table-striped">
|
||||||
<table id="bootstrap-table"></table>
|
<table id="bootstrap-table"></table>
|
||||||
</div>
|
</div>
|
||||||
|
|
@ -338,27 +338,13 @@
|
||||||
function importList(){
|
function importList(){
|
||||||
$('#uploadInput').click()
|
$('#uploadInput').click()
|
||||||
}
|
}
|
||||||
function downloadTem(){
|
document.getElementById('uploadInput').addEventListener('change', function(event) {
|
||||||
$.modal.loading("正在下载,请稍候...");
|
|
||||||
$.post( prefix + "/list/export", {}, 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();
|
|
||||||
})
|
|
||||||
|
|
||||||
} document.getElementById('uploadInput').addEventListener('change', function(event) {
|
|
||||||
const file = event.target.files[0];
|
const file = event.target.files[0];
|
||||||
let data=new FormData()
|
let data=new FormData()
|
||||||
data.append('file',file)
|
data.append('file',file)
|
||||||
data.append('orderId',$('#bootstrap-table').attr('deliveryid'))
|
data.append('deliveryId',$('#bootstrap-table').attr('deliveryid'))
|
||||||
|
|
||||||
var xhr = new XMLHttpRequest(); // 创建XMLHttpRequest对象
|
var xhr = new XMLHttpRequest(); // 创建XMLHttpRequest对象
|
||||||
xhr.open('POST',prefix+'/list/importData', true); // 设置请求类型和URL
|
xhr.open('POST',prefix+'/importData', true); // 设置请求类型和URL
|
||||||
// 当请求完成时执行的回调函数
|
// 当请求完成时执行的回调函数
|
||||||
xhr.onload = function (res) {
|
xhr.onload = function (res) {
|
||||||
let data=JSON.parse(res.currentTarget.response)
|
let data=JSON.parse(res.currentTarget.response)
|
||||||
|
|
|
||||||
|
|
@ -138,10 +138,6 @@
|
||||||
<h4 class="form-header h4">合同清单列表</h4>
|
<h4 class="form-header h4">合同清单列表</h4>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-sm-12 select-table table-striped">
|
<div class="col-sm-12 select-table table-striped">
|
||||||
<button type="button" class="btn btn-white btn-sm" onclick="sub.delRow()"><i class="fa fa-minus"> 删除</i></button>
|
|
||||||
<button type="button" class="btn btn-white btn-sm" onclick="downloadTem()"><i class="fa fa-download"> 下载模板</i></button>
|
|
||||||
<button type="button" class="btn btn-white btn-sm" onclick="importList()"><i class="fa fa-upload"> 导入</i></button>
|
|
||||||
|
|
||||||
<table id="bootstrap-table"></table>
|
<table id="bootstrap-table"></table>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -107,10 +107,10 @@
|
||||||
field: 'orderDate',
|
field: 'orderDate',
|
||||||
title: '合同签定日期'
|
title: '合同签定日期'
|
||||||
},
|
},
|
||||||
// {
|
{
|
||||||
// field: 'status',
|
field: 'status',
|
||||||
// title: '合同状态'
|
title: '合同状态'
|
||||||
// },
|
},
|
||||||
{
|
{
|
||||||
title: '操作',
|
title: '操作',
|
||||||
align: 'center',
|
align: 'center',
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue