diff --git a/src/App.vue b/src/App.vue index 7a9ca44..2ec7355 100644 --- a/src/App.vue +++ b/src/App.vue @@ -39,7 +39,6 @@ export default defineComponent({ } catch {} }; setInterval(refreshFanTemp, 1000 * 3); - refreshFanTemp(); return {}; }, diff --git a/src/components/PlanDialog.vue b/src/components/PlanDialog.vue index 9f2e749..e3413e2 100644 --- a/src/components/PlanDialog.vue +++ b/src/components/PlanDialog.vue @@ -138,7 +138,7 @@ @@ -347,6 +347,8 @@ const getEWeekDays = (str: string) => { } }; +const __MIN_DELAY = 10; + export default defineComponent({ name: "ComponentPlanDialog", @@ -355,6 +357,7 @@ export default defineComponent({ let $q = useQuasar(); let $t = useI18n(); + const min_delay = ref(__MIN_DELAY); let show_dialog = ref(false); let type = ref(1); let name = ref(null); @@ -413,8 +416,8 @@ export default defineComponent({ const requestAddPlan = async () => { let entity = new PlanEntity(); for (let i = 1; i < datas.value.length; i += 2) { - if (parseInt(datas.value[i].value) < 180) { - datas.value[i].value = "180"; + if (parseInt(datas.value[i].value) < __MIN_DELAY) { + datas.value[i].value = __MIN_DELAY.toString(); } } entity.group_uuid = selected.value; @@ -451,8 +454,8 @@ export default defineComponent({ const requestEditPlan = async () => { let entity = new PlanEntity(); for (let i = 1; i < datas.value.length; i += 2) { - if (parseInt(datas.value[i].value) < 180) { - datas.value[i].value = "180"; + if (parseInt(datas.value[i].value) < __MIN_DELAY) { + datas.value[i].value = __MIN_DELAY.toString(); } } entity.group_uuid = selected.value; @@ -489,6 +492,7 @@ export default defineComponent({ return { show_dialog, + min_delay, type, name, uuid, @@ -573,8 +577,8 @@ export default defineComponent({ } for (let i = 1; i < datas.value.length; i += 2) { - if (parseInt(datas.value[i].value) < 180) { - datas.value[i].value = "180"; + if (parseInt(datas.value[i].value) < __MIN_DELAY) { + datas.value[i].value = __MIN_DELAY.toString(); } } @@ -611,7 +615,7 @@ export default defineComponent({ datas.value.push({ key: "param_delay", - value: "180", + value: __MIN_DELAY.toString(), }); }, onContextMenu( diff --git a/src/components/SignalSourceDialog.vue b/src/components/SignalSourceDialog.vue index 333f42c..4b6651b 100644 --- a/src/components/SignalSourceDialog.vue +++ b/src/components/SignalSourceDialog.vue @@ -438,6 +438,38 @@ export default defineComponent({ if (item_data) { setMediaUrlLabel(item_data.window_type); } + try { + console.log(item_data.media_url); + const url = new URL(item_data.media_url); + console.log(url); + console.log(url.host); + console.log(url.pathname); + if (url.host == "media" && url.pathname.startsWith("/usb")) { + const usb_index = parseInt(url.pathname.substr("/usb".length, 1)); + if (!isNaN(usb_index)) { + const target_path = decodeURI(url.pathname); + item_data.media_url = + "/usb" + + (usb_index + 1).toString() + + target_path.substr("/usb0".length); + } else { + console.error("url:", item_data.media_url); + console.error("url:", url); + console.error( + "usb_index:", + url.pathname.substr("/usb".length, 1) + ); + console.error("usb_index:", usb_index); + } + } else if ( + url.host == "userdata" && + url.pathname.startsWith("/media_player_datas") + ) { + item_data.media_url = decodeURI(url.pathname).substr( + "/media_player_datas/".length + ); + } + } catch {} show_dialog.value = true; }, resetData() { diff --git a/src/components/SubtitleDialog.vue b/src/components/SubtitleDialog.vue index 555ceb0..e770deb 100644 --- a/src/components/SubtitleDialog.vue +++ b/src/components/SubtitleDialog.vue @@ -54,55 +54,9 @@ - - - - - - - - - - - - - - - - - - - - - - - - -