fix app office load error

This commit is contained in:
kuaifan 2021-12-11 22:45:15 +08:00
parent 03c0449a0b
commit cece720f68
2 changed files with 3 additions and 5 deletions

View File

@ -44,8 +44,6 @@ export default {
data() { data() {
return { return {
serverUrl: 'http://' + window.systemInformation.ippr + '.3/',
fileName: null, fileName: null,
fileType: null, fileType: null,
fileUrl: null, fileUrl: null,
@ -72,7 +70,7 @@ export default {
watch: { watch: {
value: { value: {
handler(val) { handler(val) {
this.fileUrl = this.serverUrl + 'api/file/content/?id=' + val.id + '&token=' + this.userToken; this.fileUrl = 'http://nginx/api/file/content/?id=' + val.id + '&token=' + this.userToken;
this.fileType = this.getType(val.type); this.fileType = this.getType(val.type);
this.fileName = val.name; this.fileName = val.name;
}, },
@ -140,7 +138,7 @@ export default {
"id": this.userInfo.userid, "id": this.userInfo.userid,
"name": this.userInfo.nickname "name": this.userInfo.nickname
}, },
"callbackUrl": this.serverUrl + 'api/file/content/office?id=' + this.value.id + '&token=' + this.userToken, "callbackUrl": 'http://nginx/api/file/content/office?id=' + this.value.id + '&token=' + this.userToken,
} }
}; };
this.$nextTick(() => { this.$nextTick(() => {

View File

@ -17,7 +17,7 @@
<script src="{{ asset_main('js/scroll-into-view.min.js') }}"></script> <script src="{{ asset_main('js/scroll-into-view.min.js') }}"></script>
<script> <script>
window.csrfToken = { csrfToken : "{{ csrf_token() }}" }; window.csrfToken = { csrfToken : "{{ csrf_token() }}" };
window.systemInformation = { version : "{{ $version }}", origin: window.location.origin + "/", apiUrl: null, ippr: "{{ env('APP_IPPR') }}" }; window.systemInformation = { version : "{{ $version }}", origin: window.location.origin + "/", apiUrl: null };
</script> </script>
</head> </head>
<body> <body>