/// <summary> /// 小游戏 - 订单状态跟踪 /// </summary> /// <param name="request"></param> /// <returns></returns> public static async Task <OperationResult <GameOrderTrackingResponse> > GameOrderTrackingAsync(GameOrderTackingRequest request) { try { var gameVersion = request.GameVersion; IList <DefaultGameManager> gameManagers; if (gameVersion == GameVersionEnum.None) { gameManagers = GameManagerFactory.GetAllGameManagers(); } else { gameManagers = new List <DefaultGameManager>() { GameManagerFactory.GetGameManager(gameVersion) }; } foreach (var defaultGameManager in gameManagers) { try { await defaultGameManager.GameOrderTrackingAsync(request); } catch (NotImplementedException e) { } } return(OperationResult.FromResult(new GameOrderTrackingResponse())); } catch (NotImplementedException e) { // 未实现 return(OperationResult.FromError <GameOrderTrackingResponse>("-3", Resource.Invalid_Game_NotImpl)); } }
/// <summary> /// 小游戏 - 订单状态跟踪 /// </summary> /// <param name="request"></param> /// <returns></returns> public virtual Task <GameOrderTrackingResponse> GameOrderTrackingAsync(GameOrderTackingRequest request) { throw new NotImplementedException(); }
/// <summary> /// 小游戏 - 订单状态跟踪 /// </summary> /// <param name="request"></param> /// <returns></returns> public async Task <OperationResult <GameOrderTrackingResponse> > GameOrderTrackingAsync(GameOrderTackingRequest request) { return(await GameManager.GameOrderTrackingAsync(request)); }