internal void Update(PlantillaExamen parent) { // if we're not dirty then don't update the database if (!this.IsDirty) { return; } OidPlantilla = parent.Oid; try { ValidationRules.CheckRules(); if (!IsValid) { throw new iQValidationException(moleQule.Library.Resources.Messages.GENERIC_VALIDATION_ERROR); } Preguntas_PlantillaRecord obj = parent.Session().Get <Preguntas_PlantillaRecord>(Oid); obj.CopyValues(this.Base.Record); parent.Session().Update(obj); } catch (Exception ex) { iQExceptionHandler.TreatException(ex); } MarkOld(); }
public virtual void CopyValues(Preguntas_PlantillaRecord source) { if (source == null) { return; } Oid = source.Oid; _oid_plantilla = source.OidPlantilla; _oid_submodulo = source.OidSubmodulo; _n_preguntas = source.NPreguntas; _oid_tema = source.OidTema; }