完成订单详情

This commit is contained in:
wwz
2025-03-13 09:15:51 +08:00
parent 7dde4ed754
commit e6ca187e5a
14 changed files with 219 additions and 176 deletions

View File

@@ -47,4 +47,22 @@ export const APIuserupload = (data) => {
method: 'post',
data: data
})
}
//用户密码修改
export const APIuserpwd = (data) => {
return request({
url: url + '/user/pwd',
method: 'put',
data: data
})
}
//验证码获取
export const APIusercode = (data) => {
return request({
url: url + '/user/code',
method: 'get',
data: data
})
}

View File

@@ -56,14 +56,13 @@ const useWebSocket = (options = {}) => {
// 连接 WebSocket
const connect = () => {
if (!isNetworkConnected.value) {
uni.showToast({
title: '网络未连接...',
icon: 'none'
})
setTimeout(() => {
uni.navigateBack()
uni.pro.switchTab('index/index')
}, 1000)
console.log('网络未连接,暂不尝试连接 WebSocket');
return;
@@ -112,7 +111,6 @@ const useWebSocket = (options = {}) => {
clearTimeout(reconnectTimer.value); // 清除重连定时器
if (res.code == '1006') {
console.log('服务器正常关闭,停止重连');
uni.navigateBack()
autoReconnect.value = false;
return false;
}
@@ -143,7 +141,7 @@ const useWebSocket = (options = {}) => {
icon: 'none'
})
setTimeout(() => {
uni.navigateBack()
uni.pro.switchTab('index/index')
}, 1000)
return;
}
@@ -184,7 +182,6 @@ const useWebSocket = (options = {}) => {
// 手动关闭连接
const closeSocket = () => {
isManuallyClosed.value = true;
uni.navigateBack()
closeExistingConnection();
};
@@ -230,7 +227,6 @@ const useWebSocket = (options = {}) => {
title: '重连次数达到上限,停止重连',
icon: 'none'
});
uni.navigateBack()
}
};