How to show more than one record using content plugin.

pkjoshi

Active Member
I am trying to display multiple records from a list using content plugin, but having trouble.

Can't make out what I am doing wrong, I have tried various combinations, none of which worked for example:

Code:
{fabrik view=list id=15  member___club_name=2 & member_repeat_designation___designation=6 & member_repeat_designation___designation=9  layout=div showfilters=0}
 
{fabrik view=list id=15  member___club_name=2 & member_repeat_designation___designation=6,9  layout=div showfilters=0}
 
{fabrik view=list id=15  member___club_name=2 & member_repeat_designation___designation=6&9  layout=div showfilters=0}

What is the correct way of doing it. Wiki has no direction on this.
 
Thanks Troester. Don't know what I am missing here.

I have this code in a form footer, which is not working
Code:
{fabrik view=list id=15 member___club_name={club_name___id} member_repeat_designation___designation[value]=6,9,35,3 layout=div & showfilters=0}
 
{fabrik view=list id=15 member___club_name={club_name___id} layout=default resetfilters=1}

but if I am using just member_repeat_designation___designation=6 it does work to the extent that it shows the relevant record, but another problem is that the second list view is rendering the copy of the first one and not as per the code above.

Do you see any problem in the code?
 
Different points:
- resetfilters isn't working (it has been), see https://github.com/Fabrik/fabrik/issues/781
- inside {} you must use [], where does club_name___id come from, a URL parameter?
- displaying the same list twice with content plugin may create issues because it's creating the same HTML id twice (and HTML id has to be unique)
 
Thank you so much Troester.
resetfilters is very essential, is there any quickfix or I must go back to 3.0.6.3.
inside {} you must use []. you mean {club_name___id} to be [club_name___id] or something else?

where does club_name___id come from, a URL parameter? - I am having a list of club and another list of members. club list is having element as club_name___id and member list is having a db join element with club list as member___club_name. I have menu item with club list linked to it.
What I want to achieve here is when you click on the club-name record in club list, it should show
  1. the details view of the club
  2. the details view of the President, secretary, treasurer and first vice president in div layout below 1
  3. the list of related members of club below 2
If I omit this
Code:
{fabrik view=list id=15 member___club_name={club_name___id} member_repeat_designation___designation[value]=6,9,35,3 layout=div & showfilters=0}
then the related members list shows fine below the details view of the club. But I want to show in the layout, which is posing all sorts of issues.

-displaying the same list twice ..(HTML id has to be unique). This part I addressed by creating a copy of that list. But reset filters still doesn't work.

Thanks.
 
I still don't understand where club_name___id is coming from.

What troester is refering to is using [something] to pick up the value of a query string parameter, so if you have &something=123 on the URL, you can then use [something] inside your {fabrik ...} plugin string, like club___name=[something], which will then get replaced with 123, the value of something=123 in the query string.

So ... I'm just not understanding where that comes from in your page.

I don't know if we'll be able to fix the clearfilter in this scenario in 3.0, it may have to be a 3.1 fix.

-- hugh
 
I still don't understand where club_name___id is coming from
Hi Hugh, but that part is working fine, what I am trying to achieve. That is the list included in the form outro is getting filtered dynamically with the club_name___id.

I don't know if we'll be able to fix the clearfilter in this scenario in 3.0, it may have to be a 3.1 fix.
I already had a fix by just replacing the single file plugins/content/fabrik/fabrik.php from 3.6.3, which is working fine. I don't know if it will have any side affects for now.
You can see and understand the difference what has altered in the 3.6.3 and 3.0.8 in this file, which is beyond my capability.

Thanks.
 
Hi Hugh,
One question still bothering me when you say
I don't know if we'll be able to fix the clearfilter in this scenario in 3.0, it may have to be a 3.1 fix.

That means do you suggest that we should switch to 3.1x and we will not be having a stable version/release for 3x?

Thanks.
 
OK, looks like this is not an easy one to fix. The problem is the change in J! from the JRequest to $app->input for handing query string args.

Long story short, we can add stuff to $app->input, which is how we add the table___element=foo filters from the content plugin, by adding them to the standard J! input array.

The problem is, we can't remove them. So it works in 3.0.6.3 because we were using the old, deprecated JRequest method of adding and removing query string args, which did allow us to remove them after a given plugin was run, so they didn't exist when the next plugin ran.

I'm trying to see if there's some kind of workaround I can come up with.

-- hugh
 
Thanks so much Hugh for taking so much trouble.
I am pretty confident that if you are at it, you will definitely find a way.
 
Actually, looks like I was mistaken, and the problem is actually in our code. I see what's happening now, I just haven't yet worked out how to prevent it.

-- hugh
 
Yes, I just tried: multi-select dbjoin still not shown in details view.
Maybe you should bump the thread.
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top