import{d as Ne,u as ke,n as i,aA as Se,L as We,P as ze,a3 as De,r as c,b as oe,c as Ce,e,j as t,o as m,w as u,i as h,x as ce,f as s,g as l,h as n,z as r,I as re,ai as M,O as je,K as x,S as Ve,a5 as Ee,a6 as Te,_ as Be}from"./index-4789ca0a.js";import{_ as Pe}from"./Pie.vue_vue_type_script_setup_true_lang-3d154c5f.js";import{_ as Oe}from"./Line.vue_vue_type_script_setup_true_lang-dc4534b9.js";import{T as D}from"./index-296c76cc.js";import{a as de,b as Ue,f as Fe,d as _e}from"./fun-3edebd8d.js";import"./app-803627bb.js";const ue=C=>(Ee("data-v-8eb58523"),C=C(),Te(),C),qe={class:"card-header"},Ae={class:"type-it-container"},Ke={class:"button-container"},Le={class:"card-header"},$e={class:"type-it-container"},Me={class:"button-container"},Re={class:"card-header"},Ge={class:"type-it-container"},Qe={class:"card-header"},Xe={class:"type-it-container"},Ye={class:"button-container"},He={class:"card-header"},Je={class:"type-it-container"},Ze={class:"button-container"},et={class:"image-container",style:{display:"flex",gap:"16px","flex-direction":"column"}},tt=["src"],st={class:"connected_devices_container opposite_color",style:{width:"100%",height:"35vh",display:"flex","flex-direction":"column","justify-content":"space-between"}},at={class:"inner_container",style:{display:"flex","justify-content":"center","align-items":"center"}},lt={class:"icon_container",style:{display:"flex","justify-content":"center","align-items":"center"}},it={id:"h_wire_device",style:{display:"inline-block"}},nt={style:{display:"flex","align-items":"center"}},ot={style:{"font-size":"70px"}},ct=ue(()=>l("sub",{style:{"font-size":"16px",top:"16px"}},"台",-1)),rt={id:"h_wireless_device",style:{display:"inline-block","margin-left":"30px"}},dt={style:{display:"flex","align-items":"center"}},_t={style:{"font-size":"70px"}},ut=ue(()=>l("sub",{style:{"font-size":"16px",top:"16px"}},"台",-1)),pt={class:"bottom_container",style:{display:"flex","justify-content":"center","align-items":"flex-end"}},mt={class:"descriptions_container",style:{width:"100%"}},vt={class:"dialog-footer"},ft=Ne({name:"Welcome",__name:"index",setup(C){const U=ke(),R=i(!0),{version:pe}={dependencies:{"@pureadmin/descriptions":"^1.1.1","@pureadmin/utils":"^1.9.7","@vueuse/core":"^10.2.0","@vueuse/motion":"^2.0.0","animate.css":"^4.1.1",axios:"^1.4.0",dayjs:"^1.11.8",echarts:"^5.4.2","element-plus":"2.3.6","js-cookie":"^3.0.5",mitt:"^3.0.0",mockjs:"^1.1.0",nprogress:"^0.2.0",path:"^0.12.7",pinia:"^2.1.4","pinyin-pro":"^3.15.2",qs:"^6.11.2","responsive-storage":"^2.2.0",sortablejs:"^1.15.0",typeit:"^8.7.1",vue:"^3.3.4","vue-router":"^4.2.2","vue-types":"^5.1.0",vuex:"^4.1.0"},devDependencies:{"@commitlint/cli":"^17.6.6","@commitlint/config-conventional":"^17.6.6","@iconify-icons/ep":"^1.2.12","@iconify-icons/ri":"^1.2.9","@iconify/vue":"^4.1.1","@pureadmin/theme":"^3.1.0","@types/js-cookie":"^3.0.3","@types/mockjs":"^1.0.7","@types/node":"^20.3.1","@types/nprogress":"0.2.0","@types/qs":"^6.9.7","@types/sortablejs":"^1.15.1","@typescript-eslint/eslint-plugin":"^5.60.0","@typescript-eslint/parser":"^5.60.0","@vitejs/plugin-vue":"^4.2.3","@vitejs/plugin-vue-jsx":"^3.0.1","@vue/eslint-config-prettier":"^7.1.0","@vue/eslint-config-typescript":"^11.0.3",autoprefixer:"^10.4.14",cloc:"^2.11.0",cssnano:"^6.0.1",eslint:"^8.43.0","eslint-plugin-prettier":"^4.2.1","eslint-plugin-vue":"^9.15.1",husky:"^8.0.3","lint-staged":"^13.2.2",picocolors:"^1.0.0",postcss:"^8.4.24","postcss-html":"^1.5.0","postcss-import":"^15.1.0","postcss-scss":"^4.0.6",prettier:"^2.8.8","pretty-quick":"^3.1.3",rimraf:"^5.0.1","rollup-plugin-visualizer":"^5.9.2",sass:"^1.63.6","sass-loader":"^13.3.2",stylelint:"^15.9.0","stylelint-config-html":"^1.1.0","stylelint-config-recess-order":"^4.2.0","stylelint-config-recommended":"^12.0.0","stylelint-config-recommended-scss":"^12.0.0","stylelint-config-recommended-vue":"^1.4.0","stylelint-config-standard":"^33.0.0","stylelint-config-standard-scss":"^9.0.0","stylelint-order":"^6.0.3","stylelint-prettier":"^3.0.0","stylelint-scss":"^5.0.1",svgo:"^3.0.2",tailwindcss:"^3.3.2",terser:"^5.18.1",typescript:"5.0.4","unplugin-element-plus":"^0.7.2",vite:"^4.3.9","vite-plugin-cdn-import":"^0.3.5","vite-plugin-compression":"^0.5.1","vite-plugin-mock":"2.9.6","vite-plugin-remove-console":"^2.1.1","vite-svg-loader":"^4.0.0","vue-eslint-parser":"^9.3.1","vue-tsc":"^1.8.1"},name:"pure-admin-thin",version:"1.0.2"},j=i(!1),G=i(!0),me=i([{name:"",data:""}]),{height:V}=Se(),a=We(),Q=i(),X=i(),v=i("");let F=i({}),E=i({}),Y=i([]),H=i(),ve=i("../pic/qrcode_ssid_wifikey.png?_="+Date.now()),T=i([]),B=i([]),P=i([]),I=i(),N=i(),J=i(),k=i(),Z=i(),ee=i(),y=i(!1),g=i(!1),q=i(0),A=i(0),b=i(!1),w=i(!1);ze(()=>{R.value=!1,F.value=a.state.NetWork,E.value=a.state.NetInfo,Q.value=a.state.Signal,X.value=a.state.BandInfo,H.value=Ue(a.state.NetWork.realtime_time),q.value=a.state.NetWork.realtime_tx_thrpt,A.value=a.state.NetWork.realtime_rx_thrpt,y.value=a.state.NetWork.ppp_status=="ppp_connected",b.value==!0&&y.value==!0&&(b.value=!1),g.value=a.state.NetWork.wifi_cur_state=="1",w.value==!0&&g.value==!0&&(w.value=!1),I.value=a.state.NetWork.data_volume_limit_unit,k.value=a.state.NetWork.data_volume_limit_switch,J.value=a.state.NetWork.data_volume_alert_percent,I.value=="data"?N.value=Fe(a.state.NetWork.data_volume_limit_size):N.value=a.state.NetWork.data_volume_limit_size,ee.value=a.state.NetWork.monthly_time,Z.value=parseInt(a.state.NetWork.monthly_tx_bytes)+parseInt(a.state.NetWork.monthly_rx_bytes),P.value.push(new Date().getSeconds()),P.value.length>30&&P.value.shift(),T.value.push(_e(q.value)),T.value.length>30&&T.value.shift(),B.value.push(_e(A.value)),B.value.length>30&&B.value.shift(),Y.value=[{name:"网络类型",val:a.state.NetInfo.sub_network_type},{name:"IMSI",val:a.state.NetInfo.sim_imsi},{name:"网络名称(SSID)",val:a.state.NetWork.SSID1!=""?a.state.NetWork.SSID1:a.state.NetInfo.m_SSID},{name:"最大连接数",val:a.state.NetInfo.MAX_Access_num},{name:"Wi-Fi 覆盖范围远距离",val:a.state.NetInfo.wifi_coverage=="long_mode"?"远距离 Wi-Fi 范围":a.state.NetInfo.wifi_coverage=="medium_mode"?"中距离 Wi-Fi 范围":"近距离 Wi-Fi 范围 - 最佳电池续航"},{name:"IP类型",val:a.state.NetInfo.pdp_type=="IP"?"IPv4":a.state.NetInfo.pdp_type},{name:"IP 地址",val:a.state.NetInfo.lan_ipaddr},{name:"WAN IP 地址",val:a.state.NetInfo.wan_ipaddr},{name:"IPV6 地址",val:a.state.NetInfo.ipv6_wan_ipaddr},{name:"软件版本",val:a.state.NetInfo.cr_version},{name:"硬件版本",val:a.state.NetInfo.hw_version},{name:"cellid",val:a.state.NetInfo.detail_cell_id}];const _=a.state.NetWork.network_provider;if(a.state.NetWork.modem_main_state=="modem_sim_undetected")v.value="SIM卡无效";else{const o=_.toLowerCase().replaceAll(" ","");v.value=o.replace(/chinamobile|chinatelecom|chinaunicom/g,f=>{switch(f){case"chinamobile":return"中国移动";case"chinatelecom":return"中国电信";case"chinaunicom":return"中国联通";default:return _!=""?_:"服务受限"}}),v.value==""&&a.state.NetWork.network_type=="Limited Service"&&(v.value="服务受限"),v.value==""&&a.state.NetWork.network_type=="No Service"&&(v.value="无服务")}});function fe(_){b.value=_,je(_==!0?"CONNECT_NETWORK":"DISCONNECT_NETWORK").then(o=>{o.result=="success"?x("成功发送请求",{type:"success"}):(x("操作失败",{type:"error"}),b.value=!1)}).catch(o=>{x("请求失败",{type:"error"}),b.value=!1})}function he(_){w.value=_,Ve({goformId:"SET_WIFI_INFO",wifiEnabled:_==!0?"1":"0"}).then(o=>{o.result=="success"?x("成功发送请求",{type:"success"}):(x("操作失败",{type:"error"}),w.value=!1)}).catch(o=>{x("请求失败",{type:"error"}),w.value=!1})}function ye(){U.push({name:"QuickSettings"})}function ge(){U.push({name:"DataPlan"})}function be(){j.value=!1,G.value=!1}De({api_url:"",http_type:"POST",http_head:"",http_body:"",js_code:""}),i({id:"",api_url:"",http_type:"",http_head:"",http_body:"",js_code:""});function we(){U.push({name:"connect"})}return(_,o)=>{const f=c("el-button"),O=c("el-table-column"),te=c("el-table"),se=c("el-popover"),d=c("el-descriptions-item"),K=c("el-descriptions"),ae=c("el-scrollbar"),S=c("el-card"),W=c("el-col"),le=c("el-switch"),ie=c("el-text"),L=c("el-tag"),$=c("IconifyIconOnline"),xe=c("el-row"),Ie=c("el-dialog"),z=oe("motion"),ne=oe("loading");return m(),Ce("div",null,[e(xe,{gutter:24},{default:t(()=>[u((m(),h(W,{xs:24,sm:24,md:12,lg:12,xl:12,class:"mb-[18px]",initial:{opacity:0,y:100},enter:{opacity:1,y:0,transition:{delay:200}}},{default:t(()=>[e(S,{shadow:"never",style:ce({height:`calc(${s(V)}px - 35vh - 250px)`})},{header:t(()=>[l("div",qe,[l("div",Ae,[e(s(D),{className:"type-it2",values:["设备状态信息"],cursor:!1,speed:60})]),l("div",Ke,[e(se,{placement:"bottom",width:400},{reference:t(()=>[e(f,{plain:""},{default:t(()=>[n("更多信息")]),_:1})]),default:t(()=>[e(te,{data:s(Y)},{default:t(()=>[e(O,{property:"name",label:"项目"}),e(O,{property:"val",label:"值"})]),_:1},8,["data"])]),_:1})])])]),default:t(()=>[e(ae,{height:`calc(${s(V)}px - 35vh - 340px)`},{default:t(()=>[e(K,{direction:"vertical",column:5,border:"",size:"default"},{default:t(()=>[e(d,{label:"IMEI",span:2},{default:t(()=>[n(r(s(E).imei),1)]),_:1}),e(d,{label:"信号强度","min-width":80},{default:t(()=>[n(r(Q.value.rssi)+" dBm",1)]),_:1}),e(d,{label:"频段",span:2},{default:t(()=>[n(r(X.value),1)]),_:1}),e(d,{label:"ICCID",span:2},{default:t(()=>[n(r(s(E).ziccid),1)]),_:1}),e(d,{label:"运营商",span:2},{default:t(()=>[n(r(v.value),1)]),_:1}),e(d,{label:"网络名称",span:2,"min-width":120},{default:t(()=>[n(r(s(F).SSID1!=""?s(F).SSID1:s(E).m_SSID),1)]),_:1})]),_:1})]),_:1},8,["height"])]),_:1},8,["style"])]),_:1})),[[z]]),u((m(),h(W,{xs:24,sm:24,md:12,lg:12,xl:12,class:"mb-[18px]",initial:{opacity:0,y:100},enter:{opacity:1,y:0,transition:{delay:200}}},{default:t(()=>[e(S,{shadow:"never",style:ce({height:`calc(${s(V)}px - 35vh - 250px)`})},{header:t(()=>[l("div",Le,[l("div",$e,[e(s(D),{className:"type-it1",values:["设备实时信息"],cursor:!1,speed:120})]),l("div",Me,[e(f,{plain:"",onClick:ye},{default:t(()=>[n("快速设置")]),_:1})])])]),default:t(()=>[u((m(),h(ae,{height:`calc(${s(V)}px - 35vh - 340px)`},{default:t(()=>[e(K,{direction:"vertical",column:3,border:"",size:"default"},{default:t(()=>[e(d,{label:"WIFI状态",align:"center"},{default:t(()=>[e(le,{size:"small",modelValue:s(g),"onUpdate:modelValue":o[0]||(o[0]=p=>re(g)?g.value=p:g=p),onChange:he},null,8,["modelValue"])]),_:1}),e(d,{label:"蜂窝数据",align:"center"},{default:t(()=>[e(le,{size:"small",modelValue:s(y),"onUpdate:modelValue":o[1]||(o[1]=p=>re(y)?y.value=p:y=p),onChange:fe},null,8,["modelValue"])]),_:1}),e(d,{label:"网络类型",align:"center"},{default:t(()=>[e(ie,null,{default:t(()=>[n(r(s(a).state.NetInfo.sub_network_type),1)]),_:1})]),_:1}),e(d,{label:"漫游时间",align:"center"},{default:t(()=>[e(ie,null,{default:t(()=>[n(r(s(H)),1)]),_:1})]),_:1}),e(d,{label:"实时上传"},{default:t(()=>[n(r(s(de)(s(q).toString())),1)]),_:1}),e(d,{label:"实时下载"},{default:t(()=>[n(r(s(de)(s(A).toString())),1)]),_:1})]),_:1})]),_:1},8,["height"])),[[ne,R.value||s(b)||s(w)]])]),_:1},8,["style"])]),_:1})),[[z]]),u((m(),h(W,{xs:24,sm:24,md:12,lg:8,xl:8,class:"mb-[18px]",initial:{opacity:0,y:100},enter:{opacity:1,y:0,transition:{delay:400}}},{default:t(()=>[e(S,{shadow:"never"},{header:t(()=>[l("div",Re,[l("div",Ge,[e(s(D),{className:"type-it4",values:["上传下载折线图(KB)"],cursor:!1,speed:120})])])]),default:t(()=>[e(Oe,{time:s(P),up:s(T),down:s(B)},null,8,["time","up","down"])]),_:1})]),_:1})),[[z]]),u((m(),h(W,{xs:24,sm:24,md:12,lg:8,xl:8,class:"mb-[18px]",initial:{opacity:0,y:100},enter:{opacity:1,y:0,transition:{delay:400}}},{default:t(()=>[e(S,{shadow:"never"},{header:t(()=>[l("div",Qe,[l("div",Xe,[e(s(D),{className:"type-it3",values:["流量统计"],cursor:!1,speed:120}),u(e(L,{class:"ml-2"},{default:t(()=>[n("套餐："+r(s(N)),1)]),_:1},512),[[M,s(I)==="data"&&s(k)==="1"]]),u(e(L,{class:"ml-2",type:"success"},{default:t(()=>[n("套餐："+r(s(N))+"h",1)]),_:1},512),[[M,s(I)==="time"&&s(k)==="1"]]),u(e(L,{class:"ml-2",type:"danger"},{default:t(()=>[n("未设置套餐")]),_:1},512),[[M,s(k)==="0"]])]),l("div",Ye,[e(f,{plain:"",onClick:ge},{default:t(()=>[n("设置流量套餐")]),_:1})])])]),default:t(()=>[e(Pe,{unit:s(I),size:s(N),percent:s(J),Enable:s(k),Used:s(Z).toString(),Used_time:s(ee)},null,8,["unit","size","percent","Enable","Used","Used_time"])]),_:1})]),_:1})),[[z]]),u((m(),h(W,{xs:24,sm:24,md:12,lg:8,xl:8,class:"mb-[18px]",initial:{opacity:0,y:100},enter:{opacity:1,y:0,transition:{delay:400}}},{default:t(()=>[e(S,{shadow:"never"},{header:t(()=>[l("div",He,[l("div",Je,[e(s(D),{className:"type-it5",values:["已接入设备"],cursor:!1,speed:120})]),l("div",Ze,[e(se,{placement:"left",width:180,"popper-style":"padding: 5px;"},{reference:t(()=>[e(f,{plain:""},{default:t(()=>[n("连接二维码")]),_:1})]),default:t(()=>[l("div",et,[l("img",{id:"qrcode_img",src:s(ve)},null,8,tt)])]),_:1})])])]),default:t(()=>[l("div",st,[l("div",at,[l("div",lt,[e($,{icon:"circum:server",style:{margin:"1vh",width:"15vh",height:"15vh"}})])]),l("div",{class:"display_container",style:{"text-align":"center"},onClick:we},[l("div",it,[l("div",nt,[e($,{icon:"fa6-solid:network-wired",style:{margin:"5px",width:"8vh",height:"8vh"}}),l("span",ot,r(s(a).state.LanList.length),1),ct])]),l("div",rt,[l("div",dt,[e($,{icon:"icon-park-outline:wifi",style:{margin:"5px",width:"8vh",height:"8vh"}}),l("span",_t,r(s(a).state.NetWork.sta_count),1),ut])])]),l("div",pt,[l("div",mt,[e(K,{column:2,border:"",size:"default"},{default:t(()=>[e(d,{label:"当前WEB版本",align:"center"},{default:t(()=>[n(" V"+r(s(pe)),1)]),_:1})]),_:1})])])])]),_:1})]),_:1})),[[z]])]),_:1}),e(Ie,{id:"YoungTable",modelValue:j.value,"onUpdate:modelValue":o[3]||(o[3]=p=>j.value=p),title:"流量信息","align-center":"",onClose:be},{footer:t(()=>[l("span",vt,[e(f,{type:"primary",onClick:o[2]||(o[2]=p=>j.value=!1)},{default:t(()=>[n(" 我知道了 ")]),_:1})])]),default:t(()=>[u((m(),h(te,{data:me.value,border:""},{default:t(()=>[e(O,{prop:"name",label:"项目"}),e(O,{prop:"data",label:"值"})]),_:1},8,["data"])),[[ne,G.value]])]),_:1},8,["modelValue"])])}}});const It=Be(ft,[["__scopeId","data-v-8eb58523"]]);export{It as default};
