diff --git a/apps/maarch_entreprise/actions/confirm_status.php b/apps/maarch_entreprise/actions/confirm_status.php index ee5191c6543d77cf0b783ff178cc437bebd16678..7c9da1db9350c028ca042df225f1f92722851d02 100755 --- a/apps/maarch_entreprise/actions/confirm_status.php +++ b/apps/maarch_entreprise/actions/confirm_status.php @@ -134,7 +134,6 @@ function manage_form($arr_id, $history, $id_action, $label_action, $status, $col $_SESSION['action_error'] = ''; $result = ''; $coll_id = $_SESSION['current_basket']['coll_id']; - $res_id = $arr_id[0]; require_once("core/class/class_security.php"); $sec = new security(); $table = $sec->retrieve_table_from_coll($coll_id); @@ -142,13 +141,19 @@ function manage_form($arr_id, $history, $id_action, $label_action, $status, $col # save note if($formValues['note_content_to_users'] != ''){ //Add notes - $nb_avis = $sequence +1; - $userIdTypist = $_SESSION['user']['UserId']; - $content_note = $formValues['note_content_to_users']; - $content_note = str_replace(";", ".", $content_note); - $content_note = str_replace("--", "-", $content_note); - $content_note = $content_note; - $note->addNote($res_id, $coll_id, $content_note); + $msgResult = ""; + foreach($arr_id as $res_id){ + $nb_avis = $sequence +1; + $userIdTypist = $_SESSION['user']['UserId']; + $content_note = $formValues['note_content_to_users']; + $content_note = str_replace(";", ".", $content_note); + $content_note = str_replace("--", "-", $content_note); + $content_note = $content_note; + $msgResult .= $res_id.'#'; + $note->addNote($res_id, $coll_id, $content_note); + + } + } return array('result' => $res_id.'#', 'history_msg' => '');