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
9372ce69
Commit
9372ce69
authored
Oct 08, 2018
by
neo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[dev] add projectid for get cell tenplate
parent
78034487
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
23 additions
and
11 deletions
+23
-11
ReportController.java
...in/java/pwc/taxtech/atms/controller/ReportController.java
+8
-4
ReportService.java
...main/java/pwc/taxtech/atms/vat/service/ReportService.java
+2
-1
ReportGeneratorImpl.java
...wc/taxtech/atms/vat/service/impl/ReportGeneratorImpl.java
+1
-1
ReportServiceImpl.java
.../pwc/taxtech/atms/vat/service/impl/ReportServiceImpl.java
+5
-3
PeriodCellTemplateConfigMapper.java
.../taxtech/atms/vat/dao/PeriodCellTemplateConfigMapper.java
+4
-2
PeriodCellTemplateConfigExtendsMapper.xml
...vat/dao/extends/PeriodCellTemplateConfigExtendsMapper.xml
+3
-0
No files found.
atms-api/src/main/java/pwc/taxtech/atms/controller/ReportController.java
View file @
9372ce69
...
...
@@ -76,8 +76,12 @@ public class ReportController {
}
@RequestMapping
(
value
=
"getCellTemplateConfig/{reportTemplateId}/{period}/{rowIndex}/{columnIndex}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
public
OperationResultDto
<
PeriodCellTemplateConfig
>
getCellTemplateConfig
(
@PathVariable
Long
reportTemplateId
,
@PathVariable
Integer
period
,
@PathVariable
int
rowIndex
,
@PathVariable
int
columnIndex
)
{
return
reportService
.
getCellTemplateConfig
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
);
public
OperationResultDto
<
PeriodCellTemplateConfig
>
getCellTemplateConfig
(
@PathVariable
Long
reportTemplateId
,
@PathVariable
Integer
period
,
@PathVariable
int
rowIndex
,
@PathVariable
int
columnIndex
,
@RequestHeader
(
"from"
)
String
projectId
)
{
return
reportService
.
getCellTemplateConfig
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
,
projectId
);
}
@RequestMapping
(
value
=
"getStdAccountByIndustry/{industryId}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
...
...
@@ -90,12 +94,12 @@ public class ReportController {
}
@RequestMapping
(
value
=
"getCellAccountRange/{reportTemplateId}/{period}/{rowIndex}/{columnIndex}"
,
method
=
RequestMethod
.
GET
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
public
OperationResultDto
<
List
<
VatEnterpriseAccountResultDto
>>
getCellAccountRange
(
@PathVariable
Long
reportTemplateId
,
@PathVariable
Integer
period
,
@PathVariable
int
rowIndex
,
@PathVariable
int
columnIndex
,
@RequestHeader
String
from
)
{
public
OperationResultDto
<
List
<
VatEnterpriseAccountResultDto
>>
getCellAccountRange
(
@PathVariable
Long
reportTemplateId
,
@PathVariable
Integer
period
,
@PathVariable
int
rowIndex
,
@PathVariable
int
columnIndex
,
@RequestHeader
String
from
)
{
String
projectId
=
StringUtils
.
EMPTY
;
if
(
StringUtils
.
isNotBlank
(
from
)
&&
from
.
split
(
"@"
).
length
>
0
)
{
projectId
=
from
.
split
(
"@"
)[
0
];
}
return
reportService
.
getCellAccountRange
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
,
projectId
);
return
reportService
.
getCellAccountRange
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
,
projectId
);
}
@RequestMapping
(
value
=
"addCellManualData"
,
method
=
RequestMethod
.
POST
,
produces
=
MediaType
.
APPLICATION_JSON_UTF8_VALUE
)
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/ReportService.java
View file @
9372ce69
...
...
@@ -28,7 +28,8 @@ public interface ReportService {
OperationResultDto
<
ReportDto
>
getReportByTemplate
(
Long
templateId
,
Integer
period
,
String
projectId
);
OperationResultDto
<
PeriodCellTemplateConfig
>
getCellTemplateConfig
(
Long
reportTemplateId
,
Integer
periodParam
,
int
rowIndex
,
int
columnIndex
);
OperationResultDto
<
PeriodCellTemplateConfig
>
getCellTemplateConfig
(
Long
reportTemplateId
,
Integer
periodParam
,
int
rowIndex
,
int
columnIndex
,
String
porjectId
);
OperationResultDto
<
List
<
VatEnterpriseAccount
>>
getStdAccountByIndustry
(
String
industryId
,
String
projectId
);
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/ReportGeneratorImpl.java
View file @
9372ce69
...
...
@@ -515,7 +515,7 @@ public class ReportGeneratorImpl extends VatAbstractService implements ReportGen
}
List
<
PeriodCellTemplateConfigExtendDto
>
periodCellTemplateConfigExtendDtos
=
periodCellTemplateConfigMapper
.
getPeriodCellTemplateConfigExtendDtos
(
templateIdList
,
period
);
periodCellTemplateConfigMapper
.
getPeriodCellTemplateConfigExtendDtos
(
templateIdList
,
period
,
projectId
);
fixedPCTParsedFormula
(
periodCellTemplateConfigExtendDtos
,
projectId
,
period
);
List
<
CellCalcInfoDto
>
cellCalcInfoDtos
=
new
ArrayList
<>();
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/ReportServiceImpl.java
View file @
9372ce69
...
...
@@ -686,7 +686,8 @@ public class ReportServiceImpl extends VatAbstractService implements ReportServi
}
@Override
public
OperationResultDto
<
PeriodCellTemplateConfig
>
getCellTemplateConfig
(
Long
reportTemplateId
,
Integer
periodParam
,
int
rowIndex
,
int
columnIndex
)
{
public
OperationResultDto
<
PeriodCellTemplateConfig
>
getCellTemplateConfig
(
Long
reportTemplateId
,
Integer
periodParam
,
int
rowIndex
,
int
columnIndex
,
String
projectId
)
{
OperationResultDto
resultDto
=
new
OperationResultDto
();
try
{
int
period
=
periodParam
!=
null
?
periodParam
:
0
;
...
...
@@ -697,7 +698,8 @@ public class ReportServiceImpl extends VatAbstractService implements ReportServi
return
resultDto
;
}
PeriodCellTemplateConfig
periodCellTemplateConfig
=
periodCellTemplateConfigMapper
.
getConfigWithReportTemplateId
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
);
PeriodCellTemplateConfig
periodCellTemplateConfig
=
periodCellTemplateConfigMapper
.
getConfigWithReportTemplateId
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
,
projectId
);
if
(
periodCellTemplateConfig
==
null
)
{
resultDto
.
setResult
(
false
);
resultDto
.
setResultMsg
(
"no config for this template!"
);
...
...
@@ -746,7 +748,7 @@ public class ReportServiceImpl extends VatAbstractService implements ReportServi
int
period
=
periodParam
==
null
?
0
:
periodParam
;
PeriodCellTemplateConfig
periodCellTemplateConfig
=
periodCellTemplateConfigMapper
.
getConfigWithReportTemplateId
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
);
periodCellTemplateConfigMapper
.
getConfigWithReportTemplateId
(
reportTemplateId
,
period
,
rowIndex
,
columnIndex
,
projectId
);
if
(
periodCellTemplateConfig
==
null
||
StringUtils
.
isBlank
(
periodCellTemplateConfig
.
getAccountCodes
()))
{
resultDto
.
setResult
(
false
);
return
resultDto
;
...
...
atms-dao/src/main/java/pwc/taxtech/atms/vat/dao/PeriodCellTemplateConfigMapper.java
View file @
9372ce69
...
...
@@ -110,10 +110,11 @@ public interface PeriodCellTemplateConfigMapper extends MyVatMapper {
void
batchInsert
(
List
<
PeriodCellTemplateConfig
>
list
);
List
<
PeriodCellTemplateConfigExtendDto
>
getPeriodCellTemplateConfigExtendDtos
(
@Param
(
"list"
)
List
<
Long
>
list
,
@Param
(
"period"
)
Integer
period
);
List
<
PeriodCellTemplateConfigExtendDto
>
getPeriodCellTemplateConfigExtendDtos
(
@Param
(
"list"
)
List
<
Long
>
list
,
@Param
(
"period"
)
Integer
period
,
@Param
(
"projectId"
)
String
projectId
);
PeriodCellTemplateConfig
getConfigWithReportTemplateId
(
@Param
(
"reportTemplateId"
)
Long
reportTemplateId
,
@Param
(
"period"
)
Integer
period
,
@Param
(
"rowIndex"
)
int
rowIndex
,
@Param
(
"columnIndex"
)
int
columnIndex
);
@Param
(
"columnIndex"
)
int
columnIndex
,
@Param
(
"projectId"
)
String
projectId
);
}
\ No newline at end of file
atms-dao/src/main/resources/pwc/taxtech/atms/vat/dao/extends/PeriodCellTemplateConfigExtendsMapper.xml
View file @
9372ce69
...
...
@@ -209,6 +209,7 @@
#{item}
</foreach>
AND CELL_TEMPLATE.PERIOD = #{period,jdbcType=INTEGER}
AND CELL_TEMPLATE.PROJECT_ID = #{projectId,jdbcType=VARCHAR}
</select>
<select
id=
"getConfigWithReportTemplateId"
resultType=
"pwc.taxtech.atms.vat.entity.PeriodCellTemplateConfig"
>
...
...
@@ -229,6 +230,7 @@
AND CT.PERIOD = #{period,jdbcType = INTEGER}
AND CTC.DATA_SOURCE_TYPE = 2
AND CTC.PERIOD= #{period,jdbcType = INTEGER} AND ROWNUM = 1
AND CT.PROJECT_ID = #{projectId,jdbcType=VARCHAR}
</select>
</mapper>
\ No newline at end of file
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