Dashboard can no longer be edited, update did not bring success
Add a Text element to the dashboard (paragraph)
I’m using a java script to show the time and date here
Add a Widgets element to the dashboard (thresholds)
after calling the function, the system displays the error message
EmonBase, EmonCMS self hosted
@borpin, I had the V9.8.30 on it with the mentioned error, the update to V9.9.5 was done with the EmonBase update button, the database was checked but there was nothing to do.
After that I deleted the browser cache and rebooted the EmonBase, but the error was immediately reproducible.
An update via the terminal to V9.9.6-beta was not successful either
My second EmonBase (test system) has exactly the same bug, this is currently installed with V9.9.5.
Since I haven’t had to modify the dashboard for a long time, I only noticed it last week, the last dashboard modification I had as far as I can remember under Emoncms V9.8.24.
If I delete the text element (paragraph), the dashboard can be edited and saved again. But inserting a new Parargaph text element with content a clock as Java Script is aborted with the error message.
Regardless of this, the thresholds widget error will show up as soon as I press Save.
Can you inspect the text box widget content in emoncms, compare it in the 2 locations to see if there is any difference, the addition chars that I found were not displayed in the text box widget editing area, but they were present in the dashboard configuration “copy and paste” edit box (see red arrow in 2nd pic)
When I delete the hidden chars from the dashboard configuration editor the dash can then be saved with the new changes. Perhaps you have something similar? The point is you cannot believe what you see in the text box widget editor as it seems to not show these chars. so check for any differences in what is displayed in the dashboard configuration editor, bear in mind this is the complete dashboard content, so you need to hunt out the specific div’s to the text box widget for the clock, I chose a very simple page (and edited the content names to “Example”) so it is easier to locate and demonstrate, it’s not so clear on more complex dashboards.
[edit - Thinking about this some more, I have some vague recollection of there being some restriction put on scripting to reduce the chance of rogue code being injected with copied dashboards. Could it be the script tags that are causing the issue?]
[edit2 - Just did a quick test and found that adding <script></script> to a text box on a dash I am able to edit and save ok without it, is not able to be saved after adding the script tags. Removing them again allows the dash to be saved ok. Seems you can no longer have script tags directly within the dash content.]