mirror of
https://github.com/Combodo/iTop.git
synced 2026-05-17 06:18:44 +02:00
(Retrofit from trunk) N°1094
- Adding "icon" attribute to ServiceFamily and Service classes - Show icon on ServiceFamily and Service levels in BrowseBrick SVN:2.4[5043]
This commit is contained in:
@@ -187,7 +187,7 @@
|
||||
// - Adding stub div
|
||||
var textElem = $('<div></div>').addClass('mosaic-item-text');
|
||||
// - Adding image
|
||||
if( (item.image !== undefined) && (item.image !== '') )
|
||||
if( (item.image !== undefined) && (item.image !== '') && (item.image !== null) )
|
||||
{
|
||||
iItemFlags += 4;
|
||||
aElem.append( $('<div></div>').addClass('mosaic-item-image').append( $('<img />').attr('src', item.image) ) );
|
||||
|
||||
@@ -628,10 +628,19 @@ table .group-actions {
|
||||
border-radius: 0px 0px 4px 4px;
|
||||
font-size: 1em;
|
||||
}
|
||||
/****************/
|
||||
/* - Mosaic mode */
|
||||
/* Note: Some of the CSS is factorised in the "Tree mode" part */
|
||||
/****************/
|
||||
/****************************************************************/
|
||||
/* - Mosaic mode */
|
||||
/* */
|
||||
/* Note: Some of the CSS is factorised in the "Tree mode" part */
|
||||
/* */
|
||||
/* Note: .mosaic-item-layout-x classes are for different */
|
||||
/* presentation modes. Like in binary, add the values to know */
|
||||
/* which class to use. */
|
||||
/* - 1 is for name */
|
||||
/* - 2 is for description */
|
||||
/* - 4 is for image */
|
||||
/* eg. .mosaic-item-layout-5 when just name and image */
|
||||
/****************************************************************/
|
||||
#brick_content_mosaic {
|
||||
position: relative;
|
||||
padding: 10px 10px 1px 10px;
|
||||
|
||||
@@ -677,10 +677,19 @@ table .group-actions .item-action-wrapper .panel-body > p:last-child{
|
||||
font-size: 1em;
|
||||
}
|
||||
|
||||
/****************/
|
||||
/* - Mosaic mode */
|
||||
/* Note: Some of the CSS is factorised in the "Tree mode" part */
|
||||
/****************/
|
||||
/****************************************************************/
|
||||
/* - Mosaic mode */
|
||||
/* */
|
||||
/* Note: Some of the CSS is factorised in the "Tree mode" part */
|
||||
/* */
|
||||
/* Note: .mosaic-item-layout-x classes are for different */
|
||||
/* presentation modes. Like in binary, add the values to know */
|
||||
/* which class to use. */
|
||||
/* - 1 is for name */
|
||||
/* - 2 is for description */
|
||||
/* - 4 is for image */
|
||||
/* eg. .mosaic-item-layout-5 when just name and image */
|
||||
/****************************************************************/
|
||||
#brick_content_mosaic{
|
||||
position: relative;
|
||||
padding: 10px 10px 1px 10px;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<itop_design xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.2">
|
||||
<itop_design xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.4">
|
||||
<classes>
|
||||
<class id="Organization">
|
||||
<fields>
|
||||
@@ -951,6 +951,14 @@
|
||||
<default_value/>
|
||||
<is_null_allowed>false</is_null_allowed>
|
||||
</field>
|
||||
<field id="icon" xsi:type="AttributeImage">
|
||||
<display_max_width>96</display_max_width>
|
||||
<display_max_height>96</display_max_height>
|
||||
<storage_max_width>256</storage_max_width>
|
||||
<storage_max_height>256</storage_max_height>
|
||||
<default_image/>
|
||||
<is_null_allowed>true</is_null_allowed>
|
||||
</field>
|
||||
<field id="services_list" xsi:type="AttributeLinkedSet">
|
||||
<linked_class>Service</linked_class>
|
||||
<ext_key_to_me>servicefamily_id</ext_key_to_me>
|
||||
@@ -967,6 +975,9 @@
|
||||
<item id="name">
|
||||
<rank>10</rank>
|
||||
</item>
|
||||
<item id="icon">
|
||||
<rank>15</rank>
|
||||
</item>
|
||||
<item id="services_list">
|
||||
<rank>20</rank>
|
||||
</item>
|
||||
@@ -1070,6 +1081,14 @@
|
||||
<is_null_allowed>true</is_null_allowed>
|
||||
<display_style>list</display_style>
|
||||
</field>
|
||||
<field id="icon" xsi:type="AttributeImage">
|
||||
<display_max_width>96</display_max_width>
|
||||
<display_max_height>96</display_max_height>
|
||||
<storage_max_width>256</storage_max_width>
|
||||
<storage_max_height>256</storage_max_height>
|
||||
<default_image/>
|
||||
<is_null_allowed>true</is_null_allowed>
|
||||
</field>
|
||||
<field id="customercontracts_list" xsi:type="AttributeLinkedSetIndirect">
|
||||
<linked_class>lnkCustomerContractToService</linked_class>
|
||||
<ext_key_to_me>service_id</ext_key_to_me>
|
||||
@@ -1106,6 +1125,9 @@
|
||||
<item id="status">
|
||||
<rank>50</rank>
|
||||
</item>
|
||||
<item id="icon">
|
||||
<rank>55</rank>
|
||||
</item>
|
||||
<item id="servicesubcategories_list">
|
||||
<rank>60</rank>
|
||||
</item>
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<itop_design xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.2">
|
||||
<itop_design xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.4">
|
||||
<classes>
|
||||
<class id="Organization">
|
||||
<fields>
|
||||
@@ -935,6 +935,14 @@
|
||||
<default_value/>
|
||||
<is_null_allowed>false</is_null_allowed>
|
||||
</field>
|
||||
<field id="icon" xsi:type="AttributeImage">
|
||||
<display_max_width>96</display_max_width>
|
||||
<display_max_height>96</display_max_height>
|
||||
<storage_max_width>256</storage_max_width>
|
||||
<storage_max_height>256</storage_max_height>
|
||||
<default_image/>
|
||||
<is_null_allowed>true</is_null_allowed>
|
||||
</field>
|
||||
<field id="services_list" xsi:type="AttributeLinkedSet">
|
||||
<linked_class>Service</linked_class>
|
||||
<ext_key_to_me>servicefamily_id</ext_key_to_me>
|
||||
@@ -951,6 +959,9 @@
|
||||
<item id="name">
|
||||
<rank>10</rank>
|
||||
</item>
|
||||
<item id="icon">
|
||||
<rank>15</rank>
|
||||
</item>
|
||||
<item id="services_list">
|
||||
<rank>20</rank>
|
||||
</item>
|
||||
@@ -1054,6 +1065,14 @@
|
||||
<is_null_allowed>true</is_null_allowed>
|
||||
<display_style>list</display_style>
|
||||
</field>
|
||||
<field id="icon" xsi:type="AttributeImage">
|
||||
<display_max_width>96</display_max_width>
|
||||
<display_max_height>96</display_max_height>
|
||||
<storage_max_width>256</storage_max_width>
|
||||
<storage_max_height>256</storage_max_height>
|
||||
<default_image/>
|
||||
<is_null_allowed>true</is_null_allowed>
|
||||
</field>
|
||||
<field id="customercontracts_list" xsi:type="AttributeLinkedSetIndirect">
|
||||
<linked_class>lnkCustomerContractToService</linked_class>
|
||||
<ext_key_to_me>service_id</ext_key_to_me>
|
||||
@@ -1106,6 +1125,9 @@
|
||||
<item id="status">
|
||||
<rank>50</rank>
|
||||
</item>
|
||||
<item id="icon">
|
||||
<rank>55</rank>
|
||||
</item>
|
||||
<item id="servicesubcategories_list">
|
||||
<rank>60</rank>
|
||||
</item>
|
||||
|
||||
@@ -1067,6 +1067,7 @@
|
||||
<levels>
|
||||
<level id="1">
|
||||
<class>ServiceFamily</class>
|
||||
<image_att>icon</image_att>
|
||||
<levels>
|
||||
<!-- Level IDs must be numeric -->
|
||||
<level id="1">
|
||||
@@ -1080,10 +1081,10 @@
|
||||
<tooltip_att>description</tooltip_att>
|
||||
<!-- Attribute code of the above class [from the OQL] used to display a small text beside the object's name -->
|
||||
<!-- Note: This is not used in "list" mode -->
|
||||
<description_att/>
|
||||
<description_att>description</description_att>
|
||||
<!-- Attribute code of the above class [from the OQL] used to display a image beside the object's name -->
|
||||
<!-- Note: This is used in "mosaic" mode only for now -->
|
||||
<!--<image_att/>-->
|
||||
<image_att>icon</image_att>
|
||||
<!-- Title of the level, will be display in lists and others browse modes -->
|
||||
<title>Class:Service</title>
|
||||
<!-- Optional tag to add attributes to the table by their code, can be specified for each level -->
|
||||
@@ -1100,6 +1101,7 @@
|
||||
<parent_att>service_id</parent_att>
|
||||
<name_att/>
|
||||
<tooltip_att>description</tooltip_att>
|
||||
<description_att>description</description_att>
|
||||
<title>Class:ServiceSubcategory</title>
|
||||
<actions>
|
||||
<action id="create_from_this" xsi:type="create_from_this">
|
||||
|
||||
Reference in New Issue
Block a user