Commit a97e40e6 authored by 秦威威's avatar 秦威威

支付对接

parent 1755fb4b
...@@ -107,6 +107,12 @@ ...@@ -107,6 +107,12 @@
"navigationStyle": "custom" "navigationStyle": "custom"
} }
}, },
{
"path": "pages/tsby_xq",
"style": {
"navigationStyle": "custom"
}
},
{ {
"path": "pages/tsby_lsgd", "path": "pages/tsby_lsgd",
"style": { "style": {
......
...@@ -236,7 +236,6 @@ ...@@ -236,7 +236,6 @@
} }
if (index == 4) { if (index == 4) {
this.$wskj.toast("敬请期待") this.$wskj.toast("敬请期待")
this.$wskj.to("/pages/my/feedback")
return return
} }
if (index == 5) { if (index == 5) {
......
...@@ -27,7 +27,7 @@ ...@@ -27,7 +27,7 @@
style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);background: white;"> style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);background: white;">
<view class="flex vh-center mt-20"> <view class="flex vh-center mt-20">
<image class="h-40 w-40 mr-15" src="/static/icon_gd.png"> </image> <image class="h-40 w-40 mr-15" src="/static/icon_gd.png"> </image>
<text class="fs-32 fw-700" style="flex: 1;">居家报修</text> <text class="fs-32 fw-700" style="flex: 1;">{{item.type==1?'居家报修':'公区报事'}}</text>
<text>{{item.state==1?'待处理':item.state==2?'待支付':item.state==3?'已完成':item.state==4?'已取消':''}}</text> <text>{{item.state==1?'待处理':item.state==2?'待支付':item.state==3?'已完成':item.state==4?'已取消':''}}</text>
</view> </view>
<text class="fs-28 br-6 pad-20 mtb-20" <text class="fs-28 br-6 pad-20 mtb-20"
...@@ -66,6 +66,8 @@ ...@@ -66,6 +66,8 @@
}, },
onLoad(e) { onLoad(e) {
this.type = e.type this.type = e.type
},
onShow() {
this.getList() this.getList()
}, },
methods: { methods: {
...@@ -75,7 +77,7 @@ ...@@ -75,7 +77,7 @@
}, },
onCz(e, index) { onCz(e, index) {
if (e == "详情") { if (e == "详情") {
this.$wskj.to("/pagesMain/pages/bxxq") this.$wskj.to("/pagesMain/pages/bxxq?id=" + this.list[index].repairsId)
return return
} }
if (e == "关闭报修") { if (e == "关闭报修") {
......
...@@ -18,68 +18,75 @@ ...@@ -18,68 +18,75 @@
<scroll-view scroll-y style="height: 100%;"> <scroll-view scroll-y style="height: 100%;">
<view class="mar-20"> <view class="mar-20">
<view class="flex-column-center"> <view class="flex-column-center">
<image class="w-20 h-20 mr-10" style="background-color: #1FCA7C;"></image> <image class="w-40 h-40 mr-10" src="/static/icon_gd.png"></image>
<text style="flex: 1;text-align: left;">居家报修</text> <text style="flex: 1;text-align: left;"
<text style="font-size: 24rpx;color: #EEA616;">待支付</text> class="fs-32 fw-700">{{data.type==1?'居家报修':'公区报事'}}</text>
<text
style="font-size: 24rpx;color: #EEA616;">{{data.state==1?'待处理':data.state==2?'待支付':data.state==3?'已完成':data.state==4?'已取消':''}}</text>
</view> </view>
<view class="flex-column br-12 fs-28 mt-30" style="background: #EBF5F0;"> <view class="flex-column br-12 fs-28 mt-30" style="background: #EBF5F0;">
<view class="flex pad-30"> <view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">业主姓名:</text> <text class="fw-700 w-200" style="text-align: left;">业主姓名:</text>
<text>张三</text> <text>{{$wskj.isNullStr(data.proprietorName)}}</text>
</view> </view>
<view class="flex pad-30"> <view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">业主房间号</text> <text class="fw-700 w-200" style="text-align: left;">业主房间号</text>
<text>利达国宾中心1栋2单元205室</text> <text>{{data.room}}</text>
</view> </view>
<view class="flex pad-30"> <view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">业主手机号</text> <text class="fw-700 w-200" style="text-align: left;">业主手机号</text>
<text>17778767876</text> <text>{{data.proprietorPhone}}</text>
</view> </view>
</view> </view>
<view class="flex-column-center fs-32 fw-700 mt-30"> <view class="flex-column-center fs-32 fw-700 mt-30">
<image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image> <image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image>
<text>报修信息</text> <text>报修信息</text>
</view> </view>
<view class="flex-column br-12 fs-28 mtb-30 pad-30" style="background: #EBF5F0;"> <view class="flex-column br-12 fs-28 mtb-30 pad-30" style="background: #EBF5F0;">
<text style="text-align: left;">利达国宾中心利达国宾中心1栋2单元205室卫生 <text style="text-align: left;">{{data.repairsDescription}}</text>
间漏水,请物业及时查看</text>
</view> </view>
<scroll-view scroll-x="true" scroll-with-animation="true"> <scroll-view scroll-x="true" scroll-with-animation="true">
<view class="flex"> <view class="flex">
<view class="w-140 h-140 mr-15" v-for="(itemImg, index2) in 10" :key="index2"> <view class="w-140 h-140 mr-15"
<image class="w-140 h-140" style="background: #1FCA7C;"></image> v-for="(itemImg, index2) in $wskj.splitList(data.repairsImg)" :key="index2">
<image class="w-140 h-140" :src="itemImg"></image>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
<view class="flex mt-20 fs-24 v-center"> <view class="flex mt-20 fs-24 v-center">
<view class="fw-700 fs-28">报修时间:</view> <view class="fw-700 fs-28">报修时间:</view>
<view class="fs-24 ml-10">2025-03-10 10:01:45</view> <view class="fs-24 ml-10">{{data.repairsTime}}</view>
<view class="fs-24 ml-10" style="flex: 1;"></view>
<view @click="onCz('关闭报修')" v-if="data.state==2" class="fs-24 mr-10" style="color: #23BBEE;">
关闭报修</view>
</view> </view>
<view class="flex-column br-12 fs-28 mt-30" style="background: #EBF5F0;"> <view v-if="data.state==2||data.state==3" class="flex-column br-12 fs-28 mt-30"
style="background: #EBF5F0;">
<view class="flex pad-30"> <view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">负责人:</text> <text class="fw-700 w-200" style="text-align: left;">负责人:</text>
<text>张三</text> <text>{{data.accountName}}</text>
</view> </view>
<view class="flex pad-30"> <view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">手机号:</text> <text class="fw-700 w-200" style="text-align: left;">手机号:</text>
<text>利达国宾中心1栋2单元205室</text> <text>{{data.accountMobile}}</text>
</view> </view>
<view class="flex pad-30"> <view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">完成时间:</text> <text class="fw-700 w-200" style="text-align: left;">完成时间:</text>
<text>17778767876</text> <text>{{data.completeTime}}</text>
</view> </view>
</view> </view>
<view v-if="data.state==4" class="flex pad-30 br-12 mt-30" style="background: #EBF5F0;">
<text class="fw-700 w-200" style="text-align: left;">关闭时间:</text>
<text>{{data.closeTime}}</text>
</view>
</view> </view>
</scroll-view> </scroll-view>
</view> </view>
<view class="h-140 pt-20"> <view class="h-140 pt-20">
<view class="full-btn" v-if="false"> <view class="full-btn" v-if="data.state==2">
去支付 去支付
</view> </view>
<view class="full-btn" style="color: #FF682D;"> <view @click="onCz('关闭报修')" class="full-btn" style="color: #FF682D;" v-if="data.state==1">
取消报修 取消报修
</view> </view>
</view> </view>
...@@ -90,62 +97,50 @@ ...@@ -90,62 +97,50 @@
export default { export default {
data() { data() {
return { return {
title: '居家报修',
type: 0, type: 0,
reason: '', reason: '',
submitShow: false, submitShow: false,
images: '', images: '',
id: '',
data: {},
}; };
}, },
onLoad(e) { onLoad(e) {
this.type = e.type this.id = e.id
if (e.type == 0) { this.getData()
this.title = "居家报修"
} else {
this.title = "公区报事"
}
}, },
methods: { methods: {
onSubmit() { getData() {
this.$wskj.to("/pagesMain/pages/tjsq?type=" + this.type) const params = {
// if (!this.reason) { url: '/api/repairs/' + this.id,
// return this.$u.toast('请输入内容') method: 'GET',
// } }
// if (!this.images) { this.$request(params).then(res => {
// return this.$u.toast('请至少上传一张照片') this.data = res.data
// } })
// if (this.reason.length < 10) { },
// return this.$u.toast('文字描述最低10个字') gb() {
// } const params = {
// this.submitShow = true url: '/api/repairs/cancel/' + this.id,
method: 'PUT',
}
this.$request(params).then(res => {
this.$wskj.toast('关闭成功')
setTimeout(() => {
this.$wskj.goBack(1)
}, 600)
})
}, },
// 提交 onCz(e) {
onConfirmSubmit() { if (e == "关闭报修") {
// const params = { this.gb();
// url: '/api/user/yijian', return
// loadingTip: '', }
// data: { if (e == "去支付") {
// content: this.reason,
// images: this.images
// }
// }
// // console.log(params);
// this.$request(params).then(res => {
// // console.log(res)
// this.submitShow = false
// if (res.code === 1) {
// this.$u.toast(res.msg || '提交成功')
// this.reason = '' return
// this.images = '' }
// } else { },
// this.$u.toast(res.msg || '提交失败')
// }
// }).catch(err => {
// this.submitShow = false
// this.$u.toast(err.msg || '提交失败')
// })
}
}, },
}; };
</script> </script>
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
}; };
}, },
onLoad(e) { onLoad(e) {
this.onGz(1) this.onGz(e.type)
}, },
methods: { methods: {
onGz(type) { onGz(type) {
......
...@@ -2,17 +2,17 @@ ...@@ -2,17 +2,17 @@
<view class="center plr-25"> <view class="center plr-25">
<view class="flex-column-center fs-30 mt-30 h-140 pb-30 br-12 plr-25" <view class="flex-column-center fs-30 mt-30 h-140 pb-30 br-12 plr-25"
style="background: linear-gradient( 90deg, #5FE8A9 0%, #1FCA7C 100%);color: white;"> style="background: linear-gradient( 90deg, #5FE8A9 0%, #1FCA7C 100%);color: white;">
<image class="w-42 h-42 mr-20" style="background-color: #1FCA7C;"></image> <image class="w-42 h-42 mr-20" src="/pagesMain/static/icon_cz_img.png"></image>
<text>{{type==0?"电费缴纳":"水费缴纳"}}</text> <text>{{type==1?"电费缴纳":"水费缴纳"}}</text>
</view> </view>
<view class="flex-column br-12 fs-28" style="background: white;margin-top: -40rpx;color: #999999;"> <view class="flex-column br-12 fs-28" style="background: white;margin-top: -40rpx;color: #999999;">
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text>户号信息</text> <text>户号信息</text>
<text>张三</text> <text>{{$wskj.isNullStr(userinfo.name)}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text>住址信息</text> <text>住址信息</text>
<text>张三</text> <text>{{userinfo.communityName+userinfo.room}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text>缴费单位</text> <text>缴费单位</text>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<view @click="onClickPrice(index)" class="grid-item" <view @click="onClickPrice(index)" class="grid-item"
:style="index==indexTab? 'color:#ffffff;background: #1FCA7C;':'color:#000000;;background:#F2F2F2;'" :style="index==indexTab? 'color:#ffffff;background: #1FCA7C;':'color:#000000;;background:#F2F2F2;'"
v-for="(item, index) in 6" :key="index"> v-for="(item, index) in 6" :key="index">
<text class="fs-32 fw-600 mtb-20">20</text> <text class="fs-32 fw-600 mtb-20">{{(index+1)*20+''}}</text>
</view> </view>
</view> </view>
</view> </view>
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
<text class="fs-32 fw-700 mr-30"></text> <text class="fs-32 fw-700 mr-30"></text>
<input style="flex: 1;text-align: left;font-size: 30rpx;" placeholder="输入缴费金额" /> <input style="flex: 1;text-align: left;font-size: 30rpx;" placeholder="输入缴费金额" />
</view> </view>
<view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;"> <view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;" @click="onSubmit()">
立即缴费 立即缴费
</view> </view>
</view> </view>
...@@ -47,36 +47,66 @@ ...@@ -47,36 +47,66 @@
data() { data() {
return { return {
indexTab: 0, indexTab: 0,
type: 0, type: 1,
money: 20,
userinfo: '',
}; };
}, },
onLoad(options) { onLoad(options) {
this.type = options.type this.type = options.type
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
onClickPrice(index) { onClickPrice(index) {
this.indexTab = index this.indexTab = index
this.money = (index + 1) * 20
}, },
onSubmit() {
onClick(index) { this.onCjdd()
if (index == 0) { },
this.$wskj.to("/pagesMain/pages/tsby_submit?type=0") onCjdd() {
return const params = {
} url: '/api/liveBill/add',
if (index == 1) { loadingTip: '',
this.$wskj.to("/pagesMain/pages/tsby_submit?type=1") data: {
return money: this.money,
} type: this.type, //类型(1电费 2水费 3物业费 4车位管理费 5车位出租费 6储藏室出租 7其他费用)
if (index == 2) { }
this.$wskj.to("/pagesMain/pages/tsby_lsgd")
return
} }
if (index == 3) { this.$request(params).then(res => {
this.$wskj.to("/pagesMain/pages/fwgz") this.pay(res.data.billId)
return })
},
pay(orderId) {
const params = {
url: '/api/payRecord/pay',
loadingTip: '',
data: {
orderId: orderId,
amount: this.money,
payBizCode: "PRESTORE",
}
} }
this.$request(params).then(res => {
uni.requestPayment({
provider: 'wxpay',
appid: res.data.data.appId, // 微信开放平台 - 应用 - AppId,注意和微信小程序、公众号 AppId 可能不一致
nonceStr: res.data.data.nonceStr, // 随机字符串
package: res.data.data.package, // 固定值
timeStamp: res.data.data.timeStamp, // 时间戳(单位:秒)
paySign: res.data.data.paySign, // 签名,这里用的 MD5/RSA 签名
signType: 'MD5',
success: (res) => {
},
fail: (err) => {
console.log(err);
}
});
})
} }
} }
}; };
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
<text>¥0</text> <text>¥0</text>
</view> </view>
</view> </view>
<view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;"> <view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;" @click="onSubmit">
立即缴费 立即缴费
</view> </view>
<u-picker :show="show" :columns="columns" closeOnClickOverlay="true" @cancel="close" @close="close" <u-picker :show="show" :columns="columns" closeOnClickOverlay="true" @cancel="close" @close="close"
...@@ -72,7 +72,53 @@ ...@@ -72,7 +72,53 @@
this.carShow = false this.carShow = false
this.carNumber = e.value[0] this.carNumber = e.value[0]
console.log("LMG", e.value[0]) console.log("LMG", e.value[0])
} },
onSubmit() {
this.onCjdd()
},
onCjdd() {
const params = {
url: '/api/liveBill/add',
loadingTip: '',
data: {
money: this.monthsNumber.replace('个月', ''),
type: 5, //类型(1电费 2水费 3物业费 4车位管理费 5车位出租费 6储藏室出租 7其他费用)
duration: this.monthsNumber.replace('个月', '') //缴费时长(月)
}
}
this.$request(params).then(res => {
this.pay(res.data.billId)
})
},
pay(orderId) {
const params = {
url: '/api/payRecord/pay',
loadingTip: '',
data: {
orderId: orderId,
amount: this.monthsNumber.replace('个月', ''),
payBizCode: "PRESTORE",
}
}
this.$request(params).then(res => {
uni.requestPayment({
provider: 'wxpay',
appid: res.data.data.appId, // 微信开放平台 - 应用 - AppId,注意和微信小程序、公众号 AppId 可能不一致
nonceStr: res.data.data.nonceStr, // 随机字符串
package: res.data.data.package, // 固定值
timeStamp: res.data.data.timeStamp, // 时间戳(单位:秒)
paySign: res.data.data.paySign, // 签名,这里用的 MD5/RSA 签名
signType: 'MD5',
success: (res) => {
},
fail: (err) => {
console.log(err);
}
});
})
},
} }
}; };
</script> </script>
......
...@@ -5,11 +5,12 @@ ...@@ -5,11 +5,12 @@
<text class="fs-32 fw-700 mt-30" style="text-align: left;padding-left: 30rpx;">其他缴费</text> <text class="fs-32 fw-700 mt-30" style="text-align: left;padding-left: 30rpx;">其他缴费</text>
<text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">项目名称</text> <text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">项目名称</text>
<view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;"> <view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;">
<input style="width: 100%;text-align: left;" placeholder="请输入项目名称" /> <input style="width: 100%;text-align: left;" placeholder="请输入项目名称" v-model="projectName" />
</view> </view>
<text class="fs-28" style="text-align: left;padding-left: 30rpx;">项目描述</text> <text class="fs-28" style="text-align: left;padding-left: 30rpx;">项目描述</text>
<view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;"> <view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;">
<textarea style="width: 100%;text-align: left;height: 120rpx;" placeholder="请输入项目描述" /> <textarea style="width: 100%;text-align: left;height: 120rpx;" placeholder="请输入项目描述"
v-model="projectInfo" />
</view> </view>
<view class="flex-column br-12 fs-28 mt-20 pad-25" style="background: white;"> <view class="flex-column br-12 fs-28 mt-20 pad-25" style="background: white;">
...@@ -20,13 +21,13 @@ ...@@ -20,13 +21,13 @@
<view @click="onClickPrice(index)" class="grid-item" <view @click="onClickPrice(index)" class="grid-item"
:style="index==indexTab? 'color:#ffffff;background: #1FCA7C;':'color:#000000;;background:#F2F2F2;'" :style="index==indexTab? 'color:#ffffff;background: #1FCA7C;':'color:#000000;;background:#F2F2F2;'"
v-for="(item, index) in 6" :key="index"> v-for="(item, index) in 6" :key="index">
<text class="fs-32 fw-600 mtb-20">20</text> <text class="fs-32 fw-600 mtb-20">{{(index+1)*20+''}}</text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;"> <view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;" @click="onSubmit()">
立即缴费 立即缴费
</view> </view>
...@@ -39,6 +40,9 @@ ...@@ -39,6 +40,9 @@
return { return {
indexTab: 0, indexTab: 0,
type: 0, type: 0,
money: 20,
projectName: '',
projectInfo: '',
}; };
}, },
...@@ -49,25 +53,62 @@ ...@@ -49,25 +53,62 @@
methods: { methods: {
onClickPrice(index) { onClickPrice(index) {
this.indexTab = index this.indexTab = index
this.money = (index + 1) * 20
}, },
onSubmit() {
onClick(index) { this.onCjdd()
if (index == 0) { },
this.$wskj.to("/pagesMain/pages/tsby_submit?type=0") onCjdd() {
if (this.$wskj.isNull(this.projectName)) {
this.$wskj.toast('请输入项目名称')
return return
} }
if (index == 1) { if (this.$wskj.isNull(this.projectInfo)) {
this.$wskj.to("/pagesMain/pages/tsby_submit?type=1") this.$wskj.toast('请输入项目描述')
return return
} }
if (index == 2) { const params = {
this.$wskj.to("/pagesMain/pages/tsby_lsgd") url: '/api/liveBill/add',
return loadingTip: '',
data: {
money: this.money,
type: 7, //类型(1电费 2水费 3物业费 4车位管理费 5车位出租费 6储藏室出租 7其他费用)
projectName: this.projectName,
projectInfo: this.projectInfo,
}
} }
if (index == 3) { this.$request(params).then(res => {
this.$wskj.to("/pagesMain/pages/fwgz") this.pay(res.data.billId)
return })
},
pay(orderId) {
const params = {
url: '/api/payRecord/pay',
loadingTip: '',
data: {
orderId: orderId,
amount: this.money,
payBizCode: "PRESTORE",
}
} }
this.$request(params).then(res => {
uni.requestPayment({
provider: 'wxpay',
appid: res.data.data.appId, // 微信开放平台 - 应用 - AppId,注意和微信小程序、公众号 AppId 可能不一致
nonceStr: res.data.data.nonceStr, // 随机字符串
package: res.data.data.package, // 固定值
timeStamp: res.data.data.timeStamp, // 时间戳(单位:秒)
paySign: res.data.data.paySign, // 签名,这里用的 MD5/RSA 签名
signType: 'MD5',
success: (res) => {
},
fail: (err) => {
console.log(err);
}
});
})
} }
} }
}; };
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
<view class="center plr-25"> <view class="center plr-25">
<view class="flex-column-center fs-30 mt-30 h-140 pb-30 br-12 plr-25" <view class="flex-column-center fs-30 mt-30 h-140 pb-30 br-12 plr-25"
style="background: linear-gradient( 90deg, #5FE8A9 0%, #1FCA7C 100%);color: white;"> style="background: linear-gradient( 90deg, #5FE8A9 0%, #1FCA7C 100%);color: white;">
<image class="w-42 h-42 mr-20" style="background-color: #1FCA7C;"></image> <image class="w-42 h-42 mr-20" src="/pagesMain/static/icon_cz_img.png"></image>
<text>停车管理费</text> <text>停车管理费</text>
</view> </view>
<view class="flex-column br-12" style="margin-top: -50rpx;background:white;"> <view class="flex-column br-12" style="margin-top: -50rpx;background:white;">
...@@ -10,15 +10,15 @@ ...@@ -10,15 +10,15 @@
<view class="flex-column br-12 fs-28" style="color: #999999;"> <view class="flex-column br-12 fs-28" style="color: #999999;">
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text>户号信息</text> <text>户号信息</text>
<text>张三</text> <text>{{$wskj.isNullStr(userinfo.name)}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text>小区名称</text> <text>小区名称</text>
<text>张三</text> <text>{{userinfo.communityName}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text>住址信息</text> <text>住址信息</text>
<text>河南利龙物业管理有限公司</text> <text>{{userinfo.room}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;" @click="open"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;" @click="open">
<text>车位号</text> <text>车位号</text>
...@@ -89,12 +89,14 @@ ...@@ -89,12 +89,14 @@
columns: [ columns: [
['T01', 'T02', 'T03', 'T04', 'T05'] ['T01', 'T02', 'T03', 'T04', 'T05']
], ],
carNumber: '' carNumber: '',
userinfo: '',
}; };
}, },
onLoad(options) { onLoad(options) {
this.type = options.type this.type = options.type
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
......
...@@ -5,11 +5,11 @@ ...@@ -5,11 +5,11 @@
<text class="fs-32 fw-700 mt-30" style="text-align: left;padding-left: 30rpx;">物业费</text> <text class="fs-32 fw-700 mt-30" style="text-align: left;padding-left: 30rpx;">物业费</text>
<text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">房屋</text> <text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">房屋</text>
<view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;"> <view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;">
<text>111111111</text> <text>{{userinfo.room}}</text>
</view> </view>
<text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">房屋面积</text> <text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">房屋面积</text>
<view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;"> <view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;">
<text>140</text> <text>{{userinfo.sqm}}</text>
</view> </view>
<text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">缴费时长</text> <text class="fs-28 mt-30" style="text-align: left;padding-left: 30rpx;">缴费时长</text>
<view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;" @click="open"> <view class="flex-row-between mar-30 br-4 pad-25" style="background: #F2F2F2;" @click="open">
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
</view> </view>
</view> </view>
<view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;"> <view class="fullscreen-btn" style="margin: 0;margin-top: 60rpx;" @click="onSubmit()">
立即缴费 立即缴费
</view> </view>
<u-picker :show="show" :columns="columns" closeOnClickOverlay="true" @cancel="close" @close="close" <u-picker :show="show" :columns="columns" closeOnClickOverlay="true" @cancel="close" @close="close"
...@@ -39,10 +39,12 @@ ...@@ -39,10 +39,12 @@
['1个月', '3个月', '6个月', '9个月', '12个月'] ['1个月', '3个月', '6个月', '9个月', '12个月']
], ],
monthsNumber: '', monthsNumber: '',
userinfo: '',
}; };
}, },
onLoad(options) { onLoad(options) {
this.type = options.type this.type = options.type
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
...@@ -56,7 +58,52 @@ ...@@ -56,7 +58,52 @@
this.show = false this.show = false
this.monthsNumber = e.value[0] this.monthsNumber = e.value[0]
console.log("LMG", e.value[0]) console.log("LMG", e.value[0])
} },
onSubmit() {
this.onCjdd()
},
onCjdd() {
const params = {
url: '/api/liveBill/add',
loadingTip: '',
data: {
money: this.monthsNumber.replace('个月', ''),
type: 3, //类型(1电费 2水费 3物业费 4车位管理费 5车位出租费 6储藏室出租 7其他费用)
duration: this.monthsNumber.replace('个月', '') //缴费时长(月)
}
}
this.$request(params).then(res => {
this.pay(res.data.billId)
})
},
pay(orderId) {
const params = {
url: '/api/payRecord/pay',
loadingTip: '',
data: {
orderId: orderId,
amount: this.monthsNumber.replace('个月', ''),
payBizCode: "PRESTORE",
}
}
this.$request(params).then(res => {
uni.requestPayment({
provider: 'wxpay',
appid: res.data.data.appId, // 微信开放平台 - 应用 - AppId,注意和微信小程序、公众号 AppId 可能不一致
nonceStr: res.data.data.nonceStr, // 随机字符串
package: res.data.data.package, // 固定值
timeStamp: res.data.data.timeStamp, // 时间戳(单位:秒)
paySign: res.data.data.paySign, // 签名,这里用的 MD5/RSA 签名
signType: 'MD5',
success: (res) => {
},
fail: (err) => {
console.log(err);
}
});
})
},
} }
}; };
</script> </script>
......
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
<view class="center plr-25"> <view class="center plr-25">
<view class="flex-column-center fs-30 mt-30 h-140 pb-30 br-12 plr-25" <view class="flex-column-center fs-30 mt-30 h-140 pb-30 br-12 plr-25"
style="background: linear-gradient( 90deg, #5FE8A9 0%, #1FCA7C 100%);color: white;"> style="background: linear-gradient( 90deg, #5FE8A9 0%, #1FCA7C 100%);color: white;">
<image class="w-42 h-42 mr-20" style="background-color: #1FCA7C;"></image> <image class="w-42 h-42 mr-20" src="/pagesMain/static/icon_cz_img.png"></image>
<text>物业费:1栋2单元205室</text> <text>物业费:{{userinfo.room}}</text>
</view> </view>
<view class="flex-column br-12" style="margin-top: -50rpx;background:white;"> <view class="flex-column br-12" style="margin-top: -50rpx;background:white;">
<view class="flex-column"> <view class="flex-column">
...@@ -63,11 +63,13 @@ ...@@ -63,11 +63,13 @@
indexTab: 1, indexTab: 1,
indexNumber: 0, indexNumber: 0,
type: 0, type: 0,
userinfo: '',
}; };
}, },
onLoad(options) { onLoad(options) {
this.type = options.type this.type = options.type
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
<view style="background: linear-gradient( 180deg, #1FCA7C 0%, #F2F2F2 100%);height: 800rpx;"></view> <view style="background: linear-gradient( 180deg, #1FCA7C 0%, #F2F2F2 100%);height: 800rpx;"></view>
<view style="margin-top: -800rpx;"></view> <view style="margin-top: -800rpx;"></view>
<view class="fs-36 fw-600 mt-30 ml-20" style="text-align: left;color: #fff;"> <view class="fs-36 fw-600 mt-30 ml-20" style="text-align: left;color: #fff;">
<text>你好,利达国宾中心1栋2单元205室</text> <text>你好,{{userinfo.communityName+userinfo.room}}</text>
</view> </view>
<view class="mar-20 br-16" style="background-color: white;flex: 1; <view class="mar-20 br-16" style="background-color: white;flex: 1;
...@@ -40,6 +40,7 @@ ...@@ -40,6 +40,7 @@
export default { export default {
data() { data() {
return { return {
userinfo: '',
listService: [{ listService: [{
img: "/pagesMain/static/icon_shjf_1.png", img: "/pagesMain/static/icon_shjf_1.png",
title: "电费", title: "电费",
...@@ -73,7 +74,7 @@ ...@@ -73,7 +74,7 @@
}; };
}, },
onLoad(options) { onLoad(options) {
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
open() { open() {
...@@ -85,11 +86,11 @@ ...@@ -85,11 +86,11 @@
}, },
onClick(index) { onClick(index) {
if (index == 0) { if (index == 0) {
this.$wskj.to("/pagesMain/pages/jnzd?type=0") this.$wskj.to("/pagesMain/pages/jnzd?type=1")
return return
} }
if (index == 1) { if (index == 1) {
this.$wskj.to("/pagesMain/pages/jnzd?type=1") this.$wskj.to("/pagesMain/pages/jnzd?type=2")
return return
} }
if (index == 2) { if (index == 2) {
......
...@@ -7,15 +7,15 @@ ...@@ -7,15 +7,15 @@
<view class="flex-column br-12 fs-28 mt-30" style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);"> <view class="flex-column br-12 fs-28 mt-30" style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);">
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text style="color: #999999;">业主姓名</text> <text style="color: #999999;">业主姓名</text>
<text>张三</text> <text>{{$wskj.isNullStr(userinfo.name)}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text style="color: #999999;">业主房间号</text> <text style="color: #999999;">业主房间号</text>
<text>张三</text> <text>{{$wskj.isNullStr(userinfo.room)}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text style="color: #999999;">业主手机号</text> <text style="color: #999999;">业主手机号</text>
<text>张三</text> <text>{{userinfo.mobile}}</text>
</view> </view>
</view> </view>
<view class="flex-column"> <view class="flex-column">
...@@ -32,12 +32,12 @@ ...@@ -32,12 +32,12 @@
export default { export default {
data() { data() {
return { return {
userinfo: '',
}; };
}, },
onLoad(options) { onLoad(options) {
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
open() { open() {
...@@ -48,11 +48,11 @@ ...@@ -48,11 +48,11 @@
}, },
onClick(index) { onClick(index) {
if (index == 0) { if (index == 0) {
this.$wskj.to("/pagesMain/pages/tsby_submit?type=0") this.$wskj.to("/pagesMain/pages/tsby_submit?type=1")
return return
} }
if (index == 1) { if (index == 1) {
this.$wskj.to("/pagesMain/pages/tsby_submit?type=1") this.$wskj.to("/pagesMain/pages/tsby_submit?type=2")
return return
} }
if (index == 2) { if (index == 2) {
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
:style="{ color: index==0?'#FF682D':index==1?'#EEA616':index==2?'#1FCA7C':'#23BBEE'}" :style="{ color: index==0?'#FF682D':index==1?'#EEA616':index==2?'#1FCA7C':'#23BBEE'}"
v-for="(item, index) in 3" :key="index"> v-for="(item, index) in 3" :key="index">
<text class="mt-20 fs-36">25</text> <text class="mt-20 fs-36">25</text>
<text class="mb-20 fs-24">待处理</text> <text class="mb-20 fs-24">{{index==0?'待处理':index==1?'已完成':index==2?'已取消':''}}</text>
<view v-if="index==tabIndex" <view v-if="index==tabIndex"
style="background: #27CC81;height: 10rpx;width: 100%;border-radius: 12rpx;"> style="background: #27CC81;height: 10rpx;width: 100%;border-radius: 12rpx;">
</view> </view>
...@@ -20,28 +20,31 @@ ...@@ -20,28 +20,31 @@
</view> </view>
</view> </view>
</view> </view>
<view style="flex:1;overflow-y:auto;"> <view class="overflow-y">
<scroll-view scroll-y style="height: 100%;"> <scroll-view scroll-y style="height: 100%;">
<view v-for="(item, index) in 8" :key="index" @click="onClick(index)"> <view v-for="(item, index) in list" :key="index" @click="onCz('详情',index)">
<view class="flex-column br-12 mt-30 mlr-24 pad-20" <view class="flex-column br-12 mt-30 mlr-24 pad-20"
style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);background: white;"> style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);background: white;">
<view class="flex vh-center mt-20"> <view class="flex vh-center mt-20">
<image class="h-25 w-25 mr-15" style="background: #1FCA7C;"> </image> <image class="h-40 w-40 mr-15" src="/static/icon_gd.png"> </image>
<text class="fs-32 fw-700" style="flex: 1;">居家报修</text> <text class="fs-32 fw-700" style="flex: 1;">{{item.type==1?'我要投诉':'我要表扬'}}</text>
<text>待处理</text> <text>{{item.state==1?'待处理':item.state==2?'已完成':item.state==3?'已关闭':''}}</text>
</view> </view>
<text class="fs-28 br-6 pad-20 mtb-20" style="background: #EBF5F0;">待处理</text> <text class="fs-28 br-6 pad-20 mtb-20"
style="background: #EBF5F0;">{{item.commentDescription}}</text>
<scroll-view scroll-x="true" scroll-with-animation="true"> <scroll-view scroll-x="true" scroll-with-animation="true">
<view class="flex"> <view class="flex">
<view class="w-140 h-140 mr-15" v-for="(itemImg, index2) in 10" :key="index2"> <view class="w-140 h-140 mr-15"
<image class="w-140 h-140" style="background: #1FCA7C;"></image> v-for="(itemImg, index2) in $wskj.splitList(item.commentImg)" :key="index2">
<image class="w-140 h-140" :src="itemImg"></image>
</view> </view>
</view> </view>
</scroll-view> </scroll-view>
<view class="flex vh-center h-60 mt-20 fs-24"> <view class="flex vh-center h-60 mt-20 fs-24">
<text style="flex: 1;color: #000;">2025-03-10 10:01:45</text> <text style="flex: 1;color: #000;">{{item.createTime}}</text>
<text style="color: #EEA616;">去支付</text> <text @tap.stop="onCz('关闭投诉表扬',index)" v-if="item.state==1"
<text style="color: #27CC81;margin-left: 30rpx;">报修详情</text> style="color: #23BBEE;">{{item.type==1?'关闭投诉':'关闭表扬'}}</text>
<text style="color: #27CC81;margin-left: 30rpx;">{{item.type==1?'投诉详情':'表扬详情'}}</text>
</view> </view>
</view> </view>
</view> </view>
...@@ -57,14 +60,48 @@ ...@@ -57,14 +60,48 @@
return { return {
type: 0, type: 0,
tabIndex: 0, tabIndex: 0,
list: [],
}; };
}, },
onLoad(e) { onLoad(e) {
this.type = e.type this.type = e.type
}, },
onShow() {
this.getList()
},
methods: { methods: {
onClick(index) { onClick(index) {
this.$wskj.to("/pagesMain/pages/bxxq") this.tabIndex = index;
this.getList()
},
onCz(e, index) {
if (e == "详情") {
this.$wskj.to("/pagesMain/pages/tsby_xq?id=" + this.list[index].id)
return
}
if (e == "关闭投诉表扬") {
this.gb(this.list[index].id);
return
}
},
getList() {
const params = {
url: '/api/comment/userListAll?state=' + (this.tabIndex + 1),
method: 'GET',
}
this.$request(params).then(res => {
this.list = res.data
})
},
gb(id) {
const params = {
url: '/api/comment/cancel/' + id,
method: 'PUT',
}
this.$request(params).then(res => {
this.getList()
})
} }
}, },
}; };
......
...@@ -7,54 +7,45 @@ ...@@ -7,54 +7,45 @@
</view> </view>
<view class="mar-20"> <view class="mar-20">
<view class="flex-column-center"> <view class="flex-column-center">
<image class="w-20 h-20" style="background-color: #1FCA7C;"></image> <image class="w-30 h-30" src="/static/icon_home_dw.png"></image>
<text>利达国宾中心</text> <text>{{userinfo.communityName}}</text>
</view> </view>
<view class="flex-column-center fs-32 fw-700 mt-30"> <view class="flex-column-center fs-32 fw-700 mt-30 ml-10">
<image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image> <image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image>
<text>业主信息</text> <text>业主信息</text>
</view> </view>
<view class="flex-column br-12 fs-28 mt-30" style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);"> <view class="flex-column br-12 fs-28 mt-30" style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);">
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text style="color: #999999;">业主姓名</text> <text style="color: #999999;">业主姓名</text>
<text>张三</text> <text>{{$wskj.isNullStr(userinfo.name)}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text style="color: #999999;">业主房间号</text> <text style="color: #999999;">业主房间号</text>
<text>张三</text> <text>{{$wskj.isNullStr(userinfo.room)}}</text>
</view> </view>
<view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;"> <view class="flex-row-between pad-30" style="border-bottom: 1rpx solid #E9E9E9;">
<text style="color: #999999;">业主手机号</text> <text style="color: #999999;">业主手机号</text>
<text>张三</text> <text>{{userinfo.mobile}}</text>
</view> </view>
</view> </view>
<view class="flex-column-center fs-32 fw-700 mt-30"> <view class="flex-column-center fs-32 fw-700 mt-30">
<image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image> <image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image>
<text>报修信息</text> <text>{{type == 1?'投诉信息':'表扬信息'}}</text>
</view> </view>
<view class="flex-column br-12 fs-28 mt-30 pad-30" <view class="flex-column br-12 fs-28 mt-30 pad-30"
style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);"> style="box-shadow: 0px 0px 15px 1px rgba(142,142,142,0.16);">
<u--textarea v-model="reason" height="260rpx" maxlength="100" placeholder="填写下详细报修内容,有助于工作人员快速帮您解决问题" <u--textarea v-model="reason" height="260rpx" maxlength="100" placeholder="请输入信息" count
count border="border"></u--textarea> border="border"></u--textarea>
<view class="mt-30"> <view class="mt-30">
<upload-image v-model="images" maxCount="3" width="70" height="70" type="fullurl"></upload-image> <upload-image @upload="upload" v-model="imgurl" maxCount="3" width="70" height="70"
type="fullurl"></upload-image>
</view> </view>
</view> </view>
</view> </view>
<view @click="onSubmit" class="fullscreen-btn mt-50"> <view @click="onSubmit" class="fullscreen-btn">
<text>提交</text> <text>提交</text>
</view> </view>
<!-- 提交 -->
<wskj-modal :show="submitShow" :showCancelButton="true" confirmText="确定" confirmColor="#EB7318"
@close="submitShow = false" @confirm="onConfirmSubmit" @cancel="submitShow = false">
<view class="pt-40 pb-40">
<view>
<text class="fs-28">确认提交?</text>
</view>
</view>
</wskj-modal>
</view> </view>
</template> </template>
...@@ -65,58 +56,48 @@ ...@@ -65,58 +56,48 @@
title: '我要投诉', title: '我要投诉',
type: 0, type: 0,
reason: '', reason: '',
submitShow: false,
images: '', images: '',
userinfo: '',
}; };
}, },
onLoad(e) { onLoad(e) {
this.type = e.type this.type = e.type
if (e.type == 0) { if (e.type == 1) {
this.title = "我要投诉" this.title = "我要投诉"
} else { } else {
this.title = "我要表扬" this.title = "我要表扬"
} }
this.userinfo = uni.getStorageSync("userInfo")
}, },
methods: { methods: {
onSubmit() { upload(e) {
this.$wskj.to("/pagesMain/pages/tjsq?type=" + this.type) this.images = e
// if (!this.reason) {
// return this.$u.toast('请输入内容')
// }
// if (!this.images) {
// return this.$u.toast('请至少上传一张照片')
// }
// if (this.reason.length < 10) {
// return this.$u.toast('文字描述最低10个字')
// }
// this.submitShow = true
}, },
// 提交 onSubmit() {
onConfirmSubmit() { console.log(this.images)
// const params = { if (!this.reason) {
// url: '/api/user/yijian', this.$wskj.toast('请输入表扬信息');
// loadingTip: '', return
// data: { }
// content: this.reason, if (!this.images) {
// images: this.images this.$wskj.toast('请上传图片');
// } return
// } }
// // console.log(params); const params = {
// this.$request(params).then(res => { url: '/api/comment/add',
// // console.log(res) loadingTip: '加载中...',
// this.submitShow = false data: {
// if (res.code === 1) { commentDescription: this.reason,
// this.$u.toast(res.msg || '提交成功') commentImg: this.images,
type: this.type
// this.reason = '' }
// this.images = '' }
// } else { this.$request(params).then(res => {
// this.$u.toast(res.msg || '提交失败') this.$wskj.toast('提交成功')
// } setTimeout(() => {
// }).catch(err => { this.$wskj.goBack(1)
// this.submitShow = false }, 600)
// this.$u.toast(err.msg || '提交失败') })
// })
} }
}, },
}; };
......
<template>
<view class='center'>
<view style="background: linear-gradient( 180deg, #1FCA7C 0%, #F2F2F2 100%);">
<u-navbar :autoBack="true" :title="data.type==1?'投诉详情':'表扬详情'" placeholder="true" bgColor="transparent"
leftIconColor="#FFF" :title-style="{color: '#FFF'}">
</u-navbar>
<view class="h-300 flex flex-row-between v-center ml-60 mr-35">
<view class="flex-column" style="color: #1BB871;">
<text class="fs-52">{{data.type==1?'今日投诉':'今日表扬'}}</text>
<text class="fs-30">{{data.type==1?'投诉详情我知道':'表扬详情我知道'}}</text>
</view>
<image class="h-225 w-225" src="/pagesMain/static/icon_bxxq.png"></image>
</view>
</view>
<view class="overflow-y"
style="background: white;border-top-left-radius: 20rpx;border-top-right-radius: 20rpx;margin-top: -20rpx;">
<scroll-view scroll-y style="height: 100%;">
<view class="mar-20">
<view class="flex-column-center">
<image class="w-40 h-40 mr-10" src="/static/icon_gd.png"></image>
<text style="flex: 1;text-align: left;"
class="fs-32 fw-700">{{data.type==1?'我要投诉':'我要表扬'}}</text>
<text
style="font-size: 24rpx;color: #EEA616;">{{data.state==1?'待处理':data.state==2?'已完成':data.state==3?'已关闭':''}}</text>
</view>
<view class="flex-column br-12 fs-28 mt-30" style="background: #EBF5F0;">
<view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">业主姓名:</text>
<text>{{$wskj.isNullStr(userinfo.name)}}</text>
</view>
<view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">业主房间号</text>
<text>{{$wskj.isNullStr(userinfo.room)}}</text>
</view>
<view class="flex pad-30">
<text class="fw-700 w-200" style="text-align: left;">业主手机号</text>
<text>{{userinfo.mobile}}</text>
</view>
</view>
<view class="flex-column-center fs-32 fw-700 mt-30">
<image class="w-10 h-40 mr-15" style="background-color: #1FCA7C;"></image>
<text>{{data.type==1?'投诉信息':'表扬信息'}}</text>
</view>
<view class="flex-column br-12 fs-28 mtb-30 pad-30" style="background: #EBF5F0;">
<text style="text-align: left;">{{data.commentDescription}}</text>
</view>
<scroll-view scroll-x="true" scroll-with-animation="true">
<view class="flex">
<view class="w-140 h-140 mr-15"
v-for="(itemImg, index2) in $wskj.splitList(data.commentImg)" :key="index2">
<image class="w-140 h-140" :src="itemImg"></image>
</view>
</view>
</scroll-view>
<view class="flex mt-20 fs-28">
<text class="fw-700">{{data.type==1?'投诉时间:':'表扬时间:'}}</text>
<text>{{data.createTime}}</text>
</view>
<view v-if="data.state==3" class="flex pad-30 br-12 mt-30" style="background: #EBF5F0;">
<text class="fw-700 w-200" style="text-align: left;">关闭时间:</text>
<text>{{data.closeTime}}</text>
</view>
</view>
</scroll-view>
</view>
<view class="h-140 pt-20">
<view @click="onCz('关闭报修')" class="full-btn" style="color: #FF682D;" v-if="data.state==1">
{{data.type==1?'关闭投诉':'关闭表扬'}}
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
type: 0,
reason: '',
submitShow: false,
images: '',
id: '',
data: {},
userinfo: '',
};
},
onLoad(e) {
this.id = e.id
this.userinfo = uni.getStorageSync("userInfo")
this.getData()
},
methods: {
getData() {
const params = {
url: '/api/comment/' + this.id,
method: 'GET',
}
this.$request(params).then(res => {
this.data = res.data
})
},
gb() {
const params = {
url: '/api/comment/cancel/' + this.id,
method: 'PUT',
}
this.$request(params).then(res => {
this.$wskj.toast('关闭成功')
setTimeout(() => {
this.$wskj.goBack(1)
}, 600)
})
},
onCz(e) {
if (e == "关闭报修") {
this.gb();
return
}
},
},
};
</script>
<style scoped>
.center {
height: 100vh;
display: flex;
flex-direction: column;
background: white;
}
</style>
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment