Dashboard 'template' and using jQuery

Does jquery need to be enabled separately when using Dashboard 'template'?

In a flow I want to use jquery calls with button elements.
This works as expected, so far so good.

However, if something is changed/edited with the flow, the browser NR page must be reloaded. Only that way the button functionality is given again.

I guess there is a setting missing!? But which one?

JQuery is enabled in template node by default.

There are examples in the help text,

<div id="{{'my_'+$id}}" style="{{'color:'+theme.base_color}}">Some text</div>
(function(scope) {
  scope.$watch('msg', function(msg) {
    if (msg) {
      // Do something when msg arrives

This uses JQuery to update the html using the id of the element.
So if you add a scope.$watch you could update the document on the fly as variables change.
Also probably best to uncheck "pass through messages from input" if not required and "Add output messages to stored state"

From another NR example I took

(function($scope) {
 ... in here the JS code to work with the 'template'  html code 
  like \<table>  .. \</table> and all the stuff 

No further change was required with the imported JS.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.