|
|
|
@ -89,6 +89,24 @@ module System{
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.quickCheck = () => {
|
|
|
|
|
updateSqlStatus("/java/console/api/filePackage/totalVerifySqlFile");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.quitFile = () => {
|
|
|
|
|
updateSqlStatus("/java/console/api/filePackage/totalOnholeSqlFile");
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
$scope.help = () => {
|
|
|
|
|
ngDialog.open({
|
|
|
|
|
template: 'statusHelp.html',
|
|
|
|
|
width: 900,
|
|
|
|
|
height: 600,
|
|
|
|
|
closeByDocument: false,
|
|
|
|
|
className: 'ngdialog-theme-default'
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// watch for check all checkbox
|
|
|
|
|
$scope.$watch(function() {
|
|
|
|
|
return $scope.checkboxes.checked;
|
|
|
|
@ -102,6 +120,14 @@ module System{
|
|
|
|
|
$scope.$watch(function() {
|
|
|
|
|
return $scope.checkboxes.items;
|
|
|
|
|
}, function(values) {
|
|
|
|
|
$scope.checkable = false;
|
|
|
|
|
for(var index in values){
|
|
|
|
|
if(values[index] == true){
|
|
|
|
|
$scope.checkable = true;
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var checked = 0, unchecked = 0,
|
|
|
|
|
total = $scope.model.length;
|
|
|
|
|
angular.forEach($scope.model, function(item) {
|
|
|
|
@ -231,5 +257,60 @@ module System{
|
|
|
|
|
dataset: $scope.filterResult
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
function updateSqlStatus(url: string) {
|
|
|
|
|
var items = [];
|
|
|
|
|
if($scope.model && $scope.model.length > 0){
|
|
|
|
|
angular.forEach($scope.model, (item) => {
|
|
|
|
|
if($scope.checkboxes.items[item.id])
|
|
|
|
|
items.push(item);
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if(items.length <= 0)
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
$http({
|
|
|
|
|
url: url,
|
|
|
|
|
method: 'POST',
|
|
|
|
|
data: JSON.stringify(items)
|
|
|
|
|
}).success(function(data,header,config,status){
|
|
|
|
|
var result = data.data, filter;
|
|
|
|
|
if($scope.z != 'all'){
|
|
|
|
|
result = [];
|
|
|
|
|
angular.forEach(data.data, (item) =>{
|
|
|
|
|
if($scope.status[item.sysStatus].label == $scope.z)
|
|
|
|
|
result.push(item);
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
filter = result;
|
|
|
|
|
|
|
|
|
|
if($scope.x != 'all'){
|
|
|
|
|
filter = [];
|
|
|
|
|
var tmp = [];
|
|
|
|
|
angular.forEach(result, (item) => {
|
|
|
|
|
if($scope.x == item.cityName)
|
|
|
|
|
tmp.push(item);
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
filter = tmp;
|
|
|
|
|
|
|
|
|
|
if($scope.y != 'all'){
|
|
|
|
|
filter = [];
|
|
|
|
|
angular.forEach(tmp, (item) => {
|
|
|
|
|
if($scope.y == item.districtName)
|
|
|
|
|
filter.push(item);
|
|
|
|
|
});
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
$scope.tableParams.settings({
|
|
|
|
|
dataset: filter
|
|
|
|
|
});
|
|
|
|
|
//响应成功
|
|
|
|
|
}).error(function(data,header,config,status){
|
|
|
|
|
//处理响应失败
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}])
|
|
|
|
|
}
|