Compare commits
3 Commits
06bcc516d0
...
1f7eebd66a
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1f7eebd66a | ||
|
|
15288eaa10 | ||
|
|
f2acabac3f |
@ -1,6 +1,6 @@
|
|||||||
export const apiArr = {
|
export const apiArr = {
|
||||||
getUserInfo: '/api/v2/wechat/mpuser-crud/info', // 获取城市列表
|
getUserInfo: '/api/v2/wechat/mpuser-crud/info', // 获取城市列表
|
||||||
userInfoUpdate: '/api/v2/wechat/mpuser-crud/update', // 会员信息更新
|
userInfoUpdate: '/api/v2/wechat/mpuser-crud/update', // 会员信息更新
|
||||||
getAccumulationFund: '/api/v2/wechat/government-housing-fund-flow-crud/page', // 物业费公积金
|
getAccumulationFund: '/api/v2/wechat/government-housing-fund-flow-crud/page', // 物业费
|
||||||
getPoints: '/api/v2/wechat/member-points-flow-crud/page', // 积分
|
getPoints: '/api/v2/wechat/member-points-flow-crud/page', // 积分
|
||||||
}
|
}
|
||||||
@ -172,7 +172,7 @@
|
|||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="row">
|
<view class="row">
|
||||||
<view class="row_label">物业费公积金抵扣金额</view>
|
<view class="row_label">物业费抵扣金额</view>
|
||||||
<view class="row_con4">-¥{{ item.property_housing_fund }}</view>
|
<view class="row_con4">-¥{{ item.property_housing_fund }}</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -298,6 +298,15 @@ export default {
|
|||||||
this.localHeight = meun.height;
|
this.localHeight = meun.height;
|
||||||
this.currentCommunity = uni.getStorageSync("changeCommData");
|
this.currentCommunity = uni.getStorageSync("changeCommData");
|
||||||
this.currentCommunityAddr = uni.getStorageSync("currentCommunityAddr");
|
this.currentCommunityAddr = uni.getStorageSync("currentCommunityAddr");
|
||||||
|
// 解析从providentFund页面传递过来的房源信息
|
||||||
|
if (options.item) {
|
||||||
|
try {
|
||||||
|
const item = JSON.parse(decodeURIComponent(options.item));
|
||||||
|
this.currentRoom = item;
|
||||||
|
} catch (error) {
|
||||||
|
console.error("解析房源信息失败:", error);
|
||||||
|
}
|
||||||
|
}
|
||||||
this.getRoomSelect();
|
this.getRoomSelect();
|
||||||
this.getUserGovenmentMoney();
|
this.getUserGovenmentMoney();
|
||||||
},
|
},
|
||||||
@ -330,7 +339,7 @@ export default {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
// 滑动到底部生命周期函数
|
// 滑动到底部生命周期函数
|
||||||
onReachBottom() {
|
onReachBottom() {
|
||||||
// 只有在缴费记录页面且还有更多数据时才触发加载更多
|
// 只有在缴费记录页面且还有更多数据时才触发加载更多
|
||||||
@ -379,7 +388,9 @@ export default {
|
|||||||
page_size: 50,
|
page_size: 50,
|
||||||
}).then((res) => {
|
}).then((res) => {
|
||||||
this.roomList = res.rows;
|
this.roomList = res.rows;
|
||||||
this.currentRoom = this.roomList[0];
|
if (!this.currentRoom.room_id) {
|
||||||
|
this.currentRoom = this.roomList[0]
|
||||||
|
}
|
||||||
this.selectedRoomId = this.currentRoom.room_id;
|
this.selectedRoomId = this.currentRoom.room_id;
|
||||||
this.getOrderList().then(() => {
|
this.getOrderList().then(() => {
|
||||||
resolve();
|
resolve();
|
||||||
@ -401,7 +412,7 @@ export default {
|
|||||||
|
|
||||||
this.currentRoom = item;
|
this.currentRoom = item;
|
||||||
this.getOrderList();
|
this.getOrderList();
|
||||||
|
|
||||||
// 如果当前是缴费记录标签页,重新请求缴费记录数据
|
// 如果当前是缴费记录标签页,重新请求缴费记录数据
|
||||||
if (this.active === 1) {
|
if (this.active === 1) {
|
||||||
// 重置分页参数
|
// 重置分页参数
|
||||||
@ -687,7 +698,7 @@ export default {
|
|||||||
flag = false;
|
flag = false;
|
||||||
}
|
}
|
||||||
this.flag = flag;
|
this.flag = flag;
|
||||||
|
|
||||||
// 如果是第一页,直接替换数据;如果是加载更多,追加数据
|
// 如果是第一页,直接替换数据;如果是加载更多,追加数据
|
||||||
if (this.page_num === 1) {
|
if (this.page_num === 1) {
|
||||||
this.payOrderList = res.rows || [];
|
this.payOrderList = res.rows || [];
|
||||||
|
|||||||
@ -49,7 +49,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="label fix">
|
<view class="label fix">
|
||||||
<text>物业费公积金总余额</text>
|
<text>物业费总余额</text>
|
||||||
<u-icon
|
<u-icon
|
||||||
name="info-circle-fill"
|
name="info-circle-fill"
|
||||||
size="30rpx"
|
size="30rpx"
|
||||||
@ -219,7 +219,7 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
goPay() {
|
goPay() {
|
||||||
NavgateTo("../propertyPayment/index");
|
NavgateTo("../propertyPayment/index?item=" + encodeURIComponent(JSON.stringify(this.defaultName)));
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@ -1,4 +1,3 @@
|
|||||||
packages/customerService/index/index
|
|
||||||
<template>
|
<template>
|
||||||
<view class="chat-container">
|
<view class="chat-container">
|
||||||
<!-- 聊天头部 -->
|
<!-- 聊天头部 -->
|
||||||
@ -17,7 +16,7 @@ packages/customerService/index/index
|
|||||||
|
|
||||||
<!-- 聊天消息区域 -->
|
<!-- 聊天消息区域 -->
|
||||||
<scroll-view :scroll-into-view="scrollToView" class="chat-messages" lower-threshold="100" scroll-y="true"
|
<scroll-view :scroll-into-view="scrollToView" class="chat-messages" lower-threshold="100" scroll-y="true"
|
||||||
upper-threshold="100" @scrolltolower="loadMoreHistory" @scrolltoupper="loadMoreHistory">
|
upper-threshold="100" @scrolltolower="loadMoreHistory" @scrolltoupper="loadMoreHistory">
|
||||||
<!-- 加载历史消息提示 -->
|
<!-- 加载历史消息提示 -->
|
||||||
<view v-if="isLoadingHistory" class="message-time">加载历史消息...</view>
|
<view v-if="isLoadingHistory" class="message-time">加载历史消息...</view>
|
||||||
|
|
||||||
@ -32,8 +31,8 @@ packages/customerService/index/index
|
|||||||
'other': !message.isSelf,
|
'other': !message.isSelf,
|
||||||
'loading': message.isLoading
|
'loading': message.isLoading
|
||||||
}" class="message-item">
|
}" class="message-item">
|
||||||
<image :src="message.isSelf ? userAvatar : getAvatarUrl(message)" class="message-avatar"
|
<image :src="message.isSelf ? userAvatar : getAvatarUrl(message)" class="message-avatar" mode="aspectFill">
|
||||||
mode="aspectFill"></image>
|
</image>
|
||||||
<view class="message-content">
|
<view class="message-content">
|
||||||
{{ message.content }}
|
{{ message.content }}
|
||||||
</view>
|
</view>
|
||||||
@ -44,10 +43,9 @@ packages/customerService/index/index
|
|||||||
<!-- 输入区域 -->
|
<!-- 输入区域 -->
|
||||||
<view class="chat-input-area">
|
<view class="chat-input-area">
|
||||||
<view class="input-container">
|
<view class="input-container">
|
||||||
<textarea v-model="inputMessage" :adjust-position="true" auto-height class="message-input"
|
<textarea v-model="inputMessage" :adjust-position="true" auto-height class="message-input" cursor-spacing="10"
|
||||||
cursor-spacing="10" enable-keyboard-accessory-view="true" hold-keyboard="true" maxlength="500"
|
enable-keyboard-accessory-view="true" hold-keyboard="true" maxlength="500" placeholder="请输入消息..."
|
||||||
placeholder="请输入消息..." @blur="onInputBlur" @confirm="sendMessage" @focus="onInputFocus"
|
@blur="onInputBlur" @confirm="sendMessage" @focus="onInputFocus" @input="handleInput"></textarea>
|
||||||
@input="handleInput"></textarea>
|
|
||||||
<button :disabled="inputMessage.trim() === ''" class="send-btn" @tap="sendMessage">
|
<button :disabled="inputMessage.trim() === ''" class="send-btn" @tap="sendMessage">
|
||||||
发送
|
发送
|
||||||
</button>
|
</button>
|
||||||
@ -62,7 +60,7 @@ import { apiArr } from '@/api/customerService'
|
|||||||
import mqttTool from '@/utils/mqtt'
|
import mqttTool from '@/utils/mqtt'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data(){
|
data() {
|
||||||
return {
|
return {
|
||||||
localHeight: '',
|
localHeight: '',
|
||||||
top: '',
|
top: '',
|
||||||
@ -106,7 +104,7 @@ export default {
|
|||||||
scrollToBottomFlag: false
|
scrollToBottomFlag: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad(options){
|
onLoad(options) {
|
||||||
const meun = menuButtonInfo()
|
const meun = menuButtonInfo()
|
||||||
this.top = meun.top
|
this.top = meun.top
|
||||||
this.localHeight = meun.height
|
this.localHeight = meun.height
|
||||||
@ -119,7 +117,10 @@ export default {
|
|||||||
this.chatTarget = item
|
this.chatTarget = item
|
||||||
console.log('客户找客服跳转:', this.chatTarget)
|
console.log('客户找客服跳转:', this.chatTarget)
|
||||||
this.chatTarget.title = this.chatTarget.employee_name
|
this.chatTarget.title = this.chatTarget.employee_name
|
||||||
this.getMqttConfig()
|
this.getMqttConfig().then(() => {
|
||||||
|
// 获取配置后再初始化聊天
|
||||||
|
this.initChat()
|
||||||
|
})
|
||||||
} else {
|
} else {
|
||||||
// 客服选择聊天列表进来
|
// 客服选择聊天列表进来
|
||||||
this.chatTarget = item
|
this.chatTarget = item
|
||||||
@ -131,20 +132,20 @@ export default {
|
|||||||
} else {
|
} else {
|
||||||
this.chatTarget.openId = this.chatTarget.client_id_one
|
this.chatTarget.openId = this.chatTarget.client_id_one
|
||||||
}
|
}
|
||||||
|
// 初始化MQTT连接
|
||||||
|
this.initChat()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 初始化MQTT连接
|
|
||||||
this.initChat()
|
|
||||||
// 初始化用户头像
|
// 初始化用户头像
|
||||||
this.userAvatar = picUrl + uni.getStorageSync('headPhoto')
|
this.userAvatar = picUrl + uni.getStorageSync('headPhoto')
|
||||||
},
|
},
|
||||||
onShow(){
|
onShow() {
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
getAvatarUrl(record){
|
getAvatarUrl(record) {
|
||||||
return this.chatTarget.employee_image ? this.chatTarget.employee_image : 'https://wechat-img-file.oss-cn-beijing.aliyuncs.com/property-img-file/defaultTx.png'
|
return this.chatTarget.employee_image ? this.chatTarget.employee_image : 'https://wechat-img-file.oss-cn-beijing.aliyuncs.com/property-img-file/defaultTx.png'
|
||||||
},
|
},
|
||||||
async connect(){
|
async connect() {
|
||||||
this.client = null
|
this.client = null
|
||||||
const options = {
|
const options = {
|
||||||
clientId: this.selfClientId
|
clientId: this.selfClientId
|
||||||
@ -196,7 +197,7 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
async subscribe(){
|
async subscribe() {
|
||||||
if (this.isConnected && this.client) {
|
if (this.isConnected && this.client) {
|
||||||
this.client.subscribe('contact/message/receive_msg', { qos: 0 }, (err) => {
|
this.client.subscribe('contact/message/receive_msg', { qos: 0 }, (err) => {
|
||||||
if (!err) {
|
if (!err) {
|
||||||
@ -213,7 +214,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
// 初始化聊天
|
// 初始化聊天
|
||||||
async initChat(){
|
async initChat() {
|
||||||
try {
|
try {
|
||||||
// 显示连接状态
|
// 显示连接状态
|
||||||
this.connectingStatus = '正在连接客服...'
|
this.connectingStatus = '正在连接客服...'
|
||||||
@ -234,7 +235,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 获取MQTT连接配置
|
// 获取MQTT连接配置
|
||||||
async getMqttConfig(){
|
async getMqttConfig() {
|
||||||
console.log('🚀 ~ onLoad ~ this.chatTarget.open_id:', this.chatTarget.open_id)
|
console.log('🚀 ~ onLoad ~ this.chatTarget.open_id:', this.chatTarget.open_id)
|
||||||
try {
|
try {
|
||||||
// 如果没有已创建的实例或clientId,则通过API获取
|
// 如果没有已创建的实例或clientId,则通过API获取
|
||||||
@ -270,7 +271,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// MQTT断开连接回调
|
// MQTT断开连接回调
|
||||||
onDisconnect(packet){
|
onDisconnect(packet) {
|
||||||
console.log('MQTT连接断开', packet)
|
console.log('MQTT连接断开', packet)
|
||||||
this.isConnected = false
|
this.isConnected = false
|
||||||
this.client = null
|
this.client = null
|
||||||
@ -289,7 +290,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 加载历史消息
|
// 加载历史消息
|
||||||
async loadHistoryMessages(){
|
async loadHistoryMessages() {
|
||||||
if (!this.hasMoreHistory || this.isLoadingHistory) {
|
if (!this.hasMoreHistory || this.isLoadingHistory) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -322,18 +323,16 @@ export default {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// 将获取到的历史消息添加到消息列表开头
|
// 处理历史消息,转换为需要的格式
|
||||||
// 这里需要根据消息的发送方判断是否是自己发送的消息
|
const formattedMessages = historyMessages.map(msg => ({
|
||||||
historyMessages.map(msg => (
|
content: msg.content,
|
||||||
this.messages = [{
|
time: new Date(msg.create_time).getTime(),
|
||||||
content: msg.content,
|
isSelf: msg.send_client === this.selfClientId, // 修正判断条件
|
||||||
time: new Date(msg.create_time).getTime(),
|
isLoading: false
|
||||||
isSelf: msg.send_client === this.chatTarget.openId,
|
})).reverse(); // 反转消息顺序,确保最早的消息在最前面
|
||||||
isLoading: false
|
|
||||||
}, ...this.messages])) // 因为是按时间降序获取的,所以需要反转
|
|
||||||
|
|
||||||
// 添加到消息列表开头
|
// 将格式化后的历史消息添加到消息列表开头
|
||||||
// this.messages = [...formattedMessages, ...this.messages]
|
this.messages = [...formattedMessages, ...this.messages]
|
||||||
|
|
||||||
// 增加页码
|
// 增加页码
|
||||||
this.pageNum++
|
this.pageNum++
|
||||||
@ -346,9 +345,9 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 加载更多历史消息
|
// 加载更多历史消息
|
||||||
loadMoreHistory(e){
|
loadMoreHistory(e) {
|
||||||
// 只有当滚动到顶部时才加载更多历史消息
|
// 当滚动到顶部时加载更多历史消息
|
||||||
if (!e || e.detail.direction === 'top') {
|
if (e && e.detail.direction === 'top') {
|
||||||
if (!this.isLoadingHistory && this.hasMoreHistory) {
|
if (!this.isLoadingHistory && this.hasMoreHistory) {
|
||||||
this.loadHistoryMessages()
|
this.loadHistoryMessages()
|
||||||
}
|
}
|
||||||
@ -356,7 +355,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 发送消息
|
// 发送消息
|
||||||
sendMessage(){
|
sendMessage() {
|
||||||
const content = this.inputMessage.trim()
|
const content = this.inputMessage.trim()
|
||||||
console.log('发送消息', content)
|
console.log('发送消息', content)
|
||||||
if (!content || !this.client || !this.isConnected) return
|
if (!content || !this.client || !this.isConnected) return
|
||||||
@ -365,7 +364,7 @@ export default {
|
|||||||
console.log('需要发送的对象', this.chatTarget)
|
console.log('需要发送的对象', this.chatTarget)
|
||||||
// 按照用户提供的格式构建发送消息
|
// 按照用户提供的格式构建发送消息
|
||||||
const msgData = {
|
const msgData = {
|
||||||
bind_id: this.chatTarget.bindId, // 聊天列表的ID,这里暂时固定为1
|
bind_id: this.chatTarget.bindId, // 聊天列表的ID
|
||||||
send_client: this.selfClientId, // 消息发送方open_id
|
send_client: this.selfClientId, // 消息发送方open_id
|
||||||
receive_client: this.chatTarget.openId, // 消息接收方open_id
|
receive_client: this.chatTarget.openId, // 消息接收方open_id
|
||||||
type: 1, // 消息类型,1表示文字消息
|
type: 1, // 消息类型,1表示文字消息
|
||||||
@ -374,17 +373,17 @@ export default {
|
|||||||
}
|
}
|
||||||
console.log('发送消息', msgData)
|
console.log('发送消息', msgData)
|
||||||
this.client.publish(
|
this.client.publish(
|
||||||
'contact/message/send_msg', // 使用指定的发送消息主题
|
'contact/message/send_msg', // 使用指定的发送消息主题
|
||||||
JSON.stringify(msgData),
|
JSON.stringify(msgData),
|
||||||
{ Qos: 0 },
|
{ Qos: 0 },
|
||||||
(err) => {
|
(err) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
console.error('发送消息失败', err)
|
console.error('发送消息失败', err)
|
||||||
// 可以在这里添加消息发送失败的处理逻辑
|
// 可以在这里添加消息发送失败的处理逻辑
|
||||||
} else {
|
} else {
|
||||||
console.log('发送消息成功')
|
console.log('发送消息成功')
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
// 清空输入框
|
// 清空输入框
|
||||||
@ -392,11 +391,11 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 处理输入事件
|
// 处理输入事件
|
||||||
handleInput(){
|
handleInput() {
|
||||||
this.canSend = this.inputMessage.trim().length > 0
|
this.canSend = this.inputMessage.trim().length > 0
|
||||||
},
|
},
|
||||||
|
|
||||||
onInputFocus(){
|
onInputFocus() {
|
||||||
// 输入框获取焦点时,设置滚动到底部的标记
|
// 输入框获取焦点时,设置滚动到底部的标记
|
||||||
this.scrollToBottomFlag = true
|
this.scrollToBottomFlag = true
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
@ -406,13 +405,13 @@ export default {
|
|||||||
}, 300)
|
}, 300)
|
||||||
},
|
},
|
||||||
|
|
||||||
onInputBlur(){
|
onInputBlur() {
|
||||||
// 输入框失去焦点时,重置滚动标记
|
// 输入框失去焦点时,重置滚动标记
|
||||||
this.scrollToBottomFlag = false
|
this.scrollToBottomFlag = false
|
||||||
},
|
},
|
||||||
|
|
||||||
// 是否需要显示时间分割线
|
// 是否需要显示时间分割线
|
||||||
needShowTime(index){
|
needShowTime(index) {
|
||||||
if (index === 0) return true
|
if (index === 0) return true
|
||||||
|
|
||||||
const currentMsg = this.messages[index]
|
const currentMsg = this.messages[index]
|
||||||
@ -423,28 +422,28 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 格式化时间
|
// 格式化时间
|
||||||
formatTime(time){
|
formatTime(time) {
|
||||||
const date = new Date(time)
|
const date = new Date(time)
|
||||||
const hours = date.getHours().toString().padStart(2, '0')
|
const hours = date.getHours().toString().padStart(2, '0')
|
||||||
const minutes = date.getMinutes().toString().padStart(2, '0')
|
const minutes = date.getMinutes().toString().padStart(2, '0')
|
||||||
|
|
||||||
return `${ hours }:${ minutes }`
|
return `${hours}:${minutes}`
|
||||||
},
|
},
|
||||||
|
|
||||||
// 滚动到底部
|
// 滚动到底部
|
||||||
scrollToBottom(){
|
scrollToBottom() {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.scrollToView = 'msg-' + (this.messages.length - 1)
|
this.scrollToView = 'msg-' + (this.messages.length - 1)
|
||||||
}, 100)
|
}, 100)
|
||||||
},
|
},
|
||||||
|
|
||||||
// 返回上一页
|
// 返回上一页
|
||||||
goBack(){
|
goBack() {
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
},
|
},
|
||||||
|
|
||||||
// 启动心跳包 - 增强版:添加错误处理和状态检查
|
// 启动心跳包 - 增强版:添加错误处理和状态检查
|
||||||
startKeepalive(){
|
startKeepalive() {
|
||||||
// 停止之前的定时器
|
// 停止之前的定时器
|
||||||
this.stopKeepalive()
|
this.stopKeepalive()
|
||||||
|
|
||||||
@ -456,20 +455,20 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.client.publish(
|
this.client.publish(
|
||||||
'contact/message/keep_time',
|
'contact/message/keep_time',
|
||||||
JSON.stringify(keepaliveData),
|
JSON.stringify(keepaliveData),
|
||||||
{},
|
{},
|
||||||
(err) => {
|
(err) => {
|
||||||
if (err) {
|
if (err) {
|
||||||
console.error('发送心跳包失败', err)
|
console.error('发送心跳包失败', err)
|
||||||
// 心跳包发送失败可能表示连接有问题,可以考虑触发重连
|
// 心跳包发送失败可能表示连接有问题,可以考虑触发重连
|
||||||
if (!this.isConnected) {
|
if (!this.isConnected) {
|
||||||
return
|
return
|
||||||
}
|
|
||||||
console.log('心跳包发送失败,尝试检查连接状态')
|
|
||||||
// 这里可以添加额外的连接检查逻辑
|
|
||||||
}
|
}
|
||||||
|
console.log('心跳包发送失败,尝试检查连接状态')
|
||||||
|
// 这里可以添加额外的连接检查逻辑
|
||||||
}
|
}
|
||||||
|
}
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
console.warn('MQTT未连接,停止心跳包')
|
console.warn('MQTT未连接,停止心跳包')
|
||||||
@ -479,7 +478,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 停止心跳包
|
// 停止心跳包
|
||||||
stopKeepalive(){
|
stopKeepalive() {
|
||||||
if (this.keepaliveTimer) {
|
if (this.keepaliveTimer) {
|
||||||
clearInterval(this.keepaliveTimer)
|
clearInterval(this.keepaliveTimer)
|
||||||
this.keepaliveTimer = null
|
this.keepaliveTimer = null
|
||||||
@ -487,7 +486,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 跳转到切换客服页面
|
// 跳转到切换客服页面
|
||||||
goToChangeService(){
|
goToChangeService() {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: '/packages/customerService/changeService/index?currentMchId=' + this.chatTarget.mchId
|
url: '/packages/customerService/changeService/index?currentMchId=' + this.chatTarget.mchId
|
||||||
})
|
})
|
||||||
@ -495,10 +494,10 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
// 页面卸载时停止心跳包
|
// 页面卸载时停止心跳包
|
||||||
onUnload(){
|
onUnload() {
|
||||||
// 断开MQTT连接
|
// 断开MQTT连接
|
||||||
if (this.client) {
|
if (this.client) {
|
||||||
this.client.disconnect()
|
this.client.end()
|
||||||
}
|
}
|
||||||
|
|
||||||
// 停止心跳包
|
// 停止心跳包
|
||||||
|
|||||||
@ -5,12 +5,12 @@
|
|||||||
<u-icon bold color="#fff" size="40" name="arrow-left" @click="back"></u-icon>
|
<u-icon bold color="#fff" size="40" name="arrow-left" @click="back"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<div class="text1">物业费公积金</div>
|
<div class="text1">物业费</div>
|
||||||
<div class="text2">¥{{banlance}}</div>
|
<div class="text2">¥{{banlance}}</div>
|
||||||
<div class="total">全部房源合计</div>
|
<div class="total">全部房源合计</div>
|
||||||
<div class="text3">
|
<div class="text3">
|
||||||
<span>全部房源</span>
|
<span>全部房源</span>
|
||||||
物业费公积金流水
|
物业费流水
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="orderList">
|
<div class="orderList">
|
||||||
|
|||||||
@ -58,7 +58,7 @@
|
|||||||
|
|
||||||
<view class="btnList">
|
<view class="btnList">
|
||||||
<view class="btnItem" @click="payList">付款记录</view>
|
<view class="btnItem" @click="payList">付款记录</view>
|
||||||
<!-- <view class="btnItem" @click="homeMoneList">物业费公积金</view> -->
|
<!-- <view class="btnItem" @click="homeMoneList">物业费</view> -->
|
||||||
<view class="line"></view>
|
<view class="line"></view>
|
||||||
<view class="btnItem" @click="home">首页</view>
|
<view class="btnItem" @click="home">首页</view>
|
||||||
<view class="line"></view>
|
<view class="line"></view>
|
||||||
|
|||||||
@ -197,8 +197,10 @@ export default {
|
|||||||
title: '提交成功',
|
title: '提交成功',
|
||||||
icon: 'success'
|
icon: 'success'
|
||||||
})
|
})
|
||||||
// 提交成功后,重置表单
|
// 提交成功后,延迟1秒再重置表单
|
||||||
this.getInfo(this.taskId);
|
setTimeout(() => {
|
||||||
|
this.getInfo(this.taskId);
|
||||||
|
}, 1000);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
uni.hideLoading();
|
uni.hideLoading();
|
||||||
console.error('提交失败', error)
|
console.error('提交失败', error)
|
||||||
|
|||||||
@ -24,7 +24,7 @@
|
|||||||
|
|
||||||
<!-- 余额变动记录 -->
|
<!-- 余额变动记录 -->
|
||||||
<view class="records-container">
|
<view class="records-container">
|
||||||
<view class="records-title" v-if="topVal == '待收物业费'">物业费公积金变动记录</view>
|
<view class="records-title" v-if="topVal == '待收物业费'">物业费变动记录</view>
|
||||||
<view v-if="records.length == 0">
|
<view v-if="records.length == 0">
|
||||||
<view class="records-list">暂无变动记录</view>
|
<view class="records-list">暂无变动记录</view>
|
||||||
</view>
|
</view>
|
||||||
|
|||||||
@ -73,6 +73,14 @@ page {
|
|||||||
background-color: #f5f5f5;
|
background-color: #f5f5f5;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.search_input{
|
||||||
|
width: 55%;
|
||||||
|
height: 50rpx;
|
||||||
|
line-height: 50rpx;
|
||||||
|
padding: 0 15rpx;
|
||||||
|
color: #666;
|
||||||
|
}
|
||||||
|
|
||||||
.searchBox2 {
|
.searchBox2 {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|||||||
@ -33,8 +33,11 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<input class="search_input" placeholder='请输入内容' confirm-type='search' @input="searchInput"
|
<view class="search_input" @click="goSearchView">
|
||||||
@confirm="searchInput" :value="selectKeyWord" @click="goSearchView"/>
|
请输入内容
|
||||||
|
</view>
|
||||||
|
<!-- <input class="search_input" placeholder='请输入内容' confirm-type='search' @input="searchInput"
|
||||||
|
@confirm="searchInput" :value="selectKeyWord" @click="goSearchView"/> -->
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|||||||
@ -38,7 +38,7 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="section_label" @click="goWallet(2, userInfo)">
|
<view class="section_label" @click="goWallet(2, userInfo)">
|
||||||
<view>{{ userInfo.property_housing_fund }}元</view>
|
<view>{{ userInfo.property_housing_fund }}元</view>
|
||||||
<view>物业费公积金</view>
|
<view>物业费</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="section_label" @click="goWallet(3)">
|
<view class="section_label" @click="goWallet(3)">
|
||||||
<view>0元</view>
|
<view>0元</view>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user