/** * PageColumn constructor. * * @param int $sort * @param Page $type * @param string $table */ public function __construct($sort, Page $type, $table = '') { if ($type->isMulti()) { throw new StructException('PageColumns can not be multi value types!'); } parent::__construct($sort, $type, 0, true, $table); }
public function test_ajax_postfix() { global $INPUT; $page = new Page(array('autocomplete' => array('mininput' => 2, 'maxresult' => 5, 'namespace' => '', 'postfix' => 'iki'))); $INPUT->set('search', 'oku'); $this->assertEquals(array(array('label' => 'dokuwiki (wiki)', 'value' => 'wiki:dokuwiki')), $page->handleAjax()); }