Ejemplo n.º 1
0
        public void InsertList(List <m_microscopic_analysis> _lists)
        {
            foreach (m_microscopic_analysis tmp in _lists)
            {
                switch (tmp.RowState)
                {
                case CommandNameEnum.Add:
                    _repository.Add(tmp);
                    break;

                case CommandNameEnum.Edit:
                    m_microscopic_analysis existing = _repository.Find(x => x.id == tmp.id).FirstOrDefault();
                    _repository.Edit(existing, tmp);
                    break;
                }
            }
        }
Ejemplo n.º 2
0
        public void Update()
        {
            m_microscopic_analysis existing = _repository.Find(x => x.id == this.id).FirstOrDefault();

            _repository.Edit(existing, this);
        }