Skip to main content
Question

Custom Field - Customer Order Header


Forum|alt.badge.img+1
  • Do Gooder (Customer)
  • 2 replies

Hi All,

Is it possible to have a Custom Field added to the Customer Order header that remains editable after an order line has been invoiced? As in, the Customer Order is not under the Planned or Released status? My current issue is that we cannot edit the custom field once the Customer Order is past the Planned/Released status. 

 

Thank you!

8 replies

Forum|alt.badge.img+8
  • Hero (Employee)
  • 59 replies
  • March 25, 2023

Hi.

 

I’ve tried this configuration and I’m afraid the behavior you want to achieve is not possible. I created the custom field “External Code” and it is possible to update it before status “Invoiced/Closed”. Example below:

 

 

But if I try to update “External Code” in status “Invoiced/Closed” I get an error:

 

 

The entity CustomerOrder probably has a validation that prevents updates on any attributes when the state is “Invoiced/Closed”.

 

Here is what the debug console shows:

 

 

Payload:

 

Even if you handle this with some kind of Command in the form that invokes a Workflow:

https://docs.ifs.com/techdocs/23r1/040_tailoring/225_configuration/200_client_configurations/300_commands/#adding_an_executeworkflow_type_command

 

you will have to use a Projection Delegate action to update the CustomerOrder which will fail in the same way as the form does because in reality you are using the same endpoint to PATCH the resource.

 

I think the only way to go here is to make a small development that will disable this validation for all custom fields. The section you would want to modify is the one below:

 

 

You could include in the exception fields all attributes that start by “CF$_”.

 

I made a small a quick/dirty change to exclude from validation the field CF$_EXTERNAL_CODE….

 

tested again the update and this time it worked perfectly:

 

 

Unless someone comes with a better alternative, I think you may go this way. The modification is not too invasive on core code and should not be a problem to stay Evergreen (apply SU and RU frequently).

 

Regards.

Gonzalo.

 


 


Forum|alt.badge.img+8
  • Sidekick (Customer)
  • 56 replies
  • March 27, 2023

Hello Gonzalo,

I read your conversation and I have same case in my site,

Is this way safe and does not cause any issue in another page or in another step?

Thanks.


Forum|alt.badge.img+8
  • Sidekick (Customer)
  • 56 replies
  • March 27, 2023

and what you mean here?

apply SU and RU frequently

 

thanks.


Forum|alt.badge.img+8
  • Hero (Employee)
  • 59 replies
  • March 27, 2023

Hi Norahmf.

 

The modification proposed is very small and doesn’t harm any other page or functionality. You simply modify a section of the LU code to prevent raising an error when CF$_XXXXX fields are modified and there are invoiced lines.

 

This modification should be done using the LAA partial overtake concept trying to minimize the impact on the core functionality. That way, applying a Service Update (SU) or Release Update (RU) will be simple and can be done frequently to stay Evergreen.

Best regards.
Gonzalo. 

 


Forum|alt.badge.img+8
  • Sidekick (Customer)
  • 56 replies
  • March 28, 2023

Hello Gonzalo ,

 

thanks for answer.

This modification should be done using the LAA partial overtake concept trying to minimize the impact on the core functionality. That way, applying a Service Update (SU) or Release Update (RU) will be simple and can be done frequently to stay Evergreen.

 

My plan now is update Order_Customer_Api _unpack Procedure for one time by database 

Is that enough?


Forum|alt.badge.img+8
  • Hero (Employee)
  • 59 replies
  • March 28, 2023

Hi Norahmf.

 

Yes, you only need to modify Customer_Order_API.Unpack___ in the section of code that I’ve shown above.

 

Thank you much.

Best regards.

Gonzalo.

 

 

 

 

 


Forum|alt.badge.img+8
  • Sidekick (Customer)
  • 56 replies
  • March 29, 2023

Thanks, I update this Procedure and it is working fine.


Forum|alt.badge.img+28
  • Superhero (Customer)
  • 1482 replies
  • October 29, 2023

Nice work @Gonzalo this is a good solution.  Your response should be marked as best answer - @BHern12 please mark when you have a moment.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings