Part on the fly - BPM Marking OrderRel/PartDtl unfirm - Part on Planning Workbench

Hey group,

We want the order release to default to an “unfirm” status when we create a new order line.

I have this in-transaction directive on OrderRel:

//default release and PartDtl to unfirm

foreach(var ttOrderRel_xRow in (from ttOrderRel_Row in ttOrderRel
  where ttOrderRel_Row.Company == Session.CompanyID && 
  string.Equals(ttOrderRel_Row.RowMod, IceRow.ROWSTATE_ADDED, StringComparison.OrdinalIgnoreCase)
select ttOrderRel_Row))
{
  ttOrderRel_xRow.FirmRelease = false;

  var PartDtl_xRow = (from PartDtl_Row in Db.PartDtl
    where PartDtl_Row.Company == ttOrderRel_xRow.Company &&
    PartDtl_Row.OrderNum == ttOrderRel_xRow.OrderNum &&
    PartDtl_Row.OrderLine == ttOrderRel_xRow.OrderLine &&
    PartDtl_Row.OrderRelNum == ttOrderRel_xRow.OrderRelNum 
    select PartDtl_Row).FirstOrDefault();
    
    if (PartDtl_xRow != null)
    {
      PartDtl_xRow.FirmRelease = false;
    }
}

Db.Validate();

A query shows that it does set both OrderRel.FirmRelease and PartDtl.FirmRelease to false.

But when I run MRP and then Planning Workbench I get suggestions for POTF parts.

If I go into the order and cycle FirmRelease on and back to off, run MRP and then PWB, the suggestion is gone.

I have one development environment where this tests okay, but all the others do not. All on 10.2.200.18.

I tried a standard transaction and the sales order BO in code to set OrderRel.FirmRelease (RowMod = “U”) to false and then update. It did set OrderRel.FirmRelease to false but it did not set PartDtl.FirmRelease to false.

What other setting am I missing that MRP would be looking at? Maybe a different tack?

Thanks,

Joe

Hi @jdtrent
what is missing in your BPM is the timing, i.e. at this BPM in-transaction phase, PartDtl record has not been created yet, so if i were you i will try to trigger your code at post-process method Master update on Sales order BO, this is means that you need to invoke the update again and pass the changed parameter to it, also check the OrderRel RowMod status at this stage, you might need to remove the condition from the code if it has no value after running the Base script alternatively you can use the widget to set this field on OrderRel and the master update method will take care of PartDtl record.

Hi all,

We have the same issue on the above topic. We have an unfirm release line on the Sales Order Screen but line items keeps appearing in Planning Workbench. Is there a fix solution to this issue?

Thanks.

Did you ever workout a solution for this?

Thanks.

Neil,

Surely we did but I do not recall it now.

Sorry.

Joe