예제 #1
0
 Reply LoadAccountData(Request request)
 {
     var arguments = request.Arguments;
     string regionName = (string)arguments[0];
     int accountId = (int)arguments[1];
     RegionHandler regionHandler = GetRegionHandler(regionName);
     AccountIdJob job = regionHandler.PerformManualSummonerUpdate(accountId);
     SummonerUpdateResult result = new SummonerUpdateResult(job);
     string body = Serialiser.Serialize(result);
     Reply reply = new Reply(ReplyCode.Ok, ContentType.JSON, body);
     return reply;
 }
예제 #2
0
 Reply ApiUpdateSummoner(Request request)
 {
     PrivilegeCheck(request);
     var arguments = request.Arguments;
     string regionAbbreviation = (string)request.Arguments[0];
     int accountId = (int)request.Arguments[1];
     Worker worker = GetWorkerByAbbreviation(regionAbbreviation);
     OperationResult result = worker.UpdateSummonerByAccountId(accountId);
     SummonerUpdateResult output = new SummonerUpdateResult(result);
     return GetJSONReply(output);
 }