You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In our forms we are using date-fields and want to disallow dates from the past. Therefore we use the "min"-attribute:
var currentdate = new Date().toISOString().slice(0, 10);
$(".powermail_date").attr("min", currentdate).attr("data-powermail-minimum-message", "Date must be in the future!");
I just checked but min and max is not supported by default in powermail for date fields.
So I'm going to close this issue.
Nevertheless if you are interested in doing a pull request with the change, we can run the automatic tests and if everything works as expected, I could merge the PR (if it's not a code mess :)
In our forms we are using date-fields and want to disallow dates from the past. Therefore we use the "min"-attribute:
The browser-datepicker are correctly limited, but with keyboard you can type custom dates and then powermail-validation only works, if the year is not the current year probably because of a wrong compare in "isValidationMinimumConfirmed". I think fields with type "date" must be normalized before comparing values.
https://github.com/einpraegsam/powermail/blob/2930f72f2baf5b46f966c9262be2fbb7911e047b/Resources/Private/Build/JavaScript/FormValidation.js#L319-L325
Expected Behavior for min="2022-05-13":
Actual Behavior for min="2022-05-13":
TYPO3: 11.5.10
Powermail: 10.1.0
Tested with different browsers (german format dd.mm.yyyy)
The text was updated successfully, but these errors were encountered: