public virtual void GLWorkBook_RowDeleting(PXCache sender, PXRowDeletingEventArgs e)
 {
     if (e.Row == null)
     {
         return;
     }
     PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(GLVoucherBatch.workBookID));
 }
        public virtual void GLTranCode_RowDeleting(PXCache sender, PXRowDeletingEventArgs e)
        {
            if (e.Row == null)
            {
                return;
            }

            PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(GLTranDoc.tranCode));
        }
Exemplo n.º 3
0
 protected virtual void ARStatementCycle_RowDeleting(PXCache cache, PXRowDeletingEventArgs e)
 {
     if (e.Row == null)
     {
         return;
     }
     PXSelectorAttribute.CheckAndRaiseForeignKeyException(cache, e.Row, typeof(ARStatement.statementCycleId));
     PXSelectorAttribute.CheckAndRaiseForeignKeyException(cache, e.Row, typeof(Customer.statementCycleId));
     PXSelectorAttribute.CheckAndRaiseForeignKeyException(cache, e.Row, typeof(CustomerClass.statementCycleId));
 }
        protected virtual void INPriceClass_RowDeleting(PXCache sender, PXRowDeletingEventArgs e)
        {
            INPriceClass row = e.Row as INPriceClass;

            if (row != null)
            {
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(DiscountInventoryPriceClass.inventoryPriceClassID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(InventoryItem.priceClassID));
            }
        }
Exemplo n.º 5
0
        protected virtual void ARPriceClass_RowDeleting(PXCache sender, PXRowDeletingEventArgs e)
        {
            ARPriceClass row = e.Row as ARPriceClass;

            if (row != null)
            {
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(DiscountCustomerPriceClass.customerPriceClassID));

                /* TODO: add customer(location) ref. */
            }
        }
        public virtual void GLWorkBook_RowDeleting(PXCache sender, PXRowDeletingEventArgs e)
        {
            if (e.Row == null)
            {
                return;
            }
            PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(GLVoucherBatch.workBookID));

            var row = (GLWorkBook)e.Row;

            if (IsUsedAsReversingWorkbook(sender.Graph, row.WorkBookID))
            {
                throw new PXException(Messages.DeletingWorkbookIsUsedAsReversingWorkbook);
            }
        }
        protected virtual void TaxCategory_RowDeleting(PXCache sender, PXRowDeletingEventArgs e)
        {
            TaxCategory row = e.Row as TaxCategory;

            if (row != null)
            {
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(AP.APTran.taxCategoryID), typeof(Search <AP.APTran.taxCategoryID, Where <AP.APTran.released, Equal <False> > >));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(AR.ARTran.taxCategoryID), typeof(Search <AR.ARTran.taxCategoryID, Where <AR.ARTran.released, Equal <False> > >));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(AR.ARFinCharge.taxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(CA.CASplit.taxCategoryID), typeof(Search2 <CA.CASplit.taxCategoryID, InnerJoin <CA.CAAdj,
                                                                                                                                                                           On <CA.CASplit.adjRefNbr, Equal <CA.CAAdj.adjRefNbr> > >, Where <CA.CAAdj.released, Equal <False> > >));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(EP.EPExpenseClaimDetails.taxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(PO.POLine.taxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(SO.SOLine.taxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(SO.SOOrder.freightTaxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(CR.CROpportunityProducts.taxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(IN.INItemClass.taxCategoryID));
                PXSelectorAttribute.CheckAndRaiseForeignKeyException(sender, e.Row, typeof(IN.InventoryItem.taxCategoryID));
            }
        }