Help with form filtering via content plug-in or not...

genyded

Active Member
Well I have been busy (hopefully) helping other on this forum all week... but now I need some...

I can easily filter a list based on a variable IF I embed it into an Aticle using the content plug-in as follows...

Code:
 {fabrik view=form id=1 usekey=id rowid=[cid]}

Validations seem random as to when or if they work.

The only reason I am using the content plug in for the Article is the ability to filter the edit based on the system variable. I would actually prefer to do that with just a menu link to the form, but know of no way to add the filter (other than a url redirect appending it but that would tank performance and be tricky to code for when we need it versus not).

So...

1) Is there a quick easy way to passed the system variable to the form to tell it which row to edit outside in the content plug-in? (having the user pick from a pre-filtered list or even see one is not an option). The users need to go straight to the row in "edit" mode and the variable they are passing is the row ID but they do not know that.

2) If not has anyone else seen any issues with the submission and/or validation of form via the content plug-in that may be able to help?

TIA,
Dale
 
Some remarks:
If id is the PK you don't need usekey

If you have a list with "userspecific" entries you should add an element holding the Joomla userid, then you could use the Fabrik form menu with Options
row id=-1
key name = your-userelement

If the user shouldn't be allowed to edit any but his own record you must prefilter the list anyway. Otherwise anybody can edit any record by just guessing the record id and editing the URL.

Edit:
the easiest way to access a form is via URL
index.php?option=com_fabrik&view=form&formid=15&rowid=xy
Where is the cid in your example coming from?
Validations seem random as to when or if they work.
Which type of validation?
 
Thanks Hugh and hope you are feeling OK post back torture,

The usekey is a habit - and as far as I can tell it does not cause any harm, but you are right it is not really needed.

I can control the edits even down to element level with permissions, so that s not a concern/issue. It's a fairly complex setup... users will be able to say what fields other user can or cannot edit - all that I have working. All that is tripping me up now is just being able to display the "filtered" form in a way that consistently validates and submits.

If I use just the raw from as the content - I cannot easily filter it without actual modifications to the URL and a redirect (having to add the "&rowid=xxx and then redirect after the session variable containing the row is retrieved). That actually works and is not terribly slow, however I have a bunch of forms this is need for and having to keep all the form ID's tracked to modify in the site templates will be a pain.

I can quickly and easily filter one or more forms by put them into articles and using the link previously mentioned. That all works fine too for the filtering (just grabs the supplied session variable and display the row for edit), but with this approach I run into the flakiness with submits and validations. I am still looking into it but I think it's some kind of cache issues even though as far as I can tell I have all caches off.

It would be great f there was a quick easy to filter the form on the session variable without it bring in the article. So I could set something similar to {fabrik view=form id=1 usekey=id rowid=[cid]} and have it pick up the cid session variable then load the forfform.

I'll keep chugging away and see what I can come up with... thanks for taking the time to respond!

Dale
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top