Hi @Danilo_Lima,
Thanks for the file, but unfortunately it does not fix the issue. I replaced it (and deleted the cache file), and the date fields still accept unlimited digits and never move to the next field.
I compared the new jquery.scInput2.js with the previous one: the changes only add support, date separator parsing and textarea caret scrolling. Nothing related to this bug was changed.
Root cause
ScriptCase generates the split date fields like this:
<input id="SC_arrivo_dia" alt="{datatype: 'mask', maskList: '99', alignRight: true, maxLength: 2, autoTab: true, enterTab: false}">
But normalizeConfig() in jquery.scInput2.js only reads mask and alignment:
c.mask = optStr(raw.mask, '');
Since mask is empty, createEngine() returns null and the plugin ignores the field completely: no 2-digit limit, no autoTab, no right alignment. This affects every field with a mask generated with maskList, not just dates.
Fix (tested, works on our installation)
In normalizeConfig():
// case 'mask':
c.mask = optStr(has(raw.mask) && raw.mask !== '' ? raw.mask : raw.maskList, '');
and after the line that sets c.alignment:
if (!c.alignment && optBool(raw.alignRight, false)) c.alignment = 'right';
Also note that published applications load the file from <app>/_lib/lib/js/jquery.scInput2.js, so replacing it only in devel/lib/js/ is not enough until the app is republished.
Please include this in the official release so it does not get lost with the next update.
Best regards,
Nicola