91 |
} |
} |
92 |
} |
} |
93 |
|
|
94 |
|
|
95 |
|
/* |
96 |
|
* Affiche page |
97 |
|
*/ |
98 |
|
|
99 |
$dir = "../includes/modules/facture/"; |
$dir = "../includes/modules/facture/"; |
100 |
|
|
101 |
|
|
114 |
print '<tr class="liste_titre">'; |
print '<tr class="liste_titre">'; |
115 |
print '<td>'.$langs->trans("Name").'</td>'; |
print '<td>'.$langs->trans("Name").'</td>'; |
116 |
print '<td>'.$langs->trans("Description").'</td>'; |
print '<td>'.$langs->trans("Description").'</td>'; |
117 |
print '<td>'.$langs->trans("Example").'</td>'; |
print '<td nowrap>'.$langs->trans("Example").'</td>'; |
118 |
print '<td align="center" width="60">'.$langs->trans("Default").'</td>'; |
print '<td align="center" width="60">'.$langs->trans("Default").'</td>'; |
119 |
print "</tr>\n"; |
print '<td nowrap>'.$langs->trans("NextValue").'</td>'; |
120 |
|
print '</tr>'."\n"; |
121 |
|
|
122 |
clearstatcache(); |
clearstatcache(); |
123 |
|
|
126 |
$var=True; |
$var=True; |
127 |
while (($file = readdir($handle))!==false) |
while (($file = readdir($handle))!==false) |
128 |
{ |
{ |
129 |
if (is_dir($dir.$file) && substr($file, 0, 1) <> '.' && substr($file, 0, 3) <> 'CVS') |
if (is_dir($dir.$file) && substr($file, 0, 1) <> '.' && substr($file, 0, 3) <> 'CVS') |
130 |
{ |
{ |
131 |
$var = !$var; |
$var = !$var; |
132 |
print '<tr '.$bc[$var].'><td width="100">'; |
print '<tr '.$bc[$var].'><td width="100">'; |
133 |
echo "$file"; |
echo "$file"; |
134 |
print "</td><td>\n"; |
print "</td><td>\n"; |
135 |
|
|
136 |
$filebis = $file."/".$file.".modules.php"; |
$filebis = $file."/".$file.".modules.php"; |
137 |
|
|
138 |
// Chargement de la classe de numérotation |
// Chargement de la classe de numérotation |
139 |
$classname = "mod_facture_".$file; |
$classname = "mod_facture_".$file; |
140 |
require_once($dir.$filebis); |
require_once($dir.$filebis); |
141 |
|
|
142 |
$obj = new $classname($db); |
$obj = new $classname($db); |
143 |
print $obj->info(); |
print $obj->info(); |
144 |
|
|
145 |
print '</td>'; |
print '</td>'; |
146 |
|
|
147 |
// Affiche example |
// Affiche example |
148 |
print '<td>'.$obj->getExample().'</td>'; |
print '<td>'.$obj->getExample().'</td>'; |
149 |
|
|
150 |
print '<td align="center">'; |
print '<td align="center">'; |
151 |
if ($facture_addon_var == "$file") |
if ($facture_addon_var == "$file") |
152 |
{ |
{ |
153 |
print img_tick(); |
print img_tick(); |
154 |
} |
print "</td><td nowrap>".$obj->getNextValue()."</td>\n"; |
155 |
else |
} |
156 |
{ |
else |
157 |
print '<a href="facture.php?action=set&value='.$file.'">'.$langs->trans("Default").'</a>'; |
{ |
158 |
} |
print '<a href="facture.php?action=set&value='.$file.'">'.$langs->trans("Default").'</a>'; |
159 |
print "</td></tr>\n"; |
print "</td><td nowrap> </td>\n"; |
160 |
|
} |
161 |
|
print "</td></tr>\n"; |
162 |
} |
} |
163 |
} |
} |
164 |
closedir($handle); |
closedir($handle); |