68 lines
2.4 KiB
JavaScript
68 lines
2.4 KiB
JavaScript
|
import Vue from 'vue'
|
||
|
import Api from '../api/index'
|
||
|
import dayjs from 'dayjs'
|
||
|
import './style/index.less'
|
||
|
import dayfilter from '@/utils/dayfilter'
|
||
|
import {tryToJson} from '../utils/tools'
|
||
|
import { Loading } from 'element-ui';
|
||
|
|
||
|
import moduleOne11 from '../components/module/module-one-1-1.vue'
|
||
|
import moduleOne12 from '../components/module/module-one-1-2.vue'
|
||
|
import moduleOne13 from '../components/module/module-one-1-3.vue'
|
||
|
import moduleOne21 from '../components/module/module-one-2-1.vue'
|
||
|
import moduleOne22 from '../components/module/module-one-2-2.vue'
|
||
|
import moduleOne23 from '../components/module/module-one-2-3.vue'
|
||
|
//import projectOverviewChart from '../components/project-overview-chart.vue'
|
||
|
//import peopleNumber from '../components/people-number.vue'
|
||
|
import header from '../components/header.vue'
|
||
|
Loading.install(Vue);
|
||
|
//H265Player.install(Vue);
|
||
|
dayfilter(Vue);
|
||
|
const vue=new Vue();
|
||
|
Vue.component("screen-header",header)
|
||
|
Vue.component("module-one-1-1",moduleOne11)
|
||
|
Vue.component("module-one-1-2",moduleOne12)
|
||
|
Vue.component("module-one-1-3",moduleOne13)
|
||
|
Vue.component("module-one-2-1",moduleOne21)
|
||
|
Vue.component("module-one-2-2",moduleOne22)
|
||
|
Vue.component("module-one-2-3",moduleOne23)
|
||
|
Vue.prototype.$bus=new Vue();
|
||
|
//Vue.component("people-number",peopleNumber)
|
||
|
//Vue.component("project-overview-chart",projectOverviewChart)
|
||
|
Vue.prototype.$api=Api;
|
||
|
Vue.prototype.$bus=vue;
|
||
|
Vue.prototype.$apiPath=process.env.VUE_APP_BASE_API
|
||
|
Vue.prototype.$dt=dayjs;
|
||
|
Vue.prototype.$tryToJson=tryToJson
|
||
|
Vue.prototype.$toggleFullScreen=(el)=>{
|
||
|
if(document.fullscreenElement==el){
|
||
|
let screen = document.cancelFullScreen || document.webkitCancelFullScreen || document.mozCancelFullScreen || document.exitFullScreen
|
||
|
if (typeof screen != "undefined" && screen) {
|
||
|
screen.call(document);
|
||
|
return;
|
||
|
}
|
||
|
|
||
|
}else{
|
||
|
let screen = el.requestFullScreen || el.webkitRequestFullScreen || el.mozRequestFullScreen || el.msRequestFullScreen
|
||
|
if (typeof screen != "undefined" && screen) {
|
||
|
screen.call(el);
|
||
|
return;
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
window.__isfull__=false;
|
||
|
window.fullscreenInterval=setInterval(()=>{
|
||
|
if(document.fullscreenElement){
|
||
|
if(!window.__isfull__){
|
||
|
vue.$emit("fullscreen",true);
|
||
|
window.__isfull__=true;
|
||
|
}
|
||
|
}else{
|
||
|
if(window.__isfull__){
|
||
|
vue.$emit("fullscreen",false);
|
||
|
window.__isfull__=false;
|
||
|
}
|
||
|
}
|
||
|
},500);
|
||
|
window.jhcaches={};
|