Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fns_front_2
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
chenqikuai
fns_front_2
Commits
0cfc2f1e
Commit
0cfc2f1e
authored
Oct 12, 2021
by
lshan
Browse files
Options
Browse Files
Download
Plain Diff
合并
parents
f00a14c4
420f553a
Hide whitespace changes
Inline
Side-by-side
Showing
15 changed files
with
240 additions
and
101 deletions
+240
-101
index.vue
src/components/Loan/LoanHotSwipe/index.vue
+16
-9
type.ts
src/components/Loan/LoanHotSwipe/type.ts
+3
-1
branch.vue
src/components/Mine/Branch/branch.vue
+35
-17
index.vue
src/components/NavBar/index.vue
+2
-2
loanModeStore.ts
src/store/loanModeStore.ts
+15
-0
loanSearchResultStore.ts
src/store/loanSearchResultStore.ts
+11
-0
displayName.ts
src/utils/displayName.ts
+1
-1
ChatInput.vue
src/views/Chat/ChatInput.vue
+17
-2
index.vue
src/views/LoanDetail/index.vue
+32
-20
index.vue
src/views/LoanList/index.vue
+40
-17
index.vue
src/views/withMenu/Home/index.vue
+10
-7
index.vue
src/views/withMenu/Loan/index.vue
+52
-22
types.ts
src/views/withMenu/Loan/types.ts
+3
-1
branch.vue
src/views/withMenu/Mine/branch.vue
+2
-2
tailwind.config.js
tailwind.config.js
+1
-0
No files found.
src/components/Loan/LoanHotSwipe/index.vue
View file @
0cfc2f1e
...
@@ -60,20 +60,27 @@ const fetchList = () => {
...
@@ -60,20 +60,27 @@ const fetchList = () => {
skeLoading
.
value
=
false
;
skeLoading
.
value
=
false
;
ret
.
data
.
uuid
.
map
((
uuid
)
=>
{
ret
.
data
.
uuid
.
map
((
uuid
)
=>
{
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
const
{
rate_lower
,
max_amount
,
max_date
,
inst_name
,
product_name
}
=
const
{
rate_lower
,
max_amount
,
max_date
,
inst_name
,
product_name
,
product_status
}
=
ret
.
data
;
ret
.
data
;
state
.
hotProductList
.
push
({
console
.
log
(
'status'
,
product_status
);
rate_lower
,
max_amount
,
if
(
product_status
==
3
){
max_date
,
state
.
hotProductList
.
push
({
inst_name
,
rate_lower
,
product_name
,
max_amount
,
uuid
,
max_date
,
});
inst_name
,
product_name
,
uuid
,
product_status
});
}
});
});
});
});
}
}
});
});
console
.
log
(
'pro'
,
state
.
hotProductList
);
};
};
</
script
>
</
script
>
...
...
src/components/Loan/LoanHotSwipe/type.ts
View file @
0cfc2f1e
...
@@ -4,5 +4,6 @@ export interface hotProduct{
...
@@ -4,5 +4,6 @@ export interface hotProduct{
max_date
:
number
max_date
:
number
inst_name
:
string
inst_name
:
string
product_name
:
string
,
product_name
:
string
,
uuid
:
string
uuid
:
string
,
product_status
:
number
}
}
\ No newline at end of file
src/components/Mine/Branch/branch.vue
View file @
0cfc2f1e
...
@@ -30,23 +30,41 @@
...
@@ -30,23 +30,41 @@
</div>
</div>
<div
class=
"border border-blue-50"
></div>
<div
class=
"border border-blue-50"
></div>
<!-- 营业时间 -->
<!-- 营业时间 -->
<div
class=
"mt-2 pb-3"
>
<div
class=
"mt-2 pb-3 flex justify-between items-center"
>
<template
v-if=
"is_normal_work"
>
<div
class=
"overflow-hidden mr-6"
>
<icon
<div
v-if=
"is_normal_work"
class=
"mb-2"
>
name=
"icon-yingye"
<icon
color=
"#1B1F37"
name=
"icon-yingye"
size=
"14"
color=
"#1B1F37"
class=
"inline-block align-middle mr-3"
size=
"14"
/>
class=
"inline-block align-middle mr-3"
<span
/>
v-if=
"isOpen"
<span
class=
"text-app-blue border border-app-blue bg-indigo-100 text-xs px-2 rounded"
v-if=
"isOpen"
>
营业中
</span>
class=
"text-app-blue border border-app-blue bg-indigo-100 text-xs px-2 rounded"
<span
>
营业中
</span>
v-else
<span
class=
"text-app-blue border border-app-blue bg-indigo-100 text-xs px-2 rounded"
v-else
>
休息中
</span>
class=
"text-app-blue border border-app-blue bg-indigo-100 text-xs px-2 rounded"
</
template
>
>
休息中
</span>
</div>
<div
v-if=
"is_normal_work"
>
<icon
name=
"icon-a-shijian"
color=
"#1B1F37"
size=
"14"
class=
"inline-block align-text-top mr-3"
/>
<span
class=
"text-gray-400 text-sm inline-block align-top"
>
{{
weekDays
}}
丨
{{
dailyTime
}}
</span>
</div>
<template
v-else
>
<!--
<div
class=
"text-red"
>
{{
error
}}
</div>
-->
<div
class=
"text-red"
>
{{
errorReason
}}
</div>
</
template
>
</div>
<div
class=
"text-right h-3"
>
<div
class=
"text-right h-3"
>
<icon
<icon
name=
"icon-ditu"
name=
"icon-ditu"
...
...
src/components/NavBar/index.vue
View file @
0cfc2f1e
<
template
>
<
template
>
<div
class=
"navbar w-full"
style=
"z-index: 300"
>
<div
class=
"navbar w-full"
style=
"z-index: 300"
>
<div
<div
class=
"h-full theBar flex items-center px-5 justify-center relative
"
class=
"h-full theBar flex items-center px-5 justify-center relative"
style=
"background:#F7F7FA"
style=
"background:#F7F7FA"
v-bind=
"$attrs"
v-bind=
"$attrs"
>
>
...
@@ -30,7 +30,7 @@
...
@@ -30,7 +30,7 @@
@
click=
"$router.push(path)"
@
click=
"$router.push(path)"
:color=
"iconColor"
:color=
"iconColor"
/>
/>
<div
class=
"title"
>
{{
title
}}
</div>
<div
class=
"title
whitespace-nowrap overflow-hidden overflow-ellipsis px-5
"
>
{{
title
}}
</div>
</div>
</div>
</div>
</div>
<div
class=
"some-block"
v-if=
"occupyPosition"
></div>
<div
class=
"some-block"
v-if=
"occupyPosition"
></div>
...
...
src/store/loanModeStore.ts
0 → 100644
View file @
0cfc2f1e
import
{
reactive
}
from
"vue"
import
{
eLoanMode
}
from
"@/views/withMenu/Loan/types"
export
const
loanMode
=
{
state
:
reactive
({
mode
:
eLoanMode
.
personal
}),
setModeAction
(
newV
:
eLoanMode
)
{
this
.
state
.
mode
=
newV
console
.
log
(
'newV'
,
newV
);
}
}
\ No newline at end of file
src/store/loanSearchResultStore.ts
0 → 100644
View file @
0cfc2f1e
import
{
simpleItemInfo
}
from
"@/views/withMenu/Loan/types"
import
{
reactive
}
from
"@vue/reactivity"
export
const
loanSearchState
=
reactive
({
result
:
[]
as
simpleItemInfo
[]
})
export
function
setSearchResult
(
newV
:
simpleItemInfo
)
{
loanSearchState
.
result
.
push
(
newV
)
}
export
function
clearSearchResult
()
{
loanSearchState
.
result
=
[]
}
src/utils/displayName.ts
View file @
0cfc2f1e
...
@@ -51,7 +51,7 @@ export const getDisplayNamesFromAddress = async (
...
@@ -51,7 +51,7 @@ export const getDisplayNamesFromAddress = async (
return
addressList
.
map
((
item
)
=>
{
return
addressList
.
map
((
item
)
=>
{
const
msg
=
fullList
.
find
((
i
:
any
)
=>
i
?.
addr
===
item
)
const
msg
=
fullList
.
find
((
i
:
any
)
=>
i
?.
addr
===
item
)
if
(
msg
?.
out_let_name
)
{
if
(
msg
?.
out_let_name
)
{
return
msg
?.
out_let_name
+
'客服经理'
return
msg
?.
out_let_name
+
msg
.
user_name
}
else
{
}
else
{
return
msg
?.
phone
return
msg
?.
phone
}
}
...
...
src/views/Chat/ChatInput.vue
View file @
0cfc2f1e
...
@@ -58,6 +58,7 @@ import Icon from "@/components/common/Icon.vue";
...
@@ -58,6 +58,7 @@ import Icon from "@/components/common/Icon.vue";
import
{
useRoute
}
from
"vue-router"
;
import
{
useRoute
}
from
"vue-router"
;
import
{
getUserMsg
}
from
"@/utils/userMsg"
;
import
{
getUserMsg
}
from
"@/utils/userMsg"
;
import
{
eRole
}
from
"@/types/roleType"
;
import
{
eRole
}
from
"@/types/roleType"
;
import
ChatDBService
from
"@/db/ChatDBService"
;
export
default
defineComponent
({
export
default
defineComponent
({
props
:
{
props
:
{
...
@@ -117,8 +118,7 @@ export default defineComponent({
...
@@ -117,8 +118,7 @@ export default defineComponent({
console
.
log
(
'handle send'
);
console
.
log
(
'handle send'
);
const
isStaff
=
getUserMsg
()?.
role
===
eRole
.
staff
;
const
isStaff
=
getUserMsg
()?.
role
===
eRole
.
staff
;
const
isUser
=
getUserMsg
()?.
role
===
eRole
.
user
;
const
isUser
=
getUserMsg
()?.
role
===
eRole
.
user
;
console
.
log
(
isStaff
,
'isStaff'
);
if
(
isUser
&&
props
.
serviceShowValue
===
"人工服务"
)
{
if
(
isUser
&&
props
.
serviceShowValue
===
"人工服务"
)
{
messageStore
.
displayNewMessage
({
messageStore
.
displayNewMessage
({
content
:
{
content
:
{
...
@@ -131,6 +131,21 @@ export default defineComponent({
...
@@ -131,6 +131,21 @@ export default defineComponent({
datetime
:
new
Date
().
getTime
(),
datetime
:
new
Date
().
getTime
(),
type
:
ChatMessageTypes
.
robot
,
type
:
ChatMessageTypes
.
robot
,
})
})
ChatDBService
.
getInstance
().
handleEveryReceive
({
msg
:
{
content
:
{
content
:
inputText
.
value
},
from
:
getFromId
()
as
string
,
target
:
target
,
uuid
:
uuidv4
(),
state
:
'success'
,
datetime
:
new
Date
().
getTime
(),
type
:
ChatMessageTypes
.
robot
,
},
masterId
:
getFromId
()
as
string
,
isChattingWithTargetId
:
true
,
})
textInputStore
.
clearTextMessage
();
textInputStore
.
clearTextMessage
();
}
else
{
}
else
{
sendChatMessage
({
type
:
1
,
content
:
{
content
:
inputText
.
value
}
})
sendChatMessage
({
type
:
1
,
content
:
{
content
:
inputText
.
value
}
})
...
...
src/views/LoanDetail/index.vue
View file @
0cfc2f1e
...
@@ -233,28 +233,31 @@ export default defineComponent({
...
@@ -233,28 +233,31 @@ export default defineComponent({
<
span
class
=
"word8"
>
产品详情
<
/span
>
<
span
class
=
"word8"
>
产品详情
<
/span
>
<
img
class
=
"label6"
src
=
{
leftBg
}
/
>
<
img
class
=
"label6"
src
=
{
leftBg
}
/
>
<
/div
>
<
/div
>
<
div
class
=
"block10 flex"
>
<
div
class
=
" bg-white mx-5 rounded-2xl overflow-hidden mt-5"
>
<
div
class
=
"group6 flex-col"
>
<
div
class
=
"flex justify-between text-sm text-gray-800 border-b border-product-detail-bg"
>
<
div
class
=
"wrap3 flex-col"
>
<
span
class
=
" w-100 align-center bg-product-detail-bg py-4 inline-block text-center"
>
贷款机构
<
/span>
<
span
class
=
"txt11"
>
贷款机构
<
/span
>
<
span
class
=
" w-235 py-4 pr-5 inline-block break-words text-right"
>
{
inst_name
.
value
}
<
/span
>
<
span
class
=
"info15"
>
产品名称
<
/span
>
<
span
class
=
"word20"
>
贷款利率
<
/span
>
<
span
class
=
"txt12"
>
贷款额度
<
/span
>
<
span
class
=
"txt13"
>
贷款期限
<
/span
>
<
span
class
=
"txt14"
>
担保方式
<
/span
>
<
/div
>
<
/div
>
<
/div
>
<
div
class
=
"flex justify-between text-sm text-gray-800 border-b border-product-detail-bg"
>
<
div
class
=
"section4 flex-row"
>
<
span
class
=
" w-100 align-center bg-product-detail-bg py-4 inline-block text-center"
>
产品名称
<
/span
>
<
div
class
=
"mod1 flex-col"
/>
<
span
class
=
" w-235 py-4 pr-5 inline-block break-words text-right"
>
{
product_name
.
value
}
<
/span
>
<
div
class
=
"mod2 flex-col w-full text-right"
>
<
span
class
=
"info8"
>
{
inst_name
.
value
}
<
/span
>
<
span
class
=
"info9"
>
{
product_name
.
value
}
<
/span
>
<
span
class
=
"info10"
>
{
rate_lower
.
value
}
%~
{
rate_upper
.
value
}
%<
/span
>
<
span
class
=
"info11"
>
{
min_amount
.
value
}
万
~
{
max_amount
.
value
}
万
<
/span
>
<
span
class
=
"word9"
>
{
min_date
.
value
}
个月
~
{
max_date
.
value
}
个月
<
/span
>
<
span
class
=
"info12"
>
{
filterGuaranteeType
(
guarantee_type
.
value
)}
<
/span
>
<
/div
>
<
/div
>
<
/div
>
<
div
class
=
"flex text-sm text-gray-800 border-b border-product-detail-bg justify-between"
>
<
span
class
=
" w-100 align-center bg-product-detail-bg py-4 inline-block text-center"
>
贷款利率
<
/span>
<
span
class
=
" w-235 py-4 pr-5 inline-block break-words text-right"
>
{
rate_lower
.
value
}
%~
{
rate_upper
.
value
}
%<
/span
>
<
/div
>
<
div
class
=
"flex text-sm text-gray-800 border-b border-product-detail-bg justify-between"
>
<
span
class
=
" w-100 align-center bg-product-detail-bg py-4 inline-block text-center"
>
贷款额度
<
/span>
<
span
class
=
" w-235 py-4 pr-5 inline-block break-words text-right"
>
{
min_amount
.
value
}
万
~
{
max_amount
.
value
}
万
<
/span
>
<
/div
>
<
div
class
=
"flex text-sm text-gray-800 border-b border-product-detail-bg justify-between"
>
<
span
class
=
" w-100 align-center bg-product-detail-bg py-4 inline-block text-center"
>
贷款期限
<
/span>
<
span
class
=
" w-235 py-4 pr-5 inline-block break-words text-right"
>
{
min_date
.
value
}
个月
~
{
max_date
.
value
}
个月
<
/span
>
<
/div
>
<
div
class
=
"flex text-sm text-gray-800 border-b border-product-detail-bg justify-between"
>
<
span
class
=
" w-100 align-center bg-product-detail-bg py-4 inline-block text-center"
>
担保方式
<
/span>
<
span
class
=
" w-235 py-4 pr-5 inline-block break-words text-right"
>
{
filterGuaranteeType
(
guarantee_type
.
value
)}
<
/span
>
<
/div>
<
/div
>
<
/div
>
<
LoanDetailDescribe
class
=
" mt-5"
products
=
{
products
.
value
}
features
=
{
features
.
value
}
apply_to
=
{
apply_to
.
value
}
apply_cond
=
{
apply_cond
.
value
}
submit_cond
=
{
submit_cond
.
value
}
/
>
<
LoanDetailDescribe
class
=
" mt-5"
products
=
{
products
.
value
}
features
=
{
features
.
value
}
apply_to
=
{
apply_to
.
value
}
apply_cond
=
{
apply_cond
.
value
}
submit_cond
=
{
submit_cond
.
value
}
/
>
<
div
class
=
"title mx-5 mt-5"
>
营业网点
<
/div
>
<
div
class
=
"title mx-5 mt-5"
>
营业网点
<
/div
>
...
@@ -294,6 +297,7 @@ export default defineComponent({
...
@@ -294,6 +297,7 @@ export default defineComponent({
},
},
});
});
</
script
>
</
script
>
<
style
lang=
"less"
scoped
>
<
style
lang=
"less"
scoped
>
@import "./index.less";
@import "./index.less";
.title {
.title {
...
@@ -309,4 +313,11 @@ export default defineComponent({
...
@@ -309,4 +313,11 @@ export default defineComponent({
font-weight: 600;
font-weight: 600;
color: #ffffff;
color: #ffffff;
}
}
.w-100{
width:100px;
}
.w-235{
width:235px;
}
</
style
>
</
style
>
\ No newline at end of file
src/views/LoanList/index.vue
View file @
0cfc2f1e
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
@
load=
"onLoad"
@
load=
"onLoad"
>
>
<LoanCard
<LoanCard
v-for=
"item in state
.list
"
v-for=
"item in state"
:key=
"item.value"
:key=
"item.value"
:max_amount=
"item.max_amount"
:max_amount=
"item.max_amount"
:product_name=
"item.product_name"
:product_name=
"item.product_name"
...
@@ -67,9 +67,16 @@ import GroupTitle from "@/components/GroupTitle/index.vue";
...
@@ -67,9 +67,16 @@ import GroupTitle from "@/components/GroupTitle/index.vue";
import
PopUp
from
"@/components/PopUp/index.vue"
;
import
PopUp
from
"@/components/PopUp/index.vue"
;
import
LoanFilter
from
"@/components/PopUpContent/LoanFilter/index.vue"
;
import
LoanFilter
from
"@/components/PopUpContent/LoanFilter/index.vue"
;
import
LoanCard
from
"@/components/Loan/LoanCard/index.vue"
;
import
LoanCard
from
"@/components/Loan/LoanCard/index.vue"
;
import
{
defineComponent
,
ref
,
computed
,
onMounted
,
reactive
}
from
"vue"
;
import
{
defineComponent
,
ref
,
computed
,
onMounted
,
reactive
,
onUnmounted
,
}
from
"vue"
;
import
{
queryDirectLoanReq
}
from
"@/service/LoanProductService/index"
;
import
{
queryDirectLoanReq
}
from
"@/service/LoanProductService/index"
;
import
{
useRoute
}
from
"vue-router"
;
import
{
useRoute
,
useRouter
}
from
"vue-router"
;
import
{
import
{
queryLoanProductList
,
queryLoanProductList
,
queryLoanProductInfo
,
queryLoanProductInfo
,
...
@@ -78,6 +85,11 @@ import {
...
@@ -78,6 +85,11 @@ import {
import
{
simpleItemInfo
}
from
"@/views/withMenu/Loan/types"
;
import
{
simpleItemInfo
}
from
"@/views/withMenu/Loan/types"
;
import
{
iLoanProdcutItem
}
from
"@/service/LoanProductService/type"
;
import
{
iLoanProdcutItem
}
from
"@/service/LoanProductService/type"
;
import
{
Skeleton
}
from
"vant"
;
import
{
Skeleton
}
from
"vant"
;
import
{
loanSearchState
,
setSearchResult
,
clearSearchResult
,
}
from
"@/store/loanSearchResultStore"
;
export
default
defineComponent
({
export
default
defineComponent
({
components
:
{
components
:
{
...
@@ -90,9 +102,20 @@ export default defineComponent({
...
@@ -90,9 +102,20 @@ export default defineComponent({
},
},
setup
()
{
setup
()
{
const
mode
=
ref
(
+
useRoute
().
params
.
mode
);
const
mode
=
ref
(
+
useRoute
().
params
.
mode
);
onMounted
(()
=>
{
onMounted
(()
=>
{
fetchList
();
/* 状态为空时获取list */
fetchBanks
();
if
(
loanSearchState
.
result
.
length
==
0
)
{
fetchList
();
fetchBanks
();
}
});
onUnmounted
(()
=>
{
/* 返回Loan主页时需清空list */
if
(
useRoute
().
name
===
"Loan"
)
{
clearSearchResult
()
}
});
});
const
onLoad
=
()
=>
{
const
onLoad
=
()
=>
{
...
@@ -112,8 +135,8 @@ export default defineComponent({
...
@@ -112,8 +135,8 @@ export default defineComponent({
const
loading
=
ref
(
false
);
const
loading
=
ref
(
false
);
const
finished
=
ref
(
false
);
const
finished
=
ref
(
false
);
const
total
=
ref
(
0
);
const
total
=
ref
(
0
);
let
state
=
reactive
(
{
const
state
=
computed
(()
=>
{
list
:
[]
as
simpleItemInfo
[],
return
loanSearchState
.
result
;
});
});
const
bankList
=
computed
(()
=>
{
const
bankList
=
computed
(()
=>
{
...
@@ -136,7 +159,7 @@ export default defineComponent({
...
@@ -136,7 +159,7 @@ export default defineComponent({
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
const
{
max_amount
,
inst_name
,
uuid
,
features
,
product_name
}
=
const
{
max_amount
,
inst_name
,
uuid
,
features
,
product_name
}
=
ret
.
data
;
ret
.
data
;
s
tate
.
list
.
push
({
s
etSearchResult
({
max_amount
,
max_amount
,
product_name
,
product_name
,
features
,
features
,
...
@@ -158,6 +181,7 @@ export default defineComponent({
...
@@ -158,6 +181,7 @@ export default defineComponent({
}
}
});
});
};
};
return
{
return
{
mode
,
mode
,
state
,
state
,
...
@@ -262,10 +286,10 @@ export default defineComponent({
...
@@ -262,10 +286,10 @@ export default defineComponent({
queryList
()
{
queryList
()
{
this
.
loading
=
true
;
this
.
loading
=
true
;
queryDirectLoanReq
({
queryDirectLoanReq
({
rate_lower
:
+
this
.
reqParams
.
min
!
,
rate_lower
:
+
this
.
reqParams
.
min
!
?
+
this
.
reqParams
.
min
!
:
0
,
rate_upper
:
+
this
.
reqParams
.
max
!
,
rate_upper
:
+
this
.
reqParams
.
max
!
?
+
this
.
reqParams
.
max
!
:
1000
,
min_amount
:
+
this
.
reqParams
.
min2
!
,
min_amount
:
+
this
.
reqParams
.
min2
!
?
+
this
.
reqParams
.
min2
!
:
0
,
max_amount
:
+
this
.
reqParams
.
max2
!
,
max_amount
:
+
this
.
reqParams
.
max2
!
?
+
this
.
reqParams
.
max2
!
:
9999
,
bank_code
:
this
.
reqParams
.
selectedBanks
[
0
],
bank_code
:
this
.
reqParams
.
selectedBanks
[
0
],
max_date
:
this
.
reqParams
.
selectedPerids
[
0
]
max_date
:
this
.
reqParams
.
selectedPerids
[
0
]
?
this
.
reqParams
.
selectedPerids
[
0
].
max_date
?
this
.
reqParams
.
selectedPerids
[
0
].
max_date
...
@@ -281,19 +305,18 @@ export default defineComponent({
...
@@ -281,19 +305,18 @@ export default defineComponent({
}).
then
((
ret
)
=>
{
}).
then
((
ret
)
=>
{
if
(
ret
.
code
==
200
)
{
if
(
ret
.
code
==
200
)
{
this
.
loading
=
false
;
this
.
loading
=
false
;
this
.
state
.
list
=
[]
;
clearSearchResult
()
;
const
list
=
ret
.
data
.
items
.
map
((
item
)
=>
{
ret
.
data
.
items
.
map
((
item
)
=>
{
const
{
max_amount
,
inst_name
,
uuid
,
features
,
product_name
}
=
const
{
max_amount
,
inst_name
,
uuid
,
features
,
product_name
}
=
item
;
item
;
return
{
setSearchResult
(
{
max_amount
,
max_amount
,
product_name
,
product_name
,
features
,
features
,
inst_name
,
inst_name
,
uuid
,
uuid
,
};
}
)
;
});
});
this
.
state
.
list
=
list
;
}
}
});
});
},
},
...
...
src/views/withMenu/Home/index.vue
View file @
0cfc2f1e
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
:features=
"features"
:features=
"features"
:inst_name=
"inst_name"
:inst_name=
"inst_name"
class=
"mt-5"
class=
"mt-5"
@
click=
"$router.push(
{ name: 'LoanDetail', params: { uuid:
u
uid } })"
@
click=
"$router.push(
{ name: 'LoanDetail', params: { uuid:
hotLoanU
uid } })"
/>
/>
</Skeleton>
</Skeleton>
<group-title
class=
"mt-7"
title=
"精彩直播"
/>
<group-title
class=
"mt-7"
title=
"精彩直播"
/>
...
@@ -39,7 +39,7 @@
...
@@ -39,7 +39,7 @@
@
click=
"
@
click=
"
$router.push(
{
$router.push(
{
name: 'ActivityDetail',
name: 'ActivityDetail',
params: { uuid:
u
uid },
params: { uuid:
activityU
uid },
})
})
"
"
/>
/>
...
@@ -121,11 +121,12 @@ export default defineComponent({
...
@@ -121,11 +121,12 @@ export default defineComponent({
constants
:
{},
constants
:
{},
hotNews
:
[],
hotNews
:
[],
src
:
""
,
src
:
""
,
u
uid
:
""
,
activityU
uid
:
""
,
max_amount
:
0
,
max_amount
:
0
,
product_name
:
""
,
product_name
:
""
,
features
:
""
,
features
:
""
,
inst_name
:
""
,
inst_name
:
""
,
hotLoanUuid
:
""
};
};
},
},
mounted
()
{
mounted
()
{
...
@@ -166,7 +167,7 @@ export default defineComponent({
...
@@ -166,7 +167,7 @@ export default defineComponent({
if
(
ret
.
code
===
200
)
{
if
(
ret
.
code
===
200
)
{
this
.
skeLoading
=
false
;
this
.
skeLoading
=
false
;
this
.
src
=
getImageSrcFromFileHash
(
ret
.
data
.
items
[
0
]?.
file_name
);
this
.
src
=
getImageSrcFromFileHash
(
ret
.
data
.
items
[
0
]?.
file_name
);
this
.
u
uid
=
ret
.
data
.
items
[
0
]?.
uuid
;
this
.
activityU
uid
=
ret
.
data
.
items
[
0
]?.
uuid
;
}
}
},
},
async
fetchLoanProductList
()
{
async
fetchLoanProductList
()
{
...
@@ -179,9 +180,11 @@ export default defineComponent({
...
@@ -179,9 +180,11 @@ export default defineComponent({
});
});
if
(
ret
.
code
===
200
)
{
if
(
ret
.
code
===
200
)
{
this
.
skeLoading
=
false
;
this
.
skeLoading
=
false
;
this
.
uuid
=
ret
.
data
.
uuid
[
0
];
this
.
hotLoanUuid
=
ret
.
data
.
uuid
[
0
];
const
uuid
=
this
.
uuid
;
const
uuid
=
this
.
hotLoanUuid
;
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
queryLoanProductInfo
(
{
uuid
}
).
then
((
ret
)
=>
{
console
.
log
(
'uuid'
,
uuid
);
if
(
ret
.
code
===
200
)
{
if
(
ret
.
code
===
200
)
{
this
.
max_amount
=
ret
.
data
.
max_amount
;
this
.
max_amount
=
ret
.
data
.
max_amount
;
this
.
inst_name
=
ret
.
data
.
inst_name
;
this
.
inst_name
=
ret
.
data
.
inst_name
;
...
...
src/views/withMenu/Loan/index.vue
View file @
0cfc2f1e
...
@@ -10,7 +10,7 @@
...
@@ -10,7 +10,7 @@
color:
color:
eLoanMode.personal === mode ? 'rgba(62, 79, 175, 1)' : '',
eLoanMode.personal === mode ? 'rgba(62, 79, 175, 1)' : '',
}"
}"
@click="
setMode
(eLoanMode.personal)"
@click="
loanMode.setModeAction
(eLoanMode.personal)"
>个人贷
</span
>个人贷
</span
>
>
<span
<span
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
:style=
"
{
:style=
"
{
color: eLoanMode.company === mode ? 'rgba(62, 79, 175, 1)' : '',
color: eLoanMode.company === mode ? 'rgba(62, 79, 175, 1)' : '',
}"
}"
@click="
setMode
(eLoanMode.company)"
@click="
loanMode.setModeAction
(eLoanMode.company)"
>企业贷
</span
>企业贷
</span
>
>
</div>
</div>
...
@@ -60,7 +60,7 @@
...
@@ -60,7 +60,7 @@
</div>
</div>
</div>
</div>
<!-- 热门贷款 -->
<!-- 热门贷款 -->
<GroupTitle
title=
"热门贷款"
class=
"mt-2.5"
iconName=
""
/>
<GroupTitle
title=
"热门贷款"
class=
"mt-2.5"
v-if=
"count"
iconName=
""
/>
<LoanHotSwipe
:loanMode=
"mode"
class=
"mt-5"
/>
<LoanHotSwipe
:loanMode=
"mode"
class=
"mt-5"
/>
<!-- 非热门贷款 -->
<!-- 非热门贷款 -->
<GroupTitle
<GroupTitle
...
@@ -68,7 +68,12 @@
...
@@ -68,7 +68,12 @@
v-if=
"state.allProductList"
v-if=
"state.allProductList"
@
seeMore=
"$router.push(
{ name: 'LoanList', params: { mode: mode } })"
@
seeMore=
"$router.push(
{ name: 'LoanList', params: { mode: mode } })"
/>
/>
<Skeleton
:row=
"3"
:loading=
"skeLoading"
style=
"margin-top: 20px"
v-if=
"state.allProductList"
>
<Skeleton
:row=
"3"
:loading=
"skeLoading"
style=
"margin-top: 20px"
v-if=
"state.allProductList"
>
<LoanCard
<LoanCard
v-for=
"item in state.allProductList"
v-for=
"item in state.allProductList"
:key=
"item.value"
:key=
"item.value"
...
@@ -125,7 +130,13 @@ import GroupTitle from "@/components/GroupTitle/index.vue";
...
@@ -125,7 +130,13 @@ import GroupTitle from "@/components/GroupTitle/index.vue";
import
HotNews
from
"@/components/HotNews/index.vue"
;
import
HotNews
from
"@/components/HotNews/index.vue"
;
import
{
queryActivityList
}
from
"@/service/ActivityService"
;
import
{
queryActivityList
}
from
"@/service/ActivityService"
;
import
{
getImageSrcFromFileHash
}
from
"@/service/FileService"
;
import
{
getImageSrcFromFileHash
}
from
"@/service/FileService"
;
import
{
onMounted
,
PropType
,
reactive
,
watch
}
from
"@vue/runtime-core"
;
import
{
computed
,
onMounted
,
PropType
,
reactive
,
watch
,
}
from
"@vue/runtime-core"
;
import
{
getNewsList
}
from
"@/service/NewsService/index"
;
import
{
getNewsList
}
from
"@/service/NewsService/index"
;
import
{
simpleItemInfo
}
from
"./types"
;
import
{
simpleItemInfo
}
from
"./types"
;
import
{
Skeleton
}
from
"vant"
;
import
{
Skeleton
}
from
"vant"
;
...
@@ -134,12 +145,10 @@ import {
...
@@ -134,12 +145,10 @@ import {
queryLoanProductInfo
,
queryLoanProductInfo
,
queryLimit
,
queryLimit
,
}
from
"@/service/LoanProductService"
;
}
from
"@/service/LoanProductService"
;
import
{
loanMode
}
from
"@/store/loanModeStore"
;
const
mode
=
ref
(
eLoanMode
.
personal
);
import
{
clearSearchResult
}
from
"@/store/loanSearchResultStore"
let
skeLoading
=
ref
(
false
);
let
skeLoading
=
ref
(
false
);
const
setMode
=
(
v
:
eLoanMode
)
=>
{
mode
.
value
=
v
;
};
let
state
=
reactive
({
allProductList
:
[]
as
Array
<
simpleItemInfo
>
});
let
state
=
reactive
({
allProductList
:
[]
as
Array
<
simpleItemInfo
>
});
const
src
=
ref
(
""
);
const
src
=
ref
(
""
);
const
uuid
=
ref
(
""
);
const
uuid
=
ref
(
""
);
...
@@ -150,12 +159,21 @@ const limit = reactive({
...
@@ -150,12 +159,21 @@ const limit = reactive({
max_amount
:
""
,
max_amount
:
""
,
state
:
false
,
state
:
false
,
});
});
const
count
=
ref
(
0
);
watch
(
mode
,
()
=>
{
const
mode
=
computed
(()
=>
{
state
.
allProductList
=
[];
return
loanMode
.
state
.
mode
;
fetchList
();
});
});
watch
(
()
=>
loanMode
.
state
.
mode
,
()
=>
{
state
.
allProductList
=
[];
clearSearchResult
();
fetchList
();
}
);
const
getNews
=
()
=>
{
const
getNews
=
()
=>
{
getNewsList
({
getNewsList
({
limit
:
2
,
limit
:
2
,
...
@@ -177,30 +195,42 @@ const fetchActivityList = () => {
...
@@ -177,30 +195,42 @@ const fetchActivityList = () => {
skeLoading
.
value
=
false
;
skeLoading
.
value
=
false
;
};
};
const
fetchList
=
()
=>
{
const
fetchList
=
()
=>
{
// 取
从四开始的贷款,即非热门贷款
// 取
前7贷款产品遍历
skeLoading
.
value
=
true
;
skeLoading
.
value
=
true
;
queryLoanProductList
({
queryLoanProductList
({
limit
:
4
,
limit
:
7
,
loan_type
:
mode
.
value
,
loan_type
:
mode
.
value
,
offset
:
3
,
offset
:
0
,
}).
then
((
ret
)
=>
{
}).
then
((
ret
)
=>
{
if
(
ret
.
code
===
200
)
{
if
(
ret
.
code
===
200
)
{
skeLoading
.
value
=
false
;
skeLoading
.
value
=
false
;
ret
.
data
.
uuid
.
map
((
uuid
)
=>
{
ret
.
data
.
uuid
.
map
((
uuid
)
=>
{
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
queryLoanProductInfo
({
uuid
}).
then
((
ret
)
=>
{
const
{
max_amount
,
inst_name
,
uuid
,
features
,
product_name
}
=
const
{
ret
.
data
;
state
.
allProductList
.
push
({
max_amount
,
max_amount
,
product_name
,
features
,
inst_name
,
inst_name
,
uuid
,
uuid
,
});
features
,
product_name
,
product_status
,
}
=
ret
.
data
;
if
(
count
.
value
<
4
)
{
if
(
product_status
==
2
)
{
count
.
value
=
count
.
value
+
1
;
state
.
allProductList
.
push
({
max_amount
,
product_name
,
features
,
inst_name
,
uuid
,
});
}
}
});
});
});
});
}
}
});
});
count
.
value
=
0
;
};
};
const
formatLimit
=
(
limit
:
string
):
string
=>
{
const
formatLimit
=
(
limit
:
string
):
string
=>
{
...
...
src/views/withMenu/Loan/types.ts
View file @
0cfc2f1e
...
@@ -10,5 +10,6 @@ export interface simpleItemInfo{
...
@@ -10,5 +10,6 @@ export interface simpleItemInfo{
product_name
:
string
,
product_name
:
string
,
features
:
string
,
features
:
string
,
inst_name
:
string
,
inst_name
:
string
,
uuid
:
string
uuid
:
string
,
product_status
?:
number
}
}
\ No newline at end of file
src/views/withMenu/Mine/branch.vue
View file @
0cfc2f1e
...
@@ -27,8 +27,8 @@
...
@@ -27,8 +27,8 @@
<!-- 附近网点 -->
<!-- 附近网点 -->
<Skeleton
:row=
"3"
:loading=
"result.loading"
class=
"-mt-20 mb-10"
></Skeleton>
<Skeleton
:row=
"3"
:loading=
"result.loading"
class=
"-mt-20 mb-10"
></Skeleton>
<Skeleton
:row=
"3"
:loading=
"result.loading"
class=
"mt-5"
>
<Skeleton
:row=
"3"
:loading=
"result.loading"
class=
"mt-5"
>
<div
class=
"px-4 overflow-scroll -mt-
10
"
>
<div
class=
"px-4 overflow-scroll -mt-
8
"
>
<p
class=
"mt-
8 mb-5
text-base font-semibold text-gray-800"
>
附近的网点
</p>
<p
class=
"mt-
12 mb-3
text-base font-semibold text-gray-800"
>
附近的网点
</p>
<branch
<branch
v-for=
"(item, index) in result.lists"
v-for=
"(item, index) in result.lists"
:key=
"index"
:key=
"index"
...
...
tailwind.config.js
View file @
0cfc2f1e
...
@@ -64,6 +64,7 @@ module.exports = {
...
@@ -64,6 +64,7 @@ module.exports = {
"app-btn-disabled"
:
"#E7E7E7"
,
"app-btn-disabled"
:
"#E7E7E7"
,
"app-branch-deep-blue"
:
"#2C3C92"
,
"app-branch-deep-blue"
:
"#2C3C92"
,
"branch-tab-bg"
:
"#F9FBFF"
,
"branch-tab-bg"
:
"#F9FBFF"
,
"product-detail-bg"
:
"#EAF0FF"
,
black
:
colors
.
black
,
black
:
colors
.
black
,
white
:
colors
.
white
,
white
:
colors
.
white
,
gray
:
colors
.
coolGray
,
gray
:
colors
.
coolGray
,
...
...
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