public async Task <(ResponseCode code, Job result)> UpdateJob(Job job) { var results = await api.UpdateJob(job.Id, job, Constants.ApiManagementKey); if (results != null) { return(ResponseCode.Success, results); } return(ResponseCode.Error, null); }
public async Task <(ResponseCode code, Job result)> UpdateJob(Job job) { // Create an instance of the Refit RestService for the job interface. IJobServiceAPI api = RestService.For <IJobServiceAPI>(Constants.BaseUrl); var results = await api.UpdateJob(job.Id, job, Constants.ApiManagementKey); if (results != null) { return(ResponseCode.Success, results); } return(ResponseCode.Error, null); }
public async Task <(ResponseCode code, Job result)> UpdateJob(Job job) { // Create an instance of the Refit RestService for the job interface. IJobServiceAPI api = GetManagedApiService <IJobServiceAPI>(); var results = await api.UpdateJob(job.Id, job); if (results != null) { return(ResponseCode.Success, results); } return(ResponseCode.Error, null); }