@riddix/hamh 2.1.0-alpha.417 → 2.1.0-alpha.418
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/backend/cli.js
CHANGED
|
@@ -172830,10 +172830,14 @@ var vacuumRvcRunModeConfig = {
|
|
|
172830
172830
|
}
|
|
172831
172831
|
const rooms = parseVacuumRooms(attributes7);
|
|
172832
172832
|
const roomIds = [];
|
|
172833
|
+
let targetMapName;
|
|
172833
172834
|
for (const areaId of selectedAreas) {
|
|
172834
172835
|
const room = rooms.find((r) => toAreaId(r.id) === areaId);
|
|
172835
172836
|
if (room) {
|
|
172836
172837
|
roomIds.push(room.originalId ?? room.id);
|
|
172838
|
+
if (room.mapName && !targetMapName) {
|
|
172839
|
+
targetMapName = room.mapName;
|
|
172840
|
+
}
|
|
172837
172841
|
}
|
|
172838
172842
|
}
|
|
172839
172843
|
if (roomIds.length > 0) {
|
|
@@ -172861,6 +172865,18 @@ var vacuumRvcRunModeConfig = {
|
|
|
172861
172865
|
};
|
|
172862
172866
|
}
|
|
172863
172867
|
if (isDreameVacuum(attributes7)) {
|
|
172868
|
+
if (targetMapName) {
|
|
172869
|
+
const vacName = vacuumEntityId.replace("vacuum.", "");
|
|
172870
|
+
const selectedMapEntity = `select.${vacName}_selected_map`;
|
|
172871
|
+
logger181.info(
|
|
172872
|
+
`Dreame multi-floor: switching to map "${targetMapName}" via ${selectedMapEntity}`
|
|
172873
|
+
);
|
|
172874
|
+
homeAssistant.callAction({
|
|
172875
|
+
action: "select.select_option",
|
|
172876
|
+
target: selectedMapEntity,
|
|
172877
|
+
data: { option: targetMapName }
|
|
172878
|
+
});
|
|
172879
|
+
}
|
|
172864
172880
|
return {
|
|
172865
172881
|
action: "dreame_vacuum.vacuum_clean_segment",
|
|
172866
172882
|
data: {
|
|
@@ -172963,6 +172979,18 @@ var vacuumRvcRunModeConfig = {
|
|
|
172963
172979
|
};
|
|
172964
172980
|
}
|
|
172965
172981
|
if (isDreameVacuum(attributes7)) {
|
|
172982
|
+
if (room.mapName) {
|
|
172983
|
+
const vacuumName = vacuumEntityId.replace("vacuum.", "");
|
|
172984
|
+
const selectedMapEntity = `select.${vacuumName}_selected_map`;
|
|
172985
|
+
logger181.info(
|
|
172986
|
+
`Dreame multi-floor: switching to map "${room.mapName}" via ${selectedMapEntity}`
|
|
172987
|
+
);
|
|
172988
|
+
homeAssistant.callAction({
|
|
172989
|
+
action: "select.select_option",
|
|
172990
|
+
target: selectedMapEntity,
|
|
172991
|
+
data: { option: room.mapName }
|
|
172992
|
+
});
|
|
172993
|
+
}
|
|
172966
172994
|
logger181.debug(
|
|
172967
172995
|
`Dreame vacuum detected, using dreame_vacuum.vacuum_clean_segment for room ${room.name} (commandId: ${commandId3}, id: ${room.id})`
|
|
172968
172996
|
);
|