public Operation Save(SlsDefectDetail objSlsDefectDetail) { Operation objOperation = new Operation { Success = true }; long Id = _DefectDetailEntryRepository.AddEntity(objSlsDefectDetail); objOperation.OperationId = Id; try { _UnitOfWork.Commit(); } catch (Exception ex) { objOperation.Success = false; } return objOperation; }
public Operation Update(SlsDefectDetail objSlsDefectDetail) { Operation objOperation = new Operation { Success = true, OperationId = objSlsDefectDetail.Id }; _DefectDetailEntryRepository.Update(objSlsDefectDetail); try { _UnitOfWork.Commit(); } catch (Exception) { objOperation.Success = false; } return objOperation; }