Closed ukdtom closed 6 years ago
And actually not you, but @trumpy81 here it seems ;)
And disregard....
I'm a mess when it comes to frontend :(
So now assigned to both, so do fight it out in a corner ;)
The login screen is hard coded to use the whiteblue.css theme file. That should not be too difficult to change so that it uses the saved theme .css file.
Might be tricky to add it to the factory reset script though?
@trumpy81 Why would I do that? The trick of the factory reset, is to reset to factory std. Or have I lost it here?
You've lost it ... but we all knew that already ... lol 👅
What I meant was, it might be tricky telling the reset script to replace the custom theme style sheet with the default style sheet (whiteblue.css) in a way that let's it be replaced by the saved custom style sheet later on.
I haven't looked at the coding for that, so I am not sure exactly how the reset and saving of custom style sheets is being handled.
LOL, and nope....
What I do when doing a Factory Reset, is what you see in the "Manual" option of this: https://github.com/ukdtom/WebTools.bundle/wiki/Reset
What above does, is 100% resets everything to the default
Yeah I figured that much, but the default in this case is to have the whiteblue.css hard coded as the login page style sheet.
If you change that code to use the saved custom style sheet, that might effect the way that the reset script works?
Nope, cuz when starting up for the first time, the default is:
WhiteBlue.css
https://github.com/ukdtom/WebTools.bundle/blob/tommy-work3-pmsV3-partial/Contents/Code/consts.py#L399
Yes, but that would stop any custom style sheet from being applied to the login page. I trust that is not what you want.
You want to be able to use a custom style sheet on the login page after the user has selected it, but if the whiteblue.css file is hard coded, you cannot replace it.
So, the code would need to be changed to allow a custom style sheet to be used in place of whiteblue.css. In other words, the hard coding for whiteblue.css would need to be changed.
After that, a hard reset would end up using the last saved custom style sheet and not the default whiteblue.css or the whiteblue.css would be hard coded again and you could not use a saved custom style sheet for the login page.
You are wrong here.... The link I provided, is for pure backend, and is executed during startup. What it does, is detecting if a default theme has been set, and if not, we use ours.
Front-end can get to this via the only link, that is allowed without auth towards the framework, and that is:
http://<IPOfPMS>:33400/version
So why is the whiteblue.css file used for the login page instead of the saved custom style sheet?
Because of a bug in the front-end ;)
Ah ... now it makes sense, I was thinking it was coded that way ... lol
And was actually lying here :(
The following can be reached without auth:
Lets go :-) r4t
Perfect
Doesn't use the selected theme, that can be found in endpoint /version
Minor, and cosmetic though, and feel free to bump to 3.1