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
a4370868
Commit
a4370868
authored
Apr 25, 2019
by
Memorydoc
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
#分析debug
parent
ce7e50b6
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
36 additions
and
12 deletions
+36
-12
DataImportErrorDto.java
.../java/pwc/taxtech/atms/dto/vatdto/DataImportErrorDto.java
+11
-0
AnalysisServiceImpl.java
...va/pwc/taxtech/atms/service/impl/AnalysisServiceImpl.java
+6
-3
DataImportService.java
...java/pwc/taxtech/atms/service/impl/DataImportService.java
+11
-3
cit.json
atms-web/src/main/webapp/app-resources/i18n/zh-CN/cit.json
+1
-1
domestic-data-import.ctrl.js
...-import/domestic-data-import/domestic-data-import.ctrl.js
+1
-0
international-data-import.ctrl.js
...ternational-data-import/international-data-import.ctrl.js
+3
-2
international-data-import.html
.../international-data-import/international-data-import.html
+3
-3
No files found.
atms-api/src/main/java/pwc/taxtech/atms/dto/vatdto/DataImportErrorDto.java
View file @
a4370868
...
...
@@ -19,6 +19,9 @@ public class DataImportErrorDto {
@JSONField
(
name
=
"开票金额"
)
private
String
amount
;
@JSONField
(
name
=
"开票日期"
)
private
String
openDate
;
@JSONField
(
name
=
"确认/认证日期"
)
private
String
confirmTime
;
...
...
@@ -27,6 +30,14 @@ public class DataImportErrorDto {
@JSONField
(
name
=
"Sheet"
)
private
Integer
sheet
;
public
String
getOpenDate
()
{
return
openDate
;
}
public
void
setOpenDate
(
String
openDate
)
{
this
.
openDate
=
openDate
;
}
public
Integer
getSheet
()
{
return
sheet
;
}
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/AnalysisServiceImpl.java
View file @
a4370868
...
...
@@ -322,6 +322,8 @@ public class AnalysisServiceImpl extends BaseService {
return
null
;
}
public
Organization
getOrgByCompanyName
(
String
companyName
)
{
OrganizationExample
organizationExample
=
new
OrganizationExample
();
organizationExample
.
createCriteria
().
andNameEqualTo
(
companyName
);
...
...
@@ -649,6 +651,7 @@ public class AnalysisServiceImpl extends BaseService {
continue
;
}
model
.
setGmv
(
getCellBigDecimalValue
(
cell1
));
model
.
setCompanyName
(
getOrgById
(
organizationId
).
getName
());
model
.
setTrips
(
getCellBigDecimalValue
(
sheet
.
getRow
(
j
).
getCell
(
1
)));
model
.
setSubsidyB
(
getCellBigDecimalValue
(
sheet
.
getRow
(
j
).
getCell
(
2
)));
model
.
setSubsidyC
(
getCellBigDecimalValue
(
sheet
.
getRow
(
j
).
getCell
(
3
)));
...
...
@@ -682,11 +685,11 @@ public class AnalysisServiceImpl extends BaseService {
List
<
Object
>
objects
=
new
ArrayList
<>();
Integer
period
=
DateUtils
.
strToPeriod
(
param
.
getPeriod
());
String
country
=
param
.
getCountry
();
String
companyName
=
param
.
getCompanyName
();
String
organizationId
=
param
.
getCompanyName
();
switch
(
param
.
getType
())
{
case
100
:
AnalysisInternationalBusinessDataExample
analysisInternationalBusinessDataExample
=
new
AnalysisInternationalBusinessDataExample
();
analysisInternationalBusinessDataExample
.
createCriteria
().
andPeriodEqualTo
(
period
).
and
CompanyNameEqualTo
(
companyName
).
andCountryEqualTo
(
country
);
analysisInternationalBusinessDataExample
.
createCriteria
().
andPeriodEqualTo
(
period
).
and
OrganizationIdEqualTo
(
organizationId
).
andCountryEqualTo
(
country
);
List
<
AnalysisInternationalBusinessData
>
list
=
analysisInternationalBusinessDataMapper
.
selectByExample
(
analysisInternationalBusinessDataExample
);
/*List<AnalysisInternationalBUDataDto> dtos = Lists.newArrayList();
...
...
@@ -726,7 +729,7 @@ public class AnalysisServiceImpl extends BaseService {
return
objects
;
case
101
:
AnalysisInternationalTaxDataExample
analysisInternationalTaxDataExample
=
new
AnalysisInternationalTaxDataExample
();
analysisInternationalTaxDataExample
.
createCriteria
().
andPeriodEqualTo
(
period
).
and
CompanyNameEqualTo
(
companyName
).
andCountryEqualTo
(
country
);
analysisInternationalTaxDataExample
.
createCriteria
().
andPeriodEqualTo
(
period
).
and
OrganizationIdEqualTo
(
organizationId
).
andCountryEqualTo
(
country
);
List
<
AnalysisInternationalTaxData
>
list2
=
analysisInternationalTaxDataMapper
.
selectByExample
(
analysisInternationalTaxDataExample
);
List
<
AnalysisInternationalTaxDataDto
>
dtos2
=
Lists
.
newArrayList
();
list2
.
forEach
(
l2
->
{
...
...
atms-api/src/main/java/pwc/taxtech/atms/service/impl/DataImportService.java
View file @
a4370868
...
...
@@ -1578,7 +1578,7 @@ public class DataImportService extends BaseService {
for
(
int
i
=
0
;
i
<
workbook
.
getNumberOfSheets
();
i
++)
{
Sheet
sheet
=
workbook
.
getSheetAt
(
i
);
if
(
isSheetEmpty
(
sheet
))
continue
;
DataImportResponseDto
<
InvoiceRecord
>
dataImportResponseDto
=
generalIRs
(
sheet
);
DataImportResponseDto
<
InvoiceRecord
>
dataImportResponseDto
=
generalIRs
(
sheet
,
tmsPeriod
);
dataImportResponseDto1
.
addAll
(
dataImportResponseDto
.
getDataImportErrorDtos
());
//List<InvoiceRecord> irs = generalIRs(sheet);
List
<
InvoiceRecord
>
irs
=
dataImportResponseDto
.
getObjectList
();
...
...
@@ -1726,8 +1726,10 @@ public class DataImportService extends BaseService {
return
rlits
;
}
private
DataImportResponseDto
<
InvoiceRecord
>
generalIRs
(
Sheet
sheet
)
{
private
DataImportResponseDto
<
InvoiceRecord
>
generalIRs
(
Sheet
sheet
,
Integer
period
)
{
List
<
InvoiceRecord
>
irs
=
Lists
.
newArrayList
();
//存在错误的期间跳过
SimpleDateFormat
simpleDateFormat
=
new
SimpleDateFormat
(
"yyyyMM"
);
List
<
DataImportErrorDto
>
errorDtos
=
Lists
.
newArrayList
();
Set
<
String
>
orgsNot
=
new
HashSet
<>();
//先循环校验字段
...
...
@@ -1752,7 +1754,6 @@ public class DataImportService extends BaseService {
errorDtos
.
add
(
importErrorDto
);
}
}
for
(
int
j
=
1
;
j
<=
sheet
.
getLastRowNum
();
j
++)
{
InvoiceRecord
ir
=
new
InvoiceRecord
();
Long
irId
=
idService
.
nextId
();
...
...
@@ -1770,6 +1771,13 @@ public class DataImportService extends BaseService {
if
(
validIRExcelCell
(
row
,
orgsNot
).
contains
(
getCellStringValue
(
row
.
getCell
(
1
))))
{
continue
;
}
//存在错误的期间跳过
if
(
!
simpleDateFormat
.
format
(
row
.
getCell
(
12
).
getDateCellValue
()).
equals
(
period
.
toString
())){
DataImportErrorDto
importErrorDto
=
new
DataImportErrorDto
();
importErrorDto
.
setOpenDate
(
"存在日期不匹配"
);
errorDtos
.
add
(
importErrorDto
);
continue
;
}
ir
.
setBillingBody
(
getCellStringValue
(
row
.
getCell
(
1
)));
ir
.
setCustomerCompanyName
(
getCellStringValue
(
row
.
getCell
(
2
)));
ir
.
setInvoiceType
(
getCellStringValue
(
row
.
getCell
(
3
)));
...
...
atms-web/src/main/webapp/app-resources/i18n/zh-CN/cit.json
View file @
a4370868
...
...
@@ -1215,7 +1215,7 @@
"ImportNotMatch"
:
"导入文件与选择机构或期间不匹配"
,
"ProjectDescription"
:
"项目描述"
,
"ProductDescription"
:
"产品描述"
,
"Company"
:
"公司
间
"
,
"Company"
:
"公司"
,
"CompanyDescription"
:
"公司间描述"
,
"Segment1"
:
"备用段"
,
"Segment1Description"
:
"备用段描述"
,
...
...
atms-web/src/main/webapp/app/analysis/data-import/domestic-data-import/domestic-data-import.ctrl.js
View file @
a4370868
...
...
@@ -243,6 +243,7 @@
}).
success
(
function
(
resp
)
{
var
ret
=
resp
.
data
;
$scope
.
fileName
=
''
;
$scope
.
importExcelFile
=
null
;
$
(
'#busy-indicator-container'
).
hide
();
deferred
.
resolve
();
uploadAfter
();
...
...
atms-web/src/main/webapp/app/analysis/data-import/international-data-import/international-data-import.ctrl.js
View file @
a4370868
...
...
@@ -207,6 +207,7 @@
}).
then
(
function
(
resp
)
{
var
ret
=
resp
.
data
;
$scope
.
fileName
=
''
;
$scope
.
importExcelFile
=
null
;
$
(
'#busy-indicator-container'
).
hide
();
deferred
.
resolve
();
if
(
ret
.
result
)
{
...
...
@@ -540,9 +541,9 @@
var
setButtonWrapStyle
=
function
()
{
if
(
$scope
.
fileName
)
{
/*
if ($scope.fileName) {
return {width: "100%"};
}
}
*/
};
var
setGridStyle
=
function
()
{
...
...
atms-web/src/main/webapp/app/analysis/data-import/international-data-import/international-data-import.html
View file @
a4370868
...
...
@@ -49,7 +49,7 @@
ng-click=
"downloadTemplate()"
></button>
<button
type=
"button"
class=
"btn btn-vat-primary"
style=
""
class=
"btn btn-vat-primary"
translate=
"ImportBtn"
ng-click=
"doUpload()"
></button>
...
...
@@ -61,7 +61,7 @@
</div>
<div
class=
"row"
style=
"margin-top: 10px;"
>
<span
class=
"text-bold"
translate=
"Country"
>
:
</span>
<span
class=
"text-bold"
translate=
"Country"
>
<span>
:
</span>
</span>
<!-- <div class="dropdown" style="margin-left:10px">
<button class="btn btn-default dropdown-toggle" type="button" id="dropdownMenu3"
data-toggle="dropdown" aria-haspopup="true" aria-expanded="true" style="width: 150px;margin-left: 28px;">
...
...
@@ -90,7 +90,7 @@
data-none-results-text =
"没有匹配的国家"
>
</select>
<span
class=
"text-bold"
translate=
"Company"
>
:
</span>
<span
class=
"text-bold"
translate=
"Company"
>
<span>
:
</span>
</span>
<!--<div dx-tag-box="selectOrgOptionsComany" style="width: 287px;display: inline-block"></div>-->
<select
class=
"selectpicker show-tick dropup"
multiple
data-live-search=
"true"
data-width=
"auto"
data-max-options=
"1"
...
...
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