Never tried this before, but I have a system where the login details need to be username as a date, such as 2022-11-16, each time i try this I get an unauthorised response, anyone got any idea why?
I have tried sending the username by itself, as a string, and as a formatDate(‘yyyy-MM-dd’), as well as a combination of the two, format date, then convert to string.
The date in the database is stored as DATE, and not as a string.
The Login Form Input, looks like this.
<input type="date" class="form-control" id="inp_username_date" name="username_date" aria-describedby="inp_username_date_help" placeholder="Pick a Date *" required="">
Only work around so far is if I alter the MariaDB DATE to a VARCHAR instead, but that is really not ideal for me.
So strange, on you on Wappler 5.1.4 and is it a MariaDB 10.5.x database.
I just tried again, and i also tried using a setvalue for the username just like your screenshot, and neither are working, both give me an unauthorised response.
Paul, are you sure there are no 2 same (date/username) entries in your database, and the security provider just finds the other one and shows unauthorized as the password is different?
Hey, Teo, yes my database only has 1 row, and that one is just that date.
Brian, I disabled my login step, and changed it to a validate step, and i get the same results as you, showing it should be working, but as a login step, it does not do the same.
Ahh that makes sense then why it does not work, wonder if this is a George or Patrick fix, if the Wappler team feel this is even something that needs fixing I suppose, considering its not a very common practise.