[jira] Created: (OFBIZ-1481) Implement an automatic GL posting service triggered when an actual cost record is created for a work effort

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[jira] Created: (OFBIZ-1481) Implement an automatic GL posting service triggered when an actual cost record is created for a work effort

Nicolas Malin (Jira)
Implement an automatic GL posting service triggered when an actual cost record is created for a work effort
-----------------------------------------------------------------------------------------------------------

                 Key: OFBIZ-1481
                 URL: https://issues.apache.org/jira/browse/OFBIZ-1481
             Project: OFBiz
          Issue Type: Sub-task
          Components: accounting
    Affects Versions: SVN trunk
            Reporter: Jacopo Cappellato


Name of the service: "createAcctgTransForWorkEffortCost" or similar
Service definition:
    <service name="createAcctgTransForWorkEffortCost" engine="simple" auth="true"
        location="org/ofbiz/accounting/ledger/GeneralLedgerServices.xml" invoke="createAcctgTransForWorkEffortCost">
        <description>Create an accounting transaction for cost record created for a work effort</description>
        <attribute name="workEffortId" type="String" mode="IN" optional="false"/>
        <attribute name="costComponentId" type="String" mode="IN" optional="false"/>
        <attribute name="acctgTransId" type="String" mode="OUT" optional="true"/>
    </service>

1) get the CostComponent with id parameters.costComponentId and use its fields for the origAmount and origCurrencyUomId: cost and costUomId
2) get the CostComponentCalc record associated to the CostComponent and use its fields for the debit/credit account types: costGlAccountTypeId is for the credit, offsettingGlAccountTypeId is for the debit (if this is empty, use "WIP_INVENTORY")
3) get the WorkEffort with id parameters.workEffortId and get the Facility associated to it: use the Facility.ownerPartyId for the organizationPartyId
4) as we did in OFBIZ-1474, if (WorkEffort.workEffortTypeId == PROD_ORDER_TASK and WorkEffort.workEffortParentId is not empty) then select the first record from WorkEffortGoodStandard where (workEffortId == WorkEffort.workEffortParentId and workEffortGoodStdTypeId == "PRUN_PROD_DELIV")
5) use the WorkEffortGoodStandard.productId field of this record to fill the productId of the *Debit* Account Trans entry.
6) call the createAcctgTransAndEntries service passing the list with the two debit/credit entries, workEffortId = parameters.workEffortId, acctgTransTypeId = "MANUFACTURING"

Please add information about this new service to the following wiki page:

http://docs.ofbiz.org/x/Qw0


--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Commented: (OFBIZ-1481) Implement an automatic GL posting service triggered when an actual cost record is created for a work effort

Nicolas Malin (Jira)

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

Jacopo Cappellato commented on OFBIZ-1481:
------------------------------------------

the eca rule that will trigger the service is:

    <eca service="createWorkEffortInventoryProduced" event="commit">
        <condition field-name="workEffortId" operator="is-not-empty"/>
        <condition field-name="costComponentTypeId" operator="not-equals" value="ACTUAL_MAT_COST"/>
        <action service="createAcctgTransForWorkEffortCost" mode="sync"/>
    </eca>

Please include it in the patch.


> Implement an automatic GL posting service triggered when an actual cost record is created for a work effort
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1481
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1481
>             Project: OFBiz
>          Issue Type: Sub-task
>          Components: accounting
>    Affects Versions: SVN trunk
>            Reporter: Jacopo Cappellato
>
> Name of the service: "createAcctgTransForWorkEffortCost" or similar
> Service definition:
>     <service name="createAcctgTransForWorkEffortCost" engine="simple" auth="true"
>         location="org/ofbiz/accounting/ledger/GeneralLedgerServices.xml" invoke="createAcctgTransForWorkEffortCost">
>         <description>Create an accounting transaction for cost record created for a work effort</description>
>         <attribute name="workEffortId" type="String" mode="IN" optional="false"/>
>         <attribute name="costComponentId" type="String" mode="IN" optional="false"/>
>         <attribute name="acctgTransId" type="String" mode="OUT" optional="true"/>
>     </service>
> 1) get the CostComponent with id parameters.costComponentId and use its fields for the origAmount and origCurrencyUomId: cost and costUomId
> 2) get the CostComponentCalc record associated to the CostComponent and use its fields for the debit/credit account types: costGlAccountTypeId is for the credit, offsettingGlAccountTypeId is for the debit (if this is empty, use "WIP_INVENTORY")
> 3) get the WorkEffort with id parameters.workEffortId and get the Facility associated to it: use the Facility.ownerPartyId for the organizationPartyId
> 4) as we did in OFBIZ-1474, if (WorkEffort.workEffortTypeId == PROD_ORDER_TASK and WorkEffort.workEffortParentId is not empty) then select the first record from WorkEffortGoodStandard where (workEffortId == WorkEffort.workEffortParentId and workEffortGoodStdTypeId == "PRUN_PROD_DELIV")
> 5) use the WorkEffortGoodStandard.productId field of this record to fill the productId of the *Debit* Account Trans entry.
> 6) call the createAcctgTransAndEntries service passing the list with the two debit/credit entries, workEffortId = parameters.workEffortId, acctgTransTypeId = "MANUFACTURING"
> Please add information about this new service to the following wiki page:
> http://docs.ofbiz.org/x/Qw0

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Updated: (OFBIZ-1481) Implement an automatic GL posting service triggered when an actual cost record is created for a work effort

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-1481?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Brajesh Patel updated OFBIZ-1481:
---------------------------------

    Attachment: Actual_cost_record_is_created_for_a_ WorkEffort.patch

