Account Invoicing/Billing use cases

Recurring invoice module is specially designed to avoid limitations in base  Open ERP accounting functionality provided by Tiny. It is very powerful - at the same time a little bit complex, but this is the price paid for it's capabilities.

Le's start with some use case.

ISP provider. Mail services invoicing.

We have a mail server with Postfix smtp agent and mail users preferences (domain, user name, storage quota etc.) are stored in mysql database plus Postfixadmin web interface for adding and controlling users mail preferences.

Let's say there are three different service fees per month for our customers:

  • 1 domain and 1-5 e-mail users with quota 100MB for each: 5 Eur/month
  • 1 domain and 1-5 e-mail users with quota 1GB for each: 15 Eur/month
  • 1 domain and 6-25  e-mail users with quota 100MB for each: 20 Eur/month

Our goal is to make semi automatic invoices for our customers keeping in mind an actual mail server usage of particular customer e.g. quota and mail boxes count.

To achieve the goal we are going to use Open ERP, recurring invoice module and additional module for retrieving mail users data from mail server database. The calculation will be based on users account size and e-mail boxes count for each domain got from mail server in particular period.

Open ERP installation and configuration is not subject of this paper, so let's begin using Invoicing module.

Important Note: There should be installed and correctly configured accounting, products and price lists, before any attempts to set up invoicing. Any misconfiguration in above mentioned will lead to error during invoicing.

Main steps of invoicing configuration.

First we will create a methodology on which we will base our calculations.

In this case we create an primary filter in methodology object, where we filter active domains from mail server data and manually define calculation entries. Necessary information for calculation is provided via custom OpenERP mail server data retrieval/synchronization module.  With Record filter  section we select data on which calculations will be performed, in this case there are active domains. In Calculation section we define our calculation methods and dynamic fields which later appear in invoices. These methods can be defined manually or via Open ERP GUI fields, and can be changed later. This defined methodology object then can be used by Service object later.

After methodology is defined we are going to define our services in Services object.

In services object we define how invoicing will be performed. There we choose price lists, analytic journals and accounts and set up invoicing period as well.  Service object is not tied to particular partner – let's say it's is invoicing scheme for particular service or product. Later we choose methodology earlier defined for our mail server. Here we also define Work Team which is necessary for debugging and warning messages created by Invoicing modules. If this group is not set, then all warning and error messages appear only for admin user requests. Those messages are very important to notice, to correct errors in invoicing process.

To create invoices for particular partner we go to Agreement object.

There we create an Agreement for each our mail server client (Partner in terms of Open ERP),  choose defined service, enter Agreement number etc. Here we choose analytic account for particular partner too.  In this object we define also common agreement properties – start date, end date prolongation and other.  In Invoice log section we can see current state for each invoice. If all rules previously created are correct the here we shouldn't see any error state.

There should be also analytic entries for each period created automatically in Analytic Entries section. Finally we can press Uninvoiced Analytic Entries shortcut in right side, and start to create invoices using base invoice creation tools.

All invoicing work flow process can be described in this diagram:

Invoicing work flow process

Copyright © 2001 Alistek Ltd., ALL RIGHTS RESERVED