public DeleteFeeType DeleteFeeType(DeleteFeeType obj)
        {
            var returnModel = new DeleteFeeType();
            var FeeType     = _FeeTypesRepo.Get(obj.FeeTypeId);

            if (FeeType != null)
            {
                _FeeTypesRepo.Delete(FeeType);

                returnModel.Message = "Delete Successful.";
            }
            return(returnModel);
        }
예제 #2
0
 public async Task <IActionResult> DeleteFeeType(long FeeTypeId)
 {
     try
     {
         var model = new DeleteFeeType()
         {
             FeeTypeId = FeeTypeId
         };
         await Task.Run(() => _FeeTypesServ.DeleteFeeType(model));
     }
     catch (Exception)
     {
         return(BadRequest());
     }
     return(RedirectToAction("FeeTypesList"));
 }