data model + dictionaries

SVN:trunk[581]
This commit is contained in:
Romain Quetiez
2010-07-06 16:25:41 +00:00
parent ffdf72ae4d
commit f80f487f0c
3 changed files with 15 additions and 5 deletions

View File

@@ -632,6 +632,12 @@ Dict::Add('EN US', 'English', 'English', array(
'Class:NetworkInterface/Attribute:connected_name+' => '',
'Class:NetworkInterface/Attribute:connected_if_device_id' => 'Connected device',
'Class:NetworkInterface/Attribute:connected_if_device_id+' => '',
'Class:NetworkInterface/Attribute:link_type' => 'Link type',
'Class:NetworkInterface/Attribute:link_type+' => '',
'Class:NetworkInterface/Attribute:link_type/Value:uplink' => 'Up link',
'Class:NetworkInterface/Attribute:link_type/Value:uplink+' => '',
'Class:NetworkInterface/Attribute:link_type/Value:downlink' => 'Down link',
'Class:NetworkInterface/Attribute:link_type/Value:downlink+' => '',
));
//

View File

@@ -252,6 +252,10 @@ Dict::Add('EN US', 'English', 'English', array(
Dict::Add('EN US', 'English', 'English', array(
'Class:Service' => 'Service',
'Class:Service+' => '',
'Class:Service/Attribute:org_id' => 'Provider',
'Class:Service/Attribute:org_id+' => '',
'Class:Service/Attribute:provider_name' => 'Provider',
'Class:Service/Attribute:provider_name+' => '',
'Class:Service/Attribute:name' => 'Name',
'Class:Service/Attribute:name+' => '',
'Class:Service/Attribute:description' => 'Description',

View File

@@ -278,7 +278,7 @@ class Service extends cmdbAbstractObject
MetaModel::Init_Params($aParams);
MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("org_id", array("targetclass"=>"Organizations", "jointype"=>null, "allowed_values"=>null, "sql"=>"org_id", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalKey("org_id", array("targetclass"=>"Organization", "jointype"=>null, "allowed_values"=>null, "sql"=>"org_id", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("provider_name", array("allowed_values"=>null, "extkey_attcode"=>"org_id", "target_attcode"=>"name", "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("name", array("allowed_values"=>null, "sql"=>"name", "default_value"=>"", "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values"=>null, "sql"=>"description", "default_value"=>"", "is_null_allowed"=>true, "depends_on"=>array())));
@@ -289,10 +289,10 @@ class Service extends cmdbAbstractObject
MetaModel::Init_AddAttribute(new AttributeLinkedSetIndirect("document_list", array("linked_class"=>"lnkServiceToDoc", "ext_key_to_me"=>"service_id", "ext_key_to_remote"=>"document_id", "allowed_values"=>null, "count_min"=>0, "count_max"=>0, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeLinkedSetIndirect("contact_list", array("linked_class"=>"lnkServiceToContact", "ext_key_to_me"=>"service_id", "ext_key_to_remote"=>"contact_id", "allowed_values"=>null, "count_min"=>0, "count_max"=>0, "depends_on"=>array())));
MetaModel::Init_SetZListItems('details', array('name', 'description', 'type', 'status', 'subcategory_list', 'sla_list', 'document_list', 'contact_list'));
MetaModel::Init_SetZListItems('advanced_search', array('name', 'description', 'type', 'status'));
MetaModel::Init_SetZListItems('standard_search', array('name', 'description', 'type', 'status'));
MetaModel::Init_SetZListItems('list', array('name', 'description', 'type', 'status'));
MetaModel::Init_SetZListItems('details', array('name', 'description', 'org_id', 'type', 'status', 'subcategory_list', 'sla_list', 'document_list', 'contact_list'));
MetaModel::Init_SetZListItems('advanced_search', array('name', 'description', 'org_id', 'type', 'status'));
MetaModel::Init_SetZListItems('standard_search', array('name', 'description', 'org_id', 'type', 'status'));
MetaModel::Init_SetZListItems('list', array('name', 'description', 'org_id', 'type', 'status'));
}
}
class ServiceSubcategory extends cmdbAbstractObject