Skip to main content
Solved

Sales Order API

  • October 4, 2023
  • 1 reply
  • 149 views

Forum|alt.badge.img

Hi,

I’m using the endpoint of Acumatica to create a SO but, when I use this  code the order quantity is set to 0. I need to put this field disable because another field is filling it. 

 protected virtual void _(Events.RowSelected<SOLine> e)
{
PXUIFieldAttribute.SetEnabled<SOLine.orderQty>(e.Cache, e.Row, false);
}

Thank,

EV

Best answer by Django

I’m not sure what your question is. Do you want to ignore what someone using the endpoint puts into the OrderQty field?

In your graph code, if you need different logic based on whether someone is accessing the graph via the API or not, you can look at the PXGraph.IsContractBasedAPI boolean.

1 reply

Forum|alt.badge.img+7
  • Captain II
  • Answer
  • October 4, 2023

I’m not sure what your question is. Do you want to ignore what someone using the endpoint puts into the OrderQty field?

In your graph code, if you need different logic based on whether someone is accessing the graph via the API or not, you can look at the PXGraph.IsContractBasedAPI boolean.