Commit 0e133045 authored by dahai's avatar dahai

Merge remote-tracking branch 'origin/dev' into dev

parents 473d9a87 e15f264a
......@@ -195,5 +195,27 @@ angular.module('AvatarCheck', [
$location.path("/createTaskList");
}
});
}).filter('myDateFilter', function() { //可以注入依赖
return function(permanentPositionDate) {
if(permanentPositionDate!=null){
var yyyy = permanentPositionDate.substring(0,4);
var MM = permanentPositionDate.substring(4,6);
var dd = permanentPositionDate.substring(6,8);
var hh = permanentPositionDate.substring(8,10);
var mm = permanentPositionDate.substring(10,12);
var ss = permanentPositionDate.substring(12,14)
var yyyyMMddhhmmss = yyyy+"-"+MM+"-"+dd+" "+hh+":"+mm+":"+ss;
var yyyyMMdd = yyyy+"-"+MM+"-"+dd;
if(permanentPositionDate.length == 8){
return yyyyMMdd;
}else{
return yyyyMMddhhmmss;
}
}else{
return permanentPositionDate;
}
}
})
;
......@@ -113,7 +113,7 @@
</td>
</tr>
</table>
<table class="table table-bordered table-hover postTable" ng-if="postPackageData">
<table class="table table-bordered table-hover postTable" ng-if="postPackageData.length>0">
<thead>
<tr>
<th>NO.</th>
......@@ -128,28 +128,28 @@
<tbody>
<tr ng-repeat="item in postPackageData">
<td>{{$index+1}}</td>
<td>{{item.formStartTime}}</td>
<td>{{item.formDeadline}}</td>
<td>{{item.formStartTime | myDateFilter}}</td>
<td>{{item.formDeadline| myDateFilter}}</td>
<td>{{item.fileName}}</td>
<td>{{item.uploadDate}}</td>
<td>{{item.uploadDate | myDateFilter}}</td>
<td ng-if="item.state==0">未解析</td>
<td ng-if="item.state==1">已解析</td>
<td>
<button class="btn btn-danger">删除</button>
<button class="btn btn-danger" ng-click="deletePostData(item.fileId)">删除</button>
</td>
</tr>
</tbody>
</table>
<div style="padding-left: 27%;" >
<tm-pagination conf="paginationConf" class="ul"></tm-pagination>
</div>
<h3 ng-if="postMsgDetail.length==0">暂无记录。</h3>
<div class="row" style="padding:0 25px;" ng-if="postMsgDetail.length>0">
<div class="col-md-11"></div>
<div class="col-md-1" style="text-align: right;">
<button id="rev-btn" class="btn btn-primary" data-loading-text="Loading..." ng-click="PreviewMytableRotate()" type="button">打印</button>
</div>
<div style="padding-left: 27%;" >
<tm-pagination conf="paginationConf" class="ul"></tm-pagination>
</div>
<h3 ng-if="postPackageData.length==0">暂无记录。</h3>
<div class="row" style="padding:0 25px;" ng-if="postMsgDetail.length>0">
<div class="col-md-11"></div>
<div class="col-md-1" style="text-align: right;">
<button id="rev-btn" class="btn btn-primary" data-loading-text="Loading..." ng-click="PreviewMytableRotate()" type="button">打印</button>
</div>
</div>
</div>
</div>
</div>
......
......@@ -81,5 +81,11 @@ angular.module('AvatarCheck.excelAndSearch', ['ngRoute', 'AvatarCheck.http', 'tm
})
}
// 通过$watch currentPage和itemperPage 当他们一变化的时候,重新获取数据条目
$scope.$watch('paginationConf.currentPage +paginationConf.itemsPerPage', $scope.getPostPackage);
$scope.deletePostData = function(fileid){
}
});
\ No newline at end of file
......@@ -67,7 +67,7 @@
</td>
</tr>
</table>
<table class="table table-bordered table-hover postTable" ng-if="xmlPackageData">
<table class="table table-bordered table-hover postTable" ng-if="xmlPackageData.length>0">
<thead>
<tr>
<th>NO.</th>
......@@ -81,8 +81,8 @@
</thead>
<tbody>
<tr ng-repeat="item in xmlPackageData">
<td>{{$index}}</td>
<td>{{item.uploadDate}}</td>
<td>{{$index+1}}</td>
<td>{{item.uploadDate | date:'yyyy-MM-dd HH:mm:ss'}}</td>
<td>{{item.packageCount}}</td>
<td>{{item.cardCount}}</td>
<td>{{item.commonCardCount}}</td>
......@@ -94,10 +94,10 @@
</tr>
</tbody>
</table>
<div style="padding-left: 27%;" ng-if="xmlPackageData">
<div style="padding-left: 27%;">
<tm-pagination conf="paginationConf" class="ul"></tm-pagination>
</div>
<h3 ng-if="postMsgDetail.length==0">暂无记录。</h3>
<h3 ng-if="xmlPackageData.length==0">暂无记录。</h3>
<div class="row" style="padding:0 25px;" ng-if="postMsgDetail.length>0">
<div class="col-md-11"></div>
<div class="col-md-1" style="text-align: right;">
......
......@@ -70,10 +70,10 @@ angular.module('AvatarCheck.xmlAndSearch', ['ngRoute', 'AvatarCheck.http', 'tm.p
$scope.getXmlPackage = function(){
console.log($("#datepicker").val())
HttpService.selectXmlPackageCount($("#datepicker").val(),function(data){
$scope.paginationConf.totalItems = 50;
$scope.paginationConf.totalItems = data.respData.string;
})
HttpService.selectXmlPackage($("#datepicker").val(),$scope.paginationConf.currentPage,$scope.paginationConf.itemsPerPage,function(data){
$scope.xmlPackageData = data;
$scope.xmlPackageData = data.respData;
console.log("$scope.xmlPackageData:",$scope.xmlPackageData)
})
}
......
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