示例#1
0
 public function testFrequencyNotDisplayedWhenDisabled()
 {
     $select = new Select('id', ['items' => [new Option('bar', 'Bar', 2, true)]]);
     $select->hideFrequency();
     $expected = '<select class="SelectFilter AppFilter--id" name="id">' . PHP_EOL . '<option value="bar" selected="selected">Bar</option>' . PHP_EOL . '</select>';
     $this->assertEquals($expected, $select->render());
 }
示例#2
0
 /**
  * @return string
  */
 public function getContainerClass()
 {
     return parent::getContainerClass() . ' form-control' . ($this->size ? ' input-' . $this->size : '');
 }