⚠ 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 to show only login user record in datatable



Manoj Fernando
  • profile picture
  • Member

Posted 19 April 2016 - 08:38 AM

Hi,

 

I wan't to show only login user profile records in the data table.

 

I am using Tank Auth as authentication library.

 

Please help..

 

Thanks!


Paul Savostin
  • profile picture
  • Member

Posted 03 May 2016 - 16:11 PM

No mater what auth library u have using, to display only login users u need this list, then using pure where and or_where from this list


portapipe
  • profile picture
  • Member

Posted 22 August 2016 - 09:19 AM

$crud->where('author',$this->tank_model->get_user_id());

 

(I don't know the model name of tank auth, just replace "tank_model" with the right one ;) )

 

If you don't need the register part there is a lightweight script to manage the login: Login-GroceryCrud