View source | View content page | Page history | Printable version   
Toolbox
Main Page
Upload file
What links here
Recent changes
Help

PDF Books
Show collection (0 pages)
Collections help

Search

Projects:Reinvoice/Technical Specification

Contents

Introduction

In this document are described all the developments needed to create a massive invoice process to generate sales invoices from re-invoicing purchase invoices.

Module Definition

Process Definition

Two processes have been created:

Re-invoice process

Process definition

Create invoices

Process definition

OB.OBREINV = OB.OBREINV || {};

OB.OBREINV.Process = {

createInvoices: function (params, view) {
  params.action = 'PROCESS';
  params.actionHandler = 'com.openbravo.gps.invoicingprocessbase.process.BaseProcessHandler';
  params.adTabId = '3A35F9481CD14EAC86ACF6C7E756A9A4';
  params.processId = '12FFAFDAF219415B8BD2303C337483D0';
  params.vadidate = function (row) {
    // Blocked invoices cannot be selected
    //if (row.oBSCNTRInvoiceType === 'B') {
      //return OB.I18N.getLabel('OBINBS_BlockedNoPossibleInvoice');
    //}
    return false;
  };
  OB.OBINBS.Process.execute(params, view);
 }
};

The objective of this js is to initialize some parameters that will be used by BaseProcessHandler.

Process parameters

Modified tables and windows

Temporary sales invoice proposal

Add a column in C_INVOICE table:

Add a field linked to the defined column above in Temporary sales invoice proposal window:

Menu entries

Created a menu entry linked to the process Re-invoicing

Dataset

Java artifacts

ReinvoiceComponentProvider

Just to register the component ob-reinvoice-multirecordprocess.js.

ReinvoiceDao

Data access object to centralize all the DB transactions.

ReinvoiceProcess

ReInvoiceProcess extends BaseInvoiceProcess and overrides two methods:

Notice that this class is not defined in process definition but in Invoicing configuration window. The reason is that the BaseProcessHandler manages all the requests and execute the instance of the java class of process to be executed, ReinvoiceProcess in this case.

Retrieved from "http://wiki.openbravo.com/wiki/Projects:Reinvoice/Technical_Specification"

This page has been accessed 592 times. This page was last modified on 22 April 2014, at 16:56. Content is available under Creative Commons Attribution-ShareAlike 2.5 Spain License.