diff --git a/src/common/ClientConnection.ts b/src/common/ClientConnection.ts index ff9dcab..a4c5ab8 100644 --- a/src/common/ClientConnection.ts +++ b/src/common/ClientConnection.ts @@ -426,7 +426,6 @@ export default class ClientConnection { public async addMode(group_uuid?: string, name?: string, index?: number) { try { - console.log(index); return await this.doRpc( new Protocol.AddModeRequestEntity(0, name, group_uuid, index) ); @@ -626,6 +625,15 @@ export default class ClientConnection { console.error(e); } } + public async setWindowVolume(window_id: number, volume: number) { + try { + return await this.doRpc( + new Protocol.SetWindowVolumeRequestEntity(window_id, volume, 0) + ); + } catch (e) { + console.error(e); + } + } public restartDevice(delay_ms?: number) { this.ws?.send( diff --git a/src/components/EditVolumeDialog.vue b/src/components/EditVolumeDialog.vue new file mode 100644 index 0000000..0622902 --- /dev/null +++ b/src/components/EditVolumeDialog.vue @@ -0,0 +1,72 @@ + + + + + diff --git a/src/components/ModeDialog.vue b/src/components/ModeDialog.vue index ecc1c0b..104709d 100644 --- a/src/components/ModeDialog.vue +++ b/src/components/ModeDialog.vue @@ -257,7 +257,6 @@ export default defineComponent({ tree_nodes, showDialog(options: any) { if (options) { - console.log(options); type.value = options.type ?? 1; if (type.value == 2) { name.value = options.data?.name ?? null; diff --git a/src/components/PlanDialog.vue b/src/components/PlanDialog.vue index fdc0c75..9f2e749 100644 --- a/src/components/PlanDialog.vue +++ b/src/components/PlanDialog.vue @@ -520,7 +520,6 @@ export default defineComponent({ timing_cycle.value = $t.t("disable"); week_days.value = EWeekDays.EWeekAll; if (type.value == 2) { - console.log(options); name.value = options.data?.name ?? $t.t("new plan 1"); selected.value = options.data?.item_data?.group_uuid ?? null; uuid.value = options.data?.item_data?.uuid ?? null; diff --git a/src/components/Window.vue b/src/components/Window.vue index f3ba5f8..1ae883e 100644 --- a/src/components/Window.vue +++ b/src/components/Window.vue @@ -13,11 +13,28 @@ @mouseup="onMouseLeave" > - + {{ $t("edit volume") }} + + + {{ $t("mute") }} + + {{ $t("close this window") }} @@ -25,6 +42,7 @@ @@ -34,6 +52,7 @@ {{ $t("close all windwos") }} @@ -46,7 +65,7 @@
+