noalyss  Version-6.7.2
 All Data Structures Namespaces Files Functions Variables Enumerations
ledger_detail_bottom.php
Go to the documentation of this file.
00001 <?php
00002     $cmd=new IText('BON_COMMANDE',$obj->info->command);
00003     $other=new IText('OTHER',$obj->info->other);
00004 ?>
00005 <div class="myfieldset">
00006     <h1 class="legend"><?php echo _("Information")?></h1>
00007     <table>
00008         <tr>
00009             <td><?php echo _(" Bon de commande")?>   :</td><td> <?php echo HtmlInput::infobulle(31)." ".$cmd->input();  ?></td>
00010         </tr>
00011         <tr>
00012             <td> <?php echo _("Autre information")?> : </td><td><?php echo HtmlInput::infobulle(30)." ".$other->input();?></td>
00013         </tr>
00014     </table>
00015 </div>
00016 <div class="myfieldset">
00017 <h1 class="legend">
00018 <?php echo _('Rapprochement');?>
00019 </h1>
00020 <?php 
00021 $oRap=new Acc_Reconciliation($cn);
00022 $oRap->jr_id=$jr_id;
00023 $aRap=$oRap->get();
00024 if ($aRap  != null ) {
00025   $tableid="tb".$div;
00026   echo '<table id="'.$tableid.'">';
00027   for ($e=0;$e<count($aRap);$e++)  {
00028     $opRap=new Acc_Operation($cn);
00029     $opRap->jr_id=$aRap[$e];
00030     $internal=$opRap->get_internal();
00031     $array_jr=$cn->get_array('select jr_montant,jr_comment from jrn where jr_id=$1',array($aRap[$e]));
00032     $amount=$array_jr[0]['jr_montant'];
00033     $str="modifyOperation(".$aRap[$e].",".$gDossier.")";
00034     $rmReconciliation=new IButton('rmr');
00035     $rmReconciliation->label='enlever';
00036     $rmReconciliation->javascript="if (confirm ('vous confirmez?') ) {";
00037     $rmReconciliation->javascript.=sprintf('dropLink(\'%s\',\'%s\',\'%s\',\'%s\');deleteRowRec(\'%s\',this);}',
00038                                           $gDossier,
00039                                           $div,
00040                                           $jr_id,
00041                                            $aRap[$e],
00042                                            $tableid
00043                                           );
00044     if ( $access=='W')
00045       $remove=$rmReconciliation->input();
00046     else
00047       $remove='';
00048         $comment=strip_tags($array_jr[0]['jr_comment']);
00049     echo tr (td('<a class="line" href="javascript:void(0)" onclick="'.$str.'" >'.$internal.'</A>').td(nbm($amount)).td($comment).td($remove));
00050   }
00051   echo '</table>';
00052 }
00053 ?>
00054 <?php 
00055 if ( $access=='W') {
00056      $wConcerned=new IConcerned("rapt".$div);
00057      $wConcerned->amount_id=$obj->det->jr_montant;
00058     echo $wConcerned->input();
00059 
00060 }
00061 ?>
00062 </div>
00063 <?php 
00064 $array = Follow_Up::get_all_operation($jr_id);
00065 if (count($array) > 0)
00066 {
00067         ?>
00068         <div class="myfieldset">
00069                 <h1 class="legend">Actions liƩes</h1>
00070         <?php 
00071         /**
00072          * show eventually action
00073          */
00074         $array = Follow_Up::get_all_operation($jr_id);
00075         echo '<ul style="list-style-type:square;">';
00076         for ($i = 0; $i < count($array); $i++)
00077         {
00078                 if ( $div == 'popup')
00079                 {
00080                         echo '<li>'.HtmlInput::detail_action($array[$i]['ag_id'], h($array[$i]['ag_ref']." ".$array[$i]['ag_title']),0).'</li>';
00081                 }
00082                 else
00083                 {
00084                         echo '<li>'.HtmlInput::detail_action($array[$i]['ag_id'], h($array[$i]['ag_ref']." ".$array[$i]['ag_title']),1).'</li>';
00085                 }
00086         }
00087         echo '</ul>';
00088 
00089         echo '</div>';
00090 }
00091 ?>
00092 
00093 <?php 
00094 
00095 require_once('template/ledger_detail_file.php');
00096 ?>
00097 <hr>
00098 <?php 
00099 
00100 if ( $div != 'popup' ) {
00101   $a=new IButton('Fermer',_('Fermer'));
00102   $a->label=_("Fermer");
00103   $a->javascript="removeDiv('".$div."')";
00104   echo $a->input();
00105 }
00106 
00107 ?>
00108 <?php 
00109 
00110 /**
00111  * if you can write
00112  */
00113   if ( $access=='W') {
00114   echo HtmlInput::submit('save',_('Sauver'),'onClick="return verify_ca(\'popup\');"');
00115   $owner=new Own($cn);
00116   if ($owner->MY_ANALYTIC != 'nu' && $div=='popup'){
00117     echo '<input type="button" class="button" value="'._('verifie CA').'" onClick="verify_ca(\'popup\');">';
00118   }
00119 
00120   $per=new Periode($cn,$obj->det->jr_tech_per);
00121   if ( $per->is_closed() == 0 && $owner->MY_STRICT=='N'){
00122     $remove=new IButton('Effacer');
00123     $remove->label=_('Effacer');
00124     $remove->javascript="if ( confirm('Vous confirmez effacement ?')) {removeOperation('".$obj->det->jr_id."',".dossier::id().",'".$div."')}";
00125     echo $remove->input();
00126   }
00127 
00128   $reverse=new IButton('bext'.$div);
00129   $reverse->label=_('Extourner');
00130   $reverse->javascript="g('ext".$div."').style.display='block'";
00131   echo $reverse->input();
00132 
00133 echo '</form>';
00134 
00135   echo '<div id="ext'.$div.'" style="display:none">';
00136   $date=new IDate('ext_date');
00137   $r="<form id=\"form_".$div."\" onsubmit=\"this.divname='$div';return reverseOperation(this);\">";
00138   $r.=HtmlInput::hidden('jr_id',$_REQUEST['jr_id']).HtmlInput::hidden('div',$div).dossier::hidden().HtmlInput::hidden('act','reverseop');
00139   $r.='<h2 class="info">Extourner </H2>';
00140   $r.="entrez une date :".$date->input();
00141   $r.=HtmlInput::submit('x','accepter','onclick="return confirm(\'Vous confirmez  ? \');"');
00142   $r.='</form>';
00143   echo $r;
00144   echo '</div>';
00145 
00146 
00147 
00148 }
00149 ?>
 All Data Structures Namespaces Files Functions Variables Enumerations