18 |
ilm |
1 |
/*
|
|
|
2 |
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
|
|
|
3 |
*
|
|
|
4 |
* Copyright 2011 OpenConcerto, by ILM Informatique. All rights reserved.
|
|
|
5 |
*
|
|
|
6 |
* The contents of this file are subject to the terms of the GNU General Public License Version 3
|
|
|
7 |
* only ("GPL"). You may not use this file except in compliance with the License. You can obtain a
|
|
|
8 |
* copy of the License at http://www.gnu.org/licenses/gpl-3.0.html See the License for the specific
|
|
|
9 |
* language governing permissions and limitations under the License.
|
|
|
10 |
*
|
|
|
11 |
* When distributing the software, include this License Header Notice in each file.
|
|
|
12 |
*/
|
|
|
13 |
|
|
|
14 |
package org.openconcerto.erp.core.finance.accounting.report;
|
|
|
15 |
|
|
|
16 |
import org.openconcerto.erp.config.ComptaPropsConfiguration;
|
|
|
17 |
import org.openconcerto.erp.preferences.TemplateNXProps;
|
|
|
18 |
import org.openconcerto.sql.Configuration;
|
|
|
19 |
import org.openconcerto.sql.model.SQLRow;
|
|
|
20 |
|
|
|
21 |
public class PdfGenerator_2033E extends PdfGenerator {
|
|
|
22 |
|
|
|
23 |
public PdfGenerator_2033E() {
|
156 |
ilm |
24 |
super("2033E.pdf", "2033E.pdf", TemplateNXProps.getInstance().getStringProperty("Location2033E"));
|
18 |
ilm |
25 |
setTemplateOffset(0, 0);
|
|
|
26 |
setOffset(0, 0);
|
|
|
27 |
}
|
|
|
28 |
|
|
|
29 |
public void generate() {
|
|
|
30 |
setFontBold(14);
|
156 |
ilm |
31 |
final SQLRow rowSociete = ((ComptaPropsConfiguration) Configuration.getInstance()).getRowSociete();
|
18 |
ilm |
32 |
addText("NOM", rowSociete.getString("TYPE") + " " + rowSociete.getString("NOM"), 138, 722);
|
|
|
33 |
setFontRoman(12);
|
|
|
34 |
addText("OUVERT", "1er janvier 2004", 105, 703);
|
|
|
35 |
addText("CLOS", "31 décembre 2004", 274, 703);
|
|
|
36 |
addSplittedText("DUREE", "12", 502, 703, 19);
|
|
|
37 |
|
|
|
38 |
// Copyright
|
|
|
39 |
setFontRoman(9);
|
156 |
ilm |
40 |
addText("", "Document généré par le logiciel OpenConcerto", 350, 161, 0);
|
18 |
ilm |
41 |
|
|
|
42 |
setFontRoman(10);
|
|
|
43 |
long t = 785123456L;
|
|
|
44 |
int yy = 0;
|
|
|
45 |
int y = 651;
|
|
|
46 |
for (int i = 0; i < 8; i++) {
|
|
|
47 |
addTextRight("PROD1." + yy, insertCurrencySpaces("" + t), 563, y);
|
|
|
48 |
yy++;
|
|
|
49 |
y -= 18;
|
|
|
50 |
}
|
|
|
51 |
y -= 18;
|
|
|
52 |
for (int i = 0; i < 11; i++) {
|
|
|
53 |
addTextRight("CONSO1." + yy, insertCurrencySpaces("" + t), 563, y);
|
|
|
54 |
yy++;
|
|
|
55 |
y -= 18;
|
|
|
56 |
}
|
|
|
57 |
y -= 16;
|
|
|
58 |
|
|
|
59 |
//
|
|
|
60 |
addTextRight("TOT1." + yy, insertCurrencySpaces("" + t), 563, y);
|
|
|
61 |
}
|
|
|
62 |
|
|
|
63 |
}
|