Invoices Listing

From PhpCOIN Documentation

Jump to: navigation, search

The Invoices listing can be viewed by a logged-in admin, or by a logged-in client. It allows an admin to see a listing of all your invoices in one place, while a client can see all their own invoices in one place.

You can specify how may invoices should be listed per page via Admin -> Parameters -> common -> invoices -> Listing Items Per Page for: Invoices

You can also specify whether or not clients should be able to see their pending (not yet issued) invoices on HelpDesk Listings. Enabling this will affect the display of balances on the listing and on the Summary page. The option is chosen via Admin -> Parameters -> common -> invoices -> Invoice Show Client Pending Invoices

The default listing sort is by Issued Date in DESCending order. You can edit the source code to change what the sort is, as well as the order. In file /coin_modules/invoices/invoices_funcs.php find the function do_view_invoices(). Within that function is the following code block:

# Set Order ASC / DESC part of sort
	IF (!$adata['so'])		{$adata['so'] = 'D';}
	IF ($adata['so'] == 'A')	{$order_AD = ' ASC';}
	IF ($adata['so'] == 'D')	{$order_AD = ' DESC';}

Set the first line to A or D, depending on whether you want ASCending or DESCending sort

Immediately below that block is:

# Set Sort orders
IF (!$adata['sb'])		{$adata['sb'] = '3';	}
IF ($adata['sb'] == '1') {$_order = ' ORDER BY '.$_DBCFG['invoices'].'.invc_id 
IF ($adata['sb'] == '2') {$_order = ' ORDER BY '.$_DBCFG['invoices'].'.invc_status 
IF ($adata['sb'] == '3') {$_order = ' ORDER BY '.$_DBCFG['invoices'].'.invc_ts 
IF ($adata['sb'] == '4') {$_order = ' ORDER BY '.$_DBCFG['invoices'].'.invc_ts_due 
IF ($adata['sb'] == '5') {$_order = ' ORDER BY '.$_DBCFG['invoices'].'.invc_total_cost 
IF ($adata['sb'] == '6') {$_order = ' ORDER BY '.$_DBCFG['clients'].'.cl_name_last 
IF ($adata['sb'] == '7') {$_order = ' ORDER BY '.$_DBCFG['clients'].'.cl_user_name 

Set the first line to the number of the ORDER BY fields that you want.

Personal tools

Inscrita el Registro Mercantil de Mallorca Tomo 2140, Hoja No. PM-51034, Folio 135
This website owned and operated by: Technology Services RPVW S.L. CIF# B57345084
Avda Constitucion 48 Bajos Alaro 07340 Baleares SPAIN
Tel:+34 971518362    Fax: +34 971518368    eMail: