Esempio n. 1
0
        public async Task Update(PhieuDatChiTiet inputModel)
        {
            try
            {
                await _unitOfWork.PhieuDatChiTietRepository.Update(inputModel);

                await _unitOfWork.SaveChange();
            }
            catch (Exception ex)
            {
                await _unitOfWork.Rollback();

                throw ex;
            }
        }
Esempio n. 2
0
        public async Task <PhieuDatChiTiet> Create(PhieuDatChiTiet inputModel)
        {
            try
            {
                var result = await _unitOfWork.PhieuDatChiTietRepository.Add(inputModel);

                await _unitOfWork.SaveChange();

                return(result);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }