[ 
https://issues.apache.org/jira/browse/OFBIZ-13223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17945068#comment-17945068
 ] 

Nicolas Malin commented on OFBIZ-13223:
---------------------------------------

Hey thanks [~yashwant.dhakad] for this spot.

I had another vision on this pb, can you try my patch to see if it's ok
{code:xml}
Index: applications/manufacturing/widget/manufacturing/JobshopScreens.xml
===================================================================
diff --git a/applications/manufacturing/widget/manufacturing/JobshopScreens.xml 
b/applications/manufacturing/widget/manufacturing/JobshopScreens.xml
--- a/applications/manufacturing/widget/manufacturing/JobshopScreens.xml        
(revision 1cfef45f89d2714fef1a94729fa48f554be75c6e)
+++ b/applications/manufacturing/widget/manufacturing/JobshopScreens.xml        
(date 1725979880400)
@@ -227,7 +227,7 @@
                             </condition>
                             <widgets>
                                 <screenlet 
title="${uiLabelMap.ManufacturingMandatoryWorkEfforts}">
-                                    <include-form name="MandatoryWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
+                                    <include-grid name="MandatoryWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
                                 </screenlet>
                             </widgets>
                         </section>
@@ -237,7 +237,7 @@
                             </condition>
                             <widgets>
                                 <screenlet 
title="${uiLabelMap.ManufacturingDependentWorkEfforts}">
-                                    <include-form name="DependentWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
+                                    <include-grid name="DependentWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
                                 </screenlet>
                             </widgets>
                         </section>
@@ -346,7 +346,7 @@
                 <decorator-screen name="CommonJobshopDecorator" 
location="${parameters.commonJobshopDecorator}">
                     <decorator-section name="body">
                         <screenlet 
title="${uiLabelMap.ManufacturingPrecedingProductionRun}">
-                            <include-form name="MandatoryWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
+                            <include-grid name="MandatoryWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>
                         </screenlet>
                         <screenlet 
title="${uiLabelMap.ManufacturingSucceedingProductionRun}">
                             <include-form name="DependentWorkEfforts" 
location="component://manufacturing/widget/manufacturing/ProductionRunForms.xml"/>

{code}
I image when DependentWorkEfforts and MandatoryWorkEfforts form move to grid, 
all link to them wasn't propagate correctly.

 

Nicolas

> Error rendering included form "MandatoryWorkEfforts" when approving parent 
> production run
> -----------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-13223
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-13223
>             Project: OFBiz
>          Issue Type: Bug
>          Components: manufacturing
>    Affects Versions: Upcoming Branch, 24.09.01
>            Reporter: Yashwant Dhakad
>            Assignee: Nicolas Malin
>            Priority: Minor
>         Attachments: 
> OFBiz-Manufacturing-Manager-Production-Run-Declaration-04-16-2025_01_29_PM.png
>
>
> Description:
> When attempting to approve a main production run that has dependent 
> production runs, an error is thrown, and the UI displays an error message 
> instead of rendering the "MandatoryWorkEfforts" section. This prevents the 
> user from proceeding further with the production run process.
> Steps to Reproduce:
> * Create a production run with dependent production components.
> * Navigate to the Production Run screen.
> * Confirm or approve the main job (production run).
> * Observe the error in the ManufacturingMandatoryWorkEfforts section.
> Expected Result: The "MandatoryWorkEfforts" form should load properly with 
> required data.
> Actual Result: An error is shown:
> ERROR MESSAGE
> java.lang.RuntimeException: Error rendering included form named 
> [MandatoryWorkEfforts] at location 
> [component://manufacturing/widget/manufacturing/ProductionRunForms.xml]: 
> java.lang.NullPointerException: Cannot invoke 
> "org.w3c.dom.Element.getAttribute(String)" because "formElement" is 
> nulljava.lang.NullPointerException: Cannot invoke 
> "org.w3c.dom.Element.getAttribute(String)" because "formElement" is null



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to