⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

how can I pass restrictions in to the ajax_list call?



frednurk
  • profile picture
  • Member

Posted 18 December 2013 - 20:19 PM

I want to be able to generate a list with a restriction.  For example, a list of only men from my users list:

 

$crud->where('gender', 'm')

 

I do this by adding a parameter to my url:

users/list_users?gender=m

 

 

However, when I go to the list page, ajax_list is immediately called, and it does not include the parameter, so the list restriction vanishes.  Also, pagination does not include this parameter.

 

Is there a proper way to do this?

 

Is there a way to pass that parameter in to the ajax_list and ajax_list_info calls?