|
|
@@ -45,6 +45,7 @@
|
|
|
import { mapState } from 'vuex';
|
|
|
import axios from 'axios';
|
|
|
import pageableTable from '@/mixins/pageableTable';
|
|
|
+import https from 'https';
|
|
|
|
|
|
export default {
|
|
|
name: 'MetaObjectMoveList',
|
|
|
@@ -73,16 +74,31 @@ export default {
|
|
|
}
|
|
|
},
|
|
|
mounted() {
|
|
|
- axios
|
|
|
- .get(`https://${this.baseUrl}/mmo/websocket/check`)
|
|
|
+ const agent = new https.Agent({
|
|
|
+ rejectUnauthorized: false // 允许访问无效或过期的 SSL 证书
|
|
|
+ });
|
|
|
+ const instance = axios.create({
|
|
|
+ httpsAgent: agent // 指定自定义的 SSL 证书验证方式
|
|
|
+ });
|
|
|
+ instance.get(`https://${this.baseUrl}/mmo/websocket/check`)
|
|
|
.then(res => {
|
|
|
- if (res.data != 'success') {
|
|
|
+ if (res.data !== 'success') {
|
|
|
this.$message.error(res.data);
|
|
|
}
|
|
|
})
|
|
|
.catch(e => {
|
|
|
- this.$message.error(e);
|
|
|
+ this.$message.error(e.message);
|
|
|
});
|
|
|
+ // axios
|
|
|
+ // .get(`https://${this.baseUrl}/mmo/websocket/check`)
|
|
|
+ // .then(res => {
|
|
|
+ // if (res.data != 'success') {
|
|
|
+ // this.$message.error(res.data);
|
|
|
+ // }
|
|
|
+ // })
|
|
|
+ // .catch(e => {
|
|
|
+ // this.$message.error(e);
|
|
|
+ // });
|
|
|
},
|
|
|
methods: {
|
|
|
beforeGetData() {
|