mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-16 16:56:04 +00:00
98_structure.pm: new attribute setStateIndirectly (Forum #70488)
git-svn-id: https://svn.fhem.de/fhem/trunk@16865 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
44b9bfcf31
commit
d2c76ed604
@ -49,6 +49,7 @@ structure_Initialize($)
|
||||
disable
|
||||
disabledForIntervals
|
||||
evaluateSetResult:1,0
|
||||
setStateIndirectly:1,0
|
||||
setStructType:0,1
|
||||
);
|
||||
use warnings 'qw';
|
||||
@ -420,10 +421,11 @@ structure_Set($@)
|
||||
my $filter;
|
||||
if($list[1] ne "?") {
|
||||
my $state = join(" ", @list[1..@list-1]);
|
||||
readingsSingleUpdate($hash, "state", $state, 1);
|
||||
readingsSingleUpdate($hash, "state", $state, 1)
|
||||
if(!AttrVal($me, "setStateIndirectly", undef));
|
||||
|
||||
if($state =~ /^\[(FILTER=.*)]/) {
|
||||
delete($hash->{INSET}); # Experimental, Forum #35382
|
||||
delete($hash->{INSET}); # Forum #35382
|
||||
$filter = $1;
|
||||
@list = split(" ", $list[0] ." ". substr($state, length($filter)+2));
|
||||
}
|
||||
@ -523,6 +525,7 @@ structure_Attr($@)
|
||||
group=>1,
|
||||
icon=>1,
|
||||
room=>1,
|
||||
setStateIndirectly=>1,
|
||||
stateFormat=>1,
|
||||
webCmd=>1,
|
||||
userattr=>1
|
||||
@ -731,6 +734,12 @@ structure_Attr($@)
|
||||
compute the new status.
|
||||
</li>
|
||||
|
||||
<li>setStateIndirectly<br>
|
||||
If true (1), set the state only when member devices report a state
|
||||
change, else the state is first set to the set command argument. Default
|
||||
is 0.
|
||||
</li>
|
||||
|
||||
<li>setStructType<br>
|
||||
If true (1), then the <struct-type> will be set as an attribute for
|
||||
each member device to the name of the structure. True is the default for
|
||||
@ -947,6 +956,11 @@ structure_Attr($@)
|
||||
neuen Status auswerten soll.
|
||||
</li>
|
||||
|
||||
<li>setStateIndirectly<br>
|
||||
Falls wahr (1), dann wird der Status der Struktur nur aus dem
|
||||
Statusmeldungen der Mitglied-Geräte bestimmt, sonst wird zuerst der
|
||||
Status auf dem set Argument gesetzt. Die Voreinstellung ist 0.
|
||||
</li>
|
||||
|
||||
<li>setStructType<br>
|
||||
Falls wahr (1), <struct-type> wird als Attribute für jedes
|
||||
|
Loading…
x
Reference in New Issue
Block a user