Skip to content

Commit 9ee10e5

Browse files
committed
_identifier for view connection
1 parent a384bc2 commit 9ee10e5

File tree

12 files changed

+16
-8
lines changed

12 files changed

+16
-8
lines changed

Ajax/common/html/BaseHtml.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ public function compile(JsUtils $js=NULL, &$view=NULL) {
201201
if (isset($js)===true) {
202202
$this->run($js);
203203
if (isset($view) === true) {
204-
$js->addViewElement($this->identifier, $result, $view);
204+
$js->addViewElement($this->_identifier, $result, $view);
205205
}
206206
}
207207
return $result;

Ajax/common/html/BaseWidget.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,11 @@
99
*/
1010
abstract class BaseWidget {
1111
protected $identifier;
12+
protected $_identifier;
1213

1314
public function __construct($identifier) {
1415
$this->identifier=$this->cleanIdentifier($identifier);
16+
$this->_identifier=$this->identifier;
1517
}
1618

1719
public function getIdentifier() {

Ajax/common/html/traits/BaseHtmlEventsTrait.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -173,4 +173,8 @@ public function jsShow() {
173173
public function jsHide() {
174174
return $this->jsDoJquery("hide");
175175
}
176+
177+
public function jsToggle($value) {
178+
return $this->jsDoJquery("hide",$value);
179+
}
176180
}

Ajax/semantic/html/collections/HtmlGrid.php

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,6 @@ public function setWide($wide) {
5656
}
5757
return $this;
5858
}
59-
60-
public function setColWidth($numCol,$width){
61-
foreach ($this->content as $row){
62-
$row->getCol($numCol)->setWidth($width);
63-
}
64-
}
6559

6660
/**
6761
* Defines the grid width
@@ -318,4 +312,4 @@ public function addDivider($afterColIndex, $vertical=true, $content=NULL) {
318312
$col=$this->getCell(0, $afterColIndex);
319313
return $col->addDivider($vertical, $content);
320314
}
321-
}
315+
}

Ajax/semantic/html/collections/form/HtmlFormCheckbox.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ class HtmlFormCheckbox extends HtmlFormField {
1616
use CheckboxTrait;
1717
public function __construct($identifier, $label=NULL, $value=NULL, $type=NULL) {
1818
parent::__construct("field-".$identifier, new HtmlCheckbox($identifier,$label,$value,$type));
19+
$this->_identifier=$identifier;
1920
}
2021

2122
public static function slider($identifier, $label="", $value=NULL) {

Ajax/semantic/html/collections/form/HtmlFormDropdown.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ class HtmlFormDropdown extends HtmlFormField {
99

1010
public function __construct($identifier,$items=array(), $label=NULL,$value=NULL,$multiple=false,$associative=true) {
1111
parent::__construct("field-".$identifier, (new HtmlDropdown("dropdown-".$identifier,$value,$items,$associative))->asSelect($identifier,$multiple), $label);
12+
$this->_identifier=$identifier;
1213
}
1314

1415
public function setItems($items){

Ajax/semantic/html/collections/form/HtmlFormInput.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ public function __construct($identifier, $label=NULL,$type="text",$value=NULL,$p
1212
if(!isset($placeholder) && $type==="text")
1313
$placeholder=$label;
1414
parent::__construct("field-".$identifier, new HtmlInput($identifier,$type,$value,$placeholder), $label);
15+
$this->_identifier=$identifier;
1516
}
1617

1718
public function getDataField(){

Ajax/semantic/html/collections/form/HtmlFormRadio.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,6 @@ class HtmlFormRadio extends HtmlFormField {
1616

1717
public function __construct($identifier, $name=NULL, $label=NULL, $value=NULL, $type=NULL) {
1818
parent::__construct("field-".$identifier, new HtmlRadio($identifier, $name, $label, $value, $type));
19+
$this->_identifier=$identifier;
1920
}
2021
}

Ajax/semantic/html/collections/form/HtmlFormTextarea.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ public function __construct($identifier, $label=NULL,$value=NULL,$placeholder=NU
1313
if(!isset($placeholder))
1414
$placeholder=$label;
1515
parent::__construct("field-".$identifier, new HtmlTextarea($identifier,$value,$placeholder,$rows), $label);
16+
$this->_identifier=$identifier;
1617
}
1718

1819
/**

Ajax/semantic/html/elements/HtmlInput.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ class HtmlInput extends HtmlSemDoubleElement {
1414

1515
public function __construct($identifier, $type="text", $value="", $placeholder="") {
1616
parent::__construct("div-" . $identifier, "div", "ui input");
17+
$this->_identifier=$identifier;
1718
$this->content=[ "field" => new \Ajax\common\html\html5\HtmlInput($identifier, $type, $value, $placeholder) ];
1819
$this->_states=[ State::DISABLED,State::FOCUS,State::ERROR ];
1920
$this->_variations=[ Variation::TRANSPARENT ];

0 commit comments

Comments
 (0)