Skip to content
Snippets Groups Projects
Commit c0cc95bb authored by Ghislain Loas's avatar Ghislain Loas Committed by Laurent
Browse files

hackfest domain selector in search widget : wrap selector in div + fix label for

parent 60cc533e
Branches
Tags
3 merge requests!2080Sandbox detach zf from storm,!1940Dev#48981 3455 lier des cartes via bokeh,!1929Dev#48981 3455 lier des cartes via bokeh
......@@ -189,15 +189,15 @@ class ZendAfi_View_Helper_TagRechercheSimple extends Zend_View_Helper_HtmlElemen
protected function _renderDomainSelectAsSelect($domains) {
$domains = [0 => $this->view->_('Partout')] + $domains;
return $this->view->tag('label',
$this->view->_('Rechercher dans le domaine')
.
$this->view->formSelect(
'facettes',
0,
[],
$domains),
['for' => 'id_catalogue']);
return $this->view->tag('div',
$this->view->tag('label',
$this->view->_('Rechercher dans le domaine'),
['for' => 'facettes'])
. $this->view->formSelect(
'facettes',
0,
[],
$domains));
}
......
......@@ -113,6 +113,16 @@ class ZendAfi_View_Helper_TagRechercheSimpleDefaultTest extends ViewHelperTestCa
}
/**
* @depends withDomainSelectInputShouldBePresent
* @test
*/
public function domainSelectLabelShouldBePrensent($html) {
$this->assertXPath($html,
'//div/label[@for="facettes"][following-sibling::select[@name="facettes"]/option[1][@value="0"][@selected="selected"]]');
}
/**
* @depends withDomainSelectInputShouldBePresent
* @test
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment