1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
|
<?php
/**
* Template für die Einstellungen des Rechnungen Moduls
*/
?>
<script type="text/javascript">
/**
* Wird beim anlegen einer neuen Fußzeile aufgerufen
*/
function wpsg_addFooter()
{
jQuery('#foottext_list').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
jQuery.ajax( {
url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&action=module&modul=wpsg_mod_rechnungen&do=add&noheader=1',
success: function(data) {
jQuery('#foottext_list').html(data);
}
} );
return false;
} // function wpsg_addFooter()
/**
* Wird beim entfernen einer Fußzeile aufgerufen
*/
function wpsg_removeFooter(foot_id)
{
if (!confirm('<?php echo __('Sind Sie sich sicher, dass Sie diese Fußzeile löschen möchten?', 'wpsg'); ?>')) return false;
jQuery('#foottext_list').html('<img src="<?php echo WPSG_URL; ?>views/gfx/ajax-loader.gif" alt="<?php echo __('Bitte warten ...', 'wpsg'); ?>" />');
jQuery.ajax( {
url: '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&action=module&modul=wpsg_mod_rechnungen&do=removeFooter&noheader=1',
data: {
foot_id: foot_id
},
success: function(data) {
jQuery('#foottext_list').html(data);
}
} );
return false;
} // function wpsg_removeFooter()
</script>
<br />
<div class="wpsg_admin_box" id="wpsg_tab">
<div class="head">
<div class="title">
<div class="tab" id="tab1"><?php echo __('Vordefinierte Textfelder', 'wpsg'); ?></div>
<div class="tab" id="tab2"><?php echo __('Fußzeile', 'wpsg'); ?></div>
<div class="tab" id="tab3"><?php echo __('Sonstiges', 'wpsg'); ?></div>
<div class="tabcontent tablink">
<a href="" title="<?php echo __('Neues Feld für die Fußzeile hinzufügen', 'wpsg'); ?>" class="wpsg_icon wpsg_icon_right wpsg_icon_add" onclick="return wpsg_addFooter();"></a>
</div>
<div class="wpsg_clear"></div>
</div>
</div>
<div class="content" id="wpsg_mwst_list">
<div id="tabcontent1" class="tabcontent">
<?php echo wpsg_drawForm_Input('wpsg_rechnungen_adresszeile', __('Adresszeile', 'wpsg'), $this->get_option('wpsg_rechnungen_adresszeile')); ?>
<div class="wpsg_hinweis"><?php echo __('Diese Zeile wird klein oberhalb der Kundenadresse platziert', 'wpsg'); ?></div>
<br />
<div class="wpsg_form_field">
<div class="wpsg_form_left">
<label><?php echo __('Briefpapier (PDF/JPG)', 'wpsg'); ?>:</label><br />
<?php if ($this->view['bp'] !== false) { ?>
<label>
<input type="checkbox" name="wpsg_rechnungen_bp_del" value="1" /> <?php echo __('Löschen', 'wpsg'); ?>
</label>
<?php } ?>
</div>
<div class="wpsg_form_right">
<?php if ($this->view['bp'] === false) { ?>
<p><?php echo __('Es wurde bisher kein Briefpapier hochgeladen', 'wpsg'); ?></p>
<?php } else { ?>
<a href="<?php echo $this->view['bp']; ?>" target="_blank"><?php echo __('Derzeitiges Briefpapier', 'wpsg'); ?></a>
<?php } ?>
<a style="float:right; position:relative;" class="wpsg_form_help" href="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=mod_rechnung_bp" rel="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=mod_rechnung_bp"></a>
<input type="file" name="wpsg_rechnungen_bp">
</div>
<div class="wpsg_clear"></div>
</div>
<div class="wpsg_form_field">
<div class="wpsg_form_left">
<label><?php echo __('Logo (JPG)', 'wpsg'); ?>:</label><br />
<?php if ($this->view['logo'] !== false) { ?>
<label>
<input type="checkbox" name="wpsg_rechnungen_logo_del" value="1" /> <?php echo __('Löschen', 'wpsg'); ?>
</label>
<?php } ?>
</div>
<div class="wpsg_form_right">
<?php if ($this->view['logo'] === false) { ?>
<p><?php echo __('Es wurde bisher kein Logo hochgeladen', 'wpsg'); ?></p>
<?php } else { ?>
<a href="<?php echo $this->view['logo']; ?>" target="_blank"><?php echo __('Derzeitiges Logo', 'wpsg'); ?></a>
<?php } ?>
<a style="float:right; position:relative;" class="wpsg_form_help" href="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=mod_rechnung_logo" rel="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=mod_rechnung_logo"></a>
<input type="file" name="wpsg_rechnungen_logo">
</div>
<div class="wpsg_clear"></div>
</div>
<div class="wpsg_hinweis"><?php echo __('Das Briefpapier wird hinter die gesamte Seite gelegt, das Logo wird rechts oben auf jeder Seite platziert. (96 dpi)', 'wpsg'); ?></div>
<br />
<table class="wpsg_mod_rechnungen_fieldtable">
<tr>
<th class="col_bezeichnung"><?php echo __('Bezeichnung', 'wpsg'); ?></th>
<th class="col_freitext"><?php echo __('Freitext', 'wpsg'); ?></th>
<th class="col_x"><?php echo __('X', 'wpsg'); ?></th>
<th class="col_y"><?php echo __('Y', 'wpsg'); ?></th>
<th class="col_color"><?php echo __('Farbe', 'wpsg'); ?></th>
<th class="col_groesse"><?php echo __('Größe', 'wpsg'); ?></th>
<th class="col_action"></th>
</tr>
<?php foreach ($this->view['fields'] as $f => $field_name) { ?>
<tr>
<td><?php echo wpsg_hspc($field_name); ?></td>
<td>
<input type="text" style="width:100%;" name="text[<?php echo $f; ?>][text]" value="<?php echo wpsg_hspc($this->view['arTexte'][$f]['text']); ?>" />
</td>
<td>
<input type="text" style="width:100%;" name="text[<?php echo $f; ?>][x]" value="<?php echo wpsg_hspc($this->view['arTexte'][$f]['x']); ?>" />
</td>
<td>
<input type="text" style="width:100%;" name="text[<?php echo $f; ?>][y]" value="<?php echo wpsg_hspc($this->view['arTexte'][$f]['y']); ?>" />
</td>
<td>
<input type="text" style="width:100%;" name="text[<?php echo $f; ?>][color]" value="<?php echo wpsg_hspc($this->view['arTexte'][$f]['color']); ?>" />
</td>
<td>
<select name="text[<?php echo $f; ?>][fontsize]" style="width:100%;">
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "8")?'selected="selected"':''); ?> value="8">8</option>
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "9")?'selected="selected"':''); ?> value="9">9</option>
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "10")?'selected="selected"':''); ?> value="10">10</option>
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "11")?'selected="selected"':''); ?> value="11">11</option>
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "12")?'selected="selected"':''); ?> value="12">12</option>
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "13")?'selected="selected"':''); ?> value="13">13</option>
<option <?php echo (($this->view['arTexte'][$f]['fontsize'] == "14")?'selected="selected"':''); ?> value="14">14</option>
</select>
</td>
<td>
<label><input type="checkbox" value="1" name="text[<?php echo $f; ?>][aktiv]" <?php echo ((wpsg_isSizedInt($this->view['arTexte'][$f]['aktiv']))?'checked="checked"':''); ?> /> <?php echo __("Aktiv", "wpsg"); ?></label>
<a style="float:right; position:relative;" class="wpsg_form_help" href="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=mod_rechnung_fieldconfig" rel="?page=wpsg-Admin&subaction=loadHelp&noheader=1&field=mod_rechnung_fieldconfig"></a>
</td>
</tr>
<?php } ?>
</table>
<br />
<input style="float:right;" class="button" onclick="if (!confirm('<?php echo __('Sind Sie sich sicher? Ihre bisherigen Einstellungen gehen verloren!', 'wpsg'); ?>')) return false; else location.href = '<?php echo WPSG_URL_WP; ?>wp-admin/admin.php?page=wpsg-Admin&action=module&modul=<?php echo $_REQUEST['modul']; ?>&do=reset&noheader=1';" type="button" value="<?php echo __('Standardeinstellungen laden', 'wpsg'); ?>" />
<div class="wpsg_hinweis">
<?php echo __('Die Angaben für X (Abstand von Links) und Y (Abstand von Oben) werden in mm eingetragen.', 'wpsg'); ?><br />
<?php echo __('Die Farbe wird im Hexadezimalformat angegeben (#FFFFF für weiß, #000000 für schwarz).', 'wpsg'); ?>
</div>
<br />
</div>
<div id="tabcontent2" class="tabcontent">
<div id="foottext_list"><?php echo $this->view['foottext_list']; ?></div>
<br />
<div class="wpsg_hinweis">
<?php echo __('Hier können Sie Texte vordefinieren, die sie unter die Rechnung setzen können.', 'wpsg'); ?>
</div>
</div>
<div id="tabcontent3" class="tabcontent">
<?php echo wpsg_drawForm_Input('wpsg_rechnungen_url', __('URL Benachrichtigung', 'wpsg'), $this->get_option('wpsg_rechnungen_url'), array('help' => 'wpsg_rechnung_url')); ?>
<?php echo wpsg_drawForm_Select('wpsg_mod_rechnungen_auto', __('Rechnungserstellung', 'wpsg'), array(
'0' => __('Manuell', 'wpsg'),
'1' => __('Bei Bestellung', 'wpsg'),
'2' => __('Bei Zahlung', 'wpsg')
), $this->get_option('wpsg_mod_rechnungen_auto'), array('help' => 'wpsg_mod_rechnungen_auto')); ?>
<?php echo wpsg_drawForm_Input('wpsg_rechnungen_faelligkeit', __('Fälligkeit in Tagen', 'wpsg'), $this->get_option('wpsg_rechnungen_faelligkeit'), array('help' => 'wpsg_rechnungen_faelligkeit')); ?>
<?php echo wpsg_drawForm_Input('wpsg_rechnungen_pdfperpage', __('Anzahl an Produkten pro Seite (PDF)', 'wpsg'), $this->get_option('wpsg_rechnungen_pdfperpage'), array('help' => 'wpsg_rechnungen_pdfperpage')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_rechnungen_pbeschreibung', __('Produktbeschreibung auf Rechnung anzeigen', 'wpsg'), $this->get_option('wpsg_rechnungen_pbeschreibung'), array('help' => 'wpsg_rechnungen_pbeschreibung')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_rechnungen_showgutschriftrechnung', __('Rechnungsnummer auf Rechnungskorrektur anzeigen', 'wpsg'), $this->get_option('wpsg_mod_rechnungen_showgutschriftrechnung'), array('help' => 'wpsg_mod_rechnungen_showgutschriftrechnung')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_rechnungen_showpv', __('Produktvariablen auf Rechnung anzeigen', 'wpsg'), $this->get_option('wpsg_mod_rechnungen_showpv'), array('help' => 'wpsg_mod_rechnungen_showpv')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_rechnungen_showov', __('Bestellvariablen auf Rechnung anzeigen', 'wpsg'), $this->get_option('wpsg_mod_rechnungen_showov'), array('help' => 'wpsg_mod_rechnungen_showov')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_rechnungen_showanr', __('Artikelnummer auf Rechnung als Nr. verwenden', 'wpsg'), $this->get_option('wpsg_mod_rechnungen_showanr'), array('help' => 'wpsg_mod_rechnungen_showanr')); ?>
<?php echo wpsg_drawForm_Checkbox('wpsg_mod_rechnungen_hideCountry', __('Land auf Lieferschein verbergen', 'wpsg'), $this->get_option('wpsg_mod_rechnungen_hideCountry'), array('help' => 'wpsg_mod_rechnungen_hideCountry')); ?>
<?php echo wpsg_drawForm_Input('wpsg_rechnungen_start', __('Startnummer (Rechnungen)', 'wpsg'), $this->get_option('wpsg_rechnungen_start'), array('help' => 'wpsg_rechnungen_start')); ?>
<?php echo wpsg_drawForm_Input('wpsg_gutschrift_start', __('Startnummer (Rechnungskorrektur)', 'wpsg'), $this->get_option('wpsg_gutschrift_start'), array('help' => 'wpsg_gutschrift_start')); ?>
<?php echo wpsg_drawForm_Select('wpsg_mod_rechnungen_gutschrifttax', __('Mehrwertsteuersatz für Bearbeitungsgebühr', 'wpsg'), wpsg_tax_groups(), $this->get_option('wpsg_mod_rechnungen_gutschrifttax'), array('help' => 'wpsg_mod_rechnungen_gutschrifttax')); ?>
<?php echo wpsg_drawForm_Input('wpsg_rechnungen_format', __('Format (Rechnungen)', 'wpsg'), $this->get_option('wpsg_rechnungen_format'), array('help' => 'wpsg_rechnungen_format')); ?>
<?php echo wpsg_drawForm_Input('wpsg_gutschrift_format', __('Format (Rechnungskorrektur)', 'wpsg'), $this->get_option('wpsg_gutschrift_format'), array('help' => 'wpsg_gutschrift_format')); ?>
<div class="wpsg_form_field">
<div class="wpsg_form_left">
<label><?php echo __('Mögliche Platzhalter für Rechnungen und Rechnungskorrektur', 'wpsg'); ?>:</label>
</div>
<div class="wpsg_form_right">
<p>
%nr% - <?php echo __('Fortlaufende Rechnungs- bzw. Rechnungskorrekturnummer', 'wpsg'); ?><br />
%Jahr% - <?php echo __('Das aktuelle Jahr (4 Stellig)', 'wpsg'); ?><br />
%Monat% - <?php echo __('Der aktuelle Monat (01 - 12)', 'wpsg'); ?><br />
%Tag% - <?php echo __('Der Tag des Monats (01 - 31)', 'wpsg'); ?><br />
</p>
<div class="wpsg_hinweis"><?php echo __('Die Platzhalter können bei den Formatfeldern und dem Dateinamen verwendet werden. Der Platzhalter %nr% sollte dabei immer Verwendung finden.', 'wpsg'); ?></div>
</div>
</div>
<div class="wpsg_clear"></div>
</div>
</div>
</div>
<script type="text/javascript">/* <![CDATA[ */
jQuery(document).ready(function() {
jQuery('#wpsg_tab').wpsg_tab( {
'cookiename': 'wpsg_rechnungen_tab',
'tab2': function() {
jQuery('.tablink').show();
}
} );
} );
/* ]]> */</script>
|