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
f84d9a66
Commit
f84d9a66
authored
Jul 20, 2018
by
frank.xa.zhang
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev' into dev_frank
parents
8c4f8b55
c3a4d2b5
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
6 deletions
+10
-6
FormulaAgent.java
.../java/pwc/taxtech/atms/vat/service/impl/FormulaAgent.java
+4
-3
ReportGeneratorImpl.java
...wc/taxtech/atms/vat/service/impl/ReportGeneratorImpl.java
+2
-1
ReportServiceImpl.java
.../pwc/taxtech/atms/vat/service/impl/ReportServiceImpl.java
+2
-1
BB.java
...wc/taxtech/atms/vat/service/impl/report/functions/BB.java
+2
-1
No files found.
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/FormulaAgent.java
View file @
f84d9a66
package
pwc
.
taxtech
.
atms
.
vat
.
service
.
impl
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Service
;
import
pwc.taxtech.atms.common.datasource.ShardingContextHolder
;
import
pwc.taxtech.atms.common.util.MyAsserts
;
...
...
@@ -27,7 +28,7 @@ import java.util.List;
import
static
pwc
.
taxtech
.
atms
.
constant
.
Constant
.
FIRST_OR_DEFAULT
;
@
Service
@
Component
public
class
FormulaAgent
extends
VatAbstractService
{
@Autowired
public
FormulaAdminMapper
adminMp
;
...
...
@@ -105,14 +106,14 @@ public class FormulaAgent extends VatAbstractService {
return
adminMp
.
getPastProjectDbName
(
year
,
orgId
);
}
public
CellData
getCellData
(
String
dbName
,
String
templateId
,
int
periodId
)
{
public
CellData
getCellData
(
String
dbName
,
String
templateId
,
String
cellId
,
int
periodId
)
{
String
currentProjectDb
=
ShardingContextHolder
.
getDataSourceKey
();
try
{
ShardingContextHolder
.
setDataSourceKey
(
dbName
);
Report
report
=
getReportByTemplate
(
templateId
,
periodId
);
MyAsserts
.
assertNotNull
(
report
,
Exceptions
.
BB_REPORT_NULL
);
CellData
cellData
=
getCellDataListByTemplate
(
template
Id
,
report
.
getId
());
CellData
cellData
=
getCellDataListByTemplate
(
cell
Id
,
report
.
getId
());
MyAsserts
.
assertNotNull
(
cellData
,
Exceptions
.
BB_CELL_DATA_NULL
);
return
cellData
;
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/ReportGeneratorImpl.java
View file @
f84d9a66
...
...
@@ -11,6 +11,7 @@ import org.apache.poi.xssf.usermodel.XSSFWorkbook;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Service
;
import
pwc.taxtech.atms.common.POIUtil
;
import
pwc.taxtech.atms.common.util.SpringContextUtil
;
...
...
@@ -35,7 +36,7 @@ import java.util.stream.Collectors;
import
static
pwc
.
taxtech
.
atms
.
constant
.
Constant
.
EMPTY
;
@
Service
@
Component
public
class
ReportGeneratorImpl
extends
VatAbstractService
implements
ReportGenerator
{
private
static
final
Logger
logger
=
LoggerFactory
.
getLogger
(
ReportGeneratorImpl
.
class
);
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/ReportServiceImpl.java
View file @
f84d9a66
package
pwc
.
taxtech
.
atms
.
vat
.
service
.
impl
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.stereotype.Component
;
import
org.springframework.stereotype.Service
;
import
pwc.taxtech.atms.common.datasource.ShardingContextHolder
;
import
pwc.taxtech.atms.constant.enums.EnumServiceType
;
...
...
@@ -16,7 +17,7 @@ import pwc.taxtech.atms.vat.service.ReportService;
import
java.util.*
;
import
java.util.stream.Collectors
;
@
Service
@
Component
public
class
ReportServiceImpl
extends
VatAbstractService
implements
ReportService
{
@Override
public
OperationResultDto
<
List
<
ReportDto
>>
getReportTemplate
(
String
projectID
,
EnumServiceType
serviceType
,
Integer
periodParam
)
{
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/report/functions/BB.java
View file @
f84d9a66
...
...
@@ -75,7 +75,8 @@ public class BB extends FunctionBase implements FreeRefFunction {
bo
.
disCount
();
String
dbName
=
agent
.
getPastProjectDbName
(
curPeriod
.
getCurYear
(),
formulaContext
.
getOrganizationID
());
CellData
cellData
=
agent
.
getCellData
(
dbName
,
cellTemplateData
.
getReportTemplateID
(),
curPeriod
.
getCurPeriod
());
CellData
cellData
=
agent
.
getCellData
(
dbName
,
cellTemplateData
.
getReportTemplateID
(),
cellTemplateData
.
getCellTemplateID
(),
curPeriod
.
getCurPeriod
());
nullCellDto
=
ReportCellDataSourceDto
.
extractFromGroup
(
bo
,
curPeriod
,
cellData
,
cellTemplateData
);
closeDataSource
.
clean
();
closeDataSource
.
addDS
(
nullCellDto
);
...
...
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