From 8b6a1300e44616647d0b3402e83dcaf0b9dc8283 Mon Sep 17 00:00:00 2001 From: benoitpotier Date: Tue, 21 Mar 2017 16:17:48 +0100 Subject: [PATCH] progress confidentiel --- library/Metier/Partenaires/MBilans.php | 5 +++-- library/WsScore/Entreprise/v0.8/Service.php | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/library/Metier/Partenaires/MBilans.php b/library/Metier/Partenaires/MBilans.php index 9340e199..487f652e 100644 --- a/library/Metier/Partenaires/MBilans.php +++ b/library/Metier/Partenaires/MBilans.php @@ -363,7 +363,7 @@ class Metier_Partenaires_MBilans // --- 0 : consultation de l'application (calcul du score ...) // --- 1 : consultation d'un membre de scores et décisions if ($idClient > 1) { - $where.= " AND (confidentiel = '".$idClient."' OR confidentiel = 0)"; + $where.= " AND (confidentiel_client == '".$idClient."' OR confidentiel = 0)"; } $where.= " ORDER BY dateExercice DESC, CASE typeBilan WHEN 'N' THEN 1 WHEN 'S' THEN 2 ELSE 3 END"; @@ -371,7 +371,7 @@ class Metier_Partenaires_MBilans $where.= " LIMIT 0, $nbMaxBilans"; } - $fields = "typeBilan, dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaieOrigine, dateInsert, partenaire, confidentiel"; + $fields = "typeBilan, dateProvPartenaire, dateExercice, dateExercicePre, dureeExercice, dureeExercicePre, monnaieOrigine, dateInsert, partenaire, confidentiel, confidentiel_client"; $listeNb = 0; try { $listeSql = "SELECT $fields FROM jo.bilans WHERE $where"; @@ -400,6 +400,7 @@ class Metier_Partenaires_MBilans 'monnaie' => $bil['monnaieOrigine'], 'source' => $bil['partenaire'], 'confidentiel' => $bil['confidentiel'], + 'confidentielClient' => $bil['confidentiel_client'], ); $tabTri[''.$bil['dateExercice'].'-'.$bil['typeBilan']] = $bil['typeBilan'].$millesime; } diff --git a/library/WsScore/Entreprise/v0.8/Service.php b/library/WsScore/Entreprise/v0.8/Service.php index fb5e4608..c4ea7563 100644 --- a/library/WsScore/Entreprise/v0.8/Service.php +++ b/library/WsScore/Entreprise/v0.8/Service.php @@ -4331,6 +4331,7 @@ class Entreprise extends Scores_Ws_Server $element->monnaie = $bilan['monnaie']; $element->source = $bilan['source']; $element->confidentiel = $bilan['confidentiel']; + $element->confidentielClient = $bilan['confidentielClient']; $tabRet[] = $element; }