@@ 21-27 (lines=7) @@ | ||
18 | */ |
|
19 | class DataElement extends Widget { |
|
20 | ||
21 | public function __construct($identifier, $modelInstance=NULL) { |
|
22 | parent::__construct($identifier, null,$modelInstance); |
|
23 | $this->_instanceViewer=new InstanceViewer(); |
|
24 | $this->content=["table"=>new HtmlTable($identifier, 0,2)]; |
|
25 | $this->content["table"]->setDefinition(); |
|
26 | $this->_toolbarPosition=PositionInTable::BEFORETABLE; |
|
27 | } |
|
28 | ||
29 | public function compile(JsUtils $js=NULL,&$view=NULL){ |
|
30 | $this->_instanceViewer->setInstance($this->_modelInstance); |
@@ 42-47 (lines=6) @@ | ||
39 | parent::run($js); |
|
40 | } |
|
41 | ||
42 | public function __construct($identifier,$model,$modelInstance=NULL) { |
|
43 | parent::__construct($identifier, $model,$modelInstance); |
|
44 | $this->_instanceViewer=new InstanceViewer(); |
|
45 | $this->content=["table"=>new HtmlTable($identifier, 0,0)]; |
|
46 | $this->_toolbarPosition=PositionInTable::BEFORETABLE; |
|
47 | } |
|
48 | ||
49 | public function compile(JsUtils $js=NULL,&$view=NULL){ |
|
50 | $this->_instanceViewer->setInstance($this->_model); |