Implement an automatic GL posting service triggered when an actual cost record is created for a work effort.


> Implement an automatic GL posting service triggered when an actual cost record is created for a work effort
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1481
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1481
>             Project: OFBiz
>          Issue Type: Sub-task
>          Components: accounting
>    Affects Versions: SVN trunk
>            Reporter: Jacopo Cappellato
>         Attachments: Actual_cost_record_is_created_for_a_ WorkEffort.patch
>
>
> Name of the service: "createAcctgTransForWorkEffortCost" or similar
> Service definition:
>     <service name="createAcctgTransForWorkEffortCost" engine="simple" auth="true"
>         location="org/ofbiz/accounting/ledger/GeneralLedgerServices.xml" invoke="createAcctgTransForWorkEffortCost">
>         <description>Create an accounting transaction for cost record created for a work effort</description>
>         <attribute name="workEffortId" type="String" mode="IN" optional="false"/>
>         <attribute name="costComponentId" type="String" mode="IN" optional="false"/>
>         <attribute name="acctgTransId" type="String" mode="OUT" optional="true"/>
>     </service>
> 1) get the CostComponent with id parameters.costComponentId and use its fields for the origAmount and origCurrencyUomId: cost and costUomId
> 2) get the CostComponentCalc record associated to the CostComponent and use its fields for the debit/credit account types: costGlAccountTypeId is for the credit, offsettingGlAccountTypeId is for the debit (if this is empty, use "WIP_INVENTORY")
> 3) get the WorkEffort with id parameters.workEffortId and get the Facility associated to it: use the Facility.ownerPartyId for the organizationPartyId
> 4) as we did in OFBIZ-1474, if (WorkEffort.workEffortTypeId == PROD_ORDER_TASK and WorkEffort.workEffortParentId is not empty) then select the first record from WorkEffortGoodStandard where (workEffortId == WorkEffort.workEffortParentId and workEffortGoodStdTypeId == "PRUN_PROD_DELIV")
> 5) use the WorkEffortGoodStandard.productId field of this record to fill the productId of the *Debit* Account Trans entry.
> 6) call the createAcctgTransAndEntries service passing the list with the two debit/credit entries, workEffortId = parameters.workEffortId, acctgTransTypeId = "MANUFACTURING"
> Please add information about this new service to the following wiki page:
> http://docs.ofbiz.org/x/Qw0

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Assigned: (OFBIZ-1481) Implement an automatic GL posting service triggered when an actual cost record is created for a work effort

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-1481?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Anil K Patel reassigned OFBIZ-1481:
-----------------------------------

    Assignee: Anil K Patel

