Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
T
traffic-front
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangxiaoming
traffic-front
Commits
a53b3ae4
Commit
a53b3ae4
authored
Nov 14, 2018
by
neo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[Bugfix] fixed init formual status
parent
833f7caa
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
7 deletions
+9
-7
ReportController.java
...in/java/pwc/taxtech/atms/controller/ReportController.java
+5
-2
PeriodJobDto.java
...c/main/java/pwc/taxtech/atms/dto/vatdto/PeriodJobDto.java
+3
-4
PeriodJobMapper.java
...c/main/java/pwc/taxtech/atms/vat/dao/PeriodJobMapper.java
+1
-1
No files found.
atms-api/src/main/java/pwc/taxtech/atms/controller/ReportController.java
View file @
a53b3ae4
...
@@ -47,8 +47,11 @@ public class ReportController {
...
@@ -47,8 +47,11 @@ public class ReportController {
@RequestMapping
(
value
=
"getRunningJob/{projectId}/{period}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
@RequestMapping
(
value
=
"getRunningJob/{projectId}/{period}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
@ResponseBody
@ResponseBody
public
PeriodJob
getRunningJob
(
@PathVariable
String
projectId
,
@PathVariable
Integer
period
)
{
public
PeriodJobDto
getRunningJob
(
@PathVariable
String
projectId
,
@PathVariable
Integer
period
)
{
return
reportService
.
getRunningJob
(
projectId
,
period
);
PeriodJob
job
=
reportService
.
getRunningJob
(
projectId
,
period
);
if
(
job
!=
null
)
return
new
PeriodJobDto
().
copyFromPeriodJob
(
job
);
else
return
null
;
}
}
@RequestMapping
(
value
=
"getJobStatus/{projectId}//{period}/{jobId}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
@RequestMapping
(
value
=
"getJobStatus/{projectId}//{period}/{jobId}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
...
...
atms-api/src/main/java/pwc/taxtech/atms/dto/vatdto/PeriodJobDto.java
View file @
a53b3ae4
...
@@ -46,10 +46,9 @@ public class PeriodJobDto {
...
@@ -46,10 +46,9 @@ public class PeriodJobDto {
if
(
Collections
.
isEmpty
(
tasks
))
this
.
jobStatus
=
STATUS_BEGIN
;
if
(
Collections
.
isEmpty
(
tasks
))
this
.
jobStatus
=
STATUS_BEGIN
;
else
{
else
{
String
[]
codes
=
stepsCode
.
split
(
","
);
String
[]
codes
=
stepsCode
.
split
(
","
);
if
(
tasks
.
size
()
<
codes
.
length
)
this
.
jobStatus
=
STATUS_RUNNING
;
if
(
tasks
.
stream
().
anyMatch
(
m
->
m
.
status
.
equals
(
STATUS_ERROR
)))
this
.
jobStatus
=
STATUS_ERROR
;
else
{
else
if
(
tasks
.
size
()
<
codes
.
length
)
this
.
jobStatus
=
STATUS_RUNNING
;
this
.
jobStatus
=
tasks
.
stream
().
anyMatch
(
m
->
m
.
status
.
equals
(
STATUS_ERROR
))
?
STATUS_ERROR
:
STATUS_END
;
else
this
.
jobStatus
=
STATUS_END
;
}
}
}
}
}
...
...
atms-dao/src/main/java/pwc/taxtech/atms/vat/dao/PeriodJobMapper.java
View file @
a53b3ae4
...
@@ -120,7 +120,7 @@ public interface PeriodJobMapper extends MyVatMapper {
...
@@ -120,7 +120,7 @@ public interface PeriodJobMapper extends MyVatMapper {
"FROM "
+
"FROM "
+
" PERIOD_JOB "
+
" PERIOD_JOB "
+
"WHERE "
+
"WHERE "
+
" STATUS
= 'Begin
' "
+
" STATUS
LIKE '%Begin%
' "
+
" AND PROJECT_ID = #{projectId} "
+
" AND PROJECT_ID = #{projectId} "
+
" AND PERIOD =#{period}"
)
" AND PERIOD =#{period}"
)
PeriodJob
getRunningJob
(
@Param
(
"projectId"
)
String
projectId
,
@Param
(
"period"
)
Integer
period
);
PeriodJob
getRunningJob
(
@Param
(
"projectId"
)
String
projectId
,
@Param
(
"period"
)
Integer
period
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment