public ApiResult <List <AdvertisementResDto> > GetAdvertisementList(int location, int type, string city) { #region 校验请求参数 if (type != 1 && type != 2 && type != 3) { return(new ApiResult <List <AdvertisementResDto> >(40000, "请求参数Type验证未通过")); } #endregion int deviceType = 0; if (this.RequestInfo.ClientType == DevicePlatform.Android) { deviceType = 3; } else if (this.RequestInfo.ClientType == DevicePlatform.Ios) { //Ios App Store不返回广告 if (this.RequestInfo.ClientSourceId == 10) { return(new ApiResult <List <AdvertisementResDto> >()); } deviceType = 2; } else if (this.RequestInfo.ClientType == DevicePlatform.Browser) { deviceType = 1; } else { deviceType = 1; } return(advertService.GetAdvertList(location, type, deviceType, city, RequestInfo.ClientIP)); }