• Hello Fabrik Community

    Fabrik is now in the hands of the development team that brought you Fabrik for Joomla 4. We have recently transitioned the Fabrik site over to a new server and are busy trying to clean it up. We have upgraded the site to Joomla 4 and are running the latest version of Fabrik 4. We have also upgraded the Xenforo forum software to the latest version. Many of the widgets you might have been used to on the forum are no longer operational, many abandoned by the developers. We hope to bring back some of the important ones as we have time.

    Exciting times to be sure.

    The Fabrik 4.0 Official release is now available. In addition, the Fabrik codebase is now available in a public repository. See the notices about these in the announcements section

    We wish to shout out a very big Thank You to all of you who have made donations. They have really helped. But we can always use more...wink..wink..

    Also a big Thank You to those of you who have been assisting others in the forum. This takes a very big burden off of us as we work on bugs, the website and the future of Fabrik.

[SOLVED] Weird problem...

At least now with these settings (Fabrik user frontend = French, date month with text) it's replicatable ...
But no idea what's going on.
@cheesegrits ?

What I've seen:
on load the month names are lower case, calendar is inserting with a capital letter;
insert a date (year <> 2018) via calendar widget, set the cursor into the date field, do nothing, leave the field --> date changes to 2018!!
set the cursor into an existing date field, leave it --> the month will change from lower to upper case (year stays at it is)
:eek:
 
Thank god you see it now...i was starting to think i live in a twilight zone !! lollll... now if someone could put the finger on this bug, it would be very much appreciated, cause we use d F Y for date everywhere on the site, and everything is fine...it's only here in a repeat group that something is definitely wrong.

rodeokid
 
OK, I'll install the French language locally, and attempt to replicate. The good news is that once I can actually replicate a bug, I can usually fix it.

-- hugh
 
OK, looks like it's a bug in the built in calendar Javascript, specific to month names with accented characters. The parseDate() function is doing ...

Code:
str.split(/\W+/)

... to split (for example) "27 Avril 2017" into component parts. The \W is a regex symbol meaning "any non alpha-numeric character", where "alpha" is specifically the set [A-Za-z]. Which is fine for Avril, you end up with a 3 element array of date, month name and year ... [27, Avril, 2017]. But for "27 Ao?t 2017", regex considers the ? to be non alphanumeric, so you end up with a 4 element array ... [27, Ao, t, 2017] ... so the formatting parser then gets its undies in a bundle.

Which explains why I could never replicate this, as even when I switched to French, I was testing with Avril, because it happened to be April when I was testing, and I never selected a month with an accented character.

Fortunately, there's a workaround. In the "Advanced" tab for the date element settings, you can enable "Advanced formats", which tells Fabrik to load a much more robust date formatting Javascript library, rather than using the built in Joomla one, which seems to handle accented month names just fine.

This is one of those issues that very few J! extensions will ever be troubled by, because it uses a function, date.parseDate(), that almost nobody uses. You only need it if you need to convert dates between formats on the fly in Javascript. Which Fabrik does.

I tested both on my local copy of your site, and on your site, switching "liste_des_employes_3_repeat___dateabsence" to use advanced formats, and it seems to be OK.

-- hugh
 
It works ! Thank hugh very much ! I was going nuts on this one.

But now i have a new problem on this form... i can't add anymore repeat group. The ones already there have all been added by our supervisors couple of weeks ago... nothing have change since, so access right have not changed.

But right now, only a superuser can add repeat group (Absences, Retards, D?part h?tif).
So the date problem is gone, but that leaves me with a new problem i don't understand.
Thanks for your help.

rodeokid
 
Last edited:
I did a lot of test in the past few hours... no luck at all. The date problem is gone for sure, but now i can't add any other repeat group if i am logged in anything but superuser.
Normally our supervisors can add in repeat groups, and it was working fine before.
I looked in console devbug tools, no problem at all in this form.
Don't know what's going on...
Any help again please ?

rodeokid
 
Added to notes in MySites.
You now have a supervisor access user, same as the one we added a lot of absences in the past weeks, but now can't anymore.
Thanks
rodeokid
 
You'd set the new, edit and view ACLs on the id and parent_id elements for your repeat groups to "Acc?s super utilisateur". So anyone who wasn't a super user couldn't create new repeats, because Fabrik wouldn't include those fields in the insert query.

This must be a change you've made, as there's no way it would have worked like that before, and those ACL's wouldn't have changed themselves.

I've set them all to public, seems to be working.

-- hugh
 
This is really strange...why the hell should i decided to change this ?...lollll... anyway, thanks for this, really did'nt thought about checking this. Sorry about this newbie error.
Really appreciate it.
rodeokid
 
Last edited:
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top