BUG 000 Add validation in the hierachy modes when mode of the field are blank

This commit is contained in:
Julio Cesar Laura
2012-07-10 19:03:02 -04:00
parent bb02ac5d9e
commit 5cff267423

View File

@@ -136,6 +136,9 @@ class XmlForm_Field {
if ($ownerMode != '') { if ($ownerMode != '') {
$this->mode = $ownerMode; $this->mode = $ownerMode;
} }
if ($this->mode == '') {
$this->mode = 'edit';
}
$this->modeForGrid = $this->mode; $this->modeForGrid = $this->mode;
} }
@@ -3216,6 +3219,10 @@ class XmlForm_Field_Grid extends XmlForm_Field
$this->mode = $ownerMode; $this->mode = $ownerMode;
} }
if ($this->mode == '') {
$this->mode = 'edit';
}
$this->modeForGrid = $this->mode; $this->modeForGrid = $this->mode;
if ($this->mode == 'view') { if ($this->mode == 'view') {