diff --git a/VERSIONS_HOTLINE/94332 b/VERSIONS_HOTLINE/94332 new file mode 100644 index 0000000000000000000000000000000000000000..9e55ba4e3a4c7e77a17c670c1a56993eb04e8ad2 --- /dev/null +++ b/VERSIONS_HOTLINE/94332 @@ -0,0 +1 @@ + - ticket #94332 : WebService : amélioration de l'affichage des sites de retraits des reservations. \ No newline at end of file diff --git a/application/modules/opac/controllers/RechercheController.php b/application/modules/opac/controllers/RechercheController.php index f7bd5adbbe08fcfb7b23211dc85d5a546bbf808c..bded529f364f4075dfb80925e723bad72bb14d39 100644 --- a/application/modules/opac/controllers/RechercheController.php +++ b/application/modules/opac/controllers/RechercheController.php @@ -743,8 +743,11 @@ class RechercheController extends ZendAfi_Controller_Action { 'class' => 'zend_form reservation_pickup', 'action' => $this->view->url(['controller' => 'recherche', 'action' => $action])]) - ->addElement('Radio', 'code_annexe', ['required' => true, - 'allowEmpty' => false]) + ->addElement('Radio', + 'code_annexe', + ['required' => true, + 'allowEmpty' => false, + 'escape' => false]) ->addDisplayGroup(['code_annexe'], 'group', ['legend' => 'Site de retrait']); } diff --git a/tests/application/modules/opac/controllers/RechercheControllerReservationTest.php b/tests/application/modules/opac/controllers/RechercheControllerReservationTest.php index 35d11009686023ab40ec69e30a74cddd6a6f4104..a30d24dc17324037de2b805c39fb64c56fe3065d 100644 --- a/tests/application/modules/opac/controllers/RechercheControllerReservationTest.php +++ b/tests/application/modules/opac/controllers/RechercheControllerReservationTest.php @@ -800,7 +800,8 @@ abstract class RechercheControllerReservationPickupAjaxWithNanookPickupLocations ->whenCalled('pickupLocationsFor') ->answers(['36' => 'Annecy', '37' => 'Cran', - '45' => 'Istres']); + '45' => 'Istres', + '99' => 'Lunel <strong>(Disponible)</strong>']); Class_WebService_SIGB_Nanook::setService(['url_serveur' => 'http://bib.valensol.net', 'id_bib' => 12, @@ -899,6 +900,30 @@ class RechercheControllerReservationPickupAjaxNanookPickupLocationsPrecheckFirst } +class RechercheControllerReservationPickupAjaxNanookPickupLocationsStrongInLabel + extends RechercheControllerReservationPickupAjaxWithNanookPickupLocationsTestCase { + + public function setUp() { + parent::setUp(); + + $this->nanook->whenCalled('getUserAnnexe')->answers('66'); + + $this->dispatch('recherche/reservation-pickup-ajax?id_bib=2&id_origine=12&code_annexe=99©_id=12', true); + + $this->_json = json_decode($this->_response->getBody()); + } + + + /** + @see https://forge.afi-sa.net/issues/94332 + @test + */ + public function LunelShouldContainStrong() { + $this->_xpath + ->assertXPath($this->_json->content, '//strong',$this->_json->content); + } +} + class RechercheControllerReservationPickupAjaxAndNotifyByMailEnabledTest extends RechercheControllerReservationWithPickupChoiceTestCase {