mirror of
https://github.com/Combodo/iTop.git
synced 2026-02-13 07:24:13 +01:00
- Small bug fixes after a quick test by performing a clean installation on Windows/IE 8
SVN:trunk[417]
This commit is contained in:
@@ -198,7 +198,15 @@ class WizardHelper
|
||||
|
||||
public function GetIdForField($sFieldName)
|
||||
{
|
||||
return $this->m_aData['m_oFieldsMap'][$sFieldName];
|
||||
$sResult = '';
|
||||
// It may happen that the field we'd like to update does not
|
||||
// exist in the form. For example, if the field should be hidden/read-only
|
||||
// in the current state of the object
|
||||
if (isset($this->m_aData['m_oFieldsMap'][$sFieldName]))
|
||||
{
|
||||
$sResult = $this->m_aData['m_oFieldsMap'][$sFieldName];
|
||||
}
|
||||
return $sResult;
|
||||
}
|
||||
|
||||
static function ParseJsonSet($oMe, $sLinkClass, $sExtKeyToMe, $sJsonSet)
|
||||
|
||||
@@ -95,8 +95,7 @@ class lnkInfraError extends cmdbAbstractObject
|
||||
|
||||
|
||||
}
|
||||
if (false)
|
||||
{
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////
|
||||
/**
|
||||
* n-n link between any Contract and a Document
|
||||
@@ -131,6 +130,5 @@ class lnkDocumentError extends cmdbAbstractObject
|
||||
MetaModel::Init_SetZListItems('list', array('doc_id', 'error_name', 'link_type')); // Attributes to be displayed for a list
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
@@ -1268,7 +1268,7 @@ class AttributeDateTime extends AttributeDBField
|
||||
}
|
||||
|
||||
// Init static constant once for all (remove when PHP allows real static const)
|
||||
AttributeDate::InitStatics();
|
||||
AttributeDateTime::InitStatics();
|
||||
|
||||
|
||||
/**
|
||||
|
||||
@@ -18,7 +18,6 @@ jQuery.fn.popupmenu = function ()
|
||||
{
|
||||
$(this).bind('mouseenter.popup_menu click.popup_menu', function (evt)
|
||||
{
|
||||
console.log(evt.type);
|
||||
var previous_popup = popupmenu;
|
||||
var bMenuClosed = false;
|
||||
popupmenu = $(this).find('ul');
|
||||
|
||||
@@ -88,12 +88,18 @@ switch($operation)
|
||||
foreach($oWizardHelper->GetFieldsForAllowedValues() as $sAttCode)
|
||||
{
|
||||
$sId = $oWizardHelper->GetIdForField($sAttCode);
|
||||
$value = $oObj->Get($sAttCode);
|
||||
$displayValue = $oObj->GetEditValue($sAttCode);
|
||||
$oAttDef = MetaModel::GetAttributeDef($sClass, $sAttCode);
|
||||
$sHTMLValue = cmdbAbstractObject::GetFormElementForField($oPage, $sClass, $sAttCode, $oAttDef, $value, $displayValue, $sId, '', 0, array('this' => $oObj));
|
||||
|
||||
$oWizardHelper->SetAllowedValuesHtml($sAttCode, $sHTMLValue);
|
||||
if ($sId != '')
|
||||
{
|
||||
// It may happen that the field we'd like to update does not
|
||||
// exist in the form. For example, if the field should be hidden/read-only
|
||||
// in the current state of the object
|
||||
$value = $oObj->Get($sAttCode);
|
||||
$displayValue = $oObj->GetEditValue($sAttCode);
|
||||
$oAttDef = MetaModel::GetAttributeDef($sClass, $sAttCode);
|
||||
$sHTMLValue = cmdbAbstractObject::GetFormElementForField($oPage, $sClass, $sAttCode, $oAttDef, $value, $displayValue, $sId, '', 0, array('this' => $oObj));
|
||||
|
||||
$oWizardHelper->SetAllowedValuesHtml($sAttCode, $sHTMLValue);
|
||||
}
|
||||
}
|
||||
$oPage->add("<script type=\"text/javascript\">\noWizardHelper.m_oData=".$oWizardHelper->ToJSON().";\noWizardHelper.UpdateFields();\n</script>\n");
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user