Go to the documentation of this file.00001 <?php
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028 if ( ! defined ('ALLOWED') ) die('Appel direct ne sont pas permis');
00029 require_once('class_contact.php');
00030
00031 $str_dossier=Dossier::get();
00032
00033
00034 $root='?ac='.$_REQUEST['ac']."&sb=detail&f_id=".$_REQUEST["f_id"].'&'.$str_dossier;
00035 $ss_action=( isset ($_REQUEST['sc'] ))? $_REQUEST['sc']: '';
00036 switch ($ss_action)
00037 {
00038 case 'dc':
00039 $def=1;
00040 break;
00041 case 'sv':
00042 $def=2;
00043 break;
00044 case 'cn':
00045 $def=3;
00046 break;
00047 case 'op':
00048 $def=4;
00049 break;
00050 case 'let':
00051 $def=6;
00052 break;
00053 case 'bal':
00054 $def=7;
00055 break;
00056 default:
00057 $def=1;
00058 $ss_action='dc';
00059 }
00060 $f=new Fiche($cn,$_REQUEST['f_id']);
00061
00062 echo '<div class="content">';
00063 echo $f->get_gestion_title();
00064 echo ShowItem(array(
00065 array($root."&sc=dc",_('Fiche'),_('Détail de la fiche'),1),
00066 array($root.'&sc=sv',_('Suivi'),_('Suivi Fournisseur, client, banque, devis, bon de commande, courrier'),2),
00067 array($root.'&sc=cn',_('Contact'),_('Liste de contacts'),3),
00068 array($root.'&sc=op',_('Opérations'),_('Toutes les opérations'),4),
00069 array($root.'&sc=bal',_('Balance'),_('Balance du fournisseur'),7),
00070 array($root.'&sc=let',_('Lettrage'),_('Opérations & Lettrages'),6)
00071 ),
00072 'H',"mtitle","mtitle",$def,' ');
00073 echo '</div>';
00074 echo '<div>';
00075
00076
00077
00078
00079
00080 if ( $ss_action == 'dc' )
00081 {
00082 require_once('category_detail.inc.php');
00083 }
00084
00085
00086
00087 if ( $ss_action == 'sv' )
00088 {
00089 require_once('category_followup.inc.php');
00090 }
00091
00092
00093
00094
00095 if ( $ss_action == 'op')
00096 {
00097 require_once('category_operation.inc.php');
00098 }
00099
00100
00101
00102 if ( $ss_action=='bal')
00103 {
00104 require_once('balance_card.inc.php');
00105 }
00106
00107
00108
00109
00110 if ( $ss_action == 'cn')
00111 {
00112 echo '<div class="content">';
00113
00114 echo dossier::hidden();
00115 $f = new Fiche($cn, $_REQUEST['f_id']);
00116 $contact=new Contact($cn);
00117 $contact->company=$f->get_quick_code();
00118 echo $contact->summary("");
00119
00120 $sql=' select fd_id from fiche_def where frd_id='.FICHE_TYPE_CONTACT;
00121 $filter=$cn->make_list($sql);
00122 if ( empty ($filter))
00123 {
00124 echo '<span class="notice">';
00125 echo _("Vous devez aller dans fiche et créer une catégorie pour les contacts");
00126 echo '</span>';
00127 exit();
00128 }
00129
00130 $f_add_button=new IButton('add_card');
00131 $f_add_button->label=_('Créer une nouvelle fiche');
00132
00133 $f_add_button->set_attribute('filter',$filter);
00134 $f_add_button->javascript=" select_card_type(this);";
00135
00136 echo $f_add_button->input();
00137 echo '</div>';
00138 }
00139
00140
00141
00142 if ( $def==6 )
00143 {
00144 require_once('lettering.gestion.inc.php');
00145 }