Commit 58f22923 authored by 谢希宇's avatar 谢希宇

Merge branch 'master' of http://106.14.62.141:8081/sa_aidea/aidea

parents 87a9f2b8 9e5ffd17
...@@ -77,13 +77,17 @@ ...@@ -77,13 +77,17 @@
<div class="box"> <div class="box">
<div class="box-header"> <div class="box-header">
<form id="seachTableForm" action="#springUrl('/a/logistics/list')" method="get"> <form id="seachTableForm" action="#springUrl('/a/logistics/list')" method="get">
<div class="col-xs-5"> <div class="col-xs-2">
<button type="button" class="search btn btn-primary">搜索</button> <input type="text" class="form-control "
#if($shiro.hasPermission("qy:logistics:edit")) name="mailNo" placeholder="顺风运单号">
<a href="#springUrl('/a/logistics/form')" class="btn btn-primary">新增</a> </div>
<a href="#springUrl('/a/logistics/exportExcel')" class="btn btn-primary">导出</a> <div class="col-xs-5">
<a onclick="importExcel();" class="btn btn-primary">导入</a> <button type="button" class="search btn btn-primary">搜索</button>
#end #if($shiro.hasPermission("qy:logistics:edit"))
<!-- <a href="#springUrl('/a/logistics/form')" class="btn btn-primary">新增</a>
<a href="#springUrl('/a/logistics/exportExcel')" class="btn btn-primary">导出</a>
<a onclick="importExcel();" class="btn btn-primary">导入</a>-->
#end
</div> </div>
</form> </form>
</div><!-- /.box-header --> </div><!-- /.box-header -->
...@@ -91,8 +95,15 @@ ...@@ -91,8 +95,15 @@
<table id="table" class="table table-bordered table-striped"> <table id="table" class="table table-bordered table-striped">
<thead> <thead>
<tr> <tr>
<td hidden="true">Id</td><th>创建时间</th> <td hidden="true">Id</td>
<th>操作</th> <td>顺风运单号</td>
<td>订单号</td>
<td>路由节点发生时间</td>
<td>物流编码</td>
<td>路由节点发生地</td>
<td>路由节点操作码</td>
<td>路由节点描述</td>
<th>创建时间</th>
</tr> </tr>
</thead> </thead>
<tbody id="tablebody"> <tbody id="tablebody">
...@@ -145,7 +156,7 @@ ...@@ -145,7 +156,7 @@
var minute = now.getMinutes(); var minute = now.getMinutes();
var second = now.getSeconds(); var second = now.getSeconds();
return year + "-" + month + "-" + date + " " + hour + ":" return year + "-" + month + "-" + date + " " + hour + ":"
+ minute + ":" + second; + minute + ":" + second;
} }
function seachTable() { function seachTable() {
...@@ -185,32 +196,57 @@ ...@@ -185,32 +196,57 @@
"fnServerData": retrieveData, "fnServerData": retrieveData,
"pagingType": "full_numbers", "pagingType": "full_numbers",
"aoColumns": [ "aoColumns": [
{ {
"mData": "id"
},
{
"mData": "createTime"
},
{
"mData": "id" "mData": "id"
},
{
"mData":"mailNo"
},
{
"mData":"orderNo"
},
{
"mData":"acceptTime"
},
{
"mData":"number"
},
{
"mData":"acceptAddress"
},
{
"mData":"opcode"
},
{
"mData":"description"
},
{
"mData": "createTime"
}], }],
"aoColumnDefs": [ "aoColumnDefs": [
{ // set default column settings { // set default column settings
'visible': false, 'visible': false,
'targets': [0] 'targets': [0]
}, },
{
{ "aTargets": [3],
"aTargets": [1], "mData": "acceptTime",
"mData": "createTime", "mRender": function (a, b, c, d) {
"mRender": function (a, b, c, d) { return formatDates(a, "yyyy-MM-dd HH:mm:ss");
return '<a href="#springUrl("/a/logistics/form?id=' + c.id + '")" data-id="' + c.id + '" data-action="view">' + formatDates(a, "yyyy-MM-dd HH:mm:ss");
+'</a>'; }
},
}
}, {
"aTargets": [8],
] "mData": "createTime",
"mRender": function (a, b, c, d) {
return formatDates(a, "yyyy-MM-dd HH:mm:ss");
}
}
]
}); });
} }
...@@ -231,6 +267,7 @@ ...@@ -231,6 +267,7 @@
}); });
Cfapp.init(); Cfapp.init();
function removeData(data) { function removeData(data) {
Cfapp.confirm({ Cfapp.confirm({
message: "确定要删除吗", message: "确定要删除吗",
...@@ -262,22 +299,23 @@ ...@@ -262,22 +299,23 @@
} }
}); });
} }
function importExcel() {
var templateExcelUrl = "#springUrl('/a/logistics/templateExcel')";
var importExcelUrl = "#springUrl('/a/logistics/importExcel')";
Cfapp.importExcel({
title: '物流信息导入',
importurl: importExcelUrl,
templateurl: templateExcelUrl,
cancel: function () {
}, function importExcel() {
success: function () { var templateExcelUrl = "#springUrl('/a/logistics/templateExcel')";
var importExcelUrl = "#springUrl('/a/logistics/importExcel')";
Cfapp.importExcel({
title: '物流信息导入',
importurl: importExcelUrl,
templateurl: templateExcelUrl,
cancel: function () {
},
success: function () {
}
});
}
}
});
}
</script> </script>
......
...@@ -105,6 +105,9 @@ public class LogisticsController { ...@@ -105,6 +105,9 @@ public class LogisticsController {
Conds conds = new Conds(); Conds conds = new Conds();
conds.equal("del_flag", Constants.DEL_FLAG_0); conds.equal("del_flag", Constants.DEL_FLAG_0);
conds.equal("accounts_id", accountsId); conds.equal("accounts_id", accountsId);
if(!StringUtils.isEmpty(logistics.getMailNo())){
conds.equal("mail_no",logistics.getMailNo());
}
Sort sort = new Sort("create_time", OrderType.DESC); Sort sort = new Sort("create_time", OrderType.DESC);
List<Logistics> list = logisticsService.fetchSearchByPage(conds, sort, iDisplayStart, iDisplayLength); List<Logistics> list = logisticsService.fetchSearchByPage(conds, sort, iDisplayStart, iDisplayLength);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment