2 /**********************************************************************
3 Copyright (C) FrontAccounting, LLC.
4 Released under the terms of the GNU General Public License, GPL,
5 as published by the Free Software Foundation, either version 3
6 of the License, or (at your option) any later version.
7 This program is distributed in the hope that it will be useful,
8 but WITHOUT ANY WARRANTY; without even the implied warranty of
9 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10 See the License here <http://www.gnu.org/licenses/gpl-3.0.html>.
11 ***********************************************************************/
13 This file contains templates for all country specific functions.
14 If your locale needs special functionality provided by hook functions
15 copy this file to respective lang/xx_XX directory and edit templates below.
16 You can safely remove not used function templates.
21 // Price in words. $doc_type is set to document type and can be used to suppress
22 // price in words printing for selected document types.
23 // Used instead of built in simple english price_in_words() function.
25 // Returns: amount in words as string.
27 function price_in_words($amount, $doc_type)
33 // Exchange rate currency $curr as on date $date.
34 // Keep in mind FA has internally implemented 3 exrate providers
35 // If any of them supports your currency, you can simply use function below
36 // with apprioprate provider set, otherwise implement your own.
37 // Returns: $curr value in home currency units as a real number.
39 function retrieve_ex_rate($curr, $date)
41 $provider = 'ECB'; // 'ECB', 'YAHOO' or 'GOOGLE'
42 return get_extern_rate($curr, $provider, $date);
46 // Generic function called at the end of Tax Report (report 709)
47 // Can be used e.g. for special database updates on every report printing
48 // or to print special tax report footer
51 function tax_report_done()