From 2bc8bc7cfd0c89bc58fe1440523aa31637ab476e Mon Sep 17 00:00:00 2001 From: Ellert <> Date: Mon, 30 Oct 2017 12:47:07 +0000 Subject: [PATCH] doif.js: support for DOIF uiTable git-svn-id: https://svn.fhem.de/fhem/trunk@15353 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- fhem/MAINTAINER.txt | 1 + fhem/www/pgm2/doif.js | 14 ++++++++++++++ 2 files changed, 15 insertions(+) create mode 100644 fhem/www/pgm2/doif.js diff --git a/fhem/MAINTAINER.txt b/fhem/MAINTAINER.txt index f833f3f4b..95781722a 100644 --- a/fhem/MAINTAINER.txt +++ b/fhem/MAINTAINER.txt @@ -531,6 +531,7 @@ www/jscolor/* justme1968 Frontends www/pgm2/* rudolfkoenig Frontends/FHEMWEB www/pgm2/dashboard/* svenson08 Frontends www/pgm2/fhemweb_fbcalllist.js markusbloch Frontends +www/pgm2/doif.js Ellert Frontends www/pgm2/fhemweb_iconButtons.js Ellert Frontends www/pgm2/fhemweb_iconLabel.js Ellert Frontends www/pgm2/fhemweb_iconRadio.js Ellert Frontends diff --git a/fhem/www/pgm2/doif.js b/fhem/www/pgm2/doif.js new file mode 100644 index 000000000..d5a89b7bf --- /dev/null +++ b/fhem/www/pgm2/doif.js @@ -0,0 +1,14 @@ + +FW_version["doif.js"] = "$Id$"; + +function doifUpdateCell(doifname,attrname,attrcont,content,style) { + $("table[uitabid='DOIF-"+doifname+"']").find("div["+attrname+"='"+attrcont+"']").each(function() { + if(this.setValueFn) { // change widget value + this.setValueFn(content.replace(/\n/g, '\u2424')); + } else { + $(this).html(content+""); + if(style) + $(this).attr("style",style); + } + }); +} \ No newline at end of file