Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0003463Openbravo ERP05. Production managementpublic2008-02-14 11:482011-02-04 09:15
user71 
rmorley 
normalminoralways
acknowledgedopen 
5
 
pi 
Core
No
0003463: Work Effort: More Default values
Version 2.35MP1
In the window / TAB "Work Effort / Production Run", the fields "Donequantity" and "Cost Center Use" must catch default values.

"Donequantity" = "Required Quantity" in the same tab
"Cost Center Use" = "Cost Center Use Time" of the "Work Requirement/Operation" selected.

It'll be very usefull in this way.

In my production instalation, I'va implemented this Feature. To do this, I've made the next changes:

File "org\openbravo\erpCommon\ad_callouts\SL_ProductionPlan_WRPhase_data.xsql":
REPLACE THE NEXT SELECT:

      SELECT (wrp.QUANTITY - wrp.DONEQUANTITY) AS neededqty, w.secondaryunit, w.conversionrate, ccv.MA_CostCenter_Version_ID
      FROM MA_WRPhase wrp, MA_WorkRequirement w, MA_Process p
           LEFT JOIN MA_CostCenter cc ON p.MA_COSTCENTER_ID = cc.MA_CostCenter_Id
           LEFT JOIN (SELECT MA_COSTCENTER_VERSION_ID,MA_COstcenter_ID
                      FROM MA_CostCenter_Version maccv2
                      WHERE validfrom= (SELECT MAX(validfrom)
                                        FROM MA_COSTCENTER_VERSION maccv3
                                        WHERE maccv2.Ma_Costcenter_id = maccv3.Ma_Costcenter_id
                                          AND validfrom < (SELECT pr.Movementdate
                                                           FROM M_Production pr
                                                           WHERE pr.M_Production_ID = ?))) ccv ON cc.MA_Costcenter_ID = ccv.MA_COstCenter_ID
      WHERE wrp.MA_WRPhase_ID = ?
      AND wrp.MA_Process_ID = p.MA_Process_ID
      AND wrp.MA_WorkRequirement_ID = w.MA_WorkRequirement_ID

BY (INCLUDE THE COLUMN ",wrp.costcenteruse"):

      SELECT (wrp.QUANTITY - wrp.DONEQUANTITY) AS neededqty, w.secondaryunit, w.conversionrate, ccv.MA_CostCenter_Version_ID,wrp.costcenteruse
      FROM MA_WRPhase wrp, MA_WorkRequirement w, MA_Process p
           LEFT JOIN MA_CostCenter cc ON p.MA_COSTCENTER_ID = cc.MA_CostCenter_Id
           LEFT JOIN (SELECT MA_COSTCENTER_VERSION_ID,MA_COstcenter_ID
                      FROM MA_CostCenter_Version maccv2
                      WHERE validfrom= (SELECT MAX(validfrom)
                                        FROM MA_COSTCENTER_VERSION maccv3
                                        WHERE maccv2.Ma_Costcenter_id = maccv3.Ma_Costcenter_id
                                          AND validfrom < (SELECT pr.Movementdate
                                                           FROM M_Production pr
                                                           WHERE pr.M_Production_ID = ?))) ccv ON cc.MA_Costcenter_ID = ccv.MA_COstCenter_ID
      WHERE wrp.MA_WRPhase_ID = ?
      AND wrp.MA_Process_ID = p.MA_Process_ID
      AND wrp.MA_WorkRequirement_ID = w.MA_WorkRequirement_ID

AND IN File "org\openbravo\erpCommon\ad_callouts\SL_ProductionPlan_WRPhase.java":
INCLUDE THE NEW ASSIGNEMENT:

//BEG MMARQUEZ 14/02/2008 Rellenamos tambien los campos Uso del CC y Cantidad realizada
resultado.append("new Array(\"inpproductionqty\", \"" + strNeededQuantity + "\"),\n");
resultado.append("new Array(\"inpmaCostcenteruse\", \"" + data[0].costcenteruse + "\"),\n");
//END MMARQUEZ 14/02/2008

Anyways, I've attached the files.
ReleaseCandidate, Usability
Issue History
2008-07-01 18:10pjuvaraDescription Updated
2008-07-01 18:10pjuvaraSteps to Reproduce Updated
2008-07-01 18:10pjuvaraStatusnew => scheduled
2008-07-01 18:10pjuvaraProjectionnone => @20@
2008-07-01 18:10pjuvaraTarget Version => 2.60
2008-07-01 18:11pjuvaraTag Attached: ReleaseCandidate
2008-11-16 11:44pjuvaraTag Attached: Usability
2008-11-21 16:45pjuvaraStatusscheduled => acknowledged
2008-11-21 17:05pjuvaraTarget Version2.60 => trunk
2008-11-25 17:16rafarodaAssigned Touser71 => pjuvara
2008-12-10 10:33pjuvaraNote Added: 0011119
2011-02-04 09:15jpabloaeAssigned Topjuvara => rmorley

Notes
(0007052)
user71   
2005-06-01 00:00   
(edited on: 2008-06-12 09:44)
This bug was originally reported in SourceForge bug tracker and then migrated to Mantis.

You can see the original bug report in:
https://sourceforge.net/support/tracker.php?aid=1893473 [^]
(0003947)
user71   
2008-02-14 11:48   
(edited on: 2008-06-12 09:26)
Logged In: YES
user_id=1790723
Originator: YES

File Added: SL_ProductionPlan_WRPhase_data.xsql
(0011119)
pjuvara   
2008-12-10 10:33   
The issue is in:
Reload Current Page Production Management || Transactions || Work Effort || Work Effort >> Production Run