From 209b6591b74d0aebf01ce73e15b15c5a9b5e3497 Mon Sep 17 00:00:00 2001 From: Julio Cesar Laura Date: Mon, 2 Jun 2014 13:35:25 -0400 Subject: [PATCH] BUG 15071 Problemas en la extension de un output con la opcion "By clicking on the generated file link=Download the file" SOLVED - Missing validation in the dropdown class - Added validation in the dropdown class to add missing option only when the field is render in view mode --- gulliver/system/class.xmlform.php | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/gulliver/system/class.xmlform.php b/gulliver/system/class.xmlform.php index cc3b2d653..8be454dc4 100755 --- a/gulliver/system/class.xmlform.php +++ b/gulliver/system/class.xmlform.php @@ -3178,17 +3178,12 @@ class XmlForm_Field_Checkbox extends XmlForm_Field $checked = (isset( $value ) && ($value == $this->value)) ? 'checked' : ''; if ($this->labelOnRight) { $html = ''; - $html = "NSFieldType() . " name='form[" . $this->name . "]' type='checkbox' $checked $readOnly disabled > + $html = "NSFieldType() . " type='checkbox' $checked $readOnly disabled /> " . $this->label . ''; } else { - $html = "NSFieldType() . " name='form[" . $this->name . "]' type='checkbox' $checked $readOnly disabled/>"; + $html = "NSFieldType() . " type='checkbox' $checked $readOnly disabled />"; } $html .= ""; - // if($this->hint){ - // $html .= ' - // - // '; - // } return $html; } } @@ -3360,11 +3355,6 @@ class XmlForm_Field_Submit extends XmlForm_Field $sLinkNextStep = 'window.location=("casesSaveDataView?UID=' . $_SESSION['CURRENT_DYN_UID'] . '");'; $html = 'NSFieldType() . ' name="form[' . $this->name . ']" type="button" value="' . G::LoadTranslation( 'ID_CONTINUE' ) . '" onclick="' . htmlentities( $sLinkNextStep, ENT_COMPAT, 'utf-8' ) . '" />'; } - - $html .= 'name . ']" '; - $html .= 'name="form[' . $this->name . ']" '; - $html .= 'type="hidden" value="' . $this->htmlentities( $this->label, ENT_QUOTES, 'utf-8' ) . '" />'; return $html; } else { return $this->htmlentities( $value, ENT_COMPAT, 'utf-8' ); @@ -3616,7 +3606,7 @@ class XmlForm_Field_Dropdown extends XmlForm_Field $html = $html . ""; } - if ($value !== $findValue) { + if ($value !== $findValue && $this->renderMode == 'view') { $html .= ""; }