コード例 #1
0
 /**
  * Gets the total number of players in the database
  * @return integer
  */
 public function getPlayerCount()
 {
     $count = Cache::remember('player.count', 60, function () {
         return Player::count();
     });
     return intval($count);
 }
コード例 #2
0
ファイル: PlayerRepository.php プロジェクト: BP4U/BFAdminCP
 /**
  * Gets the total number of players in the database
  *
  * @return integer
  */
 public function getPlayerCount()
 {
     $count = Player::count('PlayerID');
     return intval($count);
 }