Agent.php 825 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?php
  2. namespace App\Http\Models;
  3. use Illuminate\Database\Eloquent\Model;
  4. use \App\Models;
  5. use \App\Http\Models as HttpModel;
  6. /**
  7. * 代理管理模型类
  8. */
  9. class Agent extends Model
  10. {
  11. /**
  12. * 获取游戏url及参数
  13. *
  14. * @access public
  15. * @param mixed $gmenuId 游戏Id
  16. * @return String
  17. */
  18. public function getGameUrl($gmenuId)
  19. {
  20. // 获取游戏地址数据.
  21. $gameUrlModel = new Models\GameUrl;
  22. $getGameUrlSelect = ['gameUrl_url', 'gameUrl_data'];
  23. $getameUrlWhere = [
  24. 'gmenu_id' => $gmenuId,
  25. 'gameUrl_type' => 'login',
  26. ];
  27. $getGameUrl = $gameUrlModel
  28. ->select($getGameUrlSelect)
  29. ->where($getameUrlWhere)
  30. ->first();
  31. return $getGameUrl;
  32. }//end getGameUrl()
  33. }