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
bcb8d858
Commit
bcb8d858
authored
Nov 21, 2018
by
sherlock
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'dev_oracle_sherlock' into 'dev_oracle'
Dev oracle sherlock See merge request root/atms!205
parents
e02c2c8c
3d24912b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
41 additions
and
15 deletions
+41
-15
DFFS.java
.../taxtech/atms/vat/service/impl/report/functions/DFFS.java
+4
-1
JFFS.java
.../taxtech/atms/vat/service/impl/report/functions/JFFS.java
+6
-1
preview-trial-balance.ctrl.js
...trols/preview-trial-balance/preview-trial-balance.ctrl.js
+25
-7
preview-trial-balance.html
...controls/preview-trial-balance/preview-trial-balance.html
+6
-6
No files found.
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/report/functions/DFFS.java
View file @
bcb8d858
...
@@ -11,6 +11,7 @@ import pwc.taxtech.atms.common.util.MyAsserts;
...
@@ -11,6 +11,7 @@ import pwc.taxtech.atms.common.util.MyAsserts;
import
pwc.taxtech.atms.common.util.SpringContextUtil
;
import
pwc.taxtech.atms.common.util.SpringContextUtil
;
import
pwc.taxtech.atms.constant.Constant
;
import
pwc.taxtech.atms.constant.Constant
;
import
pwc.taxtech.atms.constant.enums.FormulaDataSourceDetailType
;
import
pwc.taxtech.atms.constant.enums.FormulaDataSourceDetailType
;
import
pwc.taxtech.atms.constant.enums.FormulaDataSourceType
;
import
pwc.taxtech.atms.dpo.CellTemplatePerGroupDto
;
import
pwc.taxtech.atms.dpo.CellTemplatePerGroupDto
;
import
pwc.taxtech.atms.dto.vatdto.ReportCellDataSourceDto
;
import
pwc.taxtech.atms.dto.vatdto.ReportCellDataSourceDto
;
import
pwc.taxtech.atms.entity.AccountMapping
;
import
pwc.taxtech.atms.entity.AccountMapping
;
...
@@ -63,7 +64,8 @@ public class DFFS extends FunctionBase implements FreeRefFunction {
...
@@ -63,7 +64,8 @@ public class DFFS extends FunctionBase implements FreeRefFunction {
return
NumberEval
.
ZERO
;
return
NumberEval
.
ZERO
;
}
}
AccountMappingExample
accountMappingExample
=
new
AccountMappingExample
();
AccountMappingExample
accountMappingExample
=
new
AccountMappingExample
();
accountMappingExample
.
createCriteria
().
andOrganizationIdEqualTo
(
orgId
).
andEnterpriseAccountSetIdEqualTo
(
enterpriseAccountSetOrgs
.
get
(
0
).
getEnterpriseAccountSetId
());
accountMappingExample
.
createCriteria
().
andOrganizationIdEqualTo
(
orgId
).
andEnterpriseAccountSetIdEqualTo
(
enterpriseAccountSetOrgs
.
get
(
0
).
getEnterpriseAccountSetId
()).
andStandardAccountCodeEqualTo
(
code
);
List
<
AccountMapping
>
accountMappings
=
SpringContextUtil
.
accountMappingMapper
.
selectByExample
(
accountMappingExample
);
List
<
AccountMapping
>
accountMappings
=
SpringContextUtil
.
accountMappingMapper
.
selectByExample
(
accountMappingExample
);
double
result
=
0
;
double
result
=
0
;
...
@@ -113,6 +115,7 @@ public class DFFS extends FunctionBase implements FreeRefFunction {
...
@@ -113,6 +115,7 @@ public class DFFS extends FunctionBase implements FreeRefFunction {
dto
.
setPeriod
(
period
);
dto
.
setPeriod
(
period
);
dto
.
setIsOnlyManualInput
(
Boolean
.
FALSE
);
dto
.
setIsOnlyManualInput
(
Boolean
.
FALSE
);
dto
.
setName
(
Constant
.
DataSourceName
.
ReportDataSource
);
dto
.
setName
(
Constant
.
DataSourceName
.
ReportDataSource
);
dto
.
setType
(
FormulaDataSourceType
.
TrialBalanceSource
.
getCode
());
contain
.
add
(
dto
);
contain
.
add
(
dto
);
}
}
return
temp
.
stream
().
mapToDouble
(
a
->
a
.
getPtdCr
().
doubleValue
()).
sum
();
return
temp
.
stream
().
mapToDouble
(
a
->
a
.
getPtdCr
().
doubleValue
()).
sum
();
...
...
atms-api/src/main/java/pwc/taxtech/atms/vat/service/impl/report/functions/JFFS.java
View file @
bcb8d858
...
@@ -10,6 +10,7 @@ import pwc.taxtech.atms.common.util.DateUtils;
...
@@ -10,6 +10,7 @@ import pwc.taxtech.atms.common.util.DateUtils;
import
pwc.taxtech.atms.common.util.SpringContextUtil
;
import
pwc.taxtech.atms.common.util.SpringContextUtil
;
import
pwc.taxtech.atms.constant.Constant
;
import
pwc.taxtech.atms.constant.Constant
;
import
pwc.taxtech.atms.constant.enums.FormulaDataSourceDetailType
;
import
pwc.taxtech.atms.constant.enums.FormulaDataSourceDetailType
;
import
pwc.taxtech.atms.constant.enums.FormulaDataSourceType
;
import
pwc.taxtech.atms.dto.vatdto.ReportCellDataSourceDto
;
import
pwc.taxtech.atms.dto.vatdto.ReportCellDataSourceDto
;
import
pwc.taxtech.atms.entity.AccountMapping
;
import
pwc.taxtech.atms.entity.AccountMapping
;
import
pwc.taxtech.atms.entity.AccountMappingExample
;
import
pwc.taxtech.atms.entity.AccountMappingExample
;
...
@@ -59,7 +60,10 @@ public class JFFS extends FunctionBase implements FreeRefFunction {
...
@@ -59,7 +60,10 @@ public class JFFS extends FunctionBase implements FreeRefFunction {
return
NumberEval
.
ZERO
;
return
NumberEval
.
ZERO
;
}
}
AccountMappingExample
accountMappingExample
=
new
AccountMappingExample
();
AccountMappingExample
accountMappingExample
=
new
AccountMappingExample
();
accountMappingExample
.
createCriteria
().
andOrganizationIdEqualTo
(
orgId
).
andEnterpriseAccountSetIdEqualTo
(
enterpriseAccountSetOrgs
.
get
(
0
).
getEnterpriseAccountSetId
());
accountMappingExample
.
createCriteria
().
andOrganizationIdEqualTo
(
orgId
)
.
andEnterpriseAccountSetIdEqualTo
(
enterpriseAccountSetOrgs
.
get
(
0
).
getEnterpriseAccountSetId
())
.
andStandardAccountCodeEqualTo
(
code
);
List
<
AccountMapping
>
accountMappings
=
SpringContextUtil
.
accountMappingMapper
.
selectByExample
(
accountMappingExample
);
List
<
AccountMapping
>
accountMappings
=
SpringContextUtil
.
accountMappingMapper
.
selectByExample
(
accountMappingExample
);
double
result
=
0
;
double
result
=
0
;
...
@@ -109,6 +113,7 @@ public class JFFS extends FunctionBase implements FreeRefFunction {
...
@@ -109,6 +113,7 @@ public class JFFS extends FunctionBase implements FreeRefFunction {
dto
.
setPeriod
(
period
);
dto
.
setPeriod
(
period
);
dto
.
setIsOnlyManualInput
(
Boolean
.
FALSE
);
dto
.
setIsOnlyManualInput
(
Boolean
.
FALSE
);
dto
.
setName
(
Constant
.
DataSourceName
.
ReportDataSource
);
dto
.
setName
(
Constant
.
DataSourceName
.
ReportDataSource
);
dto
.
setType
(
FormulaDataSourceType
.
TrialBalanceSource
.
getCode
());
contain
.
add
(
dto
);
contain
.
add
(
dto
);
}
}
return
temp
.
stream
().
mapToDouble
(
a
->
a
.
getPtdDr
().
doubleValue
()).
sum
();
return
temp
.
stream
().
mapToDouble
(
a
->
a
.
getPtdDr
().
doubleValue
()).
sum
();
...
...
atms-web/src/main/webapp/app/common/controls/preview-trial-balance/preview-trial-balance.ctrl.js
View file @
bcb8d858
...
@@ -157,19 +157,37 @@
...
@@ -157,19 +157,37 @@
if
(
isExportOnly
!==
null
&&
isExportOnly
)
{
if
(
isExportOnly
!==
null
&&
isExportOnly
)
{
$scope
.
exportDataList
=
newTree
;
$scope
.
exportDataList
=
newTree
;
_
.
each
(
$scope
.
exportDataList
,
function
(
exportData
){
_
.
each
(
$scope
.
exportDataList
,
function
(
exportData
){
if
(
exportData
.
begDebitBal
&&
parseFloat
(
exportData
.
begDebitBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
if
(
exportData
.
begDebitBal
&&
parseFloat
(
exportData
.
begDebitBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
{
$scope
.
totalBegDebitBal
+=
parseFloat
(
exportData
.
begDebitBal
.
replace
(
/,/g
,
""
));
$scope
.
totalBegDebitBal
+=
parseFloat
(
exportData
.
begDebitBal
.
replace
(
/,/g
,
""
));
if
(
exportData
.
begCreditBal
&&
parseFloat
(
exportData
.
begCreditBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
exportData
.
begDebitBal
=
parseFloat
(
exportData
.
begDebitBal
.
replace
(
/,/g
,
""
)).
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
if
(
exportData
.
begCreditBal
&&
parseFloat
(
exportData
.
begCreditBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
){
$scope
.
totalBegCreditBal
+=
parseFloat
(
exportData
.
begCreditBal
.
replace
(
/,/g
,
""
));
$scope
.
totalBegCreditBal
+=
parseFloat
(
exportData
.
begCreditBal
.
replace
(
/,/g
,
""
));
if
(
exportData
.
debitBal
&&
parseFloat
(
exportData
.
debitBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
exportData
.
begCreditBal
=
parseFloat
(
exportData
.
begCreditBal
.
replace
(
/,/g
,
""
)).
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
if
(
exportData
.
debitBal
&&
parseFloat
(
exportData
.
debitBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
){
$scope
.
totalDebitBal
+=
parseFloat
(
exportData
.
debitBal
.
replace
(
/,/g
,
""
));
$scope
.
totalDebitBal
+=
parseFloat
(
exportData
.
debitBal
.
replace
(
/,/g
,
""
));
if
(
exportData
.
creditBal
&&
parseFloat
(
exportData
.
creditBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
exportData
.
debitBal
=
parseFloat
(
exportData
.
debitBal
.
replace
(
/,/g
,
""
)).
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
if
(
exportData
.
creditBal
&&
parseFloat
(
exportData
.
creditBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
{
$scope
.
totalCreditBal
+=
parseFloat
(
exportData
.
creditBal
.
replace
(
/,/g
,
""
));
$scope
.
totalCreditBal
+=
parseFloat
(
exportData
.
creditBal
.
replace
(
/,/g
,
""
));
if
(
exportData
.
endDebitBal
&&
parseFloat
(
exportData
.
endDebitBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
exportData
.
creditBal
=
parseFloat
(
exportData
.
creditBal
.
replace
(
/,/g
,
""
)).
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
if
(
exportData
.
endDebitBal
&&
parseFloat
(
exportData
.
endDebitBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
{
$scope
.
totalEndDebitBal
+=
parseFloat
(
exportData
.
endDebitBal
.
replace
(
/,/g
,
""
));
$scope
.
totalEndDebitBal
+=
parseFloat
(
exportData
.
endDebitBal
.
replace
(
/,/g
,
""
));
if
(
exportData
.
endCreditBal
&&
parseFloat
(
exportData
.
endCreditBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
exportData
.
endDebitBal
=
parseFloat
(
exportData
.
endDebitBal
.
replace
(
/,/g
,
""
)).
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
if
(
exportData
.
endCreditBal
&&
parseFloat
(
exportData
.
endCreditBal
.
replace
(
/,/g
,
""
)).
toString
()
!=
"NaN"
)
{
$scope
.
totalEndCreditBal
+=
parseFloat
(
exportData
.
endCreditBal
.
replace
(
/,/g
,
""
));
$scope
.
totalEndCreditBal
+=
parseFloat
(
exportData
.
endCreditBal
.
replace
(
/,/g
,
""
));
})
exportData
.
endCreditBal
=
parseFloat
(
exportData
.
endCreditBal
.
replace
(
/,/g
,
""
)).
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
});
$scope
.
totalEndCreditBal
=
$scope
.
totalEndCreditBal
.
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
$scope
.
totalEndDebitBal
=
$scope
.
totalEndDebitBal
.
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
$scope
.
totalCreditBal
=
$scope
.
totalCreditBal
.
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
$scope
.
totalDebitBal
=
$scope
.
totalDebitBal
.
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
$scope
.
totalBegCreditBal
=
$scope
.
totalBegCreditBal
.
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
$scope
.
totalBegDebitBal
=
$scope
.
totalBegDebitBal
.
toFixed
(
2
).
replace
(
/
(\d)(?=(\d{3})
+
\.)
/g
,
'$1,'
);
}
}
else
{
else
{
$scope
.
gridOptions
.
data
=
newTree
;
$scope
.
gridOptions
.
data
=
newTree
;
...
...
atms-web/src/main/webapp/app/common/controls/preview-trial-balance/preview-trial-balance.html
View file @
bcb8d858
...
@@ -101,12 +101,12 @@
...
@@ -101,12 +101,12 @@
<tr
ng-repeat=
"exportData in exportDataList"
on-finish-render=
"ngRepeatFinished"
>
<tr
ng-repeat=
"exportData in exportDataList"
on-finish-render=
"ngRepeatFinished"
>
<td>
{{exportData.acctCode}}
</td>
<td>
{{exportData.acctCode}}
</td>
<td>
{{exportData.accountName}}
</td>
<td>
{{exportData.accountName}}
</td>
<td>
{{exportData.begDebitBal}}
</td>
<td
style=
"text-align:right;"
>
{{exportData.begDebitBal}}
</td>
<td>
{{exportData.begCreditBal}}
</td>
<td
style=
"text-align:right;"
>
{{exportData.begCreditBal}}
</td>
<td>
{{exportData.debitBal}}
</td>
<td
style=
"text-align:right;"
>
{{exportData.debitBal}}
</td>
<td>
{{exportData.creditBal}}
</td>
<td
style=
"text-align:right;"
>
{{exportData.creditBal}}
</td>
<td>
{{exportData.endDebitBal}}
</td>
<td
style=
"text-align:right;"
>
{{exportData.endDebitBal}}
</td>
<td>
{{exportData.endCreditBal}}
</td>
<td
style=
"text-align:right;"
>
{{exportData.endCreditBal}}
</td>
</tr>
</tr>
<tr>
<tr>
<td></td>
<td></td>
...
...
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