public ActionResult <EffortGradeScaleAddViewModel> DeleteEffortGradeScale(EffortGradeScaleAddViewModel effortGradeScaleAddViewModel) { EffortGradeScaleAddViewModel effortGradeScaleDelete = new EffortGradeScaleAddViewModel(); try { effortGradeScaleDelete = _gradeService.DeleteEffortGradeScale(effortGradeScaleAddViewModel); } catch (Exception es) { effortGradeScaleDelete._failure = false; effortGradeScaleDelete._message = es.Message; } return(effortGradeScaleDelete); }
/// <summary> /// Delete EffortGradeScale /// </summary> /// <param name="effortGradeScaleAddViewModel"></param> /// <returns></returns> public EffortGradeScaleAddViewModel DeleteEffortGradeScale(EffortGradeScaleAddViewModel effortGradeScaleAddViewModel) { EffortGradeScaleAddViewModel effortGradeScaleDelete = new EffortGradeScaleAddViewModel(); try { if (TokenManager.CheckToken(effortGradeScaleAddViewModel._tenantName + effortGradeScaleAddViewModel._userName, effortGradeScaleAddViewModel._token)) { effortGradeScaleDelete = this.gradeRepository.DeleteEffortGradeScale(effortGradeScaleAddViewModel); } else { effortGradeScaleDelete._failure = true; effortGradeScaleDelete._message = TOKENINVALID; } } catch (Exception es) { effortGradeScaleDelete._failure = true; effortGradeScaleDelete._message = es.Message; } return(effortGradeScaleDelete); }