示例#1
0
        internal void CopyValues(IDataReader source)
        {
            if (source == null)
            {
                return;
            }

            _record.CopyValues(source);

            _neto = Format.DataReader.GetDecimal(source, "NETO");
        }
示例#2
0
        internal void Update(IAcreedor parent)
        {
            // if we're not dirty then don't update the database
            if (!this.IsDirty)
            {
                return;
            }

            //Debe obtener la sesion del padre pq el objeto es padre a su vez
            SessionCode = parent.SessionCode;

            ValidationRules.CheckRules();

            if (!IsValid)
            {
                throw new iQValidationException(moleQule.Resources.Messages.GENERIC_VALIDATION_ERROR);
            }

            PayrollBatchRecord obj = parent.Session().Get <PayrollBatchRecord>(Oid);

            obj.CopyValues(Base.Record);
            parent.Session().Update(obj);

            UpdateAssociatedExpenses();

            MarkOld();
        }
示例#3
0
        internal void Update(PayrollBatchs parent)
        {
            // if we're not dirty then don't update the database
            if (!this.IsDirty)
            {
                return;
            }

            ValidationRules.CheckRules();

            if (!IsValid)
            {
                throw new iQValidationException(moleQule.Resources.Messages.GENERIC_VALIDATION_ERROR);
            }

            SessionCode = parent.SessionCode;
            PayrollBatchRecord obj = Session().Get <PayrollBatchRecord>(Oid);

            obj.CopyValues(Base.Record);
            Session().Update(obj);

            UpdateAssociatedExpenses();

            MarkOld();
        }
示例#4
0
        protected override void DataPortal_Update()
        {
            if (!IsDirty)
            {
                return;
            }

            PayrollBatchRecord obj = Session().Get <PayrollBatchRecord>(Oid);

            obj.CopyValues(this.Base.Record);
            Session().Update(obj);

            UpdateAssociatedExpenses();

            MarkOld();
        }
示例#5
0
        public void Update(Registro parent)
        {
            // if we're not dirty then don't update the database
            if (!this.IsDirty)
            {
                return;
            }

            ValidationRules.CheckRules();

            SessionCode = parent.SessionCode;
            PayrollBatchRecord obj = Session().Get <PayrollBatchRecord>(Oid);

            obj.CopyValues(Base.Record);
            Session().Update(obj);

            MarkOld();
        }
示例#6
0
        internal void DeleteSelf(IAcreedor parent)
        {
            // if we're not dirty then don't update the database
            if (!this.IsDirty)
            {
                return;
            }

            // if we're new then don't update the database
            if (this.IsNew)
            {
                return;
            }

            PayrollBatchRecord obj = parent.Session().Get <PayrollBatchRecord>(Oid);

            obj.CopyValues(Base.Record);

            parent.Session().Update(obj);

            Expenses.DeleteItems(obj.Oid);

            MarkNew();
        }