'._INCOMING.'
'; $left_html .= '
'; $left_html .= ''; } // AVANCEMENT $left_html .= '
Avancement
'; $left_html .= '

'. _WF .'

'; $left_html .= ''; $left_html .= '
'; $left_html .= '
'; $left_html .= ''; $left_html .= '<<'; $left_html .= ' '. _ALL_HISTORY .''; $left_html .= ''; $left_html .= ''; $left_html .= '
'; //CIRCUIT $left_html .= '
'._VISA_WORKFLOW.'
'; $left_html .= '

'. _VISA_WORKFLOW .'

'; $modifVisaWorkflow = false; if ($core->test_service('config_visa_workflow', 'visa', false)) { $modifVisaWorkflow = true; } $visa = new visa(); $left_html .= '
'; $left_html .= '
'; $left_html .= $visa->getList($res_id, $coll_id, $modifVisaWorkflow, 'VISA_CIRCUIT', true); $left_html .= '

'; $left_html .= '
'; $left_html .= '
'; $left_html .= ''; $left_html .= '<<'; $left_html .= ' Historique du circuit de visa'; $left_html .= ''; $left_html .= ''; $left_html .= '
'; //NOTES if ($core->is_module_loaded('notes')){ require_once "modules" . DIRECTORY_SEPARATOR . "notes" . DIRECTORY_SEPARATOR . "class" . DIRECTORY_SEPARATOR . "class_modules_tools.php"; $notes_tools = new notes(); //Count notes $nbr_notes = $notes_tools->countUserNotes($res_id, $coll_id); if ($nbr_notes > 0 ) $nbr_notes = ' ('.$nbr_notes.')'; else $nbr_notes = ''; $left_html .= '
'. _NOTES.$nbr_notes .'

'. _NOTES .'

'; } /* Partie droite */ $right_html = ''; $tab_path_rep_file = $visa->get_rep_path($res_id, $coll_id); $cptAttach = count($tab_path_rep_file); if ($cptAttach < 6) { $viewMode = 'extended'; } elseif ($cptAttach < 10) { $viewMode = 'small'; } else { $viewMode = 'verysmall'; } for ($i=0; $i 15) $titleRep = substr($tab_path_rep_file[$i]['title'],0,15) . '...'; else $titleRep = $tab_path_rep_file[$i]['title']; } if ($tab_path_rep_file[$i]['attachment_type'] == 'signed_response') { $titleRep = '' . $titleRep; } //if (strlen($tab_path_rep_file[$i]['title']) > 20) $titleRep = substr($tab_path_rep_file[$i]['title'],0,20).'...'; //else $titleRep = $tab_path_rep_file[$i]['title']; $titleRep = str_replace("'", "'",$titleRep); $right_html .= '
' . $titleRep . '
'; $right_html .= ''; $right_html .= '
'; } $db = new Database(); $stmt = $db->query("select res_id from res_view_attachments where status NOT IN ('DEL','OBS') and attachment_type <> 'converted_pdf' and attachment_type <> 'print_folder' and res_id_master = ? and coll_id = ?",array($res_id,$coll_id)); if ($stmt->rowCount() > 0) { $nb_attach = ' (' . $stmt->rowCount(). ')'; } $right_html .= '
PJ ' . $nb_attach.'
'; if ($core->is_module_loaded('attachments')) { require 'modules/templates/class/templates_controler.php'; $templatesControler = new templates_controler(); $templates = array(); $templates = $templatesControler->getAllTemplatesForProcess($curdest); $_SESSION['destination_entity'] = $curdest; //var_dump($templates); $right_html .= '
'; $right_html .= '
'; $right_html .= '
'; $right_html .= '

' . _PJ . ', ' . _ATTACHEMENTS . '

'; $stmt = $db->query("select res_id from ".$_SESSION['tablename']['attach_res_attachments'] . " where (status = 'A_TRA' or status = 'TRA' or status = 'SIGN') and attachment_type <> 'converted_pdf' and attachment_type <> 'print_folder' and res_id_master = ? and coll_id = ?", array($res_id,$coll_id)); $nb_attach = 0; if ($stmt->rowCount() > 0) { $nb_attach = $stmt->rowCount(); } $right_html .= '
'; $right_html .= '
'; if ($core->is_module_loaded('templates')) { $right_html .= ''; } $right_html .= '
'; $right_html .= '
'; $right_html .= '
'; $right_html .= '
'; $right_html .= '
'; $right_html .= '
'; } $right_html .= '
'; $valid_but = 'valid_action_form( \'index_file\', \'index.php?display=true&page=manage_action&module=core\', \''.$_REQUEST['action'].'\', \''.$res_id.'\', \'res_letterbox\', \'null\', \''.$coll_id.'\', \'page\');'; //echo "{status : 1,avancement:'".$avancement_html."',circuit:'".$circuit_html."',notes_dt:'".$notes_html_dt."',notes_dd:'".$notes_html_dd."'}"; echo "{status : 1,left_html:'".addslashes($left_html)."',right_html:'".addslashes($right_html)."',valid_button:'".addslashes($valid_but)."',id_rep:'".$tab_path_rep_file[0]['res_id']."',is_vers_rep:'".$tab_path_rep_file[0]['is_version']."'}"; exit();