You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1 lines
10 KiB
1 lines
10 KiB
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-084815e6"],{"47bc":function(e,t,i){e.exports={menuText:"#bfcbd9",menuActiveText:"#6394F9",subMenuActiveText:"#f4f4f5",menuBg:"#0B1529",menuHover:"#182848",subMenuBg:"#030C17",subMenuHover:"#182848",sideBarWidth:"180px",leftBarWidth:"130px"}},5683:function(e,t,i){"use strict";i.r(t);var n=function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("ScaleScreen",{staticClass:"scale-wrap",attrs:{width:1920,height:1080,selfAdaption:e.$store.state.screenSetting.isScale}},[i("div",{staticClass:"bg"},[e.loading?i("dv-loading",[e._v("Loading...")]):i("div",{staticClass:"host-body"},[i("div",{staticClass:"d-flex jc-center title_wrap"},[i("div",{staticClass:"zuojuxing"}),e._v(" "),i("div",{staticClass:"youjuxing"}),e._v(" "),i("div",{staticClass:"guang"},[e._v(e._s(e.dateYear)+" "+e._s(e.dateWeek)+" "+e._s(e.dateDay))]),e._v(" "),i("div",{staticClass:"d-flex jc-center"},[i("div",{staticClass:"title"},[i("span",{staticClass:"title-text"},[e._v(e._s(e.screenTitle))])])]),e._v(" "),i("div",{staticClass:"timers",on:{click:e.fullScreen}},[e._v("\n "+e._s(e.isFullScreen()?"退出全屏":"全屏")+"\n "),i("i",{class:e.isFullScreen()?"el-icon-crop":"el-icon-full-screen",staticStyle:{"margin-left":"10px"}})])]),e._v(" "),i("router-view")],1)],1),e._v(" "),i("Setting",{ref:"setting"})],1)},s=[],a=i("1e55"),r=i("ed08"),c=function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("transition",{attrs:{name:"yh-setting-fade"}},[i("div",{directives:[{name:"show",rawName:"v-show",value:e.settingShow,expression:"settingShow"}],staticClass:"setting",class:{settingShow:e.settingShow}},[i("div",{staticClass:"setting_dislog",on:{click:function(t){e.settingShow=!1}}}),e._v(" "),i("div",{staticClass:"setting_inner"},[i("div",{staticClass:"setting_header"},[e._v("设置")]),e._v(" "),i("div",{staticClass:"setting_body"},[i("div",{staticClass:"left_shu"},[e._v("全局设置")]),e._v(" "),i("div",{staticClass:"setting_item"},[i("span",{staticClass:"setting_label"},[e._v("\n 是否进行自动适配"),i("span",{staticClass:"setting_label_tip"},[e._v("(默认分辨率1920*1080)")]),e._v(":\n ")]),e._v(" "),i("div",{staticClass:"setting_content"},[i("el-radio-group",{on:{change:function(t){return e.radiochange(t,"isScale")}},model:{value:e.isScaleradio,callback:function(t){e.isScaleradio=t},expression:"isScaleradio"}},[i("el-radio",{attrs:{label:!0}},[e._v("是")]),e._v(" "),i("el-radio",{attrs:{label:!1}},[e._v("否")])],1)],1)]),e._v(" "),i("div",{staticClass:"left_shu"},[e._v("实时监测")]),e._v(" "),i("div",{staticClass:"setting_item"},[i("span",{staticClass:"setting_label"},[e._v("\n 商品提醒自动轮询: "),i("span",{staticClass:"setting_label_tip"})]),e._v(" "),i("div",{staticClass:"setting_content"},[i("el-radio-group",{on:{change:function(t){return e.radiochange(t,"sbtxSwiper")}},model:{value:e.sbtxradio,callback:function(t){e.sbtxradio=t},expression:"sbtxradio"}},[i("el-radio",{attrs:{label:!0}},[e._v("是")]),e._v(" "),i("el-radio",{attrs:{label:!1}},[e._v("否")])],1)],1)]),e._v(" "),i("div",{staticClass:"setting_item"},[i("span",{staticClass:"setting_label"},[e._v(" 实时预警轮播: ")]),e._v(" "),i("div",{staticClass:"setting_content"},[i("el-radio-group",{on:{change:function(t){return e.radiochange(t,"ssyjSwiper")}},model:{value:e.ssyjradio,callback:function(t){e.ssyjradio=t},expression:"ssyjradio"}},[i("el-radio",{attrs:{label:!0}},[e._v("是")]),e._v(" "),i("el-radio",{attrs:{label:!1}},[e._v("否")])],1)],1)]),e._v(" "),i("div",{staticClass:"flex justify-center"})])])])])},l=[],o={components:{},data:function(){return{settingShow:!1,sbtxradio:!0,ssyjradio:!0,isScaleradio:!0}},computed:{},methods:{init:function(){this.settingShow=!0},radiochange:function(e,t){this.$store.commit("screenSetting/updateSwiper",{val:e,type:t})}},created:function(){this.$store.commit("screenSetting/initSwipers"),this.sbtxradio=this.$store.state.screenSetting.sbtxSwiper,this.ssyjradio=this.$store.state.screenSetting.ssyjSwiper,this.isScaleradio=this.$store.state.screenSetting.isScale},mounted:function(){document.body.appendChild(this.$el)},beforeDestroy:function(){},destroyed:function(){this.$el&&this.$el.parentNode&&this.$el.parentNode.removeChild(this.$el)}},u=o,d=i("2877"),h=Object(d["a"])(u,c,l,!1,null,"5e2c6008",null),f=h.exports,p=function(){var e=this,t=e.$createElement,i=e._self._c||t;return i("full-screen-container",[e._t("default")],2)},g=[],v=i("c80c"),m=(i("96cf"),i("3b8d")),b=i("7618");i("c5f6");function S(e,t){var i=null;return function(){for(var n=arguments.length,s=new Array(n),a=0;a<n;a++)s[a]=arguments[a];i=setTimeout((function(){"function"===typeof e&&e.apply(null,s),clearTimeout(i)}),t>0?t:100)}}var _={name:"VScaleScreen",props:{width:{type:[String,Number],default:1920},height:{type:[String,Number],default:1080},fullScreen:{type:Boolean,default:!1},autoScale:{type:[Object,Boolean],default:!0},selfAdaption:{type:Boolean,default:!0},delay:{type:Number,default:500},boxStyle:{type:Object,default:function(){return{}}},wrapperStyle:{type:Object,default:function(){return{}}}},data:function(){return{currentWidth:0,currentHeight:0,originalWidth:0,originalHeight:0,onResize:null,observer:null}},watch:{selfAdaption:function(e){e?(this.resize(),this.addListener()):(this.clearListener(),this.clearStyle())}},computed:{screenWrapper:function(){return this.$refs["screenWrapper"]}},methods:{initSize:function(){var e=this;return new Promise((function(t,i){e.screenWrapper.parentNode.style.overflow="hidden",e.screenWrapper.parentNode.scrollLeft=0,e.screenWrapper.parentNode.scrollTop=0,e.$nextTick((function(){e.width&&e.height?(e.currentWidth=e.width,e.currentHeight=e.height):(e.currentWidth=e.screenWrapper.clientWidth,e.currentHeight=e.screenWrapper.clientHeight),e.originalHeight&&e.originalWidth||(e.originalWidth=window.screen.width,e.originalHeight=window.screen.height),t()}))}))},updateSize:function(){this.currentWidth&&this.currentHeight?(this.screenWrapper.style.width="".concat(this.currentWidth,"px"),this.screenWrapper.style.height="".concat(this.currentHeight,"px")):(this.screenWrapper.style.width="".concat(this.originalWidth,"px"),this.screenWrapper.style.height="".concat(this.originalHeight,"px"))},handleAutoScale:function(e){if(this.autoScale){var t=this.screenWrapper,i=t.clientWidth,n=t.clientHeight,s=document.body.clientWidth,a=document.body.clientHeight;t.style.transform="scale(".concat(e,",").concat(e,") ");var r=Math.max((s-i*e)/2,0),c=Math.max((a-n*e)/2,0);"object"===Object(b["a"])(this.autoScale)&&(!this.autoScale.x&&(r=0),!this.autoScale.y&&(c=0)),this.screenWrapper.style.margin="".concat(c,"px ").concat(r,"px")}},updateScale:function(){var e=this.screenWrapper,t=document.body.clientWidth,i=document.body.clientHeight,n=this.currentWidth||this.originalWidth,s=this.currentHeight||this.originalHeight,a=t/n,r=i/s;if(this.fullScreen)return e.style.transform="scale(".concat(a,",").concat(r,")"),!1;var c=Math.min(a,r);this.handleAutoScale(c)},initMutationObserver:function(){var e=this,t=this.screenWrapper,i=this.observer=new MutationObserver((function(){e.onResize()}));i.observe(t,{attributes:!0,attributeFilter:["style"],attributeOldValue:!0})},clearListener:function(){window.removeEventListener("resize",this.onResize)},addListener:function(){window.addEventListener("resize",this.onResize)},clearStyle:function(){var e=this.screenWrapper;e.parentNode.style.overflow="auto",e.style=""},resize:function(){var e=Object(m["a"])(Object(v["a"])().mark((function e(){return Object(v["a"])().wrap((function(e){while(1)switch(e.prev=e.next){case 0:if(this.selfAdaption){e.next=2;break}return e.abrupt("return");case 2:return e.next=4,this.initSize();case 4:this.updateSize(),this.updateScale();case 6:case"end":return e.stop()}}),e,this)})));function t(){return e.apply(this,arguments)}return t}()},mounted:function(){var e=this;this.onResize=S((function(){e.resize()}),this.delay),this.$nextTick((function(){e.selfAdaption&&(e.resize(),e.addListener())}))},beforeDestroy:function(){this.clearListener()}},y=_,w=(i("67e8"),Object(d["a"])(y,p,g,!1,null,"09118310",null)),x=w.exports,W=i("de58"),C={components:{Setting:f,ScaleScreen:x,indexPage:W["default"]},data:function(){return{timing:null,loading:!0,dateDay:null,dateYear:null,dateWeek:null,weekday:["周日","周一","周二","周三","周四","周五","周六"],screenTitle:""}},filters:{numsFilter:function(e){return e||0}},computed:{},created:function(){},mounted:function(){var e=this;this.timeFn(),this.cancelLoading(),Object(a["b"])("config").then((function(t){e.screenTitle=t.data.config.data_screen_title||"商城可视化数据大屏"})).catch((function(t){e.pageflag=!1,e.$message({text:t,type:"warning"})}))},beforeDestroy:function(){clearInterval(this.timing)},methods:{fullScreen:function(){var e=this;if(this.loading=!0,this.isFullScreen())this.exitFullscreen();else{var t=document.getElementById("app");this.full(t)}setTimeout((function(){e.loading=!1}),1e3)},full:function(e){e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.msRequestFullscreen&&e.msRequestFullscreen()},exitFullscreen:function(){document.exitFullScreen?document.exitFullScreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitExitFullscreen?document.webkitExitFullscreen():element.msExitFullscreen&&element.msExitFullscreen()},isFullScreen:function(){return!!(document.mozFullScreen||document.webkitIsFullScreen||document.webkitFullScreen||document.msFullScreen)},showSetting:function(){this.$refs.setting.init()},timeFn:function(){var e=this;this.timing=setInterval((function(){e.dateDay=Object(r["d"])(new Date,"HH: mm: ss"),e.dateYear=Object(r["d"])(new Date,"yyyy-MM-dd"),e.dateWeek=e.weekday[(new Date).getDay()]}),1e3)},cancelLoading:function(){var e=this,t=setTimeout((function(){e.loading=!1,clearTimeout(t)}),500)}}},F=C,j=(i("a241"),Object(d["a"])(F,n,s,!1,null,null,null));t["default"]=j.exports},"67e8":function(e,t,i){"use strict";i("f484")},a241:function(e,t,i){"use strict";i("47bc")},f484:function(e,t,i){}}]); |