> Implement an automatic GL posting service triggered when an actual cost record is created for a work effort
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1481
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1481
>             Project: OFBiz
>          Issue Type: Sub-task
>          Components: accounting
>    Affects Versions: SVN trunk
>            Reporter: Jacopo Cappellato
>            Assignee: Anil K Patel
>         Attachments: Actual_cost_record_is_created_for_a_ WorkEffort.patch
>
>
> Name of the service: "createAcctgTransForWorkEffortCost" or similar
> Service definition:
>     <service name="createAcctgTransForWorkEffortCost" engine="simple" auth="true"
>         location="org/ofbiz/accounting/ledger/GeneralLedgerServices.xml" invoke="createAcctgTransForWorkEffortCost">
>         <description>Create an accounting transaction for cost record created for a work effort</description>
>         <attribute name="workEffortId" type="String" mode="IN" optional="false"/>
>         <attribute name="costComponentId" type="String" mode="IN" optional="false"/>
>         <attribute name="acctgTransId" type="String" mode="OUT" optional="true"/>
>     </service>
> 1) get the CostComponent with id parameters.costComponentId and use its fields for the origAmount and origCurrencyUomId: cost and costUomId
> 2) get the CostComponentCalc record associated to the CostComponent and use its fields for the debit/credit account types: costGlAccountTypeId is for the credit, offsettingGlAccountTypeId is for the debit (if this is empty, use "WIP_INVENTORY")
> 3) get the WorkEffort with id parameters.workEffortId and get the Facility associated to it: use the Facility.ownerPartyId for the organizationPartyId
> 4) as we did in OFBIZ-1474, if (WorkEffort.workEffortTypeId == PROD_ORDER_TASK and WorkEffort.workEffortParentId is not empty) then select the first record from WorkEffortGoodStandard where (workEffortId == WorkEffort.workEffortParentId and workEffortGoodStdTypeId == "PRUN_PROD_DELIV")
> 5) use the WorkEffortGoodStandard.productId field of this record to fill the productId of the *Debit* Account Trans entry.
> 6) call the createAcctgTransAndEntries service passing the list with the two debit/credit entries, workEffortId = parameters.workEffortId, acctgTransTypeId = "MANUFACTURING"
> Please add information about this new service to the following wiki page:
> http://docs.ofbiz.org/x/Qw0

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply | Threaded
Open this post in threaded view
|

[jira] Closed: (OFBIZ-1481) Implement an automatic GL posting service triggered when an actual cost record is created for a work effort

Nicolas Malin (Jira)
In reply to this post by Nicolas Malin (Jira)

     [ https://issues.apache.org/jira/browse/OFBIZ-1481?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Anil K Patel closed OFBIZ-1481.
-------------------------------

    Resolution: Fixed

Thanks to Brajesh Patel and others for providing implementation. Patch is in rev#600766

> Implement an automatic GL posting service triggered when an actual cost record is created for a work effort
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: OFBIZ-1481
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-1481
>             Project: OFBiz
>          Issue Type: Sub-task
>          Components: accounting
>    Affects Versions: SVN trunk
>            Reporter: Jacopo Cappellato
>            Assignee: Anil K Patel
>         Attachments: Actual_cost_record_is_created_for_a_ WorkEffort.patch
>
>
> Name of the service: "createAcctgTransForWorkEffortCost" or similar
> Service definition:
>     <service name="createAcctgTransForWorkEffortCost" engine="simple" auth="true"
>         location="org/ofbiz/accounting/ledger/GeneralLedgerServices.xml" invoke="createAcctgTransForWorkEffortCost">
>         <description>Create an accounting transaction for cost record created for a work effort</description>
>         <attribute name="workEffortId" type="String" mode="IN" optional="false"/>
>         <attribute name="costComponentId" type="String" mode="IN" optional="false"/>
>         <attribute name="acctgTransId" type="String" mode="OUT" optional="true"/>
>     </service>
> 1) get the CostComponent with id parameters.costComponentId and use its fields for the origAmount and origCurrencyUomId: cost and costUomId
> 2) get the CostComponentCalc record associated to the CostComponent and use its fields for the debit/credit account types: costGlAccountTypeId is for the credit, offsettingGlAccountTypeId is for the debit (if this is empty, use "WIP_INVENTORY")
> 3) get the WorkEffort with id parameters.workEffortId and get the Facility associated to it: use the Facility.ownerPartyId for the organizationPartyId
> 4) as we did in OFBIZ-1474, if (WorkEffort.workEffortTypeId == PROD_ORDER_TASK and WorkEffort.workEffortParentId is not empty) then select the first record from WorkEffortGoodStandard where (workEffortId == WorkEffort.workEffortParentId and workEffortGoodStdTypeId == "PRUN_PROD_DELIV")
> 5) use the WorkEffortGoodStandard.productId field of this record to fill the productId of the *Debit* Account Trans entry.
> 6) call the createAcctgTransAndEntries service passing the list with the two debit/credit entries, workEffortId = parameters.workEffortId, acctgTransTypeId = "MANUFACTURING"
> Please add information about this new service to the following wiki page:
> http://docs.ofbiz.org/x/Qw0

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.