Exemple #1
0
 /**
  * 是否已经选择了公众号并且公众号属于当前登录用户.
  *
  * @return bool
  */
 private function checkAccount()
 {
     // 当前选中的公众号ID
     $accountId = get_chosed_account();
     if (empty($accountId)) {
         return false;
     }
     //选中的公众号所属用户ID
     $accountUserId = $this->accountRepository->getAccountUserId($accountId);
     if ($accountUserId != auth()->user()->id) {
         return false;
     }
     return true;
 }