Merge remote-tracking branch 'origin/main'

# Conflicts:
#	src/utils/request.js
main
suixy 2 weeks ago
commit d5dbba7702

@ -1168,6 +1168,8 @@ import {
getLocalPositionRelativeToP4,
parseTime
} from '@/utils/tool'
// import {ScreenOrientation} from '@capacitor/screen-orientation';
// import { StatusBar, Style } from '@capacitor/status-bar';
const formUrl = 'http://192.168.1.123:5000/'
const router = useRouter()
@ -1354,10 +1356,10 @@ const getSocket = () => {
const socket = import.meta.env.MODE === 'development' ? new WebSocket("ws://192.168.1.123:7789/ws") : new WebSocket("wss://www.scrin.xyz/ws");
socket.addEventListener("open", () => {
console.log("✅ WebSocket 连接成功");
setInterval(() => {
socket.send('ping')
}, 1000)
// console.log(" WebSocket ");
// setInterval(() => {
// socket.send('ping')
// }, 1000)
});
socket.addEventListener("message", (event) => {
@ -2571,6 +2573,27 @@ onMounted(() => {
getShildTableList()
getObstacleList()
// testFun()
//
// function lockLandscapeIfSmallWidth() {
// const w = window.innerWidth;
//
// if (w < 700) {
// //
// ScreenOrientation.lock({orientation: 'landscape'});
// StatusBar.hide();
// } else {
// //
// ScreenOrientation.unlock();
// StatusBar.show();
// StatusBar.setStyle({ style: Style.Default });
// }
// }
//
// //
// lockLandscapeIfSmallWidth();
})
const testFun = () => {
let areaData111 = [

@ -9,7 +9,9 @@ export default defineConfig({
host: '0.0.0.0', port: 5173, open: true, proxy: {
'/dev-api': {
// target: 'http://192.168.1.123:5000',
target: 'http://192.168.0.103:5000',
// target: 'http://192.168.0.105:5000',
// target: 'http://192.168.0.13:5000',
target: 'http://192.168.1.123:5000',
changeOrigin: true,
ws: true,
secure: false,

Loading…
Cancel
Save