4?><TABLE
style=
"width: auto" class=
"nowrap">
6<TD><?php echo
_(
'Type de journal')?> </TD>
14 <TD><?php echo
_(
'Nom journal')?> </TD>
15 <TD> <INPUT TYPE=
"text" class=
"input_text" NAME=
"p_jrn_name" VALUE=
"<?php echo $name; ?>"></TD>
22if ( $new ||
$type==
'ODS' ):
25<
td style=
"white-space: nowrap"><?php echo
_(
'Postes utilisables journal (débit/crédit) ')?>
31<?php echo
_(
"Uniquement pour les journaux d'Opérations Diverses, les valeurs sont séparées par des espaces, on peut aussi
32 utiliser le * pour indiquer 'tous les postes qui en dépendent' exemple: 4*")?>
42if ( $new||
$type==
'FIN') :
45 <
td style=
"white-space: nowrap">
46 <?php echo
_(
'Numérotation de chaque opération')?>
49 <?php echo $num_op->input();?>
53 <TD
style=
"white-space: nowrap">
54 <?php echo
_(
'Compte en banque')?>
60 $card->extra=
$cn->make_list(
'select fd_id from fiche_def where frd_id=4');
61 $card->set_dblclick(
"fill_ipopcard(this);");
62 $card->set_function(
'fill_data');
63 $card->set_attribute(
'ipopup',
'ipop_card');
64 $list=
$cn->make_list(
'select fd_id from fiche_def where frd_id=4');
74 <
td class=
"notice" style=
"white-space: nowrap">
75 <?php echo
_(
"Obligatoire pour les journaux FIN : donner ici la fiche du compte en banque utilisée")?>
91 <
td style=
"white-space: nowrap">
94 echo
_(
"Uniquement note de débit ou crédit");
100 $negative->javascript=
"toggle_row_warning_enable('negative_amount','row_warning')";
101 echo $negative->input();
107 <
tr id=
"row_warning">
108 <
td style=
"white-space: nowrap">
109 <?php echo
_(
"Avertissement montant positif"); ?>
112 <?php echo $negative_warning->input();?>
117 <?php echo
_(
'Utilisation des quantités')?>
122 echo $quantity->input();
133 <
td style=
"white-space: nowrap"><?php echo
_(
"Minimum de lignes à afficher")?></
td>
134<
td><?php echo $min_row->input()?></
td>
137<
td><INPUT TYPE=
"hidden" id=
"p_jrn_deb_max_line" NAME=
"p_jrn_deb_max_line" VALUE=
"10"></
td>
139<
tr><
td><INPUT TYPE=
"hidden" id=
"p_ech_lib" NAME=
"p_ech_lib" VALUE=
"echeance"></
td>
143 <?php echo
_(
'Description') ?>
146 <?php echo $str_description; ?>
151<TD><?php echo
_(
'Préfixe code interne')?> </TD><TD>
152<?php echo
$code?> </TD>
155<TD><?php echo
_(
'Préfixe pièce justificative')?>
159<?php echo $pj_pref; ?>
164 <?=
_(
"Nombre de caractère du numéro de pièce, remplissage avec des 0 ")?>
167 <?=$padding->input()?>
172<?php
if ( $new == 0 ) : ?>
175 <?php echo
_(
'Dernière pièce numérotée')?>
180 <?php echo str_pad($last_seq,$this->jrn_def_pj_padding??0,
'0',STR_PAD_LEFT)?>
185 <TD><?php echo
_(
'N° pièce justificative')?>
195 <?=
_(
"Journal actif")?>
205 if ( $new == 1 ||
$type ==
'FIN'):
209 <?php echo
_(
"Devise")?>
222 if ( $new ==1 ||
$type==
'ACH' ) :
225 <
h2 class=
"h-section" > Fiches </
h2>
226 <TABLE
class=
"result" style=
"width:80%;margin-left:10%;">
229 <?php echo
_(
"Services, fournitures ou biens achetés (D)");?>
232 <?php echo
_(
"Fournisseurs (C)"); ?>
239 $Res=
$cn->exec_sql(
"select fd_id,fd_label from fiche_def order by fd_label");
244 $rdeb=$default_deb_purchase;
245 $rcred=$default_cred_purchase;
250 $CHECKED=
" unchecked";
251 foreach ( $rdeb as $element) {
252 if ( $element ==
$res[
'fd_id'] ) {
258 printf (
'<TD> <INPUT TYPE="CHECKBOX" VALUE="%s" NAME="ACH_FICHEDEB[]" class="ach_fichedeb" %s>%s</TD>',
259 $res[
'fd_id'],$CHECKED,
$res[
'fd_label']);
260 $CHECKED=
" unchecked";
261 foreach ( $rcred as $element) {
262 if ( $element ==
$res[
'fd_id'] ) {
267 printf (
'<TD> <INPUT TYPE="CHECKBOX" VALUE="%s" NAME="ACH_FICHECRED[]" class="ach_fichecred" %s>%s</TD>',
268 $res[
'fd_id'],$CHECKED,
$res[
'fd_label']);
279 if ( $new ==1 ||
$type==
'VEN' ) :
282 <
h2 class=
"h-section"> Fiches </
h2>
283 <TABLE
class=
"result" style=
"width:80%;margin-left:10%;">
287 <?php echo
_(
"Clients (D)");?>
290 <?php echo
_(
"Services, fournitures ou biens vendus (C)");?>
297 $Res=
$cn->exec_sql(
"select fd_id,fd_label from fiche_def order by fd_label");
302 $rdeb=$default_deb_sale;
303 $rcred=$default_cred_sale;
308 $CHECKED=
" unchecked";
309 foreach ( $rdeb as $element) {
310 if ( $element ==
$res[
'fd_id'] ) {
316 printf (
'<TD> <INPUT TYPE="CHECKBOX" VALUE="%s" NAME="VEN_FICHEDEB[]" class="ven_fichedeb" %s>%s</TD>',
317 $res[
'fd_id'],$CHECKED,
$res[
'fd_label']);
318 $CHECKED=
" unchecked";
319 foreach ( $rcred as $element) {
320 if ( $element ==
$res[
'fd_id'] ) {
325 printf (
'<TD> <INPUT TYPE="CHECKBOX" VALUE="%s" NAME="VEN_FICHECRED[]" class="ven_fichecred" %s>%s</TD>',
326 $res[
'fd_id'],$CHECKED,
$res[
'fd_label']);
337 if ( $new ==1 ||
$type==
'ODS' ) :
340 <
h2 class=
"h-section"> Fiches </
h2>
341 <TABLE
class=
"result" style=
"width:60%;margin-left:20%;">
344 <?php echo
_(
"Fiches utilisables (D/C)"); ?>
352 $Res=
$cn->exec_sql(
"select fd_id,fd_label from fiche_def order by fd_label");
361 $CHECKED=
" unchecked";
362 if (!empty($rdeb))
foreach ( $rdeb as $element) {
363 if ( $element ==
$res[
'fd_id'] ) {
369 printf (
'<TD> <INPUT TYPE="CHECKBOX" VALUE="%s" NAME="ODS_FICHEDEB[]" class="ods_fichedeb" %s>%s</TD>',
370 $res[
'fd_id'],$CHECKED,
$res[
'fd_label']);
371 $CHECKED=
" unchecked";
383 if ( $new ==1 ||
$type==
'FIN' ) :
386 <
h2 class=
"h-section"> Fiches </
h2>
387 <TABLE
class=
"result" style=
"width:60%;margin-left:20%;">
398 $Res=
$cn->exec_sql(
"select fd_id,fd_label from fiche_def order by fd_label");
407 $CHECKED=
" unchecked";
408 foreach ( $rdeb as $element) {
409 if ( $element ==
$res[
'fd_id'] ) {
415 printf (
'<TD> <INPUT TYPE="CHECKBOX" VALUE="%s" NAME="FIN_FICHEDEB[]" class="fin_fichedeb" %s>%s</TD>',
416 $res[
'fd_id'],$CHECKED,
$res[
'fd_label']);
417 $CHECKED=
" unchecked";
427<?php
if ( $new == 1 ) : ?>
429 var a_div=Array(
'VEN_div',
'ODS_div',
'ACH_div',
'FIN_div');
432 for (var i=0;i<a_div.length;i++)
434 $(a_div[i]).style.display=
'none';
439 $(
'type_ods').style.display=
'none';
440 $(
'type_fin').style.display=
'none';
441 $(
'type_fin2').style.display=
'none';
442 $(
'type_fin3').style.display=
'none';
443 $(
'neg_amount').style.display=
'none';
444 $(
'row_warning').style.display=
'none';
449 var ch=$(
'p_jrn_type_select_id').options[$(
'p_jrn_type_select_id').selectedIndex].value;
450 if ( ch != -1 ) { $(ch+
'_div').style.display=
'block';}
454 $(
'type_fin').style.display=
'table-row';
455 $(
'type_fin2').style.display=
'table-row';
456 $(
'type_fin3').style.display=
'table-row';
460 $(
'type_ods').style.display=
'table-row';
464 $(
'neg_amount').style.display=
'table-row';
465 toggle_row_warning_enable(
'negative_amount',
'row_warning');
470 $(
'neg_amount').style.display=
'table-row';
471 toggle_row_warning_enable(
'negative_amount',
'row_warning');
482 if (isset ($previous_p_jrn_type) ):
494toggle_row_warning_enable(
'negative_amount',
'row_warning');
501(
function () {var a_checkbox=[
'ach_fichecred',
'ach_fichedeb',
'ven_fichecred',
'ven_fichedeb',
'ods_fichedeb',
'fin_fichedeb'];
502 a_checkbox.forEach(element => activate_checkbox_range(element));})()
h2($p_string, $p_class="", $raw="")
th($p_string, $p_extra='', $raw='')
tr($p_string, $p_extra='')
td($p_string='', $p_extra='')
surround the string with td
_("actif, passif,charge,...")
Input HTML for the card show buttons, in the file, you have to add card.js How to use :
static warnbulle($p_comment)
Display a warning in a bubble, text is in message_javascript.
static infobulle($p_comment)
Display a info in a bubble, text is in message_javascript.