I have just upgraded our Xibo server to 1.7.2 which is great thanks, but have come across an issues when editing media from a regional time line.
When in the Layout Design mode, i go to the edit timeline option which then loads up the “Region Time” for that region, I then go and edit a media type say “Text” when in the edit window the new “Apply” button is present. If I use the Apply button after making some changes this works fine, however if I then go to exit the media by using normal Save button either after using the Apply button at first, or even just using the save button instead of getting returned to the “Region Timeline” menu for what I was editing I get dumped back at the Layout Design mode instead which is a right pain when having to do multiple edit per Region Timeline.
If you use the cancel button you get returned to the Region Timeline as expected. Other media items like image where the Apply button doesn’t exist the Save button seems to behave as expected and returns me to this Region Timeline list.
hhmmmmm, been going through this again and found out that in the forecast.io module It does infact load back up the Regional Timeline ok, when the other forms where this is not present this does not happen.
This has lead me to look at the code changes, and noticed from this commit
link 1
that only one line of code has been added to the forecast.io module, but when you look at the other commits to complete the Apply button config
link2
there is refreshpreview added which is not in the forecast.io module code.
Now if I disable this particular line it now actually loads up the Regional Timeline again.
Any thought’s Dan please? I can’t see how to fix this, if you suggest a fix i can sort out a commit if needed…
Cheers Dan thanks, I have tried to juggle the code around and move this piece of code to after the loadform & loadformuri responses thinking along a similar line but this made no effect in this circumstance.
Well, I am actually not sure what is happening there - the refresh preview function is being passed back as a callback to the javascript, executed and then causes an undefined error.
It can be fixed in xibo-cms.js by changing the linked line to eval(response.callBack);
Not sure what else that might break - I am thinking not much, you could try it and see?