首页修改

This commit is contained in:
仲么了
2023-08-23 16:22:08 +08:00
parent cc63cda4e7
commit 79d6771aad
34 changed files with 788 additions and 403 deletions

View File

@@ -20,7 +20,7 @@ export function getDevCount(id) {
url: '/cs-device-boot/deviceUser/devCount',
method: 'post',
data: { id },
data: {id},
})
}
@@ -89,10 +89,22 @@ export const queryTopologyDiagram = (devId) => {
// 设备扫码移交
export const transferDevice = (id) => {
export const transferDevice = (id, userId) => {
return request({
url: '/cs-device-boot/deviceUser/transfer',
method: 'POST',
data: {
ids: id,
userId: userId || uni.getStorageSync('userInfo').userIndex
},
})
}
// 设备扫码分享
export const shareDevice = (id, userId) => {
return request({
url: '/cs-device-boot/deviceUser/share',
method: 'POST',
data: {
ids: id,
},
@@ -141,8 +153,6 @@ export const updateDevice = (params) => {
header: {
'Content-Type': 'application/json',
},
data: {
pointList: params,
},
data: params,
})
}

View File

@@ -1,5 +1,6 @@
import request from '../js/request';
import config from '../js/config';
/**
* 添加反馈
* @param {*} params {description: '', files: '', title: 1type: 1user_id:12}
@@ -7,17 +8,25 @@ import config from '../js/config';
*/
export function addFeedBack(params) {
let files = params.files;
console.log(files);
console.log(files.length);
let data = JSON.parse(JSON.stringify(params));
delete data.files
return uni.uploadFile({
url: config.domain + '/cs-system-boot/feedback/addFeedBack', //仅为示例,非真实的接口地址
files: files,
header: {
Authorization: uni.getStorageSync('access_token'),
},
formData: data,
});
if (files.length) {
return uni.uploadFile({
url: config.domain + '/cs-system-boot/feedback/addFeedBack', //仅为示例,非真实的接口地址
files: files,
header: {
Authorization: uni.getStorageSync('access_token'),
},
formData: data,
});
} else {
return request({
url: '/cs-system-boot/feedback/addFeedBack',
method: 'post',
data: data,
});
}
}
/**
@@ -68,12 +77,12 @@ export function AddFeedbackChat(params) {
}
/**
* 更新反馈聊天状态
* 更新反馈聊天状态
* @param {*} params {
"id": "2e47078c0f59a4a612655bb3bbaed617",
"userId": "12"
}
* @returns
* @returns
*/
export function updateChatStatus(params) {
return request({

View File

@@ -35,5 +35,32 @@ export const queryAppInfoByType = (type) => {
}
/**
* 查看用户消息推送配置
*/
//
export const queryUserPushConfig = () => {
return request({
url: '/cs-system-boot/appInfoSet/queryByUserId',
method: 'post',
header: {
'Content-Type': 'application/json',
},
data: {},
})
}
/**
* 更新消息推送配置
*/
export const updatePushConfig = (params) => {
return request({
url: '/cs-system-boot/appInfoSet/update',
method: 'post',
header: {
'Content-Type': 'application/json',
},
data: params,
})
}

View File

@@ -1,4 +1,4 @@
const debug = true // true 是连地服务端本地false 是连接线上
const debug = false // true 是连地服务端本地false 是连接线上
const development = {
domain: 'http://192.168.1.115:10215',

View File

@@ -30,6 +30,10 @@ export default {
pageNum: 1,
pageSize: 20,
},
timer:null,
callBack: null,
firstCallBack: null,
loadedCallback: null,
reload() {
this.data = []
this.status = 'loading'
@@ -37,9 +41,13 @@ export default {
this.params.pageNum = 1
this.next()
},
callBack: null,
firstCallBack: null,
loadedCallback: null,
search() {
// 节流搜索
clearTimeout(this.timer)
this.timer = setTimeout(() => {
this.reload()
}, 300)
},
next() {
me.$request({
url: url,