How to select Prepare Document Action on Invoice ?

560 views
Skip to first unread message

USER

unread,
Aug 9, 2016, 5:28:22 AM8/9/16
to iDempiere
Hi,
We need to implement the following flow for manual sales invoices :
1- User 1 creates manually an invoice with Draft status (Default Status)
2- User 1 sets invoice status manually to "In Progress". When invoice is in draft status, document action available are Complete or Void.
3- User 2 select "In Progress" invoices and validates them one by one (Document Action = Complete)

Steps 1 and 3 are standard behaviours. But do you have any ideas to achieve step 2 ?
Thanks for your help,

raouf

unread,
Aug 9, 2016, 12:25:06 PM8/9/16
to idem...@googlegroups.com

Hi,

1. You can use a custom Invoice Window with filter DocStatus='IP', that you can list only Invoices with 'IP' Status and then you can validate them one by one.

2. You can create a new form that you list invoices by status parameter by default 'IP' after you select your invoices and you process a DocAction Complete.

Br,

Raouf

--
You received this message because you are subscribed to the Google Groups "iDempiere" group.
To unsubscribe from this group and stop receiving emails from it, send an email to idempiere+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/idempiere/3d811025-20c9-4e08-b27a-6d548df09885%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Victor Suárez

unread,
Aug 9, 2016, 4:42:55 PM8/9/16
to iDempiere
Do you have tried with Workflow?

USER

unread,
Aug 10, 2016, 3:34:55 AM8/10/16
to iDempiere
Hi,
The description of my requirement was maybe not clear enough :
We want to manually set invoice status to "In Progress". To do this we click on Document Action button. But when an invoice is draft status only possible choice in action list is "Complete" and "Void". However the "Prepare" action that will set Invoice to "In Progress" is defined in standard "Process Invoice" workflow. Any idea ?
Regards

Anozi Mada

unread,
Aug 10, 2016, 4:33:50 AM8/10/16
to iDempiere
You have to create a new Invoice model class that implements DocOptions interface if you want to manipulate the valid actions.

I don't really know about your use case but another approach is to just use workflow approval. So User 1 create and complete the Invoice, but the workflow will be suspended for approval, and the doc status will be In Progress. Then User 2 validate the Invoice by approving the document and the status will automatically change to completed and the facts will be posted.

Regards,
Anozi Mada

raouf

unread,
Aug 10, 2016, 4:55:49 AM8/10/16
to idem...@googlegroups.com

Hi,

another idea, look at org.compiere.process.DocumentEngine class and you can add your use case on getValidActions method

example :

/********************
 *  Invoice
 */
else if (AD_Table_ID == MInvoice.Table_ID)
    {
        if (docStatus.equals(DocumentEngine.STATUS_Drafted)
            || docStatus.equals(DocumentEngine.STATUS_Invalid))
        {
            options[index++] = DocumentEngine.ACTION_Prepare;
        }       
        //    Complete                    ..  CO
        else if (docStatus.equals(DocumentEngine.STATUS_Completed))
            {
                if (periodOpen) {
                    options[index++] = DocumentEngine.ACTION_Reverse_Correct;
                }
                options[index++] = DocumentEngine.ACTION_Reverse_Accrual;
            }
    }


BR,

Raouf

--
You received this message because you are subscribed to the Google Groups "iDempiere" group.
To unsubscribe from this group and stop receiving emails from it, send an email to idempiere+...@googlegroups.com.

USER

unread,
Aug 10, 2016, 9:21:08 AM8/10/16
to iDempiere
Thanks,
I'll have a look at this.
Regards

virat varma

unread,
Jun 4, 2018, 3:11:15 AM6/4/18
to iDempiere

    Hi,

How do i change Document Action.
    How do i add reactive,void to Document Action

Could any plz help me
    
 

Carlos Antonio Ruiz Gomez

unread,
Jun 4, 2018, 3:39:41 AM6/4/18
to idem...@googlegroups.com
You can find a solution at IDEMPIERE-3599

Regards,

Carlos Ruiz

virat varma

unread,
Jun 6, 2018, 5:52:12 AM6/6/18
to idem...@googlegroups.com

Hi,


How can i get Void & Reactive in Requisition Dialog Box.

Could u plz give me the Instructions.



Thanks&Regards

Carlos Antonio Ruiz Gómez

unread,
Jun 6, 2018, 6:05:41 AM6/6/18
to iDempiere
Hi Virat, I already answered above

Please stop cross-posting the same question in many threads - if you have issues implementing the suggested solution, better be specific about the problem you're finding.

Regards,

Carlos Ruiz

virat varma

unread,
Jun 13, 2018, 12:57:49 AM6/13/18
to idem...@googlegroups.com
Any one please help me.
How to resolve the Issue.
Jun 13, 2018 9:44:38 AM org.compiere.process.SvrProcess process
SEVERE: ERROR: syntax error at or near "CHAR"
  Position: 59 - ALTER TABLE C_ContactActivity ADD Schedule Meeting CHAR(20) DEFAULT NULL 
UserError: ERROR: syntax error at or near "CHAR"
  Position: 59 - ALTER TABLE C_ContactActivity ADD Schedule Meeting CHAR(20) DEFAULT NULL 
at org.compiere.process.ColumnSync.doIt(ColumnSync.java:167)
at org.compiere.process.SvrProcess.process(SvrProcess.java:201)
at org.compiere.process.SvrProcess.startProcess(SvrProcess.java:147)
at org.adempiere.util.ProcessUtil.startJavaProcess(ProcessUtil.java:172)
at org.compiere.apps.AbstractProcessCtl.startProcess(AbstractProcessCtl.java:466)
at org.compiere.apps.AbstractProcessCtl.run(AbstractProcessCtl.java:234)
at org.adempiere.webui.apps.WProcessCtl.process(WProcessCtl.java:197)
at org.adempiere.webui.apps.AbstractProcessDialog$ProcessDialogRunnable.doRun(AbstractProcessDialog.java:1083)
at org.adempiere.util.ContextRunnable.run(ContextRunnable.java:38)
at org.adempiere.webui.apps.DesktopRunnable.run(DesktopRunnable.java:40)
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.util.concurrent.FutureTask.run(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)



--
You received this message because you are subscribed to the Google Groups "iDempiere" group.
To unsubscribe from this group and stop receiving emails from it, send an email to idempiere+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/idempiere/47edcb5b-99ac-4649-8d3c-3328e00282af%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Hi,




Thanks&Regards

Orlando Curieles

unread,
Jun 13, 2018, 1:03:37 AM6/13/18
to iDempiere
The system element can't contain blank spaces, use the element name Schedule_Meeting

 Regards
To unsubscribe from this group and stop receiving emails from it, send an email to idempiere+...@googlegroups.com.



--
Hi,




Thanks&Regards

virat varma

unread,
Jun 13, 2018, 6:00:55 AM6/13/18
to idem...@googlegroups.com

Hi,

Thanks for Your Reply

I create a column in C_ContactActivity and also created a Report & Process for it.
Finally i add to Activity Tab. 
But in the tab field not displaying.
Could you please help me.


Thanks&Regards
Reply all
Reply to author
Forward
0 new messages