You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ofbiz.apache.org by "Nicolas Malin (JIRA)" <ji...@apache.org> on 2014/10/02 22:53:33 UTC

[jira] [Commented] (OFBIZ-5766) Error when adding/modifying a task to a Production Run - field type error

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

Nicolas Malin commented on OFBIZ-5766:
--------------------------------------

Guillaume,

I confirm the problem but I think your correction isn't raise the real problem.
I find that the conversion from Double to BigDecimal has been commited by David E. Jones on the revision 731851 
{quote}
Manual merge of typecheckcleanup200810 branch as of rev 731346 in that branch, resolved all conflicts; with this BigDecimal is not the native type for many entity fields and is used for many calculations; some work is still needed in certain areas of the project but this covers the most critical ones; thanks especially to Scott for his work on this
{quote}

But the problem is that most of service like "addProductionRunRoutingTask" call createWorkEffort where the attribute define by 
{code|xml}
    <service name="createWorkEffort" default-entity-name="WorkEffort" engine="simple" ...
        <auto-attributes mode="INOUT" include="pk" optional="true"/>
    </service>
{code}
Who generate an entry for Double and not BigDecimal

We have many solution, now we need to choose the best :
* Convert all service use estimatedSetupMillis and estimatedMilliSeconds from BigDecimal to Double, in other word revert a part of the commit 731851
* Extend WorkEffort service to take estimatedSetupMillis and estimatedMilliSeconds as BigDecimal
* Authorize the automatic conversion  BigDecimal to Double

Any suggest ?

> Error when adding/modifying a task to a Production Run - field type error
> -------------------------------------------------------------------------
>
>                 Key: OFBIZ-5766
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-5766
>             Project: OFBiz
>          Issue Type: Bug
>          Components: manufacturing
>    Affects Versions: Release Branch 13.07, Trunk
>            Reporter: Guillaume Sigoigne
>            Assignee: Nicolas Malin
>            Priority: Trivial
>         Attachments: Add-Task-To-Production-Run-13.07.patch, Add-Task-To-Production-Run-trunk.patch
>
>
> You select a production run, then you click on "Task" tab to list tasks included in the production run.
> You are not able to add a new task or modify any of already included tasks because of field type error.
> Following events and services are waiting estimatedMilliseconds and estimatedSetupMillis as BigDecimal instead of Double.
> Events : 
> ProductionRunSimpleEvents.editProductionRunRoutingTask
> ProductionRunSimpleEvents.addProductionRunRoutinsTask
> Services : 
> services_production_run.addProductionRunRoutingTask
> services_production_run.checkUpdatePrunRoutingTask
> Add-Task-To-Production-Run (13.07 and trunk releases) change fields type from BigDecimal to Double.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)