Explorar o código

N°583.2 Fixed regression introduced in r4861.

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@4885 a333f486-631f-4898-b8df-5754b55c2be0
glajarige %!s(int64=7) %!d(string=hai) anos
pai
achega
8b12b66854
Modificáronse 1 ficheiros con 4 adicións e 4 borrados
  1. 4 4
      core/bulkchange.class.inc.php

+ 4 - 4
core/bulkchange.class.inc.php

@@ -1,5 +1,5 @@
 <?php
 <?php
-// Copyright (C) 2010-2015 Combodo SARL
+// Copyright (C) 2010-2017 Combodo SARL
 //
 //
 //   This file is part of iTop.
 //   This file is part of iTop.
 //
 //
@@ -468,10 +468,12 @@ class BulkChange
 		//
 		//
 		foreach ($this->m_aAttList as $sAttCode => $iCol)
 		foreach ($this->m_aAttList as $sAttCode => $iCol)
 		{
 		{
+            $oAttDef = MetaModel::GetAttributeDef($this->m_sClass, $sAttCode);
+
 			// skip the private key, if any
 			// skip the private key, if any
 			if ($sAttCode == 'id') continue;
 			if ($sAttCode == 'id') continue;
 			// skip reconciliation keys
 			// skip reconciliation keys
-			if (in_array($sAttCode, $this->m_aReconcilKeys)) continue;
+			if (!$oAttDef->IsWritable() && in_array($sAttCode, $this->m_aReconcilKeys)){ continue; }
 
 
 			$oAttDef = MetaModel::GetAttributeDef($this->m_sClass, $sAttCode);
 			$oAttDef = MetaModel::GetAttributeDef($this->m_sClass, $sAttCode);
 			$aReasons = array();
 			$aReasons = array();
@@ -1308,5 +1310,3 @@ EOF
 	}	
 	}	
 }
 }
 
 
-
-?>