request('sb',"string",'list');
/*! \file
* \brief Called from the module 'Gestion' to manage the supplier
*/
$href=basename($_SERVER['PHP_SELF']);
// by default open liste
if ( $low_action == '' )
$low_action='list';
//-----------------------------------------------------
// Remove a card
//-----------------------------------------------------
if ( isset($_POST['delete_card'] ) )
{
if ( $g_user->check_action(FICADD) == 0 )
{
alert(_('Vous ne pouvez pas enlever de fiche'));
return;
}
$f_id=$_REQUEST['f_id'];
$fiche=new Bank($cn,$f_id);
$fiche->remove();
$low_action="list";
}
//-----------------------------------------------------
// list of supplier
//-----------------------------------------------------
if ( $low_action == "list" )
{
?>
';
echo $supplier->Summary($search,'bank',$sql,$noop);
echo '
';
echo '
';
echo '
';
if ($g_user->check_action(FICADD)==1)
{
/* Add button */
$f_add_button=new IButton('add_card');
$f_add_button->label=_('Créer une nouvelle fiche');
$f_add_button->set_attribute('win_refresh','yes');
$f_add_button->set_attribute('type_cat',FICHE_TYPE_FIN);
$f_add_button->javascript=" select_card_type(this);";
echo $f_add_button->input();
$f_cat_button=new IButton('add_cat');
$f_cat_button->set_attribute('type_cat',FICHE_TYPE_FIN);
$f_cat_button->set_attribute('ipopup','ipop_cat');
$f_cat_button->label=_('Ajout d\'une catégorie');
$f_cat_button->javascript='add_category(this)';
echo $f_cat_button->input();
}
echo '
';
echo '';
}
/*----------------------------------------------------------------------
* Detail for a card, Suivi, Contact, Operation,... *
* cc stands for supplier card
*----------------------------------------------------------------------*/
if ( $low_action == 'detail')
{
/* Menu */
require_once('category_card.inc.php');
return;
}
html_page_stop();
?>