Exemplo n.º 1
0
 protected override bool AfterDelete(bool success)
 {
     // when we delete BOM, then set IsVerified False on Product
     VAdvantage.Model.MProduct product = new VAdvantage.Model.MProduct(GetCtx(), GetM_Product_ID(), Get_Trx());
     product.SetIsVerified(false);
     if (!product.Save())
     {
         log.SaveError("Error", "Verified not updated on Product : " + product.GetValue());
     }
     return(true);
 }
Exemplo n.º 2
0
        }       //	beforeSave

        protected override bool AfterSave(bool newRecord, bool success)
        {
            //set verified on Product as False when we change BOMType AND BOMUse
            if (newRecord || Is_ValueChanged("BOMType") || Is_ValueChanged("BOMUse") || Is_ValueChanged("IsActive"))
            {
                VAdvantage.Model.MProduct product = new VAdvantage.Model.MProduct(GetCtx(), GetM_Product_ID(), Get_Trx());
                product.SetIsVerified(false);
                if (!product.Save())
                {
                    log.SaveError("Error", "Verified not updated on Product : " + product.GetValue());
                }
            }
            return(true);
        }