c76cfed9a7f92f80bc79de5aa8ca6b47fc9ac191
[fa-stable.git] / reporting / includes / doctext.inc
1 <?php
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 ***********************************************************************/
12 if (isset($header2type))
13 {
14         $doc_Cust_no = _("Cust no");
15         $doc_Date = _("Date");
16         if ($doctype == ST_PURCHORDER || $doctype == ST_SUPPAYMENT) // Purchase Order
17         {
18                 $doc_Charge_To = _("Order To");
19                 $doc_Delivered_To = _("Charge To");
20         }
21         else
22         {
23                 if ($doctype == ST_CUSTPAYMENT)
24                         $doc_Charge_To = _("With thanks from");
25                 else    
26                         $doc_Charge_To = _("Charge To");
27                 $doc_Delivered_To = _("Delivered To");
28         }       
29         $doc_Shipping_Company = _("Shipping Company");
30         if ($doctype == ST_SALESQUOTE)
31                 $doc_Due_Date = _("Valid until");
32         elseif ($doctype == ST_SALESORDER)
33                 $doc_Due_Date = _("Delivery Date");
34         else
35                 $doc_Due_Date = _("Due Date");
36         $doc_Your_Ref = _("Your Ref");
37         if ($doctype == ST_WORKORDER)
38         {
39                 $doc_Our_Ref = _("Type");
40                 $doc_Your_VAT_no = _("Manufactured Item");
41                 $doc_Payment_Terms = _("Required By");
42                 $doc_Customers_Ref = _("Reference");
43                 $doc_Our_Order_No = _("Into Location");
44                 $doc_Due_Date = _("Quantity");
45         }       
46         else
47         {
48                 if ($doctype == ST_SUPPAYMENT || $doctype == ST_CUSTPAYMENT)
49                         $doc_Our_Ref = _("Type");
50                 else    
51                         $doc_Our_Ref = _("Sales Person");
52                 $doc_Your_VAT_no = _("Your VAT no.");
53                 $doc_Payment_Terms = _("Payment Terms");
54                 $doc_Customers_Ref = _("Customers Reference");
55                 $doc_Our_Order_No = _("Our Order No");
56         }
57         $doc_Our_VAT_no = _("Our VAT No.");
58         $doc_Domicile = _("Domicile");
59         $doc_Extra = "";
60         if($doctype == ST_CUSTDELIVERY || $doctype == ST_SALESQUOTE || $doctype == ST_PURCHORDER || $doctype == ST_SALESORDER ||
61                 $doctype == ST_SUPPAYMENT || $doctype == ST_CUSTPAYMENT) {
62                 if ($doctype == ST_CUSTPAYMENT)
63                         $doc_Extra = _("* Subject to Realisation of the Cheque.");
64                 $doc_Bank_Account = '';
65                 $doc_Please_Quote = _("All amounts stated in");
66   } else {
67          $doc_Bank_Account = _("Bank Account");
68          $doc_Please_Quote = $doctype==ST_SALESINVOICE ? 
69          _("Please quote Invoice no. when paying. All amounts stated in") :
70          _("Please quote Credit no. when paying. All amounts stated in");
71         }
72         $doc_Address = _("Address");
73         $doc_Phone_Fax_Email = _("Phone/Fax/Email");
74         $doc_Bank = _("Bank");
75         $doc_Payment_Link = _("You can pay through");
76         if ($doctype == ST_SALESQUOTE || $doctype == ST_PURCHORDER || $doctype == ST_SALESORDER || $doctype == ST_SALESINVOICE || 
77                 $doctype == ST_CUSTCREDIT || $doctype == ST_CUSTDELIVERY || $doctype == ST_WORKORDER || $doctype == ST_SUPPAYMENT || 
78                 $doctype == ST_CUSTPAYMENT)
79         {
80                 if ($doctype == ST_SALESQUOTE)
81                         $this->title = _("SALES QUOTATION");
82                 elseif ($doctype == ST_PURCHORDER)
83                         $this->title = _("PURCHASE ORDER");
84                 elseif ($doctype == ST_CUSTDELIVERY)
85                         $this->title = ($packing_slip==1 ? _("PACKING SLIP") : _("DELIVERY NOTE"));
86                 elseif ($doctype == ST_SALESORDER)
87                         $this->title = ($print_as_quote==1 ? _("QUOTE") : _("SALES ORDER"));
88                 elseif ($doctype == ST_SALESINVOICE)
89                         $this->title = _("INVOICE");
90                 elseif ($doctype == ST_WORKORDER)
91                         $this->title = _("WORK ORDER");
92                 elseif ($doctype == ST_SUPPAYMENT)
93                         $this->title = _("REMITTANCE");
94                 elseif ($doctype == ST_CUSTPAYMENT)
95                         $this->title = _("RECEIPT");
96                 else
97                         $this->title = _("CREDIT NOTE");
98                 if ($doctype == ST_PURCHORDER)
99                         $this->headers = array(_("Item Code"), _("Item Description"),
100                                 _("Delivery Date"), _("Quantity"),      _("Unit"), _("Price"), _("Total"));
101                 elseif ($doctype == ST_WORKORDER)
102                         $this->headers = array(_("Item Code"), _("Item Description"),
103                                 _("From Location"), _("Work Centre"),   _("Unit Quantity"), _("Total Quantity"), _("Units Issued"));
104                 elseif ($doctype == ST_SUPPAYMENT || $doctype == ST_CUSTPAYMENT)
105                         $this->headers = array(_("Trans Type"), _("#"), _("Date"), _("Due Date"), _("Total Amount"), _("Left to Allocate"), _("This Allocation"));
106                 else
107                         $this->headers = array(_("Item Code"), _("Item Description"),   _("Quantity"),
108                                 _("Unit"), _("Price"), _("Discount %"), _("Total"));
109         }
110         else if ($doctype == ST_STATEMENT)
111         {
112                 $this->title = _("STATEMENT");
113                 $this->headers = array(_("Trans Type"), _("#"), _("Date"), _("DueDate"), _("Charges"),
114                         _("Credits"), _("Allocated"), _("Outstanding"));
115         }
116 }
117 if (isset($emailtype))
118 {
119         $doc_Dear_Sirs = _("Dear");
120         $doc_AttachedFile = _("Attached you will find ");
121         $doc_Kindest_regards = _("Kindest regards");
122         $doc_Payment_Link = _("You can pay through");
123 }
124 if (isset($header2type) || isset($linetype))
125 {
126         $doc_Invoice_no = ($doctype==ST_CUSTDELIVERY ? _("Delivery Note No.") : 
127                 ($doctype == ST_CUSTPAYMENT ? _("Receipt No.") :
128                 ($doctype == ST_SUPPAYMENT ? _("Remittance No.") :
129                 (($doctype==ST_SALESQUOTE || $doctype==ST_PURCHORDER || $doctype==ST_SALESORDER) ? _("Order no.") : 
130                 ($doctype==ST_SALESINVOICE ? _("Invoice No.") : ($doctype==ST_WORKORDER ? _("Word Order No") : _("Credit No.")))))));
131         $doc_Delivery_no = _("Delivery Note No.");
132         $doc_Order_no = _("Order no.");
133 }
134 if (isset($linetype))
135 {
136         if ($doctype == ST_SALESQUOTE || $doctype == ST_PURCHORDER || $doctype == ST_SALESORDER || 
137                 $doctype == ST_SALESINVOICE || $doctype == ST_CUSTCREDIT || $doctype == ST_CUSTDELIVERY)
138         {
139                 $doc_Sub_total = _("Sub-total");
140                 $doc_Shipping = _("Shipping");
141                 $doc_Included = _("Included");
142                 $doc_Amount = _("Amount");
143                 $doc_TOTAL_INVOICE = $doctype ==ST_SALESINVOICE ? _("TOTAL INVOICE") : _("TOTAL CREDIT");
144                 $doc_TOTAL_ORDER = _("TOTAL ORDER EX VAT");
145                 $doc_TOTAL_ORDER2 = _("TOTAL ORDER VAT INCL.");
146                 $doc_TOTAL_PO = _("TOTAL PO EX VAT");
147                 $doc_TOTAL_DELIVERY = _("TOTAL DELIVERY INCL. VAT");
148         }
149         elseif ($doctype == ST_SUPPAYMENT || ST_CUSTPAYMENT)
150         {
151                 $doc_Towards = _("As advance / full / part / payment towards:");
152                 $doc_by_Cheque = _("By Cash / Cheque* / Draft No.");
153                 $doc_Dated = _("Dated");
154                 $doc_Drawn = _("Drawn on Bank");
155                 $doc_Drawn_Branch = _("Branch");
156                 $doc_Received = _("Received / Sign");
157                 $doc_Total_Allocated = _("Total Allocated");
158                 $doc_Left_To_Allocate = _("Left to Allocate");
159                 if ($doctype == ST_CUSTPAYMENT)
160                         $doc_Total_Payment = _("TOTAL RECEIPT");
161                 else    
162                         $doc_Total_Payment = _("TOTAL REMITTANCE");
163         }
164         elseif ($doctype == ST_STATEMENT)
165         {
166                 $doc_Outstanding = _("Outstanding Transactions");
167                 $doc_Current = _("Current");
168                 $doc_Total_Balance = _("Total Balance");
169                 $doc_Statement = _("Statement");
170                 $doc_as_of = _("as of");
171                 $doc_Days = _("Days");
172                 $doc_Over = _("Over");
173         }
174 }
175 ?>