mirror of
https://github.com/aaPanel/aaPanel.git
synced 2026-09-28 12:24:50 +02:00
Since version 7.7.0, we recommend yours update python to 3.12. [+] Using nginx technology to load static files improves access speed [+] Refactor homepage, website, FTP, and database using vue3 [+] Table loading changed to skeleton screen [+] Add Website statistics-v2 professional plug-in [+] Add Home page - top 5 resource occupancy [+] Add protection for Files management (requires Tamper-proof for Enterprise 3.7) [+] Website, FTP, Databases page add program status [+] Add FTP log analysis (only supports Centos) [+] Add password-free login to phpMyAdmin [+] Add Proxy Project in Website (Supported when web service uses Nginx) [+] Add WP Toolkit (Pro version only) [+] Redesigned Docker module [+] Add WP Toolkit Protection [+] Add WP Toolkit Backup and Restore [+] Add WP Toolkit Migrated [+] Add WP Toolkit Clone site (supports new domain and subdomain) [+] Add WP Toolkit Create site from backup of other panel [+] Add WP Toolkit support for Cron automatic backup (only save Local disk) [+] Add WP Toolkit operation log [+] Add Integrity check for WP Toolkit [+] Add WP Toolkit plug-in management and themes management [*] Optimize phpMyAdmin formula access method [*] Optimize Home page PHP display problem [*] Optimize jump to the login interface after the login expires [*] Optimize automatic renewal of SSL at some times [*] Optimize Let's Encrypt to increase application success rate [-] Fix Logs Audit cannot be opened [-] Fix apache URL rewrite issue [-] Fix phpmyadmin installation problem [-] Fix the problem that some servers cannot install software [-] Fix upload file error [-] Fix left menu hiding problem [-] Fix aaPanel Mobile QR code display problem [-] Fix problem that third-party plug-ins are not displayed in the App Store [-] Fix issue where the menu bar is blank when opening new tabs [-] Fixed panel not being accessible in some cases [-] Fix the issue where Curl warning caused the inability to apply for SSL [-] Fix Quota issues for Website, FTP, Databases [-] Fix file interface display problem on mobile terminal
2 lines
2.2 KiB
JavaScript
2 lines
2.2 KiB
JavaScript
var e=Object.defineProperty,t=(t,s,n)=>(((t,s,n)=>{s in t?e(t,s,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[s]=n})(t,"symbol"!=typeof s?s+"":s,n),n);import{as as s,y as n}from"./vue.js?v=1721298337096";import{n as o,j as c,cu as a}from"./index.js?v=1721298337096";import{i}from"./data.js?v=1721298337096";class r{constructor(e){t(this,"socket",null),t(this,"url",""),t(this,"connectURL",(()=>{const{host:e,protocol:t}=window.location;return("http:"===t?"ws://":"wss://")+e+"/v2"})()),t(this,"sendData",{}),this.url=e.url,this.connectURL+=e.url,this.init(e)}init(e){"WebSocket"in window?this.socket=s(this.connectURL,{autoReconnect:{retries:3,delay:500},onConnected:t=>{e.onConnected&&e.onConnected(t),this.onConnected(t,e)},onMessage:(t,s)=>{e.onMessage&&e.onMessage(t,s),this.onMessage(t,s)},onDisconnected:(t,s)=>{e.onDisconnected&&e.onDisconnected(t,s),this.onDisconnected()},onError:(t,s)=>{e.onError&&e.onError(t,s),this.onError()}}):o.error("The browser does not support Websocket")}isStatus(e){var t,s;return((null==(t=this.socket)?void 0:t.status.value)||(null==(s=this.socket)?void 0:s.status))===e}channelVerify(){var e;const t={};t["x-http-token"]=null==(e=document.getElementById("request_token_head"))?void 0:e.getAttribute("token"),this.send(t)}send(e){var t;if(this.isStatus("OPEN"))null==(t=this.socket)||t.send(c(e)?JSON.stringify(e):e);else{const t=a(10);this.sendData[t]={data:e,status:!1,request:!1,callback:()=>{}}}}onConnected(e,t){t.noInit||this.channelVerify(),this.onSendData()}onSendData(){Object.entries(this.sendData).forEach((([e,t])=>{this.send(t.data),delete this.sendData[e]}))}onMessage(e,t){if("/ws_home"===this.url||"/ws_model"===this.url)try{if(i(t.data)){const s=JSON.parse(t.data),n=s.callback||s.ws_callback;n&&this.sendData[n]&&this.sendData[n].callback(e,t)}}catch(s){console.log(s)}}onDisconnected(){this.close(),console.log("断开连接")}onError(){console.log("连接错误")}close(){var e;null==(e=this.socket)||e.close()}}function l({url:e,onMessage:t,onDisconnected:s}){let o=null;const c=()=>{o&&(o.close(),o=null)};return n((()=>{c()})),{getSocket:()=>o,sendSocket:e=>{null==o||o.send(e)},closeWebSocket:c,createWebSocket:()=>{var n;n={url:e,onMessage:(e,s)=>{t(e,s)},onDisconnected:()=>{o=null,null==s||s()}},o=new r(n)}}}export{l as u};
|