public void AddNewMedicine(MedicineDTO medicine, int prescriptionId) { var entity = _DTOMappers.Map(medicine); entity.PrescriptionId = prescriptionId; _medicineRepository.AddNew(entity); }
public bool DeleteMedicine(MedicineDTO medicine) { var entity = _DTOMappers.Map(medicine); return(_medicineRepository.Delete(entity)); }
public Medicine Map(MedicineDTO medicine) => _mapper.Map <Medicine>(medicine);