diff --git a/library/Class/CriteresRecherche.php b/library/Class/CriteresRecherche.php index 07a151352f372a2b24375581b54af63ae94ac8f5..283e37be9e9d3742822f015ac1f3e84f8ef42ddf 100644 --- a/library/Class/CriteresRecherche.php +++ b/library/Class/CriteresRecherche.php @@ -210,16 +210,16 @@ class Class_CriteresRecherche { public function getPanier() { - $id_panier=$this->getParam('id_panier',''); if ($id_user=$this->getParam('id_user')) return Class_PanierNotice::getLoader()->findFirstBy(array('id_user' => $id_user, - 'id_panier' => $id_panier)); + 'id_panier' => $id_panier)); if ($id_panier) return Class_PanierNotice::find($id_panier); return null; } + public function visitCatalogue($visitor, $catalogue) { $this->setParams($catalogue->buildCriteresRecherche($this->getCriteres())); if ($catalogue->getCoteDebut()||$catalogue->getCoteFin()) @@ -228,8 +228,6 @@ class Class_CriteresRecherche { $visitor->visitNouveaute(0); if ($catalogue->getAnneeDebut() || $catalogue->getAnneeFin()) $visitor->visitAnneeDebutFin($catalogue->getAnneeDebut(),$catalogue->getAnneeFin()); - - } diff --git a/tests/library/Class/CatalogueTest.php b/tests/library/Class/CatalogueTest.php index d2920f91f8582acb4ebce64b73ff0e389242aca0..a2880861e0832d7563ca476d1632dad6806d2736 100644 --- a/tests/library/Class/CatalogueTest.php +++ b/tests/library/Class/CatalogueTest.php @@ -417,12 +417,13 @@ class CatalogueTestGetNoticesByPreferences extends ModelTestCase { $this->mock_sql ->whenCalled('fetchAll') - ->with("select notices.id_notice, notices.editeur, notices.annee, notices.date_creation, notices.facettes, notices.clef_oeuvre from notices order by alpha_titre LIMIT 0,25", + ->with("select notices.id_notice, notices.editeur, notices.annee, notices.date_creation, notices.date_maj, notices.facettes, notices.clef_oeuvre from notices order by alpha_titre LIMIT 0,25", false) ->answers(array(array('id_notice' => 23, 'editeur' => 'dargaud', 'annee' => 1975, 'date_creation' => '2011-02-23', + 'date_maj' => '2011-02-25', 'facettes' => '', 'clef_oeuvre' => 'JEUNE FILLE'))) ->beStrict(); diff --git a/tests/library/ZendAfi/View/Helper/Accueil/TagsTest.php b/tests/library/ZendAfi/View/Helper/Accueil/TagsTest.php index 80202637df36837b52085beed96aece419c33dd4..7c805a44826c73d05cafab83cdb0bacef1fdde4c 100644 --- a/tests/library/ZendAfi/View/Helper/Accueil/TagsTest.php +++ b/tests/library/ZendAfi/View/Helper/Accueil/TagsTest.php @@ -33,6 +33,7 @@ class TagsTest extends ViewHelperTestCase { 'editeur' => '', 'annee' => '', 'date_creation' => '', + 'date_maj' => '', 'clef_oeuvre' => ''); Class_Notice::newInstanceWithId(34, $notice_enreg);