internal void Update(Instructor_Promocion parent) { // if we're not dirty then don't update the database if (!this.IsDirty) { return; } OidInstructorPromocion = parent.Oid; OidInstructor = parent.OidInstructor; try { ValidationRules.CheckRules(); if (!IsValid) { throw new iQValidationException(moleQule.Library.Resources.Messages.GENERIC_VALIDATION_ERROR); } Submodulo_Instructor_PromocionRecord obj = parent.Session().Get <Submodulo_Instructor_PromocionRecord>(Oid); obj.CopyValues(this.Base.Record); parent.Session().Update(obj); } catch (Exception ex) { iQExceptionHandler.TreatException(ex); } MarkOld(); }
public virtual void CopyValues(Submodulo_Instructor_PromocionRecord source) { if (source == null) { return; } Oid = source.Oid; _oid_submodulo = source.OidSubmodulo; _oid_instructor = source.OidInstructor; _prioridad = source.Prioridad; _oid_promocion = source.OidPromocion; _oid_instructor_promocion = source.OidInstructorPromocion; }