Coder Social home page Coder Social logo

Comments (4)

REJack avatar REJack commented on May 29, 2024

use the admin only for You as the developer and create 2 more groups and create premissions to keep the companies divided

from codeigniter-aauth.

lostlian avatar lostlian commented on May 29, 2024

Thanks a lot for your reply.

It makes a lot of sense. so you say to create 1 permission per company (i have a company id column in each db table, so im able to know which company the data is from) and 3 other groups (example user_admin, manager, agent) ?

from codeigniter-aauth.

REJack avatar REJack commented on May 29, 2024

i would write it like this:

if($this->aauth->control('pepsi')){
  $fetch = $this->db->get_where('your_db',array('company_id'=>'pepsi'));
}else if($this->aauth->control('coke')){
  $fetch = $this->db->get_where('your_db',array('company_id'=>'coke'));
}

from codeigniter-aauth.

emreakay avatar emreakay commented on May 29, 2024

I am pleased to use our library @lostlian 👍
I am also thankful for your help @REJack

from codeigniter-aauth.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.