get products for give user (by ID)

Discussion in 'Customization & add-ons' started by yehudakatz, Sep 8, 2014.

  1. yehudakatz

    yehudakatz New Member

    Joined:
    Jun 5, 2012
    Messages:
    8
    Hello,

    I search a lot but without much success.

    Am_Di::getInstance()->user->getActiveProducts();
    Am_Di::getInstance()->user->getActiveProductsExpiration();

    but for any user ID (without calling login() method):

    Am_Di::getInstance()->auth->login('user', 'pass', '11.22.33.44');

    Also, is there any proper way to get user list? Right now I am getting it directly from am_user table.

    Thanks
  2. yehudakatz

    yehudakatz New Member

    Joined:
    Jun 5, 2012
    Messages:
    8
    It's something closer but still does not include information I need:

    $user = Am_Di::getInstance()->userTable->load($user_id, false);
  3. yehudakatz

    yehudakatz New Member

    Joined:
    Jun 5, 2012
    Messages:
    8
    Does this product have any support? (no replies in tickets either)
  4. yehudakatz

    yehudakatz New Member

    Joined:
    Jun 5, 2012
    Messages:
    8
  5. yehudakatz

    yehudakatz New Member

    Joined:
    Jun 5, 2012
    Messages:
    8
    Case anyone will search for the same here is solution:

    Am_Di::getInstance()->userTable->findBy(array());

    Also, if you want to work with amember, you should understand how Record class works!

    Very difficult but well written code!
    cebasso likes this.

Share This Page