internal void CopyValues(IDataReader source) { if (source == null) { return; } _record.CopyValues(source); _precio_compra = Format.DataReader.GetDecimal(source, "PRECIO_COMPRA"); _precio_venta = Format.DataReader.GetDecimal(source, "PRECIO_VENTA"); _ayuda = Format.DataReader.GetDecimal(source, "AYUDA"); _coste = Format.DataReader.GetDecimal(source, "COSTE"); _stock = Format.DataReader.GetDecimal(source, "STOCK"); _n_albaran = Format.DataReader.GetString(source, "N_ALBARAN"); }
internal void Update(Expedient parent) { // if we're not dirty then don't update the database if (!this.IsDirty) { return; } _base.Record.OidExpediente = parent.Oid; try { SessionCode = parent.SessionCode; CabezaRecord obj = Session().Get <CabezaRecord>(Oid); obj.CopyValues(this._base.Record); Session().Update(obj); } catch (Exception ex) { iQExceptionHandler.TreatException(ex); } MarkOld(); }