mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-04-20 07:16:03 +00:00
fhemweb_readingsGroup.js: fix informIds from devName-readingName to rgName-devName.readingName
git-svn-id: https://svn.fhem.de/fhem/trunk@7533 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
5492ce390e
commit
4471918b86
@ -1,4 +1,23 @@
|
|||||||
|
|
||||||
|
//$(document).ready(FW_readingsGroupReadyFn);
|
||||||
|
$(FW_readingsGroupReadyFn);
|
||||||
|
|
||||||
|
function
|
||||||
|
FW_readingsGroupReadyFn() {
|
||||||
|
// replace all informIds of the form devName-readingName with rgName-devName.readingName
|
||||||
|
$(".readingsGroup").each(function() {
|
||||||
|
var name = $(this).attr('id').split("-")[1];
|
||||||
|
$(this).find("[informId]").each(function() {
|
||||||
|
var informId = $(this).attr('informId');
|
||||||
|
var parts = informId.split("-");
|
||||||
|
if( parts[0] != name ) {
|
||||||
|
informId = name+'-'+informId.replace('-','.');
|
||||||
|
$(this).attr('informId', informId);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
function
|
function
|
||||||
FW_readingsGroupToggle(d) {
|
FW_readingsGroupToggle(d) {
|
||||||
var rg = document.getElementById( 'readingsGroup-'+d );
|
var rg = document.getElementById( 'readingsGroup-'+d );
|
||||||
|
Loading…
x
Reference in New Issue
Block a user