Ejemplo n.º 1
0
        public ActionResult <GradeUsStandardAddViewModel> DeleteGradeUsStandard(GradeUsStandardAddViewModel gradeUsStandardAddViewModel)
        {
            GradeUsStandardAddViewModel gradeUsStandardDelete = new GradeUsStandardAddViewModel();

            try
            {
                gradeUsStandardDelete = _gradeService.DeleteGradeUsStandard(gradeUsStandardAddViewModel);
            }
            catch (Exception es)
            {
                gradeUsStandardDelete._failure = true;
                gradeUsStandardDelete._message = es.Message;
            }
            return(gradeUsStandardDelete);
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Delete GradeUsStandard
        /// </summary>
        /// <param name="gradeUsStandardAddViewModel"></param>
        /// <returns></returns>
        public GradeUsStandardAddViewModel DeleteGradeUsStandard(GradeUsStandardAddViewModel gradeUsStandardAddViewModel)
        {
            GradeUsStandardAddViewModel gradeUsStandardDelete = new GradeUsStandardAddViewModel();

            try
            {
                if (TokenManager.CheckToken(gradeUsStandardAddViewModel._tenantName + gradeUsStandardAddViewModel._userName, gradeUsStandardAddViewModel._token))
                {
                    gradeUsStandardDelete = this.gradeRepository.DeleteGradeUsStandard(gradeUsStandardAddViewModel);
                }
                else
                {
                    gradeUsStandardDelete._failure = true;
                    gradeUsStandardDelete._message = TOKENINVALID;
                }
            }
            catch (Exception es)
            {
                gradeUsStandardDelete._failure = true;
                gradeUsStandardDelete._message = es.Message;
            }
            return(gradeUsStandardDelete);
        }