Пример #1
0
 /**
  * Get the user id.
  * @return integer
  */
 public function getUserId()
 {
     /* Get list of users */
     $users = User::all();
     $userData = $this->buildUserTable($users);
     $this->table(['id', 'username'], $userData);
     $user_id = $this->ask('Which user would you like to assign a role for? [1,2,...]');
     return (int) $user_id;
 }