Commit 2435c8b2 authored by weizhikai's avatar weizhikai

1、卡片展示与列表展示状态改为一致;2、VAT报表处理时的状态;3、收入明细金额加上千分位

parent b01c2bc0
......@@ -2456,7 +2456,7 @@ public class ReportServiceImpl extends BaseService {
}
public PeriodJob getRunningJob(String projectId, Integer period) {
return periodJobMapper.getRunningJob(projectId, period);
return periodJobMapper.getPeriodJob(projectId, period);
}
public PeriodJob getJobStatus(String projectId, Integer period, String jobId) {
......
......@@ -353,7 +353,7 @@
haveCreateProject: p.haveCreateProject,
yearDisplay: $scope.getYearDisplay(p),
projectStatusDisplay: $scope.translateProjectStatus(p.haveCreateProject),
projectStatusDisplay: $scope.translateProjectStatus(p.projectStatusList),
serviceIcon: getServiceIcon(p.serviceTypeID),
color: getColor(p.serviceTypeID),
organizationName: p.organizationName,
......@@ -405,13 +405,52 @@
}
};
$scope.translateProjectStatus = function (isCreate) {
if (isCreate) {
return $translate.instant('OnGoing');
} else {
return $translate.instant('NotBegin');
$scope.translateProjectStatus = function (statusIds) {
var currentMonth = vatSessionService.month;
var statusId;
if (statusIds === null || (statusIds !== null && statusIds[currentMonth] === undefined))
statusId = 0;
else {
statusId = statusIds[currentMonth];
}
}
var status = "";
switch (statusId) {
case constant.ProjectStatusEnum.UnStarted:
status = $translate.instant('NotBegin');
break;
case constant.ProjectStatusEnum.Imported:
status = $translate.instant('OnGoing');
break;
case constant.ProjectStatusEnum.AccountMapSubmitted:
status = $translate.instant('OnGoing');
break;
case constant.ProjectStatusEnum.Generated:
status = $translate.instant('OnGoing');
break;
case constant.ProjectStatusEnum.ReportSubmitted:
status = $translate.instant('ProjectStatusReportSubmitted');
break;
case constant.ProjectStatusEnum.ReportApproved:
status = $translate.instant('ProjectStatusReportApproved');
break;
case constant.ProjectStatusEnum.ReportRejected:
status = $translate.instant('ProjectStatusReportRejected');
break;
case constant.ProjectStatusEnum.Completed:
status = translate.instant('ProejctStatusCompleted');
break;
default:
status = $translate.instant('NotBegin');
}
return status;
// if (isCreate) {
// return $translate.instant('OnGoing');
// } else {
// return $translate.instant('NotBegin');
// }
};
$scope.getYearDisplay = function (p) {
if (p.serviceTypeID === enums.serviceType.VAT || p.serviceTypeID === enums.serviceType.AssetsManage) {
......
......@@ -57,7 +57,7 @@
<span style="padding-right: 10px;" class="result-style">{{projectMsg}}</span>
<span translate="OnGoing" style="padding-right:10px;"></span><span class="num-style">{{ongoingNum}}</span>
<span translate="NotBegin" style="padding-right:10px;padding-left:20px;"></span><span class="num-style">{{notBeginNum}}</span>
<span translate="completed" style="padding-right:10px;padding-left:20px;"></span><span class="num-style">{{completedNum}}</span>
<span translate="AlreadyCompleted" style="padding-right:10px;padding-left:20px;"></span><span class="num-style">{{completedNum}}</span>
</div>
<div class="task-list">
<span translate="TaskList" class="taskMsg" ng-show="serviceTypeId !=='12'"></span>
......
......@@ -211,7 +211,9 @@
//数据配置
result.push({ name: $translate.instant('ProcessData'), items: [new task('UpdateReportConfig', 'unstarted')] });
result.push({
name: $translate.instant('ProcessData'),
items: [new task('UpdateReportConfig', 'unstarted', "", "UpdateConfig")] });
result[result.length - 1].items.forEach(function (t) { t.seqNo = result.length - 1 });
......@@ -629,10 +631,18 @@
items.forEach(function(item,index){
item.status = 'completed';
item.text = $translate.instant('completed');
item.items.forEach(function (_task, index) {
tasks.forEach(function (task) {
if (task.code == _task.code) {
_task.status = 'completed';
_task.text = $translate.instant(_task.status);
}
})
})
});
$scope.tasks[0].items[0].status = 'completed';
$scope.tasks[0].items[0].text= $translate.instant('completed');
if($scope.timer){
$interval.cancel($scope.timer);
vatCommonService.setProjectStatus(vatSessionService.project.id, vatSessionService.month, constant.ProjectStatusEnum.Generated
......@@ -640,7 +650,6 @@
}
}else if(job.jobStatus=='Running'|| job.jobStatus=='Error'){
var updateConfig = tasks[0];
if(updateConfig.status == 'Error'){
$scope.tasks[0].items[0].status = 'error';
......@@ -669,20 +678,29 @@
}
}
items.forEach(function(item,index){
items.forEach(function (item, index) {
item.items.forEach(function (_task, index) {
tasks.forEach(function(task){
if(task.code==_task.code){
if(task.status == 'Error'){
var temp = false;
tasks.forEach(function (task) {
if (task.code == _task.code) {
temp = true;
if (task.status == 'Error') {
_task.status = 'error';
}else if(task.status == 'End'){
} else if (task.status == 'End') {
_task.status = 'completed';
}else if(task.status == 'Begin'){
} else if (task.status == 'Begin') {
_task.status = 'processing';
}
_task.text = $translate.instant(_task.status);
}
})
});
//此时证明该code还未开始
if(!temp){
_task.status = 'unstarted';
_task.text = $translate.instant(_task.status);
}
})
});
}
......
......@@ -73,6 +73,7 @@
dataField: 'amount',
caption: $translate.instant('RevDetailAmount'),
fixed: true,
format: {type: 'fixedPoint', precision: 2},
allowHeaderFiltering: true
},
{
......
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