public ResultViewModels <TempleEditViewModel> AddTemple(TempleEditViewModel TempleEditView) { ResultViewModels <TempleEditViewModel> result = new ResultViewModels <TempleEditViewModel>(); try { var TempleTemp = TempleService.Add(TempleEditView); if (TempleTemp == null) { result.Successed = false; result.Message = "Data is empty"; } else { result.Successed = true; result.Message = "Data added"; result.Data = TempleTemp; } } catch (Exception ex) { result.Successed = false; result.Message = "Something Went Wrong !!"; } return(result); }
public TempleEditViewModel AddTemple(TempleEditViewModel TempleEditView) { var Temple = TempleService.Add(TempleEditView); return(Temple); }