浏览代码

Fixed regression introduced in [3224] thus in iTop 2.0.3, in the data model view: could not see the OQL constraints on external keys

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@3385 a333f486-631f-4898-b8df-5754b55c2be0
romainq 10 年之前
父节点
当前提交
0e68273ee0
共有 1 个文件被更改,包括 8 次插入1 次删除
  1. 8 1
      pages/schema.php

+ 8 - 1
pages/schema.php

@@ -450,7 +450,14 @@ function DisplayClassDetails($oPage, $sClass, $sContext)
 			}
 			}
 			$sAllowedValues = implode(', ', $aDescription);
 			$sAllowedValues = implode(', ', $aDescription);
 		}
 		}
-		else $sAllowedValues = '';
+		elseif (is_object($oAllowedValuesDef = $oAttDef->GetValuesDef()))
+		{
+			$sAllowedValues = $oAllowedValuesDef->GetValuesDescription();
+		}
+		else
+		{
+			$sAllowedValues = '';
+		}
 
 
 		$aDetails[] = array('code' => $oAttDef->GetCode(), 'type' => $sType, 'origin' => $sOrigin, 'label' => $oAttDef->GetLabel(), 'description' => $sValue, 'values' => $sAllowedValues, 'moreinfo' => $sMoreInfo);
 		$aDetails[] = array('code' => $oAttDef->GetCode(), 'type' => $sType, 'origin' => $sOrigin, 'label' => $oAttDef->GetLabel(), 'description' => $sValue, 'values' => $sAllowedValues, 'moreinfo' => $sMoreInfo);
 	}
 	}