From cca6a70e77d304afaffbdf572299e0d34ca92e6e Mon Sep 17 00:00:00 2001 From: rudolfkoenig <> Date: Sun, 18 Mar 2018 21:53:09 +0000 Subject: [PATCH] fhem.pl: add device specific attributes (Forum #85868) git-svn-id: https://svn.fhem.de/fhem/trunk@16442 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/fhem.pl | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/fhem/fhem.pl b/fhem/fhem.pl index e461815a7..c063894c9 100755 --- a/fhem/fhem.pl +++ b/fhem/fhem.pl @@ -2548,12 +2548,13 @@ getAllAttr($;$) return "" if(!$defs{$d}); my $list = $AttrList; # Global values - $list .= " " . $modules{$defs{$d}{TYPE}}{AttrList} - if($modules{$defs{$d}{TYPE}}{AttrList}); - $list .= " " . $attr{global}{userattr} - if($attr{global}{userattr}); - $list .= " " . $attr{$d}{userattr} - if($attr{$d} && $attr{$d}{userattr}); + if($defs{$d}{".AttrList"}) { + $list .= " " . $defs{$d}{".AttrList"}; + } elsif($modules{$defs{$d}{TYPE}}{AttrList}) { + $list .= " " . $modules{$defs{$d}{TYPE}}{AttrList}; + } + $list .= " " . $attr{global}{userattr} if($attr{global}{userattr}); + $list .= " " . $attr{$d}{userattr} if($attr{$d} && $attr{$d}{userattr}); $list .= " userattr"; return $list; }