Skip to content
项目
群组
代码片段
帮助
当前项目
正在载入...
登录 / 注册
切换导航面板
A
applet
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
图表
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
图像
聊天
创建新问题
作业
提交
问题看板
Open sidebar
物业总平台
applet
Commits
e9730bcb
提交
e9730bcb
authored
8月 30, 2023
作者:
宋雄
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
提交二期功能
上级
5a1225db
隐藏空白字符变更
内嵌
并排
正在显示
7 个修改的文件
包含
292 行增加
和
104 行删除
+292
-104
api.js
config/api.js
+71
-2
server_config.js
config/server_config.js
+4
-3
index.vue
pages/integralList/index.vue
+30
-25
index.vue
pages/integralRecord/index.vue
+31
-20
index.vue
pages/mine/index.vue
+11
-0
index.vue
pages/pay/index.vue
+133
-53
index.vue
pages/payCostProperty/index.vue
+12
-1
没有找到文件。
config/api.js
浏览文件 @
e9730bcb
...
@@ -631,10 +631,79 @@ export const payOrderApi = (params = {}, config = {})=> {
...
@@ -631,10 +631,79 @@ export const payOrderApi = (params = {}, config = {})=> {
// 查询业主可用积分
// 查询业主可用积分
export
const
queryIntegralByOwnerIdApi
=
(
params
=
{},
config
=
{})
=>
{
export
const
queryIntegralByOwnerIdApi
=
(
params
=
{},
config
=
{})
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
http
.
get
(
'/property-c
ommunity/integral/ownerIntegral/queryIntegralByOwnerId
'
,
http
.
get
(
'/property-c
entral/wechat/integral/queryIntegralByPhone
'
,
{
{
data
:
{
data
:
{
...
params
...
params
,
phone
:
uni
.
getStorageSync
(
'user_phone'
),
platformCode
:
uni
.
getStorageSync
(
'platform_code'
)
},
...
config
})
.
then
(
res
=>
{
resolve
(
res
)
})
.
catch
(
err
=>
{
reject
(
err
)
})
})
}
// 支付物业费
export
const
payPropertyFeeApi
=
(
params
=
{},
config
=
{})
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
http
.
post
(
'/property-community/wechat/communityPayment/payPropertyFee'
,
{
...
params
,
platformCode
:
uni
.
getStorageSync
(
'platform_code'
)
},
{
...
config
})
.
then
(
res
=>
{
resolve
(
res
)
})
.
catch
(
err
=>
{
reject
(
err
)
})
})
}
// 查询业主积分列表
export
const
getOwnerIntegralApi
=
(
params
=
{},
config
=
{})
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
http
.
get
(
'/property-central/wechat/integral/getOwnerIntegral'
,
{
data
:
{
...
params
,
phone
:
uni
.
getStorageSync
(
'user_phone'
),
platformCode
:
uni
.
getStorageSync
(
'platform_code'
)
},
...
config
})
.
then
(
res
=>
{
resolve
(
res
)
})
.
catch
(
err
=>
{
reject
(
err
)
})
})
}
// 查询业主积分近30天明细
export
const
ownerIntegralListApi
=
(
params
=
{},
config
=
{})
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
http
.
get
(
'/property-central/wechat/integral/ownerIntegralList'
,
{
data
:
{
...
params
,
pageSize
:
10
,
phone
:
uni
.
getStorageSync
(
'user_phone'
),
platformCode
:
uni
.
getStorageSync
(
'platform_code'
)
},
...
config
})
.
then
(
res
=>
{
resolve
(
res
)
})
.
catch
(
err
=>
{
reject
(
err
)
})
})
}
// 查询业主全部积分明细
export
const
ownerIntegralRecordsApi
=
(
params
=
{},
config
=
{})
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
http
.
get
(
'/property-central/wechat/integral/ownerIntegralRecords'
,
{
data
:
{
...
params
,
pageSize
:
10
,
phone
:
uni
.
getStorageSync
(
'user_phone'
),
platformCode
:
uni
.
getStorageSync
(
'platform_code'
)
},
},
...
config
...
config
})
})
...
...
config/server_config.js
浏览文件 @
e9730bcb
...
@@ -2,9 +2,10 @@
...
@@ -2,9 +2,10 @@
* 接口参数
* 接口参数
*/
*/
const
serverConfig
=
{
const
serverConfig
=
{
baseURL
:
"https://life.cloud.hjxbc.cn"
,
// baseURL: "https://life.cloud.hjxbc.cn",
imageURL
:
"https://life.cloud.hjxbc.cn/sys/common/static/"
,
// imageURL: "https://life.cloud.hjxbc.cn/sys/common/static/",
// baseURL: "http://192.168.0.106:9999",
imageURL
:
"https://life.test.hjxbc.cn/sys/common/static/"
,
baseURL
:
"https://life.test.hjxbc.cn"
,
// baseURL: "http://192.168.0.119:9999",
// baseURL: "http://192.168.0.119:9999",
// baseURL: "http://220.203.25.212:9999", /* 根域名 */
// baseURL: "http://220.203.25.212:9999", /* 根域名 */
// baseURL: "http://114.67.111.37:8001" /* 根域名 */
// baseURL: "http://114.67.111.37:8001" /* 根域名 */
...
...
pages/integralList/index.vue
浏览文件 @
e9730bcb
...
@@ -4,15 +4,15 @@
...
@@ -4,15 +4,15 @@
<view
class=
"current-box"
>
<view
class=
"current-box"
>
<view
class=
"text"
>
可使用积分
</view>
<view
class=
"text"
>
可使用积分
</view>
<view
class=
"use-box"
>
<view
class=
"use-box"
>
1000
{{
integralInfo
.
availableIntegral
||
0
}}
<text
class=
"unit"
>
分
</text>
<text
class=
"unit"
>
分
</text>
</view>
</view>
<view
class=
"total-box"
>
<view
class=
"total-box"
>
<text
class=
"text"
>
当前总积分:
</text>
<text
class=
"text"
>
当前总积分:
</text>
<text
class=
"integral"
>
2000
</text>
<text
class=
"integral"
>
{{
integralInfo
.
totalIntegral
||
0
}}
</text>
<text
class=
"unit"
>
分
</text>
<text
class=
"unit"
>
分
</text>
<text
style=
"margin-left:50rpx"
class=
"text"
>
冻结积分:
</text>
<text
style=
"margin-left:50rpx"
class=
"text"
>
冻结积分:
</text>
<text
class=
"integral"
>
1000
</text>
<text
class=
"integral"
>
{{
integralInfo
.
freezeIntegral
||
0
}}
</text>
<text
class=
"unit"
>
分
</text>
<text
class=
"unit"
>
分
</text>
</view>
</view>
</view>
</view>
...
@@ -20,14 +20,14 @@
...
@@ -20,14 +20,14 @@
<view
class=
"accumulate-box"
>
<view
class=
"accumulate-box"
>
<view
class=
"text"
>
累计获得
</view>
<view
class=
"text"
>
累计获得
</view>
<view
class=
"value"
>
<view
class=
"value"
>
<text
class=
"integral"
>
10000
</text>
<text
class=
"integral"
>
{{
integralInfo
.
getIntegral
||
0
}}
</text>
<text
style=
"margin-left:5px"
class=
"unit"
>
分
</text>
<text
style=
"margin-left:5px"
class=
"unit"
>
分
</text>
</view>
</view>
</view>
</view>
<view
class=
"accumulate-box"
>
<view
class=
"accumulate-box"
>
<view
class=
"text"
>
累计使用
</view>
<view
class=
"text"
>
累计使用
</view>
<view
class=
"value"
>
<view
class=
"value"
>
<text
class=
"integral"
>
10000
</text>
<text
class=
"integral"
>
{{
integralInfo
.
useIntegral
||
0
}}
</text>
<text
style=
"margin-left:5px"
class=
"unit"
>
分
</text>
<text
style=
"margin-left:5px"
class=
"unit"
>
分
</text>
</view>
</view>
</view>
</view>
...
@@ -35,7 +35,7 @@
...
@@ -35,7 +35,7 @@
<view
class=
"text"
>
累计节省
</view>
<view
class=
"text"
>
累计节省
</view>
<view
class=
"value"
>
<view
class=
"value"
>
<text
class=
"unit"
>
¥
</text>
<text
class=
"unit"
>
¥
</text>
<text
class=
"integral"
>
80
</text>
<text
class=
"integral"
>
{{
integralInfo
.
deductionAmount
||
0
}}
</text>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -48,12 +48,12 @@
...
@@ -48,12 +48,12 @@
<image
src=
"../../static/images/icon_more.png"
class=
"icon"
></image>
<image
src=
"../../static/images/icon_more.png"
class=
"icon"
></image>
</view>
</view>
</view>
</view>
<view
class=
"item-box"
v-for=
"item in
5"
:key=
"item
"
>
<view
class=
"item-box"
v-for=
"item in
integralList"
:key=
"item.id
"
>
<view>
<view>
<view
class=
"describe"
>
支付订单
</view>
<view
class=
"describe"
>
{{
item
.
type
===
'scanQrCodePay'
?
'扫码支付'
:
'抵扣物业费'
}}
</view>
<view
class=
"date-time"
>
2017-05-01 15:00
</view>
<view
class=
"date-time"
>
{{
item
.
createTime
}}
</view>
</view>
</view>
<view
class=
"compute"
>
{{
item
%
2
?
'+'
:
'-'
}}
5
</view>
<view
class=
"compute"
>
{{
item
.
integralChange
<
0
?
item
.
integralChange
:
(
'+'
+
item
.
integralChange
)
}}
</view>
</view>
</view>
</view>
</view>
<!--
<no-data
:show=
"payList.length === 0"
text=
"暂无缴费信息"
></no-data>
-->
<!--
<no-data
:show=
"payList.length === 0"
text=
"暂无缴费信息"
></no-data>
-->
...
@@ -62,27 +62,31 @@
...
@@ -62,27 +62,31 @@
<
script
>
<
script
>
import
{
import
{
communityPaymentApi
getOwnerIntegralApi
,
ownerIntegralListApi
,
}
from
'@/config/api.js'
}
from
'@/config/api.js'
import
noData
from
'@/components/no-data/no-data'
import
noData
from
'@/components/no-data/no-data'
const
freeType
=
[
{
code
:
'SFLX00001'
,
name
:
'物业费'
},
{
code
:
'SFLX00002'
,
name
:
'水费'
},
{
code
:
'SFLX00003'
,
name
:
'电费'
},
{
code
:
'SFLX00004'
,
name
:
'燃气费'
},
{
code
:
'SFLX00005'
,
name
:
'暖气费'
}
]
export
default
{
export
default
{
components
:
{
noData
},
components
:
{
noData
},
data
()
{
data
()
{
return
{
return
{
payList
:
[]
integralInfo
:
{},
integralList
:
[],
pageNo
:
1
}
}
},
},
methods
:
{
methods
:
{
async
getList
(
chargeTypeCode
)
{
async
getMessage
()
{
let
{
result
}
=
await
communityPaymentApi
({
chargeTypeCode
})
let
{
result
}
=
await
getOwnerIntegralApi
({})
this
.
payList
=
result
.
records
result
[
'freezeIntegral'
]
=
(
result
.
systemFreezeIntegral
+
result
.
manualFreezeIntegral
).
toFixed
(
2
).
replace
(
'.00'
,
''
)
result
[
'totalIntegral'
]
=
(
Number
(
result
.
freezeIntegral
)
+
result
.
availableIntegral
).
toFixed
(
2
).
replace
(
'.00'
,
''
)
this
.
integralInfo
=
{...
result
}
},
async
getList
()
{
let
{
result
}
=
await
ownerIntegralListApi
({
pageNo
:
this
.
pageNo
})
this
.
integralList
=
[...
result
.
records
]
},
},
toRecord
(
type
)
{
toRecord
(
type
)
{
if
(
type
==
1
){
if
(
type
==
1
){
...
@@ -101,8 +105,9 @@
...
@@ -101,8 +105,9 @@
});
});
}
}
},
},
onLoad
(
option
)
{
onLoad
()
{
this
.
getMessage
()
this
.
getList
()
}
}
}
}
</
script
>
</
script
>
...
@@ -125,7 +130,7 @@
...
@@ -125,7 +130,7 @@
// background-position: top center;
// background-position: top center;
background-repeat
:
no-repeat
;
background-repeat
:
no-repeat
;
background-size
:
100%
100%
;
background-size
:
100%
100%
;
background-image
:
url('https://life.cloud.hjxbc.cn/sys/common/static/
scott/pic/5bGvHZsW4Yzc268a39033927a853f8a4ce5bc5521418_1690965501478
.png')
;
background-image
:
url('https://life.cloud.hjxbc.cn/sys/common/static/
miniapp/bg_jifen
.png')
;
// border-radius: 16rpx;
// border-radius: 16rpx;
padding
:
40rpx
;
padding
:
40rpx
;
line-height
:
1
;
line-height
:
1
;
...
...
pages/integralRecord/index.vue
浏览文件 @
e9730bcb
<
template
>
<
template
>
<view
class=
"container"
>
<view
class=
"container"
>
<view
class=
"list"
>
<view
class=
"list"
>
<view
class=
"title-box"
@
click=
"onLookAll"
>
<view
class=
"title-box"
>
<view
class=
"title"
>
2017年5月
</view>
<!--
<view
class=
"title"
>
2017年5月
</view>
-->
<uni-datetime-picker
v-model=
"range"
type=
"daterange"
@
change=
"onRangeChange"
/>
<view
class=
"statistics"
>
<view
class=
"statistics"
>
<text
class=
"text"
>
获得:
</text>
<text
class=
"text"
>
获得:
</text>
<text
class=
"text"
>
300
</text>
<text
class=
"text"
>
{{
getIntegral
}}
</text>
<text
style=
"margin-left: 10px"
class=
"text"
>
使用:
</text>
<text
style=
"margin-left: 10px"
class=
"text"
>
使用:
</text>
<text
class=
"text"
>
30
</text>
<text
class=
"text"
>
{{
useIntegral
}}
</text>
</view>
</view>
</view>
</view>
<view
class=
"item-box"
v-for=
"item in
5"
:key=
"item
"
>
<view
class=
"item-box"
v-for=
"item in
payList"
:key=
"item.id
"
>
<view>
<view>
<view
class=
"describe"
>
支付订单
</view>
<view
class=
"describe"
>
{{
item
.
type
===
'scanQrCodePay'
?
'扫码支付'
:
'抵扣物业费'
}}
</view>
<view
class=
"date-time"
>
2017-05-01 15:00
</view>
<view
class=
"date-time"
>
{{
item
.
createTime
}}
</view>
</view>
</view>
<view
class=
"compute"
>
{{
item
%
2
?
'+'
:
'-'
}}
5
</view>
<view
class=
"compute"
>
{{
item
.
integralChange
<
0
?
item
.
integralChange
:
(
'+'
+
item
.
integralChange
)
}}
</view>
</view>
</view>
</view>
</view>
<
!--
<no-data
:show=
"payList.length === 0"
text=
"暂无缴费信息"
></no-data>
--
>
<
no-data
:show=
"payList.length === 0"
text=
"暂无缴费信息"
></no-data
>
</view>
</view>
</
template
>
</
template
>
<
script
>
<
script
>
import
{
import
{
communityPayment
Api
ownerIntegralRecords
Api
}
from
'@/config/api.js'
}
from
'@/config/api.js'
import
noData
from
'@/components/no-data/no-data'
import
noData
from
'@/components/no-data/no-data'
export
default
{
export
default
{
components
:
{
noData
},
components
:
{
noData
},
data
()
{
data
()
{
return
{
return
{
getIntegral
:
0
,
useIntegral
:
0
,
pageNo
:
1
,
range
:
[],
payList
:
[]
payList
:
[]
}
}
},
},
methods
:
{
methods
:
{
async
getList
(
chargeTypeCode
)
{
onRangeChange
(
val
)
{
let
{
result
}
=
await
communityPaymentApi
({
chargeTypeCode
})
this
.
pageNo
=
1
this
.
payList
=
result
.
records
this
.
range
=
val
this
.
getList
()
},
async
getList
()
{
let
{
result
}
=
await
ownerIntegralRecordsApi
({
pageNo
:
this
.
pageNo
,
startDate
:
this
.
range
[
0
]
||
''
,
endDate
:
this
.
range
[
1
]
||
''
})
this
.
payList
=
result
.
pageList
.
records
this
.
getIntegral
=
result
.
getIntegral
this
.
useIntegral
=
result
.
useIntegral
*
-
1
},
},
toRecord
(
type
)
{
toRecord
(
type
)
{
if
(
type
==
1
){
if
(
type
==
1
){
...
@@ -49,15 +65,10 @@
...
@@ -49,15 +65,10 @@
url
:
'/pages/payCostRecord/index'
,
url
:
'/pages/payCostRecord/index'
,
});
});
}
}
},
onLookAll
()
{
uni
.
navigateTo
({
url
:
"/pages/integralRecord/index"
});
}
}
},
},
onLoad
(
option
)
{
onLoad
()
{
this
.
getList
()
}
}
}
}
</
script
>
</
script
>
...
...
pages/mine/index.vue
浏览文件 @
e9730bcb
...
@@ -74,6 +74,13 @@
...
@@ -74,6 +74,13 @@
</view>
</view>
<image
src=
"../../static/images/icon_more.png"
class=
"arrow"
></image>
<image
src=
"../../static/images/icon_more.png"
class=
"arrow"
></image>
</view>
</view>
<view
class=
"item"
@
click=
"quickEntry(9)"
>
<view
class=
"left"
>
<image
src=
"../../static/images/user06.png"
class=
"icon"
></image>
<div
class=
"title"
>
我的积分
</div>
</view>
<image
src=
"../../static/images/icon_more.png"
class=
"arrow"
></image>
</view>
</
template
>
</
template
>
<view
v-if=
"isEmployee && userType !== '2'"
class=
"item"
@
click=
"quickEntry(8)"
>
<view
v-if=
"isEmployee && userType !== '2'"
class=
"item"
@
click=
"quickEntry(8)"
>
<view
class=
"left"
>
<view
class=
"left"
>
...
@@ -189,6 +196,10 @@
...
@@ -189,6 +196,10 @@
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
'/pages/myReceipt/index'
,
url
:
'/pages/myReceipt/index'
,
});
});
}
else
if
(
type
==
9
)
{
uni
.
navigateTo
({
url
:
'/pages/integralList/index'
,
});
}
else
{
}
else
{
return
false
return
false
}
}
...
...
pages/pay/index.vue
浏览文件 @
e9730bcb
...
@@ -2,27 +2,32 @@
...
@@ -2,27 +2,32 @@
<view
class=
"container"
>
<view
class=
"container"
>
<view
class=
"property"
>
<view
class=
"property"
>
<view
class=
"address-title"
>
<view
class=
"address-title"
>
XXX小区 3号楼 2单元 102 业主
{{
pageInfo
.
platformName
}}
{{
pageInfo
.
buildingName
}}
{{
pageInfo
.
unitName
}}
{{
pageInfo
.
roomName
}}
{{
pageInfo
.
userName
}}
</view>
</view>
<view
class=
"details"
>
<view
class=
"details"
>
<view
class=
"title"
>
<view
class=
"title"
>
<view
class=
"name"
>
<view
class=
"name"
>
<view
class=
"cost"
>
3000
</view>
元
<view
class=
"cost"
>
{{
pageInfo
.
totalAmount
}}
</view>
元
</view>
</view>
<view
class=
"tag"
>
费用期间:
2022-11-21
</view>
<view
class=
"tag"
>
费用期间:
{{
pageInfo
.
createTime
}}
</view>
</view>
</view>
<view
class=
"content"
>
<view
class=
"content"
>
<view
class=
"text"
>
使用积分:
</view>
<view
class=
"text"
>
使用积分:
</view>
<input
:cursor-spacing=
"10"
placeholder-class=
"input-placeholder"
class=
"integral-input"
type=
"number"
placeholder=
"请输入使用积分数量(可不输入)"
/>
<view
class=
"input-box"
>
<view
class=
"text illustrate"
>
当前可用1000积分,可抵扣¥1元
</view>
<input
v-model=
"currentUse"
:disabled=
"ownerIntegral === 0"
:cursor-spacing=
"10"
placeholder-class=
"input-placeholder"
class=
"integral-input"
type=
"number"
placeholder=
"请输入使用积分数量(可不输入)"
/>
<button
:disabled=
"ownerIntegral === 0"
class=
"mini-btn"
type=
"primary"
size=
"mini"
@
click=
"onUseAll"
>
使用全部
</button>
</view>
<view
class=
"text illustrate"
>
当前可用
{{
ownerIntegral
}}
积分,可抵扣¥
{{
deductionIntegral
}}
元
</view>
</view>
</view>
<view
class=
"content"
>
<view
class=
"content
flex
"
>
<view
class=
"text"
>
缴费方式:
</view>
<view
class=
"text"
>
缴费方式:
</view>
<radio-group
class=
"radio-group"
@
change=
"radioChange"
>
<!--
<radio-group
class=
"radio-group"
>
<label
class=
"radio"
><radio
style=
"transform:scale(0.7)"
color=
"#6A59F2"
value=
"1"
:checked=
"payType === '1'"
/>
一键缴费
</label>
<label
class=
"radio"
v-for=
"item in radioList"
:key=
"item.value"
>
<label
class=
"radio"
><radio
style=
"transform:scale(0.7)"
color=
"#6A59F2"
value=
"2"
:checked=
"payType === '2'"
/>
季度缴费
</label>
<radio
disabled
style=
"transform:scale(0.7)"
color=
"#6A59F2"
:value=
"item.value"
:checked=
"pageInfo.chargeCycle === item.value"
/>
<label
class=
"radio"
><radio
style=
"transform:scale(0.7)"
color=
"#6A59F2"
value=
"3"
:checked=
"payType === '3'"
/>
年度缴费
</label>
{{
item
.
label
}}
</radio-group>
</label>
</radio-group>
-->
<view
class=
"text"
>
{{
chargeCycleName
}}
</view>
</view>
</view>
</view>
</view>
</view>
</view>
...
@@ -32,48 +37,120 @@
...
@@ -32,48 +37,120 @@
<
script
>
<
script
>
import
{
import
{
queryIntegralByOwnerIdApi
queryIntegralByOwnerIdApi
,
payPropertyFeeApi
}
from
'@/config/api.js'
}
from
'@/config/api.js'
export
default
{
export
default
{
data
()
{
data
()
{
return
{
return
{
userName
:
''
,
pageInfo
:
{
userPhone
:
''
,
id
:
''
,
platformName
:
''
,
ownerId
:
''
,
payType
:
'1'
,
userName
:
''
,
payDetail
:
{}
userPhone
:
''
,
platformName
:
''
,
buildingName
:
''
,
unitName
:
''
,
roomName
:
''
,
roomId
:
''
,
createTime
:
''
,
totalAmount
:
''
,
chargeCycle
:
''
},
currentUse
:
''
,
payUsePoints
:
1
,
ownerIntegral
:
0
,
deductionIntegral
:
0
}
},
computed
:
{
chargeCycleName
()
{
let
chargeCycleList
=
[
{
label
:
'每月'
,
value
:
'1'
},
{
label
:
'每季度'
,
value
:
'2'
},
{
label
:
'每年'
,
value
:
'3'
},
{
label
:
'一次性付清'
,
value
:
'4'
},
{
label
:
'预付'
,
value
:
'5'
},
]
let
row
=
chargeCycleList
.
find
(
item
=>
item
.
value
===
this
.
pageInfo
.
chargeCycle
)
return
row
?
row
.
label
:
''
}
}
},
},
methods
:
{
methods
:
{
radioChange
(
evt
)
{
onUseAll
()
{
console
.
log
(
evt
.
detail
.
value
)
this
.
currentUse
=
this
.
ownerIntegral
this
.
payType
=
evt
.
detail
.
value
},
},
async
getDetail
(
id
)
{
async
onSubmit
()
{
let
res
=
await
communityPaymentDetailApi
({
id
})
// uni.requestPayment({
this
.
payDetail
=
res
.
result
// provider: 'alipay',
},
// orderInfo: 'orderInfo', //微信、支付宝订单数据 【注意微信的订单信息,键值应该全部是小写,不能采用驼峰命名】
onSubmit
()
{
// success: function (res) {
uni
.
requestPayment
({
// console.log('success:' + JSON.stringify(res));
provider
:
'alipay'
,
// },
orderInfo
:
'orderInfo'
,
//微信、支付宝订单数据 【注意微信的订单信息,键值应该全部是小写,不能采用驼峰命名】
// fail: function (err) {
success
:
function
(
res
)
{
// console.log('fail:' + JSON.stringify(err));
console
.
log
(
'success:'
+
JSON
.
stringify
(
res
));
// }
},
// });
fail
:
function
(
err
)
{
let
payAmount
=
Number
(
this
.
pageInfo
.
totalAmount
)
console
.
log
(
'fail:'
+
JSON
.
stringify
(
err
));
let
deductionAmount
=
0
}
if
(
this
.
currentUse
)
{
});
deductionAmount
=
(
Number
(
this
.
currentUse
)
/
this
.
payUsePoints
).
toFixed
(
2
)
payAmount
=
(
payAmount
-
Number
(
deductionAmount
)).
toFixed
(
2
)
}
let
res
=
await
payPropertyFeeApi
({
paymentId
:
this
.
pageInfo
.
id
,
ownerId
:
this
.
pageInfo
.
ownerId
,
ownerPhone
:
this
.
pageInfo
.
userPhone
,
deductionAmount
,
payAmount
,
useIntegral
:
this
.
currentUse
||
0
,
platformName
:
this
.
pageInfo
.
platformName
,
residentName
:
this
.
pageInfo
.
userName
,
})
if
(
res
.
success
)
{
var
pages
=
getCurrentPages
();
var
page
=
pages
[
pages
.
length
-
2
];
page
.
$vm
.
getList
()
setTimeout
(()
=>
{
uni
.
showToast
({
title
:
'支付成功!'
,
icon
:
'none'
});
setTimeout
(()
=>
{
uni
.
navigateBack
()
},
1500
)
},
30
)
}
else
{
uni
.
showToast
({
title
:
res
.
message
,
icon
:
'none'
});
}
},
},
async
getMessage
()
{
async
getMessage
(
ownerId
)
{
let
res
=
await
queryIntegralByOwnerIdApi
({
ownerId
:
111
})
let
res
=
await
queryIntegralByOwnerIdApi
({
ownerId
})
this
.
payUsePoints
=
res
.
result
.
payUsePoints
this
.
ownerIntegral
=
res
.
result
.
ownerIntegral
this
.
deductionIntegral
=
res
.
result
.
deductionIntegral
}
}
},
},
onLoad
(
options
)
{
onLoad
(
options
)
{
this
.
userName
=
uni
.
getStorageSync
(
'user_name'
)
let
info
=
JSON
.
parse
(
options
.
params
)
this
.
userPhone
=
uni
.
getStorageSync
(
'user_phone'
)
this
.
pageInfo
=
{
this
.
platformName
=
uni
.
getStorageSync
(
'platform_name'
)
id
:
info
.
id
,
this
.
getMessage
()
ownerId
:
info
.
ownerId
,
userName
:
uni
.
getStorageSync
(
'user_name'
),
userPhone
:
uni
.
getStorageSync
(
'user_phone'
),
platformName
:
uni
.
getStorageSync
(
'platform_name'
),
buildingName
:
info
.
buildingName
,
unitName
:
info
.
unitName
,
roomName
:
info
.
roomName
,
roomId
:
info
.
roomId
,
createTime
:
info
.
createTime
,
totalAmount
:
info
.
totalAmount
,
chargeCycle
:
info
.
chargeCycle
}
this
.
getMessage
(
info
.
ownerId
)
}
}
}
}
</
script
>
</
script
>
...
@@ -150,10 +227,13 @@
...
@@ -150,10 +227,13 @@
}
}
}
}
.content
{
.content
{
border-top
:
1px
solid
#F0F0F2
;
border-top
:
1px
solid
#F0F0F2
;
padding
:
20rpx
0
;
padding
:
20rpx
0
;
&
.flex
{
display
:
flex
;
justify-content
:
space-between
;
}
.text
{
.text
{
height
:
60rpx
;
height
:
60rpx
;
line-height
:
60rpx
;
line-height
:
60rpx
;
...
@@ -171,17 +251,17 @@
...
@@ -171,17 +251,17 @@
border
:
1px
solid
#F0F0F2
;
border
:
1px
solid
#F0F0F2
;
border-radius
:
10rpx
;
border-radius
:
10rpx
;
}
}
.radio-group
{
//
.radio-group {
margin-top
:
20rpx
;
//
margin-top: 20rpx;
margin-left
:
-4px
;
//
margin-left: -4px;
.radio
{
//
.radio {
font-size
:
28rpx
;
//
font-size: 28rpx;
color
:
#373737
;
//
color: #373737;
&
:not
(
:last-child
)
{
//
&:not(:last-child) {
margin-right
:
5px
;
//
margin-right: 5px;
}
//
}
}
//
}
}
//
}
}
}
}
}
}
}
...
...
pages/payCostProperty/index.vue
浏览文件 @
e9730bcb
...
@@ -101,8 +101,19 @@
...
@@ -101,8 +101,19 @@
},
},
toDetail
(
item
)
{
toDetail
(
item
)
{
if
(
item
.
chargeTypeCode
===
'SFLX00001'
)
{
if
(
item
.
chargeTypeCode
===
'SFLX00001'
)
{
let
params
=
{
id
:
item
.
id
,
ownerId
:
item
.
ownerId
,
createTime
:
item
.
createTime
,
buildingName
:
item
.
buildingName
,
unitName
:
item
.
unitName
,
roomName
:
item
.
roomName
,
roomId
:
item
.
roomId
,
totalAmount
:
item
.
totalAmount
,
chargeCycle
:
item
.
chargeCycle
}
uni
.
navigateTo
({
uni
.
navigateTo
({
url
:
`/pages/pay/index?
id=
${
item
.
id
}
`
url
:
`/pages/pay/index?
params=
${
JSON
.
stringify
(
params
)
}
`
});
});
}
else
{
}
else
{
uni
.
navigateTo
({
uni
.
navigateTo
({
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论