This repository has been archived on 2024-04-08. You can view files and clone it, but cannot push or open issues or pull requests.
khosb/modules/invoice/invoice_construct.xml
2011-08-26 04:30:58 +10:00

260 lines
8.1 KiB
XML

<?xml version="1.0" encoding="ISO-8859-1" ?>
<construct>
<!-- Module name -->
<module>invoice</module>
<!-- Module supporting database table -->
<table>invoice</table>
<!-- Module dependancy(s) (module wont install if these modules are not yet installed) -->
<dependancy></dependancy>
<!-- DB cache in seconds -->
<cache>0</cache>
<!-- Default order_by field for SQL queries -->
<order_by>date_orig</order_by>
<!-- Default SQL limit for SQL queries -->
<limit>25</limit>
<!-- Schema version (used to determine if the schema has change during upgrades) -->
<version>1</version>
<!-- Database indexes -->
<index>
<orig>date_orig</orig>
<last>date_last</last>
<billing>billing_status</billing>
<process>process_status</process>
<account>account_id</account>
<reseller>reseller_id</reseller>
<amount>total_amt</amount>
<due_date>due_date</due_date>
<checkout>checkout_plugin_id</checkout>
<net_term>net_term_id</net_term>
</index>
<!-- Database fields -->
<field>
<!-- Record ID -->
<id>
<display>Invoice</display>
<index>1</index>
<type>I4</type>
<unique>1</unique>
</id>
<!-- Site ID -->
<site_id>
<index>1</index>
<type>I4</type>
</site_id>
<!-- Date record created -->
<date_orig>
<convert>date-now</convert>
<display>Invoice Date</display>
<type>I8</type>
</date_orig>
<!-- Date record updated -->
<date_last>
<convert>date-now</convert>
<display>Date Updated</display>
<type>I8</type>
</date_last>
<!-- Record active (BOOL)-->
<status>
<display>Active</display>
<type>L</type>
</status>
<!-- Invoice Approved: 1=YES, 0=UNUSED, NULL = NO (Approved invoices can have services provisioned) -->
<process_status>
<type>L</type>
</process_status>
<!-- Invoice is PAID when Billing STATUS = 1 -->
<billing_status>
<display>Invoice Status</display>
<type>L</type>
</billing_status>
<!-- 1 = Has this invoice been printed -->
<print_status>
<type>L</type>
</print_status>
<!-- The account this invoice belongs to -->
<account_id>
<asso_table>account</asso_table>
<asso_field>first_name,last_name</asso_field>
<display>Account</display>
<type>I8</type>
</account_id>
<!-- @todo UNKNOWN -->
<account_billing_id>
<type>I4</type>
</account_billing_id>
<!-- The afflicate who should be credited for this invoice revenue -->
<affiliate_id>
<type>C(32)</type>
</affiliate_id>
<!-- The reseller who should be credited for this invoice revenue -->
<reseller_id>
<type>C(32)</type>
</reseller_id>
<!-- Checkout plugin for this invoice -->
<checkout_plugin_id>
<type>I4</type>
</checkout_plugin_id>
<!-- Checkout plugin data (has the subscription ID for reoccurring payments) -->
<checkout_plugin_data>
<type>C(255)</type>
<convert>array</convert>
</checkout_plugin_data>
<!-- The amount of TAX this invoice includes -->
<tax_amt>
<display>Total Taxes</display>
<type>F</type>
</tax_amt>
<!-- The amount of CREDITS this invoice includes -->
<credit_amt>
<display>Total Credits</display>
<type>F</type>
</credit_amt>
<!-- The amount of DISCOUNT this invoice includes -->
<discount_amt>
<display>Total Discounts</display>
<type>F</type>
</discount_amt>
<!-- Invoice Total Charges (including taxes ??) -->
<total_amt>
<display>Amount</display>
<type>F</type>
</total_amt>
<!-- Amount already paid (in site currency) -->
<billed_amt>
<display>Amount Paid</display>
<type>F</type>
</billed_amt>
<!-- The currency id that this invoice is due (in site currency) -->
<billed_currency_id>
<type>I4</type>
</billed_currency_id>
<!-- The amount (in actual_billed_currency_id units) that payment was made in -->
<actual_billed_amt>
<type>F</type>
</actual_billed_amt>
<!-- The currency that was used to pay the invoice -->
<actual_billed_currency_id>
<type>I4</type>
</actual_billed_currency_id>
<!-- The date this invoice is due -->
<due_date>
<display>Date Due</display>
<type>I8</type>
<convert>date-time</convert>
</due_date>
<!-- Admin notes attached to the invoice -->
<notes>
<type>X</type>
</notes>
<!-- Invoice terms that govern when this invoice is overdue, and when notices should go out -->
<net_term_id>
<type>L</type>
</net_term_id>
</field>
<!-- Methods for this class, and the fields they have access to, if applicable -->
<method>
<add>id,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,status</add>
<update>id,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</update>
<delete>id</delete>
<view>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,credit_amt,billed_currency_id,due_date,net_term_id</view>
<search>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</search>
<export_excel>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</export_excel>
<export_pdf>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</export_pdf>
<export_xml>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</export_xml>
<export_csv>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</export_csv>
<export_tab>id,date_orig,date_last,process_status,billing_status,print_status,account_id,account_billing_id,reseller_id,checkout_plugin_id,tax_amt,discount_amt,total_amt,billed_amt,billed_currency_id,due_date,net_term_id</export_tab>
</method>
<!-- Method triggers -->
<trigger></trigger>
<!-- Template page display titles -->
<title>
<user_view>Invoice</user_view>
</title>
<!-- Template helpers -->
<tpl>
<invoicesoon>
<checkbox>
<field>id</field>
<type>checkbox</type>
<width>25px</width>
</checkbox>
<account_id>
<field>account_id</field>
</account_id>
<service_id>
<translate>service_id</translate>
</service_id>
<next_invoice_date>
<field>invoice_date</field>
<translate>next_invoice_date</translate>
</next_invoice_date>
<price>
<field>price</field>
<type>currency</type>
</price>
<icon>
<width>120px</width>
</icon>
</invoicesoon>
<search_show>
<checkbox>
<field>id</field>
<type>checkbox</type>
<width>25px</width>
</checkbox>
<id>
<field>id</field>
</id>
<account_id>
<field>account_id</field>
</account_id>
<date_orig>
<field>date_orig</field>
<type>date</type>
</date_orig>
<due_date>
<field>due_date</field>
<type>date</type>
</due_date>
<total_amt>
<field>total_amt</field>
<type>currency</type>
</total_amt>
<icon>
<width>120px</width>
</icon>
</search_show>
<user_search_show>
<checkbox>
<field>id</field>
<type>checkbox</type>
<width>25px</width>
</checkbox>
<id>
<field>id</field>
</id>
<date_orig>
<field>date_orig</field>
<type>date</type>
</date_orig>
<total_amt>
<field>total_amt</field>
<type>currency</type>
</total_amt>
<balance>
<field>balance</field>
<type>currency</type>
</balance>
<icon>
<width>60px</width>
</icon>
</user_search_show>
</tpl>
</construct>