mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-02-01 01:09:47 +00:00
FHEMWEB: enable devStateIcon for FHT
git-svn-id: https://svn.fhem.de/fhem/trunk@4778 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
1ce528554d
commit
6bb6a0ebdf
@ -2095,15 +2095,17 @@ FW_devState($$@)
|
|||||||
$hasOnOff = ($allSets =~ m/(^| )on(:[^ ]*)?( |$)/ &&
|
$hasOnOff = ($allSets =~ m/(^| )on(:[^ ]*)?( |$)/ &&
|
||||||
$allSets =~ m/(^| )off(:[^ ]*)?( |$)/);
|
$allSets =~ m/(^| )off(:[^ ]*)?( |$)/);
|
||||||
my $txt = $state;
|
my $txt = $state;
|
||||||
|
my $dsi = AttrVal($d, "devStateIcon", undef);
|
||||||
|
|
||||||
if(defined(AttrVal($d, "showtime", undef))) {
|
if(defined(AttrVal($d, "showtime", undef))) {
|
||||||
my $v = $defs{$d}{READINGS}{state}{TIME};
|
my $v = $defs{$d}{READINGS}{state}{TIME};
|
||||||
$txt = $v if(defined($v));
|
$txt = $v if(defined($v));
|
||||||
|
|
||||||
} elsif($allSets =~ m/\bdesired-temp:/) {
|
} elsif(!$dsi && $allSets =~ m/\bdesired-temp:/) {
|
||||||
$txt = "$1 °C" if($txt =~ m/^measured-temp: (.*)/); # FHT fix
|
$txt = "$1 °C" if($txt =~ m/^measured-temp: (.*)/); # FHT fix
|
||||||
$cmdList = "desired-temp" if(!$cmdList);
|
$cmdList = "desired-temp" if(!$cmdList);
|
||||||
|
|
||||||
} elsif($allSets =~ m/\bdesiredTemperature:/) {
|
} elsif(!$dsi && $allSets =~ m/\bdesiredTemperature:/) {
|
||||||
$txt = ReadingsVal($d, "temperature", ""); # ignores stateFormat!!!
|
$txt = ReadingsVal($d, "temperature", ""); # ignores stateFormat!!!
|
||||||
$txt =~ s/ .*//;
|
$txt =~ s/ .*//;
|
||||||
$txt .= "°C";
|
$txt .= "°C";
|
||||||
|
Loading…
Reference in New Issue
Block a user