1 |
- (function(e){function t(t){for(var a,o,c=t[0],u=t[1],d=t[2],s=0,l=[];s<c.length;s++)o=c[s],Object.prototype.hasOwnProperty.call(r,o)&&r[o]&&l.push(r[o][0]),r[o]=0;for(a in u)Object.prototype.hasOwnProperty.call(u,a)&&(e[a]=u[a]);h&&h(t);while(l.length)l.shift()();return i.push.apply(i,d||[]),n()}function n(){for(var e,t=0;t<i.length;t++){for(var n=i[t],a=!0,o=1;o<n.length;o++){var c=n[o];0!==r[c]&&(a=!1)}a&&(i.splice(t--,1),e=u(u.s=n[0]))}return e}var a={},o={app:0},r={app:0},i=[];function c(e){return u.p+"js/"+({}[e]||e)+"."+{"chunk-03ac0c0b":"514b9ef3","chunk-08050d0a":"566b1c88","chunk-0bf52100":"fbb9d6bc","chunk-124fa9c2":"35dc3a7d","chunk-1aaf262b":"29b4c560","chunk-2136ea2a":"22cc6509","chunk-2c0d6c1e":"5e256fcb","chunk-36b911c0":"5c447341","chunk-3808e5e0":"74c95a2d","chunk-39aa058f":"c6d628cf","chunk-49b5958e":"53d62f86","chunk-4a65a124":"b546035f","chunk-4abb1e16":"c9f3f6de","chunk-4ae71590":"735142dc","chunk-4ff4a214":"bdf81e86","chunk-617596b6":"2f895847","chunk-65a2c9bd":"8b36c5b5","chunk-65e38907":"9b633a82","chunk-730ea89b":"88867803","chunk-8255aba2":"fa4c0b9f","chunk-881c2bbc":"aa99d388","chunk-90e590ec":"9f446e11","chunk-9dde97e6":"2ffc6f50","chunk-a59405ca":"67699421","chunk-b326df62":"519b66e2","chunk-b64c6542":"27f85a51","chunk-d361de44":"93851377","chunk-d8ce739e":"3fcf4876","chunk-e38868b0":"379d5c99","chunk-f023c980":"6c1bef0b"}[e]+".js"}function u(t){if(a[t])return a[t].exports;var n=a[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,u),n.l=!0,n.exports}u.e=function(e){var t=[],n={"chunk-03ac0c0b":1,"chunk-08050d0a":1,"chunk-0bf52100":1,"chunk-124fa9c2":1,"chunk-1aaf262b":1,"chunk-2136ea2a":1,"chunk-2c0d6c1e":1,"chunk-36b911c0":1,"chunk-3808e5e0":1,"chunk-39aa058f":1,"chunk-49b5958e":1,"chunk-4a65a124":1,"chunk-4abb1e16":1,"chunk-4ae71590":1,"chunk-4ff4a214":1,"chunk-617596b6":1,"chunk-65a2c9bd":1,"chunk-65e38907":1,"chunk-730ea89b":1,"chunk-8255aba2":1,"chunk-881c2bbc":1,"chunk-90e590ec":1,"chunk-9dde97e6":1,"chunk-a59405ca":1,"chunk-b326df62":1,"chunk-b64c6542":1,"chunk-d361de44":1,"chunk-d8ce739e":1,"chunk-e38868b0":1,"chunk-f023c980":1};o[e]?t.push(o[e]):0!==o[e]&&n[e]&&t.push(o[e]=new Promise((function(t,n){for(var a="css/"+({}[e]||e)+"."+{"chunk-03ac0c0b":"a5d41ff3","chunk-08050d0a":"fdd31697","chunk-0bf52100":"a03972af","chunk-124fa9c2":"4cfa4da6","chunk-1aaf262b":"392a9260","chunk-2136ea2a":"61af73cf","chunk-2c0d6c1e":"ed28bb37","chunk-36b911c0":"5ce2db8c","chunk-3808e5e0":"7f8efd37","chunk-39aa058f":"1b1c5ae6","chunk-49b5958e":"96212cb8","chunk-4a65a124":"0abd09a5","chunk-4abb1e16":"cf3f0650","chunk-4ae71590":"035ca901","chunk-4ff4a214":"d98fb79d","chunk-617596b6":"8dabe8e2","chunk-65a2c9bd":"9f175d71","chunk-65e38907":"3697f206","chunk-730ea89b":"4da6d879","chunk-8255aba2":"eb571e39","chunk-881c2bbc":"7dfecbe4","chunk-90e590ec":"69f60c24","chunk-9dde97e6":"6dfb8f10","chunk-a59405ca":"45a9d533","chunk-b326df62":"2a06b8a0","chunk-b64c6542":"d1f3134c","chunk-d361de44":"47297cc8","chunk-d8ce739e":"e2e5c0b4","chunk-e38868b0":"355f1cac","chunk-f023c980":"5a143173"}[e]+".css",r=u.p+a,i=document.getElementsByTagName("link"),c=0;c<i.length;c++){var d=i[c],s=d.getAttribute("data-href")||d.getAttribute("href");if("stylesheet"===d.rel&&(s===a||s===r))return t()}var l=document.getElementsByTagName("style");for(c=0;c<l.length;c++){d=l[c],s=d.getAttribute("data-href");if(s===a||s===r)return t()}var h=document.createElement("link");h.rel="stylesheet",h.type="text/css",h.onload=t,h.onerror=function(t){var a=t&&t.target&&t.target.src||r,i=new Error("Loading CSS chunk "+e+" failed.\n("+a+")");i.code="CSS_CHUNK_LOAD_FAILED",i.request=a,delete o[e],h.parentNode.removeChild(h),n(i)},h.href=r;var m=document.getElementsByTagName("head")[0];m.appendChild(h)})).then((function(){o[e]=0})));var a=r[e];if(0!==a)if(a)t.push(a[2]);else{var i=new Promise((function(t,n){a=r[e]=[t,n]}));t.push(a[2]=i);var d,s=document.createElement("script");s.charset="utf-8",s.timeout=120,u.nc&&s.setAttribute("nonce",u.nc),s.src=c(e);var l=new Error;d=function(t){s.onerror=s.onload=null,clearTimeout(h);var n=r[e];if(0!==n){if(n){var a=t&&("load"===t.type?"missing":t.type),o=t&&t.target&&t.target.src;l.message="Loading chunk "+e+" failed.\n("+a+": "+o+")",l.name="ChunkLoadError",l.type=a,l.request=o,n[1](l)}r[e]=void 0}};var h=setTimeout((function(){d({type:"timeout",target:s})}),12e4);s.onerror=s.onload=d,document.head.appendChild(s)}return Promise.all(t)},u.m=e,u.c=a,u.d=function(e,t,n){u.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},u.r=function(e){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u.t=function(e,t){if(1&t&&(e=u(e)),8&t)return e;if(4&t&&"object"===typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(u.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)u.d(n,a,function(t){return e[t]}.bind(null,a));return n},u.n=function(e){var t=e&&e.__esModule?function(){return e["default"]}:function(){return e};return u.d(t,"a",t),t},u.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},u.p="smartscreen/",u.oe=function(e){throw console.error(e),e};var d=window["webpackJsonp"]=window["webpackJsonp"]||[],s=d.push.bind(d);d.push=t,d=d.slice();for(var l=0;l<d.length;l++)t(d[l]);var h=s;i.push([0,"chunk-vendors"]),n()})({0:function(e,t,n){e.exports=n("56d7")},"034f":function(e,t,n){"use strict";n("85ec")},"04a1":function(e,t,n){},"365c":function(e,t,n){"use strict";n.d(t,"q",(function(){return s})),n.d(t,"p",(function(){return l})),n.d(t,"o",(function(){return h})),n.d(t,"s",(function(){return m})),n.d(t,"r",(function(){return f})),n.d(t,"B",(function(){return p})),n.d(t,"v",(function(){return g})),n.d(t,"y",(function(){return b})),n.d(t,"a",(function(){return k})),n.d(t,"t",(function(){return w})),n.d(t,"C",(function(){return v})),n.d(t,"D",(function(){return y})),n.d(t,"b",(function(){return S})),n.d(t,"c",(function(){return A})),n.d(t,"A",(function(){return R})),n.d(t,"h",(function(){return x})),n.d(t,"m",(function(){return E})),n.d(t,"l",(function(){return O})),n.d(t,"E",(function(){return T})),n.d(t,"u",(function(){return N})),n.d(t,"g",(function(){return I})),n.d(t,"x",(function(){return D})),n.d(t,"i",(function(){return j})),n.d(t,"e",(function(){return C})),n.d(t,"w",(function(){return M})),n.d(t,"f",(function(){return P})),n.d(t,"k",(function(){return U})),n.d(t,"n",(function(){return L})),n.d(t,"j",(function(){return _})),n.d(t,"d",(function(){return B})),n.d(t,"z",(function(){return F}));var a=n("5530"),o=(n("d3b7"),n("bc3a")),r=n.n(o),i=n("4360"),c=n("5c96"),u=r.a.create({timeout:2e4});u.interceptors.request.use((function(e){return e.Connection="keep-alive","get"===e.method?e.params=Object(a["a"])({token:i["a"].state.token},e.params):e.data.token=i["a"].state.token,e}),(function(e){console.log(e),Promise.reject(e)})),u.interceptors.response.use((function(e){var t="";if(t="post"==e.config.method?!e.config.data||e.config.data instanceof FormData?e.config.data:JSON.parse(e.config.data):e.config.params,e.data.code&&!t.alertshow)switch(e.data.code){case 1:Object(c["Message"])({message:e.data.msg,type:"error",duration:3e3,onClose:function(){0}});break;case 403:break;case 601:break;case 404:Object(c["Message"])({message:"请求的资源不存在",type:"error",duration:3e3,onClose:function(){0}});break;default:Object(c["Message"])({message:e.data.msg,type:"error",duration:3e3,onClose:function(){0}});break}return e}),(function(e){if(e.response.data.code)switch(e.response.data.code){case 1:Object(c["Message"])({message:e.response.data.msg,type:"error",duration:3e3,onClose:function(){0}});break;case 404:Object(c["Message"])({message:"请求的资源不存在",type:"error",duration:3e3,onClose:function(){0}});break;default:console.log(e);break}return Promise.reject(e)}));var d=u;function s(e){return d({url:"/dashboard/wisdom/index",method:"post",data:e})}function l(e){return d({url:"/dashboard/wisdom/getCate1",method:"post",data:e})}function h(e){return d({url:"/dashboard/wisdom/getCate2",method:"post",data:e})}function m(e){return d({url:"/dashboard/wisdom/getData",method:"post",data:e})}function f(e){return d({url:"/dashboard/wisdom/getRead",method:"post",data:e})}function p(e){return d({url:"/dashboard/wisdom/saveLog",method:"post",data:e})}function g(e){return d({url:"/dashboard/wisdom/getWisdomImg",method:"post",data:e})}function b(e){return d({url:"/dashboard/wisdom/getRenovatePackage",method:"post",data:e})}function k(e){return d({url:"/dashboard/wisdom/callRenovatePrice",method:"post",data:e})}function w(e){return d({url:"/dashboard/wisdom/getQrcode",method:"post",data:e})}function v(e){return d({url:"/dashboard/wisdom/ergodic",method:"post",data:e})}function y(e){return d({url:"/dashboard/wisdom/logout",method:"post",data:e})}function S(e){return d({url:"/dashboard/wisdom/construction",method:"post",data:e})}function A(e){return d({url:"/dashboard/wisdom/construction_step",method:"post",data:e})}function R(e){return d({url:"/dashboard/wisdom/project",method:"post",data:e})}function x(e){return d({url:"/dashboard/wisdom/designer_detail",method:"post",data:e})}function E(e){return d({url:"/dashboard/wisdom/designer_worklist",method:"post",data:e})}function O(e){return d({url:"/dashboard/wisdom/designer_workdet",method:"post",data:e})}function T(e){return d({url:"/dashboard/wisdom/work_housetype",method:"post",data:e})}function N(e){return d({url:"/dashboard/wisdom/get_vrimg",method:"post",data:e})}function I(e){return d({url:"/dashboard/wisdom/designer_cuslist",method:"post",data:e})}function D(e){return d({url:"/dashboard/wisdom/planDetail",method:"post",data:e})}function j(e){return d({url:"/dashboard/wisdom/designer_editplan",method:"post",data:e})}function C(e){return d({url:"/dashboard/wisdom/delPlandata",method:"post",data:e})}function M(e){return d({url:"/dashboard/wisdom/housetypelist",method:"post",data:e})}function P(e){return d({url:"/dashboard/wisdom/designer_add_works",method:"post",data:e})}function U(e){return d({url:"/dashboard/wisdom/designer_work",method:"post",data:e})}function L(e){return d({url:"/dashboard/wisdom/designer_worksdet",method:"post",data:e})}function _(e){return d({url:"/dashboard/wisdom/designer_housetype",method:"post",data:e})}function B(e){return d({url:"/dashboard/wisdom/cus_designer_list",method:"post",data:e})}function F(e){return d({url:"/dashboard/wisdom/private_data",method:"post",data:e})}},4360:function(e,t,n){"use strict";n("e9c4"),n("d3b7"),n("a15b");var a=n("2b0e"),o=n("2f62"),r=n("f1ed"),i=n("365c"),c=n("5c96");a["default"].use(o["a"]);var u={activePath:localStorage.getItem("ACTIVE-PATH")?localStorage.getItem("ACTIVE-PATH"):"/index/company",token:r["a"].cookies.get("smartToken")?r["a"].cookies.get("smartToken"):"",clienType:localStorage.getItem("AUTH-CLIENTYPE")?localStorage.getItem("AUTH-CLIENTYPE"):"",configObj:localStorage.getItem("CONFIG-DATA")?JSON.parse(localStorage.getItem("CONFIG-DATA")):{},switchRecord:localStorage.getItem("SWITCH-RECORD")?localStorage.getItem("SWITCH-RECORD"):0,companyName:localStorage.getItem("COMPANY-NAME")?localStorage.getItem("COMPANY-NAME"):"智慧屏",asideArr:localStorage.getItem("ASIDE-DATA")?JSON.parse(localStorage.getItem("ASIDE-DATA")):[],bindflag:sessionStorage.getItem("BINDEMPLOYEE")?JSON.parse(sessionStorage.getItem("BINDEMPLOYEE")):""};t["a"]=new o["a"].Store({state:{activePath:u.activePath,isCollapse:!1,token:u.token,clienType:u.clienType,configObj:u.configObj,switchRecord:u.switchRecord,recordArr:[],companyName:u.companyName,asideArr:u.asideArr,bindflag:u.bindflag,isNoperate:!1,timeNumer:0},mutations:{setNoperate:function(e,t){e.isNoperate=t},setRecordTime:function(e,t){window.timers=setInterval((function(){e.timeNumer=e.timeNumer+1}),1e3)},clearTimer:function(e,t){e.timeNumer=0},setAsideArr:function(e,t){e.asideArr=t,localStorage.setItem("ASIDE-DATA",JSON.stringify(t))},setCompanyName:function(e,t){e.companyName=t,localStorage.setItem("COMPANY-NAME",t)},setRecordArrEmpty:function(e,t){e.recordArr=t},setRecordArr:function(e,t){e.recordArr.push(t)},setSwitchRecord:function(e,t){e.switchRecord=t,localStorage.setItem("SWITCH-RECORD",t)},setActivePath:function(e,t){e.activePath=t,localStorage.setItem("ACTIVE-PATH",t)},setCollapse:function(e,t){e.isCollapse=t},setToken:function(e,t){e.token=t,r["a"].cookies.set("smartToken",t)},setClienType:function(e,t){e.clienType=t,localStorage.setItem("AUTH-CLIENTYPE",t)},setConfigObj:function(e,t){e.configObj=t,localStorage.setItem("CONFIG-DATA",JSON.stringify(t))},setBindflag:function(e,t){e.bindflag=t,sessionStorage.setItem("BINDEMPLOYEE",JSON.stringify(t))}},actions:{setRequestRecord:function(e,t){var n=e.commit,a=e.state;return new Promise((function(e,t){if(a.recordArr.length){n("setRecordArr",a.timeNumer);var o=new FormData;o.append("file",""),o.append("token",a.token),o.append("time",a.recordArr.join(",")),Object(i["B"])(o).then((function(t){0==t.data.code?(e({code:200}),n("setRecordArrEmpty",[]),n("clearTimer",0),window.timers&&clearInterval(window.timers)):e({code:401,msg:t.data.msg})})).catch((function(e){t({error:">>>接口请求出错,请联系管理员"})}))}else e({code:200})}))},outLogin:function(e,t){e.commit;var n=e.state;return new Promise((function(e,t){var a=c["Loading"].service({lock:!0,text:"正在退出登录...",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),o={str:n.token};Object(i["D"])(o).then((function(t){0==t.data.code?e({code:200,data:t.data.data}):e({code:401,msg:t.data.msg}),a.close()})).catch((function(e){t({error:">>>接口请求出错,请联系管理员"})}))}))}}})},"56d7":function(e,t,n){"use strict";n.r(t);n("e260"),n("e6cf"),n("cca6"),n("a79d"),n("d3b7"),n("159b"),n("b64b");var a=n("2b0e"),o=n("5c96"),r=n.n(o),i=(n("0fae"),function(){var e=this,t=e.$createElement,n=e._self._c||t;return n("div",{attrs:{id:"app"}},[n("router-view"),e.fileurl?n("audio",{ref:"audio",staticStyle:{display:"none"},attrs:{src:e.fileurl,controls:"controls",id:"myaudio"}}):e._e(),(e.switchRecord,e._e()),1==e.switchRecord?n("div",{staticClass:"recordAudio",on:{click:e.myrecording}},[n("el-button",{directives:[{name:"show",rawName:"v-show",value:!e.RecordingSwitch,expression:"!RecordingSwitch"}],staticClass:"bc6C55FE",attrs:{type:"primary",loading:e.uloading,disabled:e.uloading,round:""}},[e._v("开 始")]),n("el-button",{directives:[{name:"show",rawName:"v-show",value:e.RecordingSwitch,expression:"RecordingSwitch"}],attrs:{type:"danger",loading:e.oloading,disabled:e.oloading,round:""}},[e._v("结 束")])],1):e._e()],1)}),c=[],u=n("5530");n("ac1f"),n("00b4"),n("5319"),n("b0c0"),n("3ca3"),n("ddb0"),n("2b3d"),n("9861"),n("a15b"),n("cfc3"),n("907a"),n("9a8c"),n("a975"),n("735e"),n("c1ac"),n("d139"),n("3a7b"),n("d5d6"),n("82f8"),n("e91f"),n("60bd"),n("5f96"),n("3280"),n("3fcc"),n("ca91"),n("25a1"),n("cd26"),n("3c5d"),n("2954"),n("649e"),n("219c"),n("170b"),n("b39a"),n("72f7"),n("c19f"),n("25f0");window.URL=window.URL||window.webkitURL,navigator.getUserMedia=navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.mozGetUserMedia||navigator.msGetUserMedia;var d=function(e,t){t=t||{},t.sampleBits=t.sampleBits||128,t.sampleRate=t.sampleRate||44100;var n=new(window.webkitAudioContext||window.AudioContext),a=n.createMediaStreamSource(e),o=n.createScriptProcessor||n.createJavaScriptNode,r=o.apply(n,[4096,1,1]),i={size:0,buffer:[],inputSampleRate:n.sampleRate,inputSampleBits:16,outputSampleRate:t.sampleRate,oututSampleBits:t.sampleBits,input:function(e){this.buffer.push(new Float32Array(e)),this.size+=e.length},compress:function(){for(var e=new Float32Array(this.size),t=0,n=0;n<this.buffer.length;n++)e.set(this.buffer[n],t),t+=this.buffer[n].length;var a=parseInt(this.inputSampleRate/this.outputSampleRate),o=e.length/a,r=new Float32Array(o),i=0,c=0;while(i<o)r[i]=e[c],c+=a,i++;return r},encodeWAV:function(){var e=Math.min(this.inputSampleRate,this.outputSampleRate),t=Math.min(this.inputSampleBits,this.oututSampleBits),n=this.compress(),a=n.length*(t/8),o=new ArrayBuffer(44+a),r=new DataView(o),i=1,c=0,u=function(e){for(var t=0;t<e.length;t++)r.setUint8(c+t,e.charCodeAt(t))};if(u("RIFF"),c+=4,r.setUint32(c,36+a,!0),c+=4,u("WAVE"),c+=4,u("fmt "),c+=4,r.setUint32(c,16,!0),c+=4,r.setUint16(c,1,!0),c+=2,r.setUint16(c,i,!0),c+=2,r.setUint32(c,e,!0),c+=4,r.setUint32(c,i*e*(t/8),!0),c+=4,r.setUint16(c,i*(t/8),!0),c+=2,r.setUint16(c,t,!0),c+=2,u("data"),c+=4,r.setUint32(c,a,!0),c+=4,8===t)for(var d=0;d<n.length;d++,c++){var s=Math.max(-1,Math.min(1,n[d])),l=s<0?32768*s:32767*s;l=parseInt(255/(65535/(l+32768))),r.setInt8(c,l,!0)}else for(var h=0;h<n.length;h++,c+=2){var m=Math.max(-1,Math.min(1,n[h]));r.setInt16(c,m<0?32768*m:32767*m,!0)}return new Blob([r],{type:"audio/mp3"})}};this.start=function(){a.connect(r),r.connect(n.destination)},this.stop=function(){r.disconnect()},this.getBlob=function(){return this.stop(),i.encodeWAV()},this.play=function(e){var t=document.getElementById("downloadRec");t.href=window.URL.createObjectURL(this.getBlob()),t.download=(new Date).toLocaleString()+".mp3",e.src=window.URL.createObjectURL(this.getBlob())},this.upload=function(e,t){var n=new FormData;n.append("audioData",this.getBlob());var a=new XMLHttpRequest;t&&(a.upload.addEventListener("progress",(function(e){t("uploading",e)}),!1),a.addEventListener("load",(function(e){t("ok",e)}),!1),a.addEventListener("error",(function(e){t("error",e)}),!1),a.addEventListener("abort",(function(e){t("cancel",e)}),!1)),a.open("POST",e),a.send(n)},r.onaudioprocess=function(e){i.input(e.inputBuffer.getChannelData(0))}};d.throwError=function(e){throw alert(e),location.reload(),new function(){this.toString=function(){return e}}},d.canRecording=null!=navigator.getUserMedia,d.get=function(e,t){if(e){if(!navigator.getUserMedia)return void d.throwErr("当前浏览器不支持录音功能。");console.log(navigator),navigator.getUserMedia({audio:!0},(function(n){var a=new d(n,t);e(a)}),(function(e){switch(console.log(e),e.code||e.name){case"PERMISSION_DENIED":case"PermissionDeniedError":d.throwError("用户拒绝提供信息。");break;case"NOT_SUPPORTED_ERROR":case"NotSupportedError":d.throwError("浏览器不支持硬件设备。");break;case"MANDATORY_UNSATISFIED_ERROR":case"MandatoryUnsatisfiedError":d.throwError("无法发现指定的硬件设备。");break;default:d.throwError("无法打开麦克风。异常信息:"+(e.code||e.name));break}}))}};var s=d,l=n("2f62"),h=n("365c"),m=n("c782"),f=n.n(m),p=n("f1ed"),g=null,b={data:function(){return{uloading:!1,oloading:!1,loading:null,RecordingSwitch:!1,files:"",recorder:null,mediaRecorder:null,fileurl:"",interval:"",playing:!0,timer:null,timeNumber:0,fileName:"",blobRecord:null}},computed:Object(u["a"])(Object(u["a"])({},Object(l["d"])({token:function(e){return e.token},switchRecord:function(e){return e.switchRecord},recordArr:function(e){return e.recordArr},isNoperate:function(e){return e.isNoperate}})),{},{isMobileDevices:function(){var e=/iPad/.test(navigator.platform)||navigator.maxTouchPoints&&navigator.maxTouchPoints>2&&/MacIntel/.test(navigator.platform),t=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);return e||t}}),watch:{isNoperate:{handler:function(e){var t=this;e&&(window.outTimer&&clearTimeout(window.outTimer),this.$confirm("长时间未操作,请确认是否继续使用!","信息提示",{confirmButtonText:"退出登录",cancelButtonText:"继续使用",type:"warning"}).then((function(){t.askOutlognFun()})).catch((function(){window.outTimer=setTimeout((function(){clearTimeout(window.outTimer),t.setNoperate(!0)}),18e5),t.setNoperate(!1)})))},immediate:!0}},created:function(){var e=this.getQueryStringArgs(location.href);e.token&&this.setToken(e.token),this.setRecordTime()},mounted:function(){var e=new(window.AudioContext||window.webkitAudioContext);g=new f.a(e)},methods:Object(u["a"])(Object(u["a"])(Object(u["a"])({},Object(l["c"])(["setToken","setRecordArr","setRecordArrEmpty","setNoperate","setRecordTime","clearTimer"])),Object(l["b"])(["setRequestRecord","outLogin"])),{},{getQueryStringArgs:function(e){e=null==e?window.location.href:e;var t=e.substring(e.lastIndexOf("?")+1),n={},a=/([^?&=]+)=([^?&=]*)/g;return t.replace(a,(function(e,t,a){var o=decodeURIComponent(t),r=decodeURIComponent(a);return r=String(r),n[o]=r,e})),n},askOutlognFun:function(){var e=this;this.RecordingSwitch?this.isMobileDevices?(this.timer&&clearInterval(this.timer),this.setRecordArr(this.timeNumber),this.stopRecording()):(this.timer&&clearInterval(this.timer),this.loading=this.$loading({lock:!0,text:"正在提交音频数据...",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),this.setRecordArr(this.timeNumber),this.End(),this.RecordingSwitch=!1):this.setRequestRecord().then((function(t){200==t.code?e.outLogin().then((function(t){200==t.code&&(p["a"].cookies.remove("smartToken"),localStorage.clear(),sessionStorage.clear(),window.location.replace("https://"+window.location.host+window.location.pathname+"#/home?token="+t.data),"home"===e.$route.name&&window.location.reload())})):401==t.code&&e.$message.error(t.msg)}))},myrecording:function(){var e=this;this.$store.state.bindflag&&"0"!=this.$store.state.bindflag?this.isMobileDevices?this.RecordingSwitch?(this.timer&&clearInterval(this.timer),this.setRecordArr(this.timeNumber),this.stopRecording()):(this.timer=setInterval((function(){e.timeNumber++}),1e3),this.uloading=!0,this.getUserMedia()):(this.RecordingSwitch?(this.timer&&clearInterval(this.timer),this.loading=this.$loading({lock:!0,text:"正在提交音频数据...",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),this.setRecordArr(this.timeNumber),this.End()):(this.timer=setInterval((function(){e.timeNumber++}),1e3),this.Start()),this.RecordingSwitch=!this.RecordingSwitch):this.$children[0].setcodetap()},getUserMedia:function(){var e=this,t=(navigator.mediaDevices?navigator.mediaDevices.getUserMedia:null)||navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.mozGetUserMedia||navigator.msGetUserMedia;t?navigator.mediaDevices.getUserMedia({audio:!0}).then((function(t){g.init(t),setTimeout((function(){g.start().then((function(){e.RecordingSwitch=!0,e.uloading=!1}))}),300)})).catch((function(t){e.uloading=!1,console.error("Error accessing microphone:",t)})):(this.RecordingSwitch=!1,this.$message.error("当前浏览器不支持录音"))},stopRecording:function(){var e=this;this.oloading=!0,g.stop().then((function(t){var n=t.blob;t.buffer;e.RecordingSwitch=!1;var a=new File([n],"recording.mp3",{type:"audio/mp3;codecs=opus",lastModified:Date.now()});e.loading=e.$loading({lock:!0,text:"正在提交音频数据...",spinner:"el-icon-loading",background:"rgba(0, 0, 0, 0.7)"}),e.fileurl=URL.createObjectURL(a),e.uploadAudioFile(a)}))},Start:function(){var e=this;s.get((function(t){t&&(e.recorder=t,e.recorder.start())}))},End:function(){var e=this;if(this.recorder){this.recorder.stop();var t=this.recorder.getBlob(),n=new File([t],"recording.mp3",{type:"audio/mp3;codecs=opus",lastModified:Date.now()});this.files=n;var a=URL.createObjectURL(n);this.fileurl=a;var o=new Audio(a);o.addEventListener("loadedmetadata",(function(t){o.duration,e.uploadAudioFile(n)}))}},uploadAudioFile:function(e){var t=this;this.uploadALY(e).then((function(e){var n=new FormData;n.append("file",e),n.append("token",t.token),n.append("time",t.recordArr.join(",")),Object(h["B"])(n).then((function(e){if(0==e.data.code){t.oloading=!1,t.setRecordArrEmpty([]),t.clearTimer(),t.loading.close(),t.$message({message:"已成功提交",type:"success"});var n=setTimeout((function(){clearTimeout(n),t.outloginFun()}),1e3)}else t.loading.close(),t.$message({message:e.data.msg,type:"error"})})).catch((function(e){t.loading.close(),t.$message({message:"音频提交失败!",type:"error"})}))}))},uploadALY:function(e){var t=this;return new Promise((function(n,a){var o=new OSS({region:"oss-cn-hangzhou",accessKeyId:"LTAI5tHjWupJSCAycy2yVbQZ",accessKeySecret:"eNFicm77Cfq3u7ZnQyw1urFmFNpf3w",bucket:"zyzswzh",secure:!0}),r=new Date,i=r.getFullYear()+""+(1*r.getMonth()+1)+r.getDate();t.fileName="dashboard/"+i+"/"+Date.now()+".mp3",o.multipartUpload(t.fileName,e).then((function(e){n(e.name)})).catch((function(e){a(e)}))}))},outloginFun:function(){var e=this;this.outLogin().then((function(t){200==t.code&&(p["a"].cookies.remove("smartToken"),localStorage.clear(),sessionStorage.clear(),window.location.replace("https://"+window.location.host+window.location.pathname+"#/home?token="+t.data),"home"===e.$route.name&&window.location.reload())}))}})},k=b,w=(n("034f"),n("af8e"),n("2877")),v=Object(w["a"])(k,i,c,!1,null,"8ff072a8",null),y=v.exports,S=n("8c4f"),A=n("4360"),R=n("323e"),x=n.n(R);n("a5d8");a["default"].use(S["a"]);var E=null,O=[{path:"/",redirect:"home"},{path:"/home",name:"home",component:function(){return n.e("chunk-9dde97e6").then(n.bind(null,"f391"))},meta:{title:"智慧屏-首页",auth:!1,index:0,keep:!0}},{redirect:"/index/company",path:"/index",name:"index",component:function(){return n.e("chunk-08050d0a").then(n.bind(null,"06ab"))},meta:{title:"智慧屏",auth:!1},children:[{path:"/index/company",name:"company",component:function(){return n.e("chunk-f023c980").then(n.bind(null,"2136"))},meta:{title:"智慧屏-公司简介",auth:!1,index:1,module:"introduce",keep:!0}},{path:"/index/modelAdvantages",name:"modelAdvantages",component:function(){return n.e("chunk-36b911c0").then(n.bind(null,"6f4b"))},meta:{title:"智慧屏-模式优势",auth:!1,index:2,module:"pattern",keep:!0}},{path:"/index/boutiqueDesign",name:"boutiqueDesign",component:function(){return n.e("chunk-881c2bbc").then(n.bind(null,"0db3"))},meta:{title:"智慧屏-精品设计",auth:!1,index:3,module:"boutique",keep:!0}},{path:"/index/platinumEngineering",name:"platinumEngineering",component:function(){return n.e("chunk-4ae71590").then(n.bind(null,"8130"))},meta:{title:"智慧屏-铂金工程",auth:!1,index:4,module:"platinum",keep:!0}},{path:"/index/materials",name:"materials",component:function(){return n.e("chunk-a59405ca").then(n.bind(null,"8cc3"))},meta:{title:"智慧屏-大牌材料",auth:!1,index:5,module:"science",keep:!0}},{path:"/index/softDecoration",name:"softDecoration",component:function(){return n.e("chunk-124fa9c2").then(n.bind(null,"f02e"))},meta:{title:"智慧屏-大牌软装",auth:!1,index:6,module:"major",keep:!0}},{path:"/index/customized",name:"customized",component:function(){return n.e("chunk-2c0d6c1e").then(n.bind(null,"23ac"))},meta:{title:"智慧屏-定制家具",auth:!1,index:7,module:"customized",keep:!0}},{path:"/index/modelHouses",name:"modelHouses",component:function(){return n.e("chunk-617596b6").then(n.bind(null,"8a0e"))},meta:{title:"智慧屏-实景样板房",auth:!1,index:8,module:"realistic",keep:!0}},{path:"/index/publicPraise",name:"publicPraise",component:function(){return n.e("chunk-4ff4a214").then(n.bind(null,"13a0"))},meta:{title:"智慧屏-口碑及服务",auth:!1,index:9,module:"praise",keep:!0}},{path:"/index/effect",name:"effect",component:function(){return n.e("chunk-2136ea2a").then(n.bind(null,"1b67"))},meta:{title:"智慧屏-效果图",auth:!1,index:10,module:"praise",keep:!0}},{path:"/index/realview",name:"realview",component:function(){return n.e("chunk-8255aba2").then(n.bind(null,"aea2"))},meta:{title:"智慧屏-实景图",auth:!1,index:11,module:"praise",keep:!0}},{path:"/index/casedetail",name:"casedetail",component:function(){return n.e("chunk-49b5958e").then(n.bind(null,"f06f"))},meta:{title:"智慧屏-案例详情",auth:!1,index:12,keep:!1}},{path:"/index/articledetail",name:"articledetail",component:function(){return n.e("chunk-e38868b0").then(n.bind(null,"6dd5"))},meta:{title:"智慧屏-图文详情",auth:!1,index:13,keep:!1}},{path:"/index/videodetail",name:"videodetail",component:function(){return n.e("chunk-d361de44").then(n.bind(null,"1fdc"))},meta:{title:"智慧屏-视频详情",auth:!1,index:14,keep:!1}},{path:"/index/vrdetail",name:"vrdetail",component:function(){return n.e("chunk-d8ce739e").then(n.bind(null,"0f837"))},meta:{title:"智慧屏-VR详情",auth:!1,index:15,keep:!1}},{path:"/index/pdfDetail",name:"pdfDetail",component:function(){return n.e("chunk-3808e5e0").then(n.bind(null,"4155"))},meta:{title:"智慧屏-PDF详情",auth:!1,index:16,keep:!1}},{path:"/index/calcquote",name:"calcquote",component:function(){return n.e("chunk-b326df62").then(n.bind(null,"cdf7"))},meta:{title:"智慧屏-计算报价",auth:!1,index:17,keep:!1}},{path:"/index/construction",name:"construction",component:function(){return n.e("chunk-03ac0c0b").then(n.bind(null,"f688"))},meta:{title:"智慧屏-在施工地",auth:!1,index:18,keep:!1}},{path:"/index/inventory",name:"inventory",component:function(){return n.e("chunk-1aaf262b").then(n.bind(null,"e610"))},meta:{title:"智慧屏-报价清单",auth:!1,index:19,keep:!1}},{path:"/index/designer",name:"designer",component:function(){return n.e("chunk-4a65a124").then(n.bind(null,"c6d5"))},meta:{title:"智慧屏-设计师介绍",auth:!1,index:20,keep:!0}},{path:"/index/worksDetail",name:"worksDetail",component:function(){return n.e("chunk-4abb1e16").then(n.bind(null,"5d15"))},meta:{title:"智慧屏-作品集详情",auth:!1,index:21,keep:!1}},{path:"/index/programme",name:"programme",component:function(){return n.e("chunk-90e590ec").then(n.bind(null,"7af6"))},meta:{title:"智慧屏-方案资料",auth:!1,index:24,keep:!1}},{path:"/index/viewpdf",name:"viewpdf",component:function(){return n.e("chunk-65a2c9bd").then(n.bind(null,"1126"))},meta:{title:"智慧屏-方案资料PDF",auth:!1,index:25,keep:!1}}]},{redirect:"/setting/projectsetting",path:"/setting",name:"setting",component:function(){return n.e("chunk-b64c6542").then(n.bind(null,"f6ce"))},meta:{title:"智慧屏",auth:!1},children:[{path:"/setting/projectsetting",name:"projectsetting",component:function(){return n.e("chunk-730ea89b").then(n.bind(null,"e652"))},meta:{title:"智慧屏-方案资料设置",auth:!1,index:55,keep:!1}},{path:"/setting/workSetting",name:"workSetting",component:function(){return n.e("chunk-39aa058f").then(n.bind(null,"adaa"))},meta:{title:"智慧屏-作品集设置",auth:!1,index:56,keep:!1}},{path:"/setting/information",name:"information",component:function(){return n.e("chunk-0bf52100").then(n.bind(null,"eaae"))},meta:{title:"智慧屏-内部资料",auth:!1,index:57,keep:!1}}]},{path:"*",component:function(){return n.e("chunk-65e38907").then(n.bind(null,"1ec6"))},meta:{title:"404页面",auth:!1}}],T=new S["a"]({mode:"hash",base:"smartscreen/",routes:O});T.beforeEach((function(e,t,n){A["a"].state.token&&(E&&clearTimeout(E),window.outTimer&&clearTimeout(window.outTimer),E=setTimeout((function(){clearTimeout(E),A["a"].commit("setNoperate",!0)}),18e5)),A["a"].state.configObj&&A["a"].state.configObj[e.meta.module]?p["a"].title("智慧屏-".concat(A["a"].state.configObj[e.meta.module].title)):p["a"].title(e.meta.title),x.a.start(),n(!0)})),T.afterEach((function(e){x.a.done()}));var N=T;function I(e){var t=[];Object.keys(e).forEach((function(n){t.push(e[n])})),A["a"].commit("setAsideArr",t)}a["default"].use(r.a),a["default"].config.productionTip=!1,new a["default"]({router:N,store:A["a"],render:function(e){return e(y)},mounted:function(){Object(h["q"])({}).then((function(e){0==e.data.code&&(A["a"].commit("setSwitchRecord",e.data.switch),I(e.data.data))}))}}).$mount("#app")},"85ec":function(e,t,n){},af8e:function(e,t,n){"use strict";n("04a1")},f1ed:function(e,t,n){"use strict";n("99af");var a=n("a78e"),o=n.n(a),r={set:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a={expires:1};Object.assign(a,n),o.a.set("xqadmin-".concat("1.0.1","-").concat(e),t,a)},get:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return o.a.get("xqadmin-".concat("1.0.1","-").concat(e))},getAll:function(){return o.a.get()},remove:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return o.a.remove("xqadmin-".concat("1.0.1","-").concat(e))}},i=r,c=n("4360"),u={cookies:i,title:function(e){var t="雪鹊";window.document.title="".concat(c["a"].state.companyName?c["a"].state.companyName:t).concat(e?" | ".concat(e):"")},open:function(e){var t=document.createElement("a");t.setAttribute("href",e),t.setAttribute("target","_blank"),t.setAttribute("id","xqadmin-link-temp"),document.body.appendChild(t),t.click(),document.body.removeChild(document.getElementById("xqadmin-link-temp"))}};t["a"]=u}});
|