Просмотр исходного кода

#1028: drop the support of non-numeric primary keys for DBObjects. This makes the queries related to the history (and the indexes) much more efficient. Beware, conversion time at setup can be long if the priv_changeop table is big.

git-svn-id: http://svn.code.sf.net/p/itop/code/trunk@3447 a333f486-631f-4898-b8df-5754b55c2be0
dflaven 10 лет назад
Родитель
Сommit
200a378265
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      core/cmdbchangeop.class.inc.php

+ 1 - 1
core/cmdbchangeop.class.inc.php

@@ -55,7 +55,7 @@ class CMDBChangeOp extends DBObject
 		MetaModel::Init_AddAttribute(new AttributeExternalField("date", array("allowed_values"=>null, "extkey_attcode"=>"change", "target_attcode"=>"date")));
 		MetaModel::Init_AddAttribute(new AttributeExternalField("userinfo", array("allowed_values"=>null, "extkey_attcode"=>"change", "target_attcode"=>"userinfo")));
 		MetaModel::Init_AddAttribute(new AttributeString("objclass", array("allowed_values"=>null, "sql"=>"objclass", "default_value"=>"", "is_null_allowed"=>false, "depends_on"=>array())));
-		MetaModel::Init_AddAttribute(new AttributeString("objkey", array("allowed_values"=>null, "sql"=>"objkey", "default_value"=>"", "is_null_allowed"=>false, "depends_on"=>array())));
+		MetaModel::Init_AddAttribute(new AttributeInteger("objkey", array("allowed_values"=>null, "sql"=>"objkey", "default_value"=>0, "is_null_allowed"=>false, "depends_on"=>array())));
 
 		MetaModel::Init_SetZListItems('details', array('change', 'date', 'userinfo')); // Attributes to be displayed for the complete details
 		MetaModel::Init_SetZListItems('list', array('change', 'date', 'userinfo')); // Attributes to be displayed for the complete details