This commit is contained in:
Wolfgang Hottgenroth
2018-01-31 20:55:58 +01:00
parent 72516fac28
commit 48fe3be0e9
4 changed files with 8 additions and 2 deletions

View File

@ -27,7 +27,7 @@ class TouchSwitchButtonSingleItem {
}
exports.TouchSwitchButtonSingleItem = TouchSwitchButtonSingleItem;
class TouchSwitchMultiButtonThing extends AItem_1.AItem {
constructor(floor, room, item, hmId, itemObjs) {
constructor(floor, room, item, itemObjs) {
super(floor, room, item, '');
this.itemObjs = itemObjs;
this.deviceTopicPre = `IoT/Touchswitch/${this.floor}/${this.room}/${this.item}`;

2
dist/main.js vendored
View File

@ -18,6 +18,7 @@ const MaxWindowContact_1 = require("./MaxWindowContact");
const UrlSwitchItem_1 = require("./UrlSwitchItem");
const Cron_1 = require("./Cron");
const HueColorBulbItem_1 = require("./HueColorBulbItem");
const TouchSwitchMultiButtonThing_1 = require("./TouchSwitchMultiButtonThing");
logger.info("Dispatcher starting");
let allLabeledItems = new Array();
// Anna -----------------------------------------------------------------------------------------------------
@ -117,6 +118,7 @@ allLabeledItems.push(bedRoomWolfgangsSide);
let bedRoomWolfgangBedLight = new HueColorBulbItem_1.HueColorBulbItem('1st', 'BedRoom', 'WolfgangBedLight', 'Bettlicht', 16);
bedRoomWolfgangBedLight.start();
allLabeledItems.push(bedRoomWolfgangBedLight);
let touchSwitchMultiButtonThing = new TouchSwitchMultiButtonThing_1.TouchSwitchMultiButtonThing('1st', 'Bedroom', 'Wolfgang', [new TouchSwitchMultiButtonThing_1.TouchSwitchButtonSingleItem(bedRoomWolfgangBedLight.getStateTopic())]);
// Schlafzimmer Pattys Seite 13980756 24 1 13980753 24 1
let bedRoomPattysSide = new M433SwitchItem_1.M433SwitchItem('1st', 'BedRoom', 'PattysSide', 'Pattys Seite Schlafzimmer', '13980756 24 1', '13980753 24 1');
bedRoomPattysSide.start();

View File

@ -33,7 +33,7 @@ export class TouchSwitchMultiButtonThing extends AItem {
private itemObjs: TouchSwitchButtonSingleItem[]
private readonly deviceTopicPre: string
constructor(floor: string, room: string, item: string, hmId: number, itemObjs: TouchSwitchButtonSingleItem[]) {
constructor(floor: string, room: string, item: string, itemObjs: TouchSwitchButtonSingleItem[]) {
super(floor, room, item, '')
this.itemObjs = itemObjs
this.deviceTopicPre = `IoT/Touchswitch/${this.floor}/${this.room}/${this.item}`

View File

@ -20,6 +20,7 @@ import { MaxWindowContact } from './MaxWindowContact'
import { UrlSwitchItem } from './UrlSwitchItem'
import { Cron } from './Cron'
import { HueColorBulbItem } from './HueColorBulbItem'
import { TouchSwitchMultiButtonThing, TouchSwitchButtonSingleItem } from './TouchSwitchMultiButtonThing'
logger.info("Dispatcher starting")
@ -149,6 +150,9 @@ let bedRoomWolfgangBedLight = new HueColorBulbItem('1st', 'BedRoom', 'WolfgangBe
bedRoomWolfgangBedLight.start()
allLabeledItems.push(bedRoomWolfgangBedLight)
let touchSwitchMultiButtonThing = new TouchSwitchMultiButtonThing('1st', 'Bedroom', 'Wolfgang',
[ new TouchSwitchButtonSingleItem(bedRoomWolfgangBedLight.getStateTopic())])
// Schlafzimmer Pattys Seite 13980756 24 1 13980753 24 1
let bedRoomPattysSide = new M433SwitchItem('1st', 'BedRoom', 'PattysSide', 'Pattys Seite Schlafzimmer', '13980756 24 1', '13980753 24 1')
bedRoomPattysSide.start()