Adjustment for display the date in a grid preview
This commit is contained in:
@@ -857,7 +857,7 @@ class XmlForm_Field_Text extends XmlForm_Field_SimpleText
|
||||
$onkeypress = G::replaceDataField ( $this->onkeypress, $owner->values );
|
||||
if ($this->replaceTags == 1) {
|
||||
$value = G::replaceDataField ( $value, $owner->values );
|
||||
}
|
||||
}
|
||||
if ($this->mode === 'edit') {
|
||||
if ($this->readOnly){
|
||||
$html = '<input class="module_app_input___gray" id="form[' . $this->name . ']" name="form[' . $this->name . ']" type ="text" size="' . $this->size . '" maxlength="' . $this->maxLength . '" value=\'' . $this->htmlentities ( $value, ENT_QUOTES, 'utf-8' ) . '\' readOnly="readOnly" style="' . htmlentities ( $this->style, ENT_COMPAT, 'utf-8' ) . '" onkeypress="' . htmlentities ( $onkeypress, ENT_COMPAT, 'utf-8' ) . '"/>';
|
||||
@@ -2999,8 +2999,17 @@ class XmlForm_Field_Date extends XmlForm_Field_SimpleText
|
||||
foreach ( $values as $v ) {
|
||||
$v = G::replaceDataField ( $v, $owner->values );
|
||||
if (! $onlyValue) {
|
||||
$id = 'form[' . $owner->name . '][' . $r . '][' . $this->name . ']';
|
||||
$html = $this->__draw_widget ( $id, $v, $owner );
|
||||
if($this->mode === 'view') {
|
||||
if ($this->required){
|
||||
$isRequired = '1';
|
||||
} else {
|
||||
$isRequired = '0';
|
||||
}
|
||||
$html = '<input class="module_app_input___gray" id="form[' . $owner->name . '][' . $r . '][' . $this->name . ']" name="form[' . $owner->name . '][' . $r . '][' . $this->name . ']" type ="text" size="' . $this->size . '" maxlength="' . $this->maxLength . '" value="' . $this->htmlentities ( $v, ENT_COMPAT, 'utf-8' ) . '" required="' . $isRequired . '" style="display:none;' . htmlentities ( $this->style, ENT_COMPAT, 'utf-8' ) . '"/>' . htmlentities ( $v, ENT_COMPAT, 'utf-8' );
|
||||
} else {
|
||||
$id = 'form[' . $owner->name . '][' . $r . '][' . $this->name . ']';
|
||||
$html = $this->__draw_widget ( $id, $v, $owner );
|
||||
}
|
||||
} else {
|
||||
$html = $v;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user