上传问题,未解决

This commit is contained in:
gyj
2024-04-19 18:15:23 +08:00
parent 38ac830a62
commit 197677e3c2
14 changed files with 144 additions and 58 deletions
+2 -2
View File
@@ -41,7 +41,7 @@
@click="videoClickOff"
/>
</div>
<div class="sharing">
<!-- <div class="sharing">
<img
class="sharImg"
src="@/assets/screenShare_on.png"
@@ -56,7 +56,7 @@
v-else
@click="sharClickOff"
/>
</div>
</div> -->
</div>
</div>
</template>
+8 -4
View File
@@ -18,11 +18,11 @@ export default {
name: "App",
components: {
homepc,
homePhone
homePhone,
},
data() {
return {
modileFlag: false
modileFlag: false,
};
},
methods: {},
@@ -30,8 +30,12 @@ export default {
this.modileFlag = getModile();
let routeParams = this.$route.query;
let appType = routeParams.type;
sessionStorage.setItem("type", appType);
}
if (appType) {
sessionStorage.setItem("type", appType);
}else{
sessionStorage.setItem("type", "tiaojie");
}
},
};
</script>
+1
View File
@@ -35,6 +35,7 @@ export default {
}
axios.get(`http://121.40.189.20:9090/onlyOfficeConfig/${edit}/${id}/${this.userId}/desktop/true`).then(res => {
this.config = res.data;
debugger
var docEditor = new DocsAPI.DocEditor("placeholder", this.config);
})
},
+69 -13
View File
@@ -71,7 +71,7 @@
<el-upload
ref="upload"
:limit="1"
action="https://api.xayunmei.com/tiaojieapi/video/upload"
action="https://api.xayunmei.com/tiaojieapitest/video/upload"
:headers="headers"
:data="filedata"
:on-change="beforeUpload"
@@ -87,7 +87,7 @@
v-if="resFlag"
ref="upload1"
:limit="1"
action="https://api.xayunmei.com/tiaojieapi/video/upload"
action="https://api.xayunmei.com/tiaojieapitest/video/upload"
:headers="headers1"
:data="filedata1"
:on-change="beforeUpload1"
@@ -99,10 +99,11 @@
>
</el-upload>
<el-upload
v-if="editFlag"
v-if="updataFlag"
ref="upload3"
:limit="1"
action="https://api.xayunmei.com/tiaojieapi/video/upload"
action=""
:http-request="upload3"
:headers="headers3"
:data="filedata3"
:on-change="beforeUpload3"
@@ -114,6 +115,7 @@
>上传调解书</el-button
>
</el-upload>
<!-- https://api.xayunmei.com/tiaojieapitest/video/upload -->
</div>
<div class="list">
<div class="applicant" v-if="applicantFile.length > 0">
@@ -178,6 +180,7 @@ import {
selectById,
selectRoleMenuByCaseId,
getMenuPermsByUser,
videoUpload
} from "@/api/room";
import { getWidth, getHeight, getWidthPhone, getModile } from "@/utils/utils";
import roomFooter from "./components/roomFooter.vue";
@@ -314,10 +317,12 @@ export default {
this.sharFlag = true;
this.videoList = "videoList";
this.screenShareFlag = false;
if(this.userList.length >= 1){
if (this.userList.length > 1) {
this.videoClass = "videoItem1";
}else{
} else if (this.userList.length < 1) {
this.videoClass = "videoItem";
} else if (this.userList.length == 1) {
this.videoClass = "videoItem3";
}
},
/**获取当前用户操作权限 */
@@ -373,15 +378,47 @@ export default {
this.$refs.upload3.clearFiles();
this.selectByIdFn(this.caseId);
},
upload3(param){
const formData = new FormData()
formData.append('file', param.file);
formData.append('annexType', 7);
formData.append('officeFlag', 1);
formData.append('caseId', this.caseId);
videoUpload(formData).then(res=>{
console.log('上传图片成功')
})
// axios.post(url, formData).then(response => {
// //根据返回值进行判断是否上传成功
// if(response.data.flag){
// //上传成功
// console.log('上传图片成功')
// }else{
// //上传失败
// console.log('图片上传失败')
// }
// }).catch(response => {
// console.log('异常处理')
// })
},
preview(item, flag) {
if (item.onlyOfficeFileId) {
this.$router.push({
path: "/onlyoffice",
query: { id: item.onlyOfficeFileId, flag: flag },
});
// this.$router.push({
// path: "/onlyoffice",
// query: { id: item.onlyOfficeFileId, flag: flag },
// });
let flag = 1;
if(this.editFlag){
flag = 1
}else{
flag = 0
}
window.open(
`http://121.40.189.20:8002/onlyoffice?id=${item.onlyOfficeFileId}&flag=${flag}`,
"_black"
);
} else {
window.open(
"https://api.xayunmei.com/tiaojieapi" + item.annexPath,
"http://121.40.189.20:6001" + item.annexPath,
"_black"
);
}
@@ -536,7 +573,7 @@ export default {
this.userList.splice(deleteIndex, 1);
}
if (this.modileFlag) {
this.userHeight = getHeight(this.userList);
// this.userHeight = getHeight(this.userList);
} else {
this.userClassPhone = getWidthPhone(this.userList);
}
@@ -575,11 +612,24 @@ export default {
return this.$refs.myQuillEditor.quill;
},
},
watch: {
userList(value) {
if (value.length == 1) {
this.videoClass = "videoItem3";
} else if (value.length > 1) {
this.videoClass = "videoItem1";
} else if (value.length < 1) {
this.videoClass = "videoItem";
}
},
},
async mounted() {
if (this.userList.length == 1) {
this.videoClass = "videoItem";
this.videoClass = "videoItem3";
} else if (this.userList.length > 1) {
this.videoClass = "videoItem1";
} else if (this.userList.length < 1) {
this.videoClass = "videoItem";
}
// 判断设备类型
this.modileFlag = getModile();
@@ -722,6 +772,12 @@ export default {
background: red;
border-radius: 20px;
}
.videoItem3 {
width: 48%;
height: 100%;
background: red;
border-radius: 20px;
}
.videoItem2 {
width: 90%;
height: 25%;
+4 -4
View File
@@ -71,7 +71,7 @@
<el-upload
ref="upload"
:limit="1"
action="https://api.xayunmei.com/tiaojieapi/video/upload"
action="https://api.xayunmei.com/tiaojieapitest/video/upload"
:headers="headers"
:data="filedata"
:on-change="beforeUpload"
@@ -87,7 +87,7 @@
v-if="resFlag"
ref="upload1"
:limit="1"
action="https://api.xayunmei.com/tiaojieapi/video/upload"
action="https://api.xayunmei.com/tiaojieapitest/video/upload"
:headers="headers1"
:data="filedata1"
:on-change="beforeUpload1"
@@ -102,7 +102,7 @@
v-if="editFlag"
ref="upload3"
:limit="1"
action="https://api.xayunmei.com/tiaojieapi/video/upload"
action="https://api.xayunmei.com/tiaojieapitest/video/upload"
:headers="headers3"
:data="filedata3"
:on-change="beforeUpload3"
@@ -381,7 +381,7 @@ export default {
});
} else {
window.open(
"https://api.xayunmei.com/tiaojieapi" + item.annexPath,
"https://api.xayunmei.com/tiaojieapitest" + item.annexPath,
"_black"
);
}