One of my Lists suddenly stopped displaying

mbeley

Member
I have a form that I've been working on for a while, it's multi-page and quite complex. I'm getting to the point where I'm happy with it.
But the corresponding list suddenly stopped working.
I cannot access it in the back office, using either one of the "View Data" buttons in List or Form.
And not surprisingly it is also inaccessible in the front office.

I get an Internal Server Error.
The error log shows
[Tue Apr 01 11:03:30 2014] [error] [client 78.231.36.185] File does not exist: /home/boagente/public_html/500.shtml, referer: http://www.boagente.com/wconsult/INEFP/administrator/index.php?option=com_fabrik&view=forms

I tried to update the database from the Forms view, but nothing happens.
Please help!
Mathieu
 
I've had cases like that. If this happened just after you made a change, try to undo this change. If you can't, go to the "Groups". Since you have a multi-page form, you have several groups. Unpublish all of them except the first one or the one that contains the "id" (Primary Key) element and see if you can access your form/list.
If you can, re-publish one group at a time until you hit the one that's causing the error. If the issue with this group is not obvious, unpublish all its elements, but one and test. If the form works, re-publish 1 element at a time until you find the culprit.
 
OK I found the culprit.
It's a concat label.
Oddly it is displaying in the Form, but blocking the list from displaying.
 
Are you using the tablename in your concat? Like ...

foo.bar, ' - ', foo.baz

Try using {thistable} instead of the actual table name ...

{thistable}.bar, ' - ', {thistable}.baz

Also, if you are trying to use "Additional joins" on your join, that feature is currently broken, and woin't work in list view, and will cause problems if you are trying to use anything from the additional joins in your concat label.

-- hugh
 
I tried the Concat again with your advice, Hugh. It does not break the list view this time, which is great news.
But I'm still not out of the woods. Let me explain.

I have a Job Offer form that uses cascading dropdowns where the user can select the company and branch (where the job is offered). So I'm storing the Company ID in the Job Offer.

Later I need to select a Job Offer (from a Candidate's record).
But Job Offers don't have names, and it's very difficult to ask users to give a name to a Job Offer.
So I created a Concat Label in the Job Offer field of the Candidate form.
It looks like this:
{thistable}.joboffer_profession,' - ',{thistable}.joboffer_company,' - ',{thistable}.date_time
Where thistable is Job Offers.
The problem is that the Profession and the Company are not listed in my Job Offers table, only their ID are listed.

If I go back to my Job Offers table and change the database join to store the Company name instead of ID, it breaks the cascading dropdown.
In fact it brings me in the situation I was describing last week: http://fabrikar.com/forums/index.ph...ropdown-using-parent_id-in-repeat-table.38068
 
Ouch! After writing this post, I went back to my Elements, and I have a very bad surprise: the 2 messages below are repeated many times:
Notice: Undefined property: stdClass::$full_element_name in /home/boagente/public_html/wconsult/INEFP/administrator/components/com_fabrik/models/elements.php on line 193
Notice: Undefined property: stdClass::$db_table_name in /home/boagente/public_html/wconsult/INEFP/administrator/components/com_fabrik/models/elements.php on line 195

And then the Elements are displayed, but in the table, in the Group column, all elements have the following notice:
Notice: Undefined property: stdClass::$group_name in /home/boagente/public_html/wconsult/INEFP/administrator/components/com_fabrik/views/elements/tmpl/bootstrap.php on line 205
 
This happened after I fixed the cascading dropdown in the Job Offer form (I went back to storing the Company ID rather than the Company Name).
Fortunately, and surprisingly (to me) I have been able to register a Job Offer in the front end in the meantime.
 
The problem is that the Profession and the Company are not listed in my Job Offers table, only their ID are listed.

Yup, that's a fairly well known issue.; You can solve it by doing sub-queries in the concat label, to fetch the "name" from those tables, using the key values you have. Something like this:

Code:
(SELECT name FROM profession WHERE id = {thistable}.joboffer_profession), ' - ', (SELECT name FROM company WHERE id = {thistable}.joboffer_company), ' - ',{thistable}.date_time

You'll need to change that to use the appropriate 'name' on those two tables, and change 'id' if that isn't the PK field name on those tables.

I'm looking at those notices now.

-- hugh
 
Nope. Was about to post and say everything looks normal on the back end.

I've seen that happen occasionally, always seems to last just a few page loads, then it goes away. I have a suspicion it's to do with spurious errors on one of the queries we use to assemble the list of elements, one of our metadata tables being joined (like #_fabrik_form_groups, or #_fabrik_forms etc) gets wedged up somehow. Usually seems to happen on shared hosts, probably when you exceed some resource limit on your database usage.

Anyway ... let me know if it happens again.

-- hugh
 
One more quick question, my Concat labels are working great, except that a time is displayed with the dates.
I made sure that the elemenst involved are configured without time, meaning Show time selector = No and date formats (list and form) do not contain time.
Any way I can get rid of the time?

re: backup, yes! my host takes care of backup at least once a day. thanks for asking...
 
For the time, it is because dates are always stored in the database in a "complete" format: YYYY-MM-DD HH:MM:SS. There might be an SQL instruction to retreive only the date part of a date record, but I don't know it off hand.
 
We are in need of some funding.
More details.

Thank you.

Members online

No members online now.
Back
Top