修改巡检内容
This commit is contained in:
@@ -284,11 +284,8 @@ onLoad(option => {
|
|||||||
|
|
||||||
minioObj = JSON.parse(uni.getStorageSync(MINIO_KEY) || "\{\}")
|
minioObj = JSON.parse(uni.getStorageSync(MINIO_KEY) || "\{\}")
|
||||||
// console.log(minioObj)
|
// console.log(minioObj)
|
||||||
|
|
||||||
})
|
|
||||||
|
|
||||||
onShow(()=>{
|
|
||||||
getList();
|
getList();
|
||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
// 下拉刷新
|
// 下拉刷新
|
||||||
@@ -336,7 +333,7 @@ const getList = async() => {
|
|||||||
item.loading=false;
|
item.loading=false;
|
||||||
if(item.resultContent){
|
if(item.resultContent){
|
||||||
if(item.pointType==2 ||item.pointType==1){
|
if(item.pointType==2 ||item.pointType==1){
|
||||||
item['chooseList'] = item.resultContent.split(",") //JSON.parse(item.resultContent)
|
item['chooseList'] = item.resultContent.split(",")||[]; //JSON.parse(item.resultContent)
|
||||||
}else if(item.pointType==7){
|
}else if(item.pointType==7){
|
||||||
let imgList = item.resultContent?.split(",")||[];
|
let imgList = item.resultContent?.split(",")||[];
|
||||||
imgList.forEach(imgUrl=>{
|
imgList.forEach(imgUrl=>{
|
||||||
@@ -357,7 +354,6 @@ const getList = async() => {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
})
|
})
|
||||||
// console.log(data.pointList)
|
// console.log(data.pointList)
|
||||||
optionObj.value = data
|
optionObj.value = data
|
||||||
|
|||||||
@@ -109,13 +109,9 @@ onLoad(async option => {
|
|||||||
problemId.value = option.problemId;
|
problemId.value = option.problemId;
|
||||||
|
|
||||||
minioObj = JSON.parse(uni.getStorageSync(MINIO_KEY) || "\{\}")
|
minioObj = JSON.parse(uni.getStorageSync(MINIO_KEY) || "\{\}")
|
||||||
|
|
||||||
let userinfo = await getUserInfo({});
|
let userinfo = await getUserInfo({});
|
||||||
realname.value = userinfo.realname
|
realname.value = userinfo.realname
|
||||||
|
|
||||||
})
|
|
||||||
|
|
||||||
onShow(()=>{
|
|
||||||
getList();
|
getList();
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -191,14 +187,12 @@ const chooseMedia = () => {
|
|||||||
let data = res.data;
|
let data = res.data;
|
||||||
mediaArr.value.push(data.fileName);
|
mediaArr.value.push(data.fileName);
|
||||||
if (file.fileType === 'image') {// 图片
|
if (file.fileType === 'image') {// 图片
|
||||||
// imgArr.value.push(data.fileUrl)
|
|
||||||
imgArr.value.push({
|
imgArr.value.push({
|
||||||
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
||||||
url:minioObj.minioUrl +"/"+data.fileName,
|
url:minioObj.minioUrl +"/"+data.fileName,
|
||||||
name:data.fileName
|
name:data.fileName
|
||||||
})
|
})
|
||||||
} else if (file.fileType === 'video') {// 视频
|
} else if (file.fileType === 'video') {// 视频
|
||||||
// videoArr.value.push(data.fileUrl)
|
|
||||||
videoArr.value.push({
|
videoArr.value.push({
|
||||||
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
||||||
url:minioObj.minioUrl +"/"+data.fileName,
|
url:minioObj.minioUrl +"/"+data.fileName,
|
||||||
|
|||||||
@@ -120,10 +120,7 @@ onLoad(async option => {
|
|||||||
minioObj = JSON.parse(uni.getStorageSync(MINIO_KEY) || "\{\}")
|
minioObj = JSON.parse(uni.getStorageSync(MINIO_KEY) || "\{\}")
|
||||||
|
|
||||||
let userinfo = await getUserInfo({});
|
let userinfo = await getUserInfo({});
|
||||||
realname.value = userinfo.realname
|
realname.value = userinfo.realname;
|
||||||
|
|
||||||
})
|
|
||||||
onShow(()=>{
|
|
||||||
getList();
|
getList();
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -212,10 +209,9 @@ const chooseMedia = () => {
|
|||||||
maxDuration: 60, // 拍摄视频最长拍摄时间
|
maxDuration: 60, // 拍摄视频最长拍摄时间
|
||||||
camera: 'back',
|
camera: 'back',
|
||||||
success: (res) => {
|
success: (res) => {
|
||||||
console.log("chooseMedia=>",res)
|
// console.log("chooseMedia=>",res)
|
||||||
res.tempFiles.forEach(async file => {
|
res.tempFiles.forEach(async file => {
|
||||||
// tempFilePath
|
// console.log(`文件类型: ${file.fileType}, 文件路径: ${file.tempFilePath}`);
|
||||||
console.log(`文件类型: ${file.fileType}, 文件路径: ${file.tempFilePath}`);
|
|
||||||
let compressImg = file.tempFilePath;
|
let compressImg = file.tempFilePath;
|
||||||
// 图片进行压缩
|
// 图片进行压缩
|
||||||
if (file.fileType === 'image') {
|
if (file.fileType === 'image') {
|
||||||
@@ -235,17 +231,15 @@ const chooseMedia = () => {
|
|||||||
}
|
}
|
||||||
imgLoading.value=true;
|
imgLoading.value=true;
|
||||||
minioUpload(param).then(res=>{
|
minioUpload(param).then(res=>{
|
||||||
let data = res.data;console.log("上传成功后=>",res)
|
let data = res.data;//console.log("上传成功后=>",res)
|
||||||
mediaArr.value.push(data.fileName);
|
mediaArr.value.push(data.fileName);
|
||||||
if (file.fileType === 'image') {// 图片
|
if (file.fileType === 'image') {// 图片
|
||||||
// imgArr.value.push(data.fileUrl)
|
|
||||||
imgArr.value.push({
|
imgArr.value.push({
|
||||||
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
||||||
url:minioObj.minioUrl +"/"+data.fileName,
|
url:minioObj.minioUrl +"/"+data.fileName,
|
||||||
name:data.fileName
|
name:data.fileName
|
||||||
})
|
})
|
||||||
} else if (file.fileType === 'video') {// 视频
|
} else if (file.fileType === 'video') {// 视频
|
||||||
// videoArr.value.push(data.fileUrl)
|
|
||||||
videoArr.value.push({
|
videoArr.value.push({
|
||||||
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
shortUrl:minioObj.minioThumbUrl +"/"+data.fileName,
|
||||||
url:minioObj.minioUrl +"/"+data.fileName,
|
url:minioObj.minioUrl +"/"+data.fileName,
|
||||||
|
|||||||
Reference in New Issue
Block a user