简体   繁体   中英

Get rows where field equal value in grocery crud

$crud->set_table('pages',"where permission =1"); <----------------------how to do this in the right way 
$crud->set_relation('pagetype','themes','name'); 
$crud->set_rules('systemTTL', 'System Title', 'trim|required|min_length[4]|xss_clean|alpha_dash'); 
$crud->callback_add_field('title',array($this,'edit_field_callback'));

Hellooo I have multiple users with permissions and i want to show only raws which are for certain user group ....

Thank you

Use the where method:

$crud->where('permission', 1);

Edit: Here is the documentation.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM