Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
K
komatsu-lease-app
Project
Project
Details
Activity
Releases
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
komatsu
komatsu-lease-app
Commits
3647d0ac
Commit
3647d0ac
authored
Dec 05, 2022
by
Step_by_step
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 还款计划查询
parent
360a3ad0
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
288 additions
and
15 deletions
+288
-15
ListItem.vue
src/components/ListItem.vue
+1
-1
index.js
src/modules/calculator/store/index.js
+13
-5
detail.vue
src/modules/calculator/views/detail.vue
+30
-9
index.js
src/modules/repayPlan/api/index.js
+13
-0
index.js
src/modules/repayPlan/store/index.js
+14
-0
plan.vue
src/modules/repayPlan/views/plan.vue
+217
-0
No files found.
src/components/ListItem.vue
View file @
3647d0ac
...
...
@@ -63,7 +63,7 @@ defineEmits(['clickRight', 'click'])
padding: 8px 8px;
}
.
box+.box
{
.
swipe + .swipe
{
margin-top: 20px;
}
...
...
src/modules/calculator/store/index.js
View file @
3647d0ac
const
state
=
{};
import
{
ref
,
computed
}
from
'vue'
import
{
defineStore
}
from
'pinia'
export
default
{
namespaced
:
true
,
state
,
};
export
const
useCounterStore
=
defineStore
(
'counter'
,
()
=>
{
const
count
=
ref
(
0
)
const
doubleCount
=
computed
(()
=>
count
.
value
*
2
)
function
increment
()
{
count
.
value
++
}
return
{
count
,
doubleCount
,
increment
}
})
src/modules/calculator/views/detail.vue
View file @
3647d0ac
...
...
@@ -18,7 +18,7 @@
<
script
setup
>
import
{
goBack
}
from
"@/utils/globalFun"
import
{
NavBar
,
Button
}
from
"vant"
;
import
{
NavBar
,
Button
,
Toast
}
from
"vant"
;
import
Notice
from
"@/components/Notice.vue"
import
AuForm
from
'@/components/AuForm.vue'
;
import
AuFormClass
from
"@/components/useAuForm"
;
...
...
@@ -28,36 +28,37 @@ const form = $ref();
const
formConfig
=
$ref
(
new
AuFormClass
([
{
title
:
'物件价格'
,
propName
:
'p
aymentReqDat
e'
,
propName
:
'p
ric
e'
,
type
:
'currency'
,
value
:
''
,
isRequired
:
true
isRequired
:
true
,
},
{
title
:
'还款方式'
,
propName
:
'pay
mentRe3qDat3
e'
,
propName
:
'pay
Typ
e'
,
type
:
'cell'
,
value
:
''
,
value
:
'
均等还款
'
,
isRequired
:
true
,
select
:
[],
disabled
:
true
},
{
title
:
'融资租期(月)'
,
propName
:
'
paymentReqDat3e
'
,
propName
:
'
leaseTermMonth
'
,
type
:
'digit'
,
value
:
''
,
isRequired
:
true
},
{
title
:
'首付款比例'
,
propName
:
'
paymentReqDat3e
'
,
propName
:
'
firstPaymentRatio
'
,
type
:
'rate'
,
value
:
''
,
isRequired
:
true
},
{
title
:
'首付租金日'
,
propName
:
'
paymentReqDat3
e'
,
propName
:
'
firstPaymentDat
e'
,
type
:
'cell'
,
value
:
''
,
isRequired
:
true
,
...
...
@@ -65,9 +66,29 @@ const formConfig = $ref(new AuFormClass([
},
]))
const
checkValues
=
(
values
)
=>
{
if
(
+
values
.
price
<=
0
)
{
Toast
({
message
:
'请输入正确的物件价格'
,
position
:
'top'
});
return
false
;
}
else
if
(
values
.
firstPaymentRatio
>
1
)
{
Toast
({
message
:
'请输入正确首付款比例'
,
position
:
'top'
});
return
false
;
}
return
true
;
}
const
router
=
useRouter
();
const
computing
=
()
=>
{
router
.
push
({
name
:
'calculator-views-plan'
})
if
(
formConfig
.
validate
())
{
let
formValueObj
=
formConfig
.
getValues
()
let
validateValue
=
checkValues
(
formValueObj
)
if
(
validateValue
)
{
router
.
push
({
name
:
'calculator-views-plan'
})
}
}
else
{
Toast
({
message
:
'请将信息填写完整'
,
position
:
'top'
});
}
}
</
script
>
...
...
src/modules/repayPlan/api/index.js
0 → 100644
View file @
3647d0ac
import
{
get
,
put
,
post
,
File
,
deleteReq
}
from
'@/utils/http'
const
baseURL
=
import
.
meta
.
env
.
VITE_HTTP_BASE_URL
const
api
=
{
// getMakingList (data) { // 查询合同制作列表
// return get(
// `${baseURL}/hlct/v1/0/contracts/toMake`,
// {...data}
// )
// },
};
export
default
api
;
src/modules/repayPlan/store/index.js
0 → 100644
View file @
3647d0ac
import
{
ref
,
computed
}
from
'vue'
import
{
defineStore
}
from
'pinia'
export
const
useCounterStore
=
defineStore
(
'counter'
,
()
=>
{
const
count
=
ref
(
0
)
const
doubleCount
=
computed
(()
=>
count
.
value
*
2
)
function
increment
()
{
count
.
value
++
}
return
{
count
,
doubleCount
,
increment
}
})
src/modules/repayPlan/views/plan.vue
0 → 100644
View file @
3647d0ac
<
template
>
<RepayPlan
navTitle=
"还款计划"
:currencyObj=
"currencyObj"
>
<template
#
list
>
<div
class=
"repay_list"
>
<div
class=
"left"
>
<div
class=
"times-box"
v-for=
"i in 30"
>
<div
class=
"times"
>
{{
i
}}
期
</div>
</div>
</div>
<div
class=
"right"
>
<div
class=
"item"
v-for=
"i in 30"
>
<div
class=
"left-item"
>
<span>
租金
</span>
<span>
2022-06-20
</span>
</div>
<div
class=
"center-item"
>
<p>
<span>
应付金额
</span>
<span>
¥9,000.00
</span>
</p>
<p>
<span>
待付金额
</span>
<span>
¥0.00
</span>
</p>
</div>
<div
class=
"right-item"
>
<span>
明细
</span>
<span
class=
"flag-button overtime"
>
<Icon
style=
"margin-right: 1px;"
name=
"info-o"
/>
逾期
</span>
</div>
</div>
</div>
</div>
</
template
>
<
template
#
footer
>
</
template
>
</RepayPlan>
</template>
<
script
setup
>
import
RepayPlan
from
'@/components/RepayPlan.vue'
import
{
Icon
}
from
'vant'
const
currencyObj
=
$ref
({
financingCurrency
:
'200,000.00'
,
headerCurrency
:
'5,000.00'
,
fristCurrency
:
'10,000.00'
,
times
:
'12'
})
</
script
>
<
style
lang=
"less"
scoped
>
@lineColr: #dcdddf;
.repay_list {
display: flex;
width: 100%;
height: 98%;
overflow-y: auto;
scrollbar-width: none;
/* firefox */
}
.repay_list::-webkit-scrollbar {
display: none;
/* Chrome Safari */
}
@leftW: 45px;
.left {
flex: 0 1 @leftW;
}
.times-box {
display: flex;
height: 100px;
flex-direction: column;
justify-content: center;
background-image: linear-gradient(@lineColr 0%, @lineColr 16%, transparent 16%, transparent 33%, @lineColr 33%, @lineColr 83%, transparent 83%, transparent 100%);
/* 35%设置虚线点y轴上的长度 */
background-position: 50% 50%;
/* right配置右边框位置的虚线 */
background-size: 1px 20px;
/* 第一个参数设置虚线点x轴上的长度;第二个参数设置虚线点的间距 */
background-repeat: repeat-y;
}
.times-box:nth-child(1) {
margin-top: 25px;
height: 70px;
justify-content: flex-start;
}
.times-box:nth-last-child(1) {
// bottom: 80px;
height: 70px;
justify-content: flex-end;
}
.times {
height: @leftW;
width: @leftW;
display: flex;
justify-content: center;
line-height: @leftW;
color: #fff;
background-color: #019ae5;
border-radius: 5px;
}
.right {
flex: 1 0 auto;
padding-left: 20px;
}
.item {
display: flex;
justify-content: space-around;
box-sizing: border-box;
margin-top: 15px;
margin-bottom: 30px;
width: 98%;
height: 70px;
border: 1px solid #dedede;
background-color: #eef5fd;
border-radius: 5px;
padding: 10px 5px 3px 10px;
font-size: 13px;
&>div {
display: flex;
flex-direction: column;
justify-content: space-around;
}
}
.left-item {
flex: 1 0 30%;
span:nth-child(1) {
font-weight: 600;
}
span:nth-child(2) {
color: gray;
}
}
.center-item {
flex: 1 0 45%;
p {
color: gray;
display: flex;
justify-content: space-between;
span:nth-child(2) {
font-weight: 600;
}
}
&>p:nth-child(1) span:nth-child(2) {
color: #019ae5;
}
}
.right-item {
flex: 1 0 25%;
text-align: center;
span:nth-child(1) {
color: #019ae5;
}
span:nth-child(2) {
color: gray;
}
}
.flag-button {
display: flex;
justify-content: center;
align-items: center;
width: 80%;
margin: 0 auto;
height: 40%;
border-radius: 10px;
font-size: 12px;
}
.overtime {
background-color: #eeeeee;
color: orange !important;
border: 1px solid #e2e3e4;
}
.nopay {
background-color: #bec2c5;
color: white !important;
border: 1px solid #bec2c5;
}
.pay {
background-color: #f0f0f0;
color: gray !important;
border: 1px solid #eaeaea;
}
</
style
>
\ 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