Add error message if setup no complete.
This commit is contained in:
parent
29fa4a642d
commit
1df5ac2c54
@ -29,7 +29,7 @@ $Id$
|
||||
|
||||
<!-- ========================= Cadre "Article" ============================= -->
|
||||
<fieldset class="cadre_facturation"><legend class="titre1"><?php echo $langs->trans("Article"); ?></legend>
|
||||
<form id="frmFacturation" class="formulaire1" method="post" action="facturation_verif.php">
|
||||
<form id="frmFacturation" class="formulaire1" method="post" action="facturation_verif.php" autocomplete="off">
|
||||
<input type="hidden" name="token" value="<?php echo $_SESSION['newtoken']; ?>" />
|
||||
|
||||
<input type="hidden" name="hdnSource" value="NULL" />
|
||||
@ -42,12 +42,22 @@ $Id$
|
||||
onchange="javascript: setSource('REF');"
|
||||
onfocus="javascript: this.select(); verifResultat('resultats_dhtml', this.value);"
|
||||
onBlur="javascript: document.getElementById('resultats_dhtml').innerHTML = '';"/>
|
||||
<!--onKeyUp="javascript: verifResultat('resultats_dhtml', this.value);" />-- >
|
||||
</td>
|
||||
<td class="select_design">
|
||||
<select name="selProduit" onchange="javascript: setSource('LISTE');">
|
||||
<option value="0"><?php echo $top_liste_produits; ?></option>
|
||||
<?php /*
|
||||
$selected='';
|
||||
$htmlname='idprod';
|
||||
$status=-1;
|
||||
$rice_level=$company->price_level;
|
||||
print ajax_autocompleter($selected, $htmlname, DOL_URL_ROOT.'/product/ajaxproducts.php', 'outjson=1&price_level='.$price_level.'&type='.$filtertype.'&mode=1&status='.$status.'&finished='.$finished, $conf->global->PRODUIT_USE_SEARCH_TO_SELECT);
|
||||
if (! $hidelabel) print $langs->trans("RefOrLabel").' : ';
|
||||
print '<input type="text" size="4" name="search_'.$htmlname.'" id="search_'.$htmlname.'" value="'.$selected_input_value.'" />';
|
||||
*/
|
||||
?>
|
||||
|
||||
<select id="selProduit" name="selProduit" onchange="javascript: setSource('LISTE');">
|
||||
<?php
|
||||
print '<option value="0">'.$top_liste_produits.'</option>'."\n";
|
||||
|
||||
$id = $obj_facturation->id();
|
||||
|
||||
@ -93,7 +103,7 @@ $Id$
|
||||
</select>
|
||||
</td>
|
||||
</tr>
|
||||
<tr><td><div id="resultats_dhtml"></div></td></tr>
|
||||
<!-- <tr><td><div id="resultats_dhtml"></div></td></tr> -->
|
||||
</table>
|
||||
</form>
|
||||
|
||||
|
||||
@ -38,36 +38,43 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
ORDER BY id';
|
||||
dol_syslog($request);
|
||||
$res = $db->query ($request);
|
||||
if ( $db->num_rows($res) ) {
|
||||
if (! $res)
|
||||
{
|
||||
dol_print_error($db);
|
||||
exit;
|
||||
}
|
||||
|
||||
if ( $db->num_rows($res) )
|
||||
{
|
||||
|
||||
$ret=array(); $i=0;
|
||||
|
||||
|
||||
/** add Ditto for MultiPrix*/
|
||||
$thirdpartyid = $_SESSION['CASHDESK_ID_THIRDPARTY'];
|
||||
$societe = new Societe($db);
|
||||
$societe->fetch($thirdpartyid);
|
||||
/** end add Ditto */
|
||||
|
||||
/** end add Ditto */
|
||||
|
||||
while ( $tab = $db->fetch_array($res) )
|
||||
{
|
||||
foreach ( $tab as $cle => $valeur )
|
||||
{
|
||||
$ret[$i][$cle] = $valeur;
|
||||
}
|
||||
|
||||
|
||||
/** add Ditto for MultiPrix*/
|
||||
if($conf->global->PRODUIT_MULTIPRICES)
|
||||
{
|
||||
$product = new Product($db, $ret[$i]['id']);
|
||||
|
||||
|
||||
if(isset($product->multiprices[$societe->price_level]))
|
||||
{
|
||||
$ret[$i]['price'] = $product->multiprices_ttc[$societe->price_level];
|
||||
}
|
||||
}
|
||||
/** end add Ditto */
|
||||
|
||||
|
||||
}
|
||||
/** end add Ditto */
|
||||
|
||||
|
||||
$i++;
|
||||
}
|
||||
$tab = $ret;
|
||||
|
||||
Loading…
Reference in New Issue
Block a user