فهرست منبع

Compiler: allow optional zlists

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@1935 a333f486-631f-4898-b8df-5754b55c2be0
romainq 13 سال پیش
والد
کامیت
2cd0de768e
1فایلهای تغییر یافته به همراه8 افزوده شده و 5 حذف شده
  1. 8 5
      setup/compiler.class.inc.php

+ 8 - 5
setup/compiler.class.inc.php

@@ -667,11 +667,14 @@ EOF;
 		$sZlists = '';
 		$sZlists = '';
 		foreach ($aListRef as $sListCode => $sListTag)
 		foreach ($aListRef as $sListCode => $sListTag)
 		{
 		{
-			$oListNode = $this->GetUniqueElement($oPresentation, $sListTag);
-			$aAttributes = $this->GetNodeAsArrayOfItems($oListNode);
-	
-			$sZAttributes = var_export($aAttributes, true);
-			$sZlists .= "		MetaModel::Init_SetZListItems('$sListCode', $sZAttributes);\n";
+			$oListNode = $this->GetOptionalElement($oPresentation, $sListTag);
+			if ($oListNode)
+			{
+				$aAttributes = $this->GetNodeAsArrayOfItems($oListNode);
+		
+				$sZAttributes = var_export($aAttributes, true);
+				$sZlists .= "		MetaModel::Init_SetZListItems('$sListCode', $sZAttributes);\n";
+			}
 		}
 		}
 	
 	
 		// Methods
 		// Methods