Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
sfp-program
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Sweet Zhang
sfp-program
Commits
22659fdb
Commit
22659fdb
authored
Sep 27, 2022
by
Sweet Zhang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
使用说明增加外链,参数设定对接
parent
2ebf9aa4
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
38 additions
and
17 deletions
+38
-17
api/api.ts
+5
-0
pages/header/header.vue
+1
-1
pages/housePurchase/planningParameters.vue
+29
-14
pages/index/index.vue
+2
-1
util/interceptor.ts
+1
-1
No files found.
api/api.ts
View file @
22659fdb
...
...
@@ -22,6 +22,11 @@ export default {
//购房能力测算
housePurchasePlanAnalysis
(
params
){
return
request
(
`
${
baseURL
}
/api/sfp/calcuteUtil/housePurchasePlanAnalysis`
,
"POST"
,
params
)
},
// 各城市商品住宅销售价格查询接口
queryCommercialHousingPrice
(
params
){
return
request
(
`
${
baseURL
}
/api/sfp/calcuteConfig/queryCommercialHousingPrice`
,
"POST"
,
params
)
}
}
pages/header/header.vue
View file @
22659fdb
...
...
@@ -17,7 +17,7 @@
},
methods
:{
}
}
</
script
>
...
...
pages/housePurchase/planningParameters.vue
View file @
22659fdb
...
...
@@ -35,16 +35,17 @@
data
(){
return
{
paramsLists
:[
{
id
:
'01'
,
name
:
'房价增长率'
,
value
:
6.25
,
type
:
'data-picker'
,
remark
:
''
},
{
id
:
'02'
,
name
:
'房屋折旧率'
,
value
:
2
,
type
:
'number'
,
remark
:
''
},
{
id
:
'03'
,
name
:
'首付款最低成数'
,
value
:
30
,
type
:
'number'
,
remark
:
''
},
{
id
:
'04'
,
name
:
'
新房贷款年利率'
,
value
:
4.9
,
type
:
'number'
,
remark
:
'
'
},
{
id
:
'05'
,
name
:
'资产投资回报率'
,
value
:
3.74
,
type
:
'number'
,
remark
:
''
},
{
id
:
'06'
,
name
:
'收入增长率'
,
value
:
3
,
type
:
'number'
,
remark
:
'国家统计局2022年第二季度数据显示全国居民人均可支配收入增长率为3.0%'
},
{
id
:
'07'
,
name
:
'可接受本金损失'
,
value
:
10
,
type
:
'number'
,
remark
:
''
}
{
id
:
'01'
,
name
:
'房价增长率'
,
value
:
6.25
,
type
:
'data-picker'
,
remark
:
''
,
alias
:
'housePriceGrowthRate'
},
{
id
:
'02'
,
name
:
'房屋折旧率'
,
value
:
2
,
type
:
'number'
,
remark
:
''
,
alias
:
'houseDepreciationRate'
},
{
id
:
'03'
,
name
:
'首付款最低成数'
,
value
:
30
,
type
:
'number'
,
remark
:
''
,
alias
:
'downPaymentMin'
},
{
id
:
'04'
,
name
:
'
贷款年利率'
,
value
:
4.9
,
type
:
'number'
,
remark
:
''
,
alias
:
'interestRate
'
},
{
id
:
'05'
,
name
:
'资产投资回报率'
,
value
:
3.74
,
type
:
'number'
,
remark
:
''
,
alias
:
'tnvestmentRate'
},
{
id
:
'06'
,
name
:
'收入增长率'
,
value
:
3
,
type
:
'number'
,
remark
:
'国家统计局2022年第二季度数据显示全国居民人均可支配收入增长率为3.0%'
,
alias
:
'incomeRate'
},
{
id
:
'07'
,
name
:
'可接受本金损失'
,
value
:
10
,
type
:
'number'
,
remark
:
''
,
alias
:
'acceptableLossRate'
}
],
editParamLists
:[],
provinceList
:[]
provinceList
:[],
cityInfo
:
null
}
},
...
...
@@ -57,25 +58,39 @@
},
methods
:{
onchange
(
e
)
{
const
value
=
e
.
detail
.
value
console
.
log
(
e
)
// const value = e.detail.value;
},
onnodeclick
(
node
)
{
console
.
log
(
node
)
// console.log(node);
this
.
cityInfo
=
{
provinceId
:
node
.
value
,
cityId
:
node
.
parent_value
?
node
.
parent_value
:
null
,
area
:
1
,
isNew
:
1
}
this
.
queryCommercialHousingPrice
(
this
.
cityInfo
)
},
resetParams
(){
this
.
editParamLists
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
paramsLists
))
console
.
log
(
this
.
editParamLists
)
},
provCityQry
(){
api
.
provCityQry
({
insurerId
:
888
}).
then
((
res
)
=>
{
console
.
log
(
res
)
if
(
res
[
'success'
]){
this
.
provinceList
=
common
.
action
(
res
[
'data'
][
'provinces'
]);
console
.
log
(
this
.
provinceList
)
}
})
},
confirmParams
(){
},
// 获取房价增长率
queryCommercialHousingPrice
(
provinceId
,
cityId
){
api
.
queryCommercialHousingPrice
(
this
.
cityInfo
).
then
(
res
=>
{
if
(
res
[
'success'
]){
this
.
editParamLists
.
find
(
item
=>
item
.
alias
===
'housePriceGrowthRate'
)[
'value'
]
=
res
[
'data'
][
'priceInfo'
][
'rateB'
];
}
})
}
},
mounted
()
{
this
.
editParamLists
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
paramsLists
));
...
...
pages/index/index.vue
View file @
22659fdb
...
...
@@ -11,6 +11,7 @@
<view
class=
"banner"
>
<img
src=
"/static/images/policyIrrBanner.png"
alt=
""
srcset=
""
>
<!-- 使用说明 -->
<text
@
click=
"instructionForUse()"
>
使用说明
</text>
<head></head>
</view>
<scroll-view
scroll-y=
"true"
class=
"formInfoContainer"
id=
"formInfoContainer"
>
...
...
@@ -298,7 +299,7 @@
methods
:
{
// 使用说明跳转
instructionForUse
(){
window
.
location
.
href
=
'https://mp.weixin.qq.com/s/
V8RtUN9I2hECv2UiefF1HA
'
;
window
.
location
.
href
=
'https://mp.weixin.qq.com/s/
ZmlFZv51Pr0qpKeFiebI3Q
'
;
},
// 数字千分位处理
numberConverter
(
val
){
...
...
util/interceptor.ts
View file @
22659fdb
...
...
@@ -49,7 +49,7 @@ export const interceptor = () => {
// 响应拦截器,可以对数据进行预处理
success
(
args
)
{
uni
.
hideLoading
()
console
.
log
(
args
);
//
console.log(args);
},
fail
(
err
)
{
console
.
log
(
'interceptor-fail'
,
err
)
...
...
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