예제 #1
0
 private void MergeFireExtinguisherControl(FireExtinguisherControl originalFireExtinguisherControl, ControlRequest FireExtinguisherControl)
 {
     originalFireExtinguisherControl.Consortium     = this.ConsortiumRepository.GetById(FireExtinguisherControl.ConsortiumId);
     originalFireExtinguisherControl.Provider       = this.ProviderRepository.GetById(FireExtinguisherControl.ProviderId);
     originalFireExtinguisherControl.ControlDate    = FireExtinguisherControl.ControlDate;
     originalFireExtinguisherControl.ExpirationDate = FireExtinguisherControl.ExpirationDate;
 }
예제 #2
0
        public FireExtinguisherControl CreateFireExtinguisherControl(ControlRequest FireExtinguisherControl)
        {
            var entityToInsert = new FireExtinguisherControl()
            {
            };

            MergeFireExtinguisherControl(entityToInsert, FireExtinguisherControl);
            FireExtinguisherControlRepository.Insert(entityToInsert);
            return(entityToInsert);
        }
예제 #3
0
 public FireExtinguisherControl UpdateFireExtinguisherControl(FireExtinguisherControl originalFireExtinguisherControl, ControlRequest FireExtinguisherControl)
 {
     this.MergeFireExtinguisherControl(originalFireExtinguisherControl, FireExtinguisherControl);
     FireExtinguisherControlRepository.Update(originalFireExtinguisherControl);
     return(originalFireExtinguisherControl);
 }