修复添加、修改预案时点删除会一次性删除两个模式的BUG

This commit is contained in:
fangxiang 2022-07-25 14:52:22 +08:00
parent 4a50f89a69
commit 36c1b0b4a3
8 changed files with 31 additions and 30 deletions

View File

@ -1,6 +1,6 @@
{
"name": "media_player_client",
"version": "1.4.20",
"version": "1.4.21",
"description": "A Quasar Framework app",
"productName": "MediaPlayerClient",
"author": "fangxiang <fangxiang@cloudview.work>",
@ -10,7 +10,7 @@
},
"dependencies": {
"@quasar/cli": "^1.3.2",
"@quasar/extras": "^1.14.0",
"@quasar/extras": "^1.15.0",
"@tinymce/tinymce-vue": "4",
"@types/element-resize-detector": "^1.1.3",
"autoprefixer": "^10.4.2",
@ -18,7 +18,7 @@
"core-js": "^3.21.0",
"element-resize-detector": "^1.2.4",
"qrcode.vue": "^3.3.3",
"quasar": "^2.7.3",
"quasar": "^2.7.5",
"reconnecting-websocket": "^4.4.0",
"sortablejs": "^1.15.0",
"to": "^0.2.9",

View File

@ -148,7 +148,7 @@ export default defineComponent({
const build_info = await GlobalData.getInstance()
.getCurrentClient()
?.getBuildInfo();
console.log(build_info);
// console.log(build_info);
if (build_info) {
server_version.value = build_info.version;
server_commit_hash.value = build_info.commit_hash;

View File

@ -517,11 +517,8 @@ export default defineComponent({
date_format_options.value = [];
time_format_options.value = [];
if (
($store.state.device_attribute & Protocol.EDeviceAttribute.CustomISV) ==
0
) {
console.log();
if ($t.locale.value == "zh-CN") {
date_format_options.value = [...date_formats_en_, ...date_formats_zh_];
time_format_options.value = [...time_formats_en_, ...time_formats_zh_];
} else {

View File

@ -754,10 +754,7 @@ export default defineComponent({
},
deleteRow() {
if (datas.value.length > current_index) {
const start = Math.floor(current_index / 2);
if (!isNaN(start)) {
datas.value.splice(start, 2);
}
datas.value.splice(current_index, 1);
}
},
async onSubmit() {

View File

@ -329,6 +329,7 @@ import {
onUnmounted,
computed,
nextTick,
Ref,
} from "vue";
import { useStore } from "src/store";
import GlobalData from "src/common/GlobalData";
@ -384,7 +385,9 @@ export default defineComponent({
"EwindowType::Timer",
]);
let signal_source_options = [
const signal_source_options: Ref<any> = ref([]);
const build_signal_source_options = [
{
label: $t.t("multimedia file"),
value: "EwindowType::Multimedia",
@ -413,20 +416,24 @@ export default defineComponent({
];
const refresh_signal_source_options = () => {
signal_source_options.value = [];
for (const item of build_signal_source_options) {
signal_source_options.value.push(item);
}
if (
($store.state.device_attribute & Protocol.EDeviceAttribute.CustomISV) ==
0
) {
signal_source_options.push({
signal_source_options.value.push({
label: $t.t("weather"),
value: "EwindowType::Weather",
});
} else {
const index = signal_source_options.findIndex(
(element) => element && element.value == "EwindowType::Weather"
const index = signal_source_options.value.findIndex(
(element: any) => element && element.value == "EwindowType::Weather"
);
if (index != -1) {
signal_source_options.splice(index, 1);
signal_source_options.value.splice(index, 1);
}
}
};

View File

@ -218,8 +218,8 @@
:disable="plan_running"
:icon="
selected_window?.muted
? 'img:pad/play_control/unmute_icon.png'
: 'img:pad/play_control/mute_icon.png'
? 'img:pad/play_control/mute_icon.png'
: 'img:pad/play_control/unmute_icon.png'
"
flat
size="1.2rem"

View File

@ -79,7 +79,7 @@
size="lg"
v-if="selected_window?.muted"
:disable="plan_running"
icon="volume_mute"
icon="volume_off"
@click="unmuteWindow"
><q-tooltip> {{ $t("unmute") }}</q-tooltip></q-btn
>
@ -89,7 +89,7 @@
round
flag
size="lg"
icon="volume_off"
icon="volume_mute"
@click="muteWindow"
><q-tooltip> {{ $t("mute") }}</q-tooltip></q-btn
>

View File

@ -1238,10 +1238,10 @@
update-notifier "^5.1.0"
validate-npm-package-name "^3.0.0"
"@quasar/extras@^1.14.0":
version "1.14.0"
resolved "https://registry.npmmirror.com/@quasar/extras/-/extras-1.14.0.tgz#cbdb2c8ea8f9ef551adea28592bf9f9f6c1c5165"
integrity sha512-4qVLqiKHV8tpvj/VgyxI5FlWCwQvWQzq15xlLeCDpzLOGeJruUXs+QCAB5gFgdDHPbU2ax2YgAxyGoQSCS7ACw==
"@quasar/extras@^1.15.0":
version "1.15.0"
resolved "https://registry.npmmirror.com/@quasar/extras/-/extras-1.15.0.tgz#ed397abdc8372b2b1de525dd93c7ec6bc061db8f"
integrity sha512-e5IHHqo3i/u7yWdcdspBbthnrDDZ3VRXaQoyhEEy526lzITFAw3hnlt4h7YnZ6Ck6gVIM0YbCaZbKaQYfKPOzQ==
"@quasar/fastclick@1.1.4":
version "1.1.4"
@ -8883,10 +8883,10 @@ qs@6.9.6:
resolved "https://registry.npmmirror.com/qs/-/qs-6.9.6.tgz#26ed3c8243a431b2924aca84cc90471f35d5a0ee"
integrity sha512-TIRk4aqYLNoJUbd+g2lEdz5kLWIuTMRagAXxl78Q0RiVjAOugHmeKNGdd3cwo/ktpf9aL9epCfFqWDEKysUlLQ==
quasar@^2.7.3:
version "2.7.3"
resolved "https://registry.npmmirror.com/quasar/-/quasar-2.7.3.tgz#ff57ac5f3c9a8fdc345f59362d7b0f45c80bc68d"
integrity sha512-4YQQP1FbfshXwav9QcOHpvSg4eME4iKzd85m4562EqcfuhRtycC/2WQg+cRxlEr43gEHM0uXaJmybNUWZpoYkw==
quasar@^2.7.5:
version "2.7.5"
resolved "https://registry.npmmirror.com/quasar/-/quasar-2.7.5.tgz#a3feb5d50647313c4d6e1451223c158e10792902"
integrity sha512-DWI0S+bXASfMSPrB8c/LVsXpA4dF7cBUbaJlcrM+1ioTNBHtiudma2Nhk2SDd5bzk9AYVHh5A8JCZuKqQAXt7g==
query-string@^5.0.1:
version "5.1.1"