static public void RejectTestTask(Int64 taskId, string message) { SendConfirmTestTaskRequestData requestData = new SendConfirmTestTaskRequestData(); requestData.actor = Settings.Actor; requestData.agent = Settings.Agent; requestData.task = taskId.ToString(); requestData.confirm = false; requestData.message = message; ProjectManagerServerResponse response = PerformRequest(ConfirmTaskUrl(), requestData); CheckWebError("Отклонение выполнения задачи", response); }
static public bool ConfirmTask(Int64 taskId) { SendConfirmTestTaskRequestData requestData = new SendConfirmTestTaskRequestData(); requestData.actor = Settings.Actor; requestData.agent = Settings.Agent; requestData.task = taskId.ToString(); requestData.confirm = true; try { ProjectManagerServerResponse response = PerformRequest(ConfirmTaskUrl(), requestData); CheckWebError("Подтверждение выполнения задачи", response); return(response.kind == "accepted"); } catch (Exception) { return(false); } }