OPNsense Forum

Archive => 17.7 Legacy Series => Topic started by: Ren on October 30, 2017, 07:14:51 pm

Title: Bring focus to error message when required field contain invalid data
Post by: Ren on October 30, 2017, 07:14:51 pm
I tried configuring my OPENVPN server  to use google as a time server.

(http://i204.photobucket.com/albums/bb240/xs_studio/OpenSENSE/NTP%20OpenVPN_zpshgxkcif8.png)

I then saved my settings and briefly an error message flashed on screen (too fast for me to read) and returned me to above screen. I then i had to scroll to top of the page to see the error message.

(http://i204.photobucket.com/albums/bb240/xs_studio/OpenSENSE/NTP%20OpenVPN%20Error_zps0mxlvslq.png)

So i decided not to use a time server as i was just testing a few things. I unchecked the option (http://i204.photobucket.com/albums/bb240/xs_studio/OpenSENSE/NTP%20OpenVPN%20Unchecked_zpsusai3lbq.png)and again an error message flashed on screen. It was the same error message " NTP Server must contain a valid IP"

So it seems once i've enabled an option i have to fill it with the required/valid data before i'm able to disable it even though the settings did not save (i made other changes at the time so i didn't want to cancel my other changes). Additionally,  field contains invalid data the error message that is displayed when attempting to save the current settings flashes too quickly. Can the error message be displayed for longer or until the user tries to edit a field on the page ?
Title: Re: Bring focus to error message when required field contain invalid data
Post by: franco on October 31, 2017, 09:11:34 am
Hi,

Thanks for this, but this is far better suited for GitHub: https://github.com/opnsense/core/issues

From experience we did this in another fork a few years back, but it requires touching every static .php page that there is, something we'd rather not do anymore. The MVC dialogs and forms can do this already and we'd rather migrate the static .php pages to MVC than improve them one by one over and over again.

In MVC terms it means we only have to add something once, not currently 150 times each, because that is how many static pages we still have.


Cheers,
Franco
Title: Re: Bring focus to error message when required field contain invalid data
Post by: Ren on November 01, 2017, 07:18:42 am
Hi,

Thanks for this, but this is far better suited for GitHub: https://github.com/opnsense/core/issues

From experience we did this in another fork a few years back, but it requires touching every static .php page that there is, something we'd rather not do anymore. The MVC dialogs and forms can do this already and we'd rather migrate the static .php pages to MVC than improve them one by one over and over again.

In MVC terms it means we only have to add something once, not currently 150 times each, because that is how many static pages we still have.


Cheers,
Franco

Ok thanks for info