Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
P
precision-effect
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
耿迪迪
precision-effect
Commits
1f684b63
Commit
1f684b63
authored
Aug 25, 2023
by
耿迪迪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
应还款金额计算修改
parent
ced17d1d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
2 deletions
+10
-2
SettlementDebit.java
.../system/service/impl/debitSettlement/SettlementDebit.java
+3
-1
CommonInfo.vue
...sion-effect-web/src/views/debit/components/CommonInfo.vue
+7
-1
No files found.
precision-effect-system/src/main/java/com/zehong/system/service/impl/debitSettlement/SettlementDebit.java
View file @
1f684b63
...
...
@@ -54,7 +54,9 @@ public class SettlementDebit {
public
void
repayment
(
TDebitCredit
tDebitCredit
){
this
.
tDebitCredit
=
tDebitCredit
;
//计算还款日期
long
time
=
tDebitCredit
.
getExpectedRepaymentDate
().
getTime
()
-
tDebitCredit
.
getSumInterestDate
().
getTime
();
//long time = tDebitCredit.getExpectedRepaymentDate().getTime() - tDebitCredit.getSumInterestDate().getTime();
//2023-08-25 修改为根据实际还款日计算
long
time
=
new
Date
().
getTime
()
-
tDebitCredit
.
getSumInterestDate
().
getTime
();
long
days
=
Math
.
round
(((
double
)
time
)
/
1000
/
60
/
60
/
24
);
//还款部门
BigDecimal
repayAmount
=
tDebitCredit
.
getLittleTotal
().
multiply
(
new
BigDecimal
(
1
+
0.08
/
360
*
days
)).
setScale
(
2
,
RoundingMode
.
HALF_UP
);
...
...
precision-effect-web/src/views/debit/components/CommonInfo.vue
View file @
1f684b63
...
...
@@ -61,9 +61,10 @@
</el-form-item>
</el-col>
<el-col
:span=
"12"
>
<el-form-item
label=
"
应还
金额"
>
{{
payable
()
}}
</el-form-item>
<el-form-item
label=
"
预计还款
金额"
>
{{
payable
()
}}
</el-form-item>
</el-col>
</el-row>
<el-form-item
label=
"应还金额"
v-if=
"debitData.debitStatus == '2'"
>
{{
realPayable
()
}}
</el-form-item>
<el-form-item
label=
"备注"
>
{{
debitData
.
remark
==
null
?
"-"
:
debitData
.
remark
}}
</el-form-item>
<el-divider></el-divider>
</el-form>
...
...
@@ -124,6 +125,11 @@
let
time
=
new
Date
(
this
.
debitData
.
expectedRepaymentDate
).
getTime
()
/
1000
-
new
Date
(
this
.
debitData
.
sumInterestDate
).
getTime
()
/
1000
;
let
day
=
Math
.
round
(
time
/
60
/
60
/
24
);
return
(
this
.
debitData
.
littleTotal
*
(
1
+
0.08
/
360
*
day
)).
toFixed
(
2
);
},
realPayable
(){
let
time
=
new
Date
().
getTime
()
/
1000
-
new
Date
(
this
.
debitData
.
sumInterestDate
).
getTime
()
/
1000
;
let
day
=
Math
.
round
(
time
/
60
/
60
/
24
);
return
(
this
.
debitData
.
littleTotal
*
(
1
+
0.08
/
360
*
day
)).
toFixed
(
2
);
}
}
}
...
...
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