Merge branch 'wujie'
This commit is contained in:
commit
089ce906d4
|
@ -9,8 +9,8 @@
|
||||||
"test": "echo \"No test specified\" && exit 0"
|
"test": "echo \"No test specified\" && exit 0"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@quasar/cli": "^1.3.2",
|
"@quasar/cli": "^1.4.0",
|
||||||
"@quasar/extras": "^1.15.6",
|
"@quasar/extras": "^1.15.9",
|
||||||
"@tinymce/tinymce-vue": "4",
|
"@tinymce/tinymce-vue": "4",
|
||||||
"@types/element-resize-detector": "^1.1.3",
|
"@types/element-resize-detector": "^1.1.3",
|
||||||
"autoprefixer": "^10.4.2",
|
"autoprefixer": "^10.4.2",
|
||||||
|
@ -18,7 +18,7 @@
|
||||||
"core-js": "^3.21.0",
|
"core-js": "^3.21.0",
|
||||||
"element-resize-detector": "^1.2.4",
|
"element-resize-detector": "^1.2.4",
|
||||||
"qrcode.vue": "^3.3.3",
|
"qrcode.vue": "^3.3.3",
|
||||||
"quasar": "^2.10.2",
|
"quasar": "^2.11.3",
|
||||||
"reconnecting-websocket": "^4.4.0",
|
"reconnecting-websocket": "^4.4.0",
|
||||||
"sortablejs": "^1.15.0",
|
"sortablejs": "^1.15.0",
|
||||||
"to": "^0.2.9",
|
"to": "^0.2.9",
|
||||||
|
|
|
@ -23,6 +23,11 @@ export default defineComponent({
|
||||||
const $store = useStore();
|
const $store = useStore();
|
||||||
const $q = useQuasar();
|
const $q = useQuasar();
|
||||||
|
|
||||||
|
if ((window as any).$wujie) {
|
||||||
|
const $wujie = (window as any).$wujie;
|
||||||
|
$store.commit("setWuJie", $wujie);
|
||||||
|
}
|
||||||
|
|
||||||
document.title = $t.t("title");
|
document.title = $t.t("title");
|
||||||
|
|
||||||
if (!navigator.cookieEnabled) {
|
if (!navigator.cookieEnabled) {
|
||||||
|
|
|
@ -45,6 +45,7 @@
|
||||||
</q-item>
|
</q-item>
|
||||||
<q-item
|
<q-item
|
||||||
clickable
|
clickable
|
||||||
|
v-if="$store.state.isLedPlayer()"
|
||||||
v-close-popup
|
v-close-popup
|
||||||
:disable="$props.disable"
|
:disable="$props.disable"
|
||||||
@click="$emit('edit_rect', $props.window.window_id)"
|
@click="$emit('edit_rect', $props.window.window_id)"
|
||||||
|
|
|
@ -135,6 +135,7 @@
|
||||||
<q-btn
|
<q-btn
|
||||||
stretch
|
stretch
|
||||||
:disable="!$store.state.power_state"
|
:disable="!$store.state.power_state"
|
||||||
|
v-if="$store.state.isLedPlayer()"
|
||||||
flat
|
flat
|
||||||
stack
|
stack
|
||||||
no-caps
|
no-caps
|
||||||
|
|
|
@ -1,6 +1,10 @@
|
||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<q-toolbar style="background-color: #3e9acd" class="shadow-2 text-white" @dragstart.prevent>
|
<q-toolbar
|
||||||
|
style="background-color: #3e9acd"
|
||||||
|
class="shadow-2 text-white"
|
||||||
|
@dragstart.prevent
|
||||||
|
>
|
||||||
<q-btn-dropdown
|
<q-btn-dropdown
|
||||||
v-if="false"
|
v-if="false"
|
||||||
v-touch-hold:10000.mouse="handleHold"
|
v-touch-hold:10000.mouse="handleHold"
|
||||||
|
@ -29,7 +33,7 @@
|
||||||
</q-btn-dropdown>
|
</q-btn-dropdown>
|
||||||
|
|
||||||
<q-btn-dropdown
|
<q-btn-dropdown
|
||||||
v-if="show_device_list"
|
v-if="show_device_list && !$store.state.$wujie"
|
||||||
stretch
|
stretch
|
||||||
no-caps
|
no-caps
|
||||||
flat
|
flat
|
||||||
|
@ -72,7 +76,11 @@
|
||||||
</q-list>
|
</q-list>
|
||||||
</q-btn-dropdown>
|
</q-btn-dropdown>
|
||||||
|
|
||||||
<q-separator vertical inset />
|
<q-separator
|
||||||
|
vertical
|
||||||
|
inset
|
||||||
|
v-if="show_device_list && !$store.state.$wujie"
|
||||||
|
/>
|
||||||
|
|
||||||
<q-btn
|
<q-btn
|
||||||
stretch
|
stretch
|
||||||
|
@ -187,6 +195,7 @@
|
||||||
:disable="plan_running || !$store.state.power_state"
|
:disable="plan_running || !$store.state.power_state"
|
||||||
:icon="/*vertical_align_bottom*/ 'img:new_icon/edit_window_rect.png'"
|
:icon="/*vertical_align_bottom*/ 'img:new_icon/edit_window_rect.png'"
|
||||||
:label="$t('toolbar edit window rect')"
|
:label="$t('toolbar edit window rect')"
|
||||||
|
v-if="$store.state.isLedPlayer()"
|
||||||
class="q-mr-sm"
|
class="q-mr-sm"
|
||||||
@click="editRect"
|
@click="editRect"
|
||||||
/>
|
/>
|
||||||
|
@ -288,7 +297,11 @@
|
||||||
:label="$t('other setting')"
|
:label="$t('other setting')"
|
||||||
class="q-mr-sm"
|
class="q-mr-sm"
|
||||||
>
|
>
|
||||||
<q-list style="background-color: #3e9acd" class="shadow-2 text-white" @dragstart.prevent>
|
<q-list
|
||||||
|
style="background-color: #3e9acd"
|
||||||
|
class="shadow-2 text-white"
|
||||||
|
@dragstart.prevent
|
||||||
|
>
|
||||||
<q-item
|
<q-item
|
||||||
clickable
|
clickable
|
||||||
:disable="!$store.state.power_state"
|
:disable="!$store.state.power_state"
|
||||||
|
@ -445,7 +458,11 @@
|
||||||
<q-item-section avatar style="margin-right: 0px; padding-right: 0px">
|
<q-item-section avatar style="margin-right: 0px; padding-right: 0px">
|
||||||
<!-- <q-icon class="text-white rotate" name="img:svgs/fan.svg" /> -->
|
<!-- <q-icon class="text-white rotate" name="img:svgs/fan.svg" /> -->
|
||||||
<!-- <q-icon class="text-white rotate" name="img:new_icon/fan.png" /> -->
|
<!-- <q-icon class="text-white rotate" name="img:new_icon/fan.png" /> -->
|
||||||
<q-icon class="text-white" :style="{'animation':fan}" name="img:new_icon/fan.png" />
|
<q-icon
|
||||||
|
class="text-white"
|
||||||
|
:style="{ animation: fan }"
|
||||||
|
name="img:new_icon/fan.png"
|
||||||
|
/>
|
||||||
</q-item-section>
|
</q-item-section>
|
||||||
<q-item-section style="margin-left: -25px">
|
<q-item-section style="margin-left: -25px">
|
||||||
{{ $store.state.fan_temp.toFixed(1) }} ℃
|
{{ $store.state.fan_temp.toFixed(1) }} ℃
|
||||||
|
@ -575,13 +592,11 @@ export default defineComponent({
|
||||||
const plan_running = computed(
|
const plan_running = computed(
|
||||||
() => $store.state.current_running_plan.trim() != ""
|
() => $store.state.current_running_plan.trim() != ""
|
||||||
);
|
);
|
||||||
const fan = computed(
|
const fan = computed(() => {
|
||||||
() => {
|
let wendu: any = $store.state.fan_temp.toFixed(1);
|
||||||
let wendu:any=($store.state.fan_temp).toFixed(1)
|
let sulv: any = 1 - wendu / 150;
|
||||||
let sulv:any=(1-(wendu/150))
|
return "rotate " + sulv + "s linear infinite";
|
||||||
return 'rotate '+sulv+'s linear infinite'
|
});
|
||||||
}
|
|
||||||
);
|
|
||||||
const checkRegistered = () => {
|
const checkRegistered = () => {
|
||||||
if (
|
if (
|
||||||
GlobalData.getInstance().getCurrentClient()?.is_connected &&
|
GlobalData.getInstance().getCurrentClient()?.is_connected &&
|
||||||
|
|
|
@ -138,6 +138,7 @@
|
||||||
:disable="plan_running || !$store.state.power_state"
|
:disable="plan_running || !$store.state.power_state"
|
||||||
:icon="/*vertical_align_bottom*/ 'img:new_icon/edit_window_rect.png'"
|
:icon="/*vertical_align_bottom*/ 'img:new_icon/edit_window_rect.png'"
|
||||||
:label="$t('toolbar edit window rect')"
|
:label="$t('toolbar edit window rect')"
|
||||||
|
v-if="$store.state.isLedPlayer()"
|
||||||
class="q-mr-sm"
|
class="q-mr-sm"
|
||||||
@click="editRect"
|
@click="editRect"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -47,10 +47,10 @@ export default route<StateInterface>(function (/* { store, ssrContext } */) {
|
||||||
if (auth_obj) {
|
if (auth_obj) {
|
||||||
const auth = parseInt(auth_obj);
|
const auth = parseInt(auth_obj);
|
||||||
const target_auth = parseInt(<string>to.meta.permission_level);
|
const target_auth = parseInt(<string>to.meta.permission_level);
|
||||||
if (target_auth == NaN) {
|
if (isNaN(target_auth)) {
|
||||||
next();
|
next();
|
||||||
return;
|
return;
|
||||||
} else if (auth != NaN) {
|
} else {
|
||||||
if (auth > target_auth) {
|
if (auth > target_auth) {
|
||||||
next();
|
next();
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -2,26 +2,37 @@ import { RouteRecordRaw } from "vue-router";
|
||||||
|
|
||||||
import PermissionLevel from "src/entities/PermissionLevel";
|
import PermissionLevel from "src/entities/PermissionLevel";
|
||||||
|
|
||||||
|
import RedirectPage from "src/RedirectPage.vue";
|
||||||
|
import Login from "pages/Login.vue";
|
||||||
|
import MainLayout from "layouts/MainLayout.vue";
|
||||||
|
import Index from "pages/Index.vue";
|
||||||
|
|
||||||
|
import PadLogin from "src/pad/Login.vue";
|
||||||
|
import PadMainLayout from "src/pad/MainLayout.vue";
|
||||||
|
import PadIndex from "src/pad/Index.vue";
|
||||||
|
|
||||||
|
import Error404 from "pages/Error404.vue";
|
||||||
|
|
||||||
const routes: RouteRecordRaw[] = [
|
const routes: RouteRecordRaw[] = [
|
||||||
{
|
{
|
||||||
path: "/",
|
path: "/",
|
||||||
meta: {},
|
meta: {},
|
||||||
component: () => import("src/RedirectPage.vue"),
|
component: RedirectPage,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/pc/login",
|
path: "/pc/login",
|
||||||
component: () => import("pages/Login.vue"),
|
component: Login,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/pc",
|
path: "/pc",
|
||||||
meta: {
|
meta: {
|
||||||
permission_level: PermissionLevel.User,
|
permission_level: PermissionLevel.User,
|
||||||
},
|
},
|
||||||
component: () => import("layouts/MainLayout.vue"),
|
component: MainLayout,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: "",
|
path: "",
|
||||||
component: () => import("pages/Index.vue"),
|
component: Index,
|
||||||
meta: {
|
meta: {
|
||||||
permission_level: PermissionLevel.User,
|
permission_level: PermissionLevel.User,
|
||||||
},
|
},
|
||||||
|
@ -30,18 +41,18 @@ const routes: RouteRecordRaw[] = [
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/pad/login",
|
path: "/pad/login",
|
||||||
component: () => import("src/pad/Login.vue"),
|
component: PadLogin,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
path: "/pad",
|
path: "/pad",
|
||||||
meta: {
|
meta: {
|
||||||
permission_level: PermissionLevel.User,
|
permission_level: PermissionLevel.User,
|
||||||
},
|
},
|
||||||
component: () => import("src/pad/MainLayout.vue"),
|
component: PadMainLayout,
|
||||||
children: [
|
children: [
|
||||||
{
|
{
|
||||||
path: "",
|
path: "",
|
||||||
component: () => import("src/pad/Index.vue"),
|
component: PadIndex,
|
||||||
meta: {
|
meta: {
|
||||||
permission_level: PermissionLevel.User,
|
permission_level: PermissionLevel.User,
|
||||||
},
|
},
|
||||||
|
@ -53,7 +64,7 @@ const routes: RouteRecordRaw[] = [
|
||||||
// but you can also remove it
|
// but you can also remove it
|
||||||
{
|
{
|
||||||
path: "/:catchAll(.*)*",
|
path: "/:catchAll(.*)*",
|
||||||
component: () => import("pages/Error404.vue"),
|
component: Error404,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
|
@ -39,6 +39,11 @@ export class CustomDefines {
|
||||||
function_mirroring_output = false;
|
function_mirroring_output = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export interface WuJieInterface {
|
||||||
|
props: any;
|
||||||
|
bus: EventEmitter;
|
||||||
|
}
|
||||||
|
|
||||||
export interface StateInterface {
|
export interface StateInterface {
|
||||||
// Define your own store structure, using submodules if needed
|
// Define your own store structure, using submodules if needed
|
||||||
// example: ExampleStateInterface;
|
// example: ExampleStateInterface;
|
||||||
|
@ -80,9 +85,11 @@ export interface StateInterface {
|
||||||
fusion_configuration: object;
|
fusion_configuration: object;
|
||||||
isLedPlayer: () => boolean;
|
isLedPlayer: () => boolean;
|
||||||
isSpecialVideo: () => boolean;
|
isSpecialVideo: () => boolean;
|
||||||
|
|
||||||
|
$wujie: WuJieInterface | null;
|
||||||
//
|
//
|
||||||
selected_projector: string;
|
selected_projector: string;
|
||||||
EnableBlending:boolean
|
EnableBlending: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
// provide typings for `this.$store`
|
// provide typings for `this.$store`
|
||||||
|
@ -299,6 +306,7 @@ export const storeKey: InjectionKey<VuexStore<StateInterface>> =
|
||||||
|
|
||||||
import window_color_list from "./window_color_list.js";
|
import window_color_list from "./window_color_list.js";
|
||||||
import { EProductNames } from "src/entities/ProductNames";
|
import { EProductNames } from "src/entities/ProductNames";
|
||||||
|
import EventEmitter from "events";
|
||||||
export const NullSignalSource =
|
export const NullSignalSource =
|
||||||
"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF";
|
"FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF";
|
||||||
|
|
||||||
|
@ -355,6 +363,8 @@ export default store(function (/* { ssrContext } */) {
|
||||||
isSpecialVideo: () => {
|
isSpecialVideo: () => {
|
||||||
return Store.state.product_name == EProductNames.SPECIAL_VIDEO;
|
return Store.state.product_name == EProductNames.SPECIAL_VIDEO;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
$wujie: null,
|
||||||
},
|
},
|
||||||
|
|
||||||
mutations: {
|
mutations: {
|
||||||
|
@ -562,31 +572,31 @@ export default store(function (/* { ssrContext } */) {
|
||||||
},
|
},
|
||||||
setWallCol(state: StateInterface, playload?: any) {
|
setWallCol(state: StateInterface, playload?: any) {
|
||||||
const num = parseInt(playload);
|
const num = parseInt(playload);
|
||||||
if (num != NaN && num > 0) {
|
if (!isNaN(num) && num > 0) {
|
||||||
state.wall_col = num;
|
state.wall_col = num;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
setWallRow(state: StateInterface, playload?: any) {
|
setWallRow(state: StateInterface, playload?: any) {
|
||||||
const num = parseInt(playload);
|
const num = parseInt(playload);
|
||||||
if (num != NaN && num > 0) {
|
if (!isNaN(num) && num > 0) {
|
||||||
state.wall_row = num;
|
state.wall_row = num;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
setDeviceScreenWidth(state: StateInterface, playload?: any) {
|
setDeviceScreenWidth(state: StateInterface, playload?: any) {
|
||||||
const num = parseInt(playload);
|
const num = parseInt(playload);
|
||||||
if (num != NaN && num > 0) {
|
if (!isNaN(num) && num > 0) {
|
||||||
state.device_screen_width = num;
|
state.device_screen_width = num;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
setDeviceScreenHeight(state: StateInterface, playload?: any) {
|
setDeviceScreenHeight(state: StateInterface, playload?: any) {
|
||||||
const num = parseInt(playload);
|
const num = parseInt(playload);
|
||||||
if (num != NaN && num > 0) {
|
if (!isNaN(num) && num > 0) {
|
||||||
state.device_screen_height = num;
|
state.device_screen_height = num;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
setDeviceScreenRefreshRate(state: StateInterface, playload?: any) {
|
setDeviceScreenRefreshRate(state: StateInterface, playload?: any) {
|
||||||
const num = parseInt(playload);
|
const num = parseInt(playload);
|
||||||
if (num != NaN && num > 0) {
|
if (!isNaN(num) && num > 0) {
|
||||||
state.device_screen_refresh_rate = num;
|
state.device_screen_refresh_rate = num;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -999,12 +1009,15 @@ export default store(function (/* { ssrContext } */) {
|
||||||
state.connect_list.slice(index, 1);
|
state.connect_list.slice(index, 1);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
setWuJie(state: StateInterface, playload?: any) {
|
||||||
|
state.$wujie = playload;
|
||||||
|
},
|
||||||
},
|
},
|
||||||
getters: {
|
getters: {
|
||||||
GetTheCurrentlySelectedCamera(state) {
|
GetTheCurrentlySelectedCamera(state) {
|
||||||
let arr = state.selected_projector.split('/');
|
let arr = state.selected_projector.split("/");
|
||||||
return [Number(arr[0]), Number(arr[1])];
|
return [Number(arr[0]), Number(arr[1])];
|
||||||
}
|
},
|
||||||
},
|
},
|
||||||
// enable strict mode (adds overhead!)
|
// enable strict mode (adds overhead!)
|
||||||
// for dev mode and --debug builds only
|
// for dev mode and --debug builds only
|
||||||
|
|
Loading…
Reference in New Issue