Merge branch 'develop' of https://github.com/Combodo/iTop into develop

This commit is contained in:
Benjamin Dalsass
2023-04-12 14:39:09 +02:00
29 changed files with 322 additions and 168 deletions

View File

@@ -219,24 +219,25 @@ class URP_UserProfile extends UserRightsBaseClassGUI
{
$aParams = array
(
"category" => "addon/userrights,grant_by_profile,filter",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"category" => "addon/userrights,grant_by_profile,filter",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass"=>"User", "jointype"=> "", "allowed_values"=>null, "sql"=>"userid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values"=>null, "extkey_attcode"=> 'userid', "target_attcode"=>"login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass" => "User", "jointype" => "", "allowed_values" => null, "sql" => "userid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values" => null, "extkey_attcode" => 'userid', "target_attcode" => "login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid", array("targetclass"=>"URP_Profiles", "jointype"=> "", "allowed_values"=>null, "sql"=>"profileid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values"=>null, "extkey_attcode"=> 'profileid', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid",
array("targetclass" => "URP_Profiles", "jointype" => "", "allowed_values" => null, "sql" => "profileid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array(), "allow_target_creation" => false)));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values" => null, "extkey_attcode" => 'profileid', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('userid', 'profileid', 'reason')); // Attributes to be displayed for the complete details

View File

@@ -325,24 +325,25 @@ class URP_UserProfile extends UserRightsBaseClassGUI
{
$aParams = array
(
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass"=>"User", "jointype"=> "", "allowed_values"=>null, "sql"=>"userid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values"=>null, "extkey_attcode"=> 'userid', "target_attcode"=>"login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass" => "User", "jointype" => "", "allowed_values" => null, "sql" => "userid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values" => null, "extkey_attcode" => 'userid', "target_attcode" => "login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid", array("targetclass"=>"URP_Profiles", "jointype"=> "", "allowed_values"=>null, "sql"=>"profileid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values"=>null, "extkey_attcode"=> 'profileid', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid",
array("targetclass" => "URP_Profiles", "jointype" => "", "allowed_values" => null, "sql" => "profileid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array(), "allow_target_creation" => false)));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values" => null, "extkey_attcode" => 'profileid', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('userid', 'profileid', 'reason')); // Attributes to be displayed for the complete details

View File

@@ -268,24 +268,25 @@ class URP_UserProfile extends UserRightsBaseClass
{
$aParams = array
(
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"category" => "addon/userrights",
"key_type" => "autoincrement",
"name_attcode" => array("userlogin", "profile"),
"state_attcode" => "",
"reconc_keys" => array(),
"db_table" => "priv_urp_userprofile",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass"=>"User", "jointype"=> "", "allowed_values"=>null, "sql"=>"userid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values"=>null, "extkey_attcode"=> 'userid', "target_attcode"=>"login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("userid", array("targetclass" => "User", "jointype" => "", "allowed_values" => null, "sql" => "userid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("userlogin", array("allowed_values" => null, "extkey_attcode" => 'userid', "target_attcode" => "login")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid", array("targetclass"=>"URP_Profiles", "jointype"=> "", "allowed_values"=>null, "sql"=>"profileid", "is_null_allowed"=>false, "on_target_delete"=>DEL_AUTO, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values"=>null, "extkey_attcode"=> 'profileid', "target_attcode"=>"name")));
MetaModel::Init_AddAttribute(new AttributeExternalKey("profileid",
array("targetclass" => "URP_Profiles", "jointype" => "", "allowed_values" => null, "sql" => "profileid", "is_null_allowed" => false, "on_target_delete" => DEL_AUTO, "depends_on" => array(), "allow_target_creation" => false)));
MetaModel::Init_AddAttribute(new AttributeExternalField("profile", array("allowed_values" => null, "extkey_attcode" => 'profileid', "target_attcode" => "name")));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reason", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// Display lists
MetaModel::Init_SetZListItems('details', array('userid', 'profileid', 'reason')); // Attributes to be displayed for the complete details

View File

@@ -47,18 +47,33 @@ abstract class Action extends cmdbAbstractObject
"key_type" => "autoincrement",
"name_attcode" => "name",
"complementary_name_attcode" => array('finalclass', 'description'),
"state_attcode" => "",
"state_attcode" => "status",
"reconc_keys" => array('name'),
"db_table" => "priv_action",
"db_key_field" => "id",
"db_finalclass_field" => "realclass",
'style' => new ormStyle(null, null, null, null, null, '../images/icons/icons8-in-transit.svg'),
"style" => new ormStyle("ibo-dm-class--Action", "ibo-dm-class-alt--Action", "var(--ibo-dm-class--Action--main-color)", "var(--ibo-dm-class--Action--complementary-color)", null, '../images/icons/icons8-in-transit.svg'),
);
MetaModel::Init_Params($aParams);
//MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeString("name", array("allowed_values"=>null, "sql"=>"name", "default_value"=>null, "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values"=>null, "sql"=>"description", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeEnum("status", array("allowed_values" => new ValueSetEnum(array('test' => 'Being tested', 'enabled' => 'In production', 'disabled' => 'Inactive')), "sql" => "status", "default_value" => "test", "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("name", array("allowed_values" => null, "sql" => "name", "default_value" => null, "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("description", array("allowed_values" => null, "sql" => "description", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
// MetaModel::Init_AddAttribute(new AttributeEnum("status", array("allowed_values" => new ValueSetEnum(array('test' => 'Being tested', 'enabled' => 'In production', 'disabled' => 'Inactive')), "sql" => "status", "default_value" => "test", "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeEnum("status", array(
"allowed_values" => new ValueSetEnum(array('test' => 'Being tested', 'enabled' => 'In production', 'disabled' => 'Inactive')),
"styled_values" => [
'test' => new ormStyle('ibo-dm-enum--Action-status-test', 'ibo-dm-enum-alt--Action-status-test', 'var(--ibo-dm-enum--Action-status-test--main-color)', 'var(--ibo-dm-enum--Action-status-test--complementary-color)', null, null),
'enabled' => new ormStyle('ibo-dm-enum--Action-status-enabled', 'ibo-dm-enum-alt--Action-status-enabled', 'var(--ibo-dm-enum--Action-status-enabled--main-color)', 'var(--ibo-dm-enum--Action-status-enabled--complementary-color)', 'fas fa-check', null),
'disabled' => new ormStyle('ibo-dm-enum--Action-status-disabled', 'ibo-dm-enum-alt--Action-status-disabled', 'var(--ibo-dm-enum--Action-status-disabled--main-color)', 'var(--ibo-dm-enum--Action-status-disabled--complementary-color)', null, null),
],
"display_style" => 'list',
"sql" => "status",
"default_value" => "test",
"is_null_allowed" => false,
"depends_on" => array(),
)));
MetaModel::Init_AddAttribute(new AttributeLinkedSetIndirect("trigger_list",
array("linked_class" => "lnkTriggerAction", "ext_key_to_me" => "action_id", "ext_key_to_remote" => "trigger_id", "allowed_values" => null, "count_min" => 0, "count_max" => 0, "depends_on" => array(), "display_style" => 'property')));
@@ -170,13 +185,13 @@ abstract class ActionNotification extends Action
{
$aParams = array
(
"category" => "grant_by_profile,core/cmdb",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array('name'),
"db_table" => "priv_action_notification",
"db_key_field" => "id",
"category" => "grant_by_profile,core/cmdb",
"key_type" => "autoincrement",
"name_attcode" => "name",
"state_attcode" => "",
"reconc_keys" => array('name'),
"db_table" => "priv_action_notification",
"db_key_field" => "id",
"db_finalclass_field" => "",
);
MetaModel::Init_Params($aParams);
@@ -232,27 +247,56 @@ class ActionEmail extends ActionNotification
MetaModel::Init_Params($aParams);
MetaModel::Init_InheritAttributes();
MetaModel::Init_AddAttribute(new AttributeEmailAddress("test_recipient", array("allowed_values"=>null, "sql"=>"test_recipient", "default_value"=>"", "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeEmailAddress("test_recipient", array("allowed_values" => null, "sql" => "test_recipient", "default_value" => "", "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("from", array("allowed_values"=>null, "sql"=>"from", "default_value"=>null, "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("from_label", array("allowed_values"=>null, "sql"=>"from_label", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reply_to", array("allowed_values"=>null, "sql"=>"reply_to", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("reply_to_label", array("allowed_values"=>null, "sql"=>"reply_to_label", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeOQL("to", array("allowed_values"=>null, "sql"=>"to", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeOQL("cc", array("allowed_values"=>null, "sql"=>"cc", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeOQL("bcc", array("allowed_values"=>null, "sql"=>"bcc", "default_value"=>null, "is_null_allowed"=>true, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeTemplateString("subject", array("allowed_values"=>null, "sql"=>"subject", "default_value"=>null, "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeTemplateHTML("body", array("allowed_values"=>null, "sql"=>"body", "default_value"=>null, "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeEnum("importance", array("allowed_values"=>new ValueSetEnum('low,normal,high'), "sql"=>"importance", "default_value"=>'normal', "is_null_allowed"=>false, "depends_on"=>array())));
MetaModel::Init_AddAttribute(new AttributeString("from", array("allowed_values" => null, "sql" => "from", "default_value" => null, "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("from_label", array("allowed_values" => null, "sql" => "from_label", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("reply_to", array("allowed_values" => null, "sql" => "reply_to", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeString("reply_to_label", array("allowed_values" => null, "sql" => "reply_to_label", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeOQL("to", array("allowed_values" => null, "sql" => "to", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeOQL("cc", array("allowed_values" => null, "sql" => "cc", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeOQL("bcc", array("allowed_values" => null, "sql" => "bcc", "default_value" => null, "is_null_allowed" => true, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeTemplateString("subject", array("allowed_values" => null, "sql" => "subject", "default_value" => null, "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeTemplateHTML("body", array("allowed_values" => null, "sql" => "body", "default_value" => null, "is_null_allowed" => false, "depends_on" => array())));
MetaModel::Init_AddAttribute(new AttributeEnum("importance", array("allowed_values" => new ValueSetEnum('low,normal,high'), "sql" => "importance", "default_value" => 'normal', "is_null_allowed" => false, "depends_on" => array())));
// Display lists
// - Attributes to be displayed for the complete details
MetaModel::Init_SetZListItems('details', array('name', 'description', 'status', 'test_recipient', 'from', 'from_label', 'reply_to', 'reply_to_label', 'to', 'cc', 'bcc', 'subject', 'body', 'importance', 'trigger_list'));
MetaModel::Init_SetZListItems('details', array(
'col:col1' => array(
'fieldset:ActionEmail:main' => array(
0 => 'name',
1 => 'description',
2 => 'status',
3 => 'subject',
4 => 'body',
5 => 'importance',
),
'fieldset:ActionEmail:trigger' => array(
0 => 'trigger_list',
),
),
'col:col2' => array(
'fieldset:ActionEmail:recipients' => array(
0 => 'from',
1 => 'from_label',
2 => 'reply_to',
3 => 'reply_to_label',
4 => 'test_recipient',
5 => 'to',
6 => 'cc',
7 => 'bcc',
),
),
));
// - Attributes to be displayed for a list
MetaModel::Init_SetZListItems('list', array('name', 'status', 'to', 'subject'));
// Search criteria
// - Criteria of the std search form
MetaModel::Init_SetZListItems('standard_search', array('name','description', 'status', 'subject'));
MetaModel::Init_SetZListItems('standard_search', array('name', 'description', 'status', 'subject'));
// - Criteria of the advanced search form
// MetaModel::Init_SetZListItems('advanced_search', array('name'));
}

View File

@@ -1000,7 +1000,9 @@ class ToolsLog extends LogAPI
/**
* @see \CMDBSource::LogDeadLock()
* @since 2.7.1
* @since 2.7.1 PR #139
*
* @link https://dev.mysql.com/doc/refman/5.7/en/innodb-deadlocks.html
*/
class DeadLockLog extends LogAPI
{
@@ -1025,10 +1027,10 @@ class DeadLockLog extends LogAPI
{
switch ($iMysqlErrorNo)
{
case 1205:
case CMDBSource::MYSQL_ERRNO_WAIT_TIMEOUT:
return self::CHANNEL_WAIT_TIMEOUT;
break;
case 1213:
case CMDBSource::MYSQL_ERRNO_DEADLOCK:
return self::CHANNEL_DEADLOCK_FOUND;
break;
default:

View File

@@ -19,7 +19,7 @@ $ibo-input-set--item--siblings-spacing: 3px !default;
$ibo-input-set--item--margin-y: 1px !default;
$ibo-input-set--item--padding-x: 6px !default;
$ibo-input-set--item--padding-y: $ibo-spacing-200 !default;
$ibo-input-set--item--max-width: 120px !default;
$ibo-input-set--item--max-width: 360px !default;
$ibo-input-set--item--background-color: $ibo-color-white-100 !default;
$ibo-input-set--item--border: none !default;
$ibo-input-set--item--border-radius: $ibo-border-radius-300 !default;

View File

@@ -0,0 +1,89 @@
/*
* @copyright Copyright (C) 2010-2023 Combodo SARL
* @license http://opensource.org/licenses/AGPL-3.0
*/
// Class itself
$ibo-dm-class--Action--main-color: $ibo-color-blue-grey-600 !default;
$ibo-dm-class--Action--complementary-color: $ibo-color-white-100 !default;
:root {
--ibo-dm-class--Action--main-color: #{$ibo-dm-class--Action--main-color};
--ibo-dm-class--Action--complementary-color: #{$ibo-dm-class--Action--complementary-color};
}
.ibo-dm-class--Action {
--ibo-main-color: #{$ibo-dm-class--Action--main-color};
--ibo-main-color--100: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-class--Action--main-color, $ibo-color-base-lightness-100), $ibo-color-base-opacity-for-lightness-100)};
--ibo-main-color--900: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-class--Action--main-color, $ibo-color-base-lightness-900), $ibo-color-base-opacity-for-lightness-900)};
--ibo-complementary-color: #{$ibo-dm-class--Action--complementary-color};
}
.ibo-dm-class-alt--Action {
--ibo-main-color: #{$ibo-dm-class--Action--complementary-color};
--ibo-complementary-color: #{$ibo-dm-class--Action--main-color};
}
// State attribute, "enabled" value
$ibo-dm-enum--Action-status-enabled--main-color: $ibo-lifecycle-active-state-primary-color !default;
$ibo-dm-enum--Action-status-enabled--complementary-color: $ibo-lifecycle-active-state-secondary-color !default;
:root {
--ibo-dm-enum--Action-status-enabled--main-color: #{$ibo-dm-enum--Action-status-enabled--main-color};
--ibo-dm-enum--Action-status-enabled--complementary-color: #{$ibo-dm-enum--Action-status-enabled--complementary-color};
}
.ibo-dm-enum--Action-status-enabled {
--ibo-main-color: #{$ibo-dm-enum--Action-status-enabled--main-color};
--ibo-main-color--100: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-enum--Action-status-enabled--main-color, $ibo-color-base-lightness-100), $ibo-color-base-opacity-for-lightness-100)};
--ibo-main-color--900: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-enum--Action-status-enabled--main-color, $ibo-color-base-lightness-900), $ibo-color-base-opacity-for-lightness-900)};
--ibo-complementary-color: #{$ibo-dm-enum--Action-status-enabled--complementary-color};
}
.ibo-dm-enum-alt--Action-status-enabled {
--ibo-main-color: #{$ibo-dm-enum--Action-status-enabled--complementary-color};
--ibo-complementary-color: #{$ibo-dm-enum--Action-status-enabled--main-color};
}
// State attribute, "disabled" value
$ibo-dm-enum--Action-status-disabled--main-color: $ibo-lifecycle-frozen-state-primary-color !default;
$ibo-dm-enum--Action-status-disabled--complementary-color: $ibo-lifecycle-frozen-state-secondary-color !default;
:root {
--ibo-dm-enum--Action-status-disabled--main-color: #{$ibo-dm-enum--Action-status-disabled--main-color};
--ibo-dm-enum--Action-status-disabled--complementary-color: #{$ibo-dm-enum--Action-status-disabled--complementary-color};
}
.ibo-dm-enum--Action-status-disabled {
--ibo-main-color: #{$ibo-dm-enum--Action-status-disabled--main-color};
--ibo-main-color--100: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-enum--Action-status-disabled--main-color, $ibo-color-base-lightness-100), $ibo-color-base-opacity-for-lightness-100)};
--ibo-main-color--900: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-enum--Action-status-disabled--main-color, $ibo-color-base-lightness-900), $ibo-color-base-opacity-for-lightness-900)};
--ibo-complementary-color: #{$ibo-dm-enum--Action-status-disabled--complementary-color};
}
.ibo-dm-enum-alt--Action-status-disabled {
--ibo-main-color: #{$ibo-dm-enum--Action-status-disabled--complementary-color};
--ibo-complementary-color: #{$ibo-dm-enum--Action-status-disabled--main-color};
}
// State attribute, "test" value
$ibo-dm-enum--Action-status-test--main-color: $ibo-lifecycle-inactive-state-primary-color !default;
$ibo-dm-enum--Action-status-test--complementary-color: $ibo-lifecycle-inactive-state-secondary-color !default;
:root {
--ibo-dm-enum--Action-status-test--main-color: #{$ibo-dm-enum--Action-status-test--main-color};
--ibo-dm-enum--Action-status-test--complementary-color: #{$ibo-dm-enum--Action-status-test--complementary-color};
}
.ibo-dm-enum--Action-status-test {
--ibo-main-color: #{$ibo-dm-enum--Action-status-test--main-color};
--ibo-main-color--100: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-enum--Action-status-test--main-color, $ibo-color-base-lightness-100), $ibo-color-base-opacity-for-lightness-100)};
--ibo-main-color--900: #{ibo-adjust-alpha(ibo-adjust-lightness($ibo-dm-enum--Action-status-test--main-color, $ibo-color-base-lightness-900), $ibo-color-base-opacity-for-lightness-900)};
--ibo-complementary-color: #{$ibo-dm-enum--Action-status-test--complementary-color};
}
.ibo-dm-enum-alt--Action-status-test {
--ibo-main-color: #{$ibo-dm-enum--Action-status-test--complementary-color};
--ibo-complementary-color: #{$ibo-dm-enum--Action-status-test--main-color};
}

View File

@@ -9,4 +9,5 @@
/* to see what the compiler generates for XML DM classes. */
/**************************************************************************************************************************/
@import "user";
@import "user";
@import "action";

View File

@@ -419,7 +419,7 @@ Dict::Add('FR FR', 'French', 'Français', array(
//
Dict::Add('FR FR', 'French', 'Français', array(
'Class:PowerConnection' => 'Connection Electrique',
'Class:PowerConnection' => 'Connexion électrique',
'Class:PowerConnection+' => '',
));

View File

@@ -416,7 +416,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => ' Odebrat >> ',
'UI:Button:FilterList' => ' Filtrovat... ',
'UI:Button:Create' => ' Vytvořit ',
'UI:Button:Delete' => ' Odstranit ! ',
'UI:Button:Delete' => ' Odstranit ',
'UI:Button:Rename' => ' Přejmenovat... ',
'UI:Button:ChangePassword' => ' Změnit heslo ',
'UI:Button:ResetPassword' => ' Obnovit heslo ',

View File

@@ -405,7 +405,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => ' Fjern >> ',
'UI:Button:FilterList' => ' Filter... ',
'UI:Button:Create' => ' Opret ',
'UI:Button:Delete' => ' Slet! ',
'UI:Button:Delete' => ' Slet ',
'UI:Button:Rename' => ' Omdøb... ',
'UI:Button:ChangePassword' => ' Skift Password ',
'UI:Button:ResetPassword' => ' Reset Password ',

View File

@@ -445,7 +445,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => 'Entfernen >>',
'UI:Button:FilterList' => 'Filter...',
'UI:Button:Create' => 'Erstellen',
'UI:Button:Delete' => 'Löschen!',
'UI:Button:Delete' => 'Löschen',
'UI:Button:Rename' => 'Umbenennen...',
'UI:Button:ChangePassword' => 'Passwort ändern',
'UI:Button:ResetPassword' => 'Passwort zurücksetzen',

View File

@@ -207,7 +207,7 @@ Operators:<br/>
'Core:AttributeTag' => 'Tags',
'Core:AttributeTag+' => '',
'Core:Context=REST/JSON' => 'REST',
'Core:Context=Synchro' => 'Synchro',
'Core:Context=Setup' => 'Setup',
@@ -519,40 +519,43 @@ Dict::Add('EN US', 'English', 'English', array(
//
Dict::Add('EN US', 'English', 'English', array(
'Class:ActionEmail' => 'Email notification',
'Class:ActionEmail+' => '',
'Class:ActionEmail/Attribute:status+' => 'This status drives who will be notified: just the Test recipient, all (To, cc and Bcc) or no-one',
'Class:ActionEmail/Attribute:status/Value:test+' => 'Only the Test recipient is notified',
'Class:ActionEmail/Attribute:status/Value:enabled+' => 'All To, Cc and Bcc emails are notified',
'Class:ActionEmail/Attribute:status/Value:disabled+' => 'The email notification will not be sent',
'Class:ActionEmail/Attribute:test_recipient' => 'Test recipient',
'Class:ActionEmail/Attribute:test_recipient+' => 'Destination email used when notification is being tested',
'Class:ActionEmail/Attribute:from' => 'From (email)',
'Class:ActionEmail/Attribute:from+' => 'Sender email address will be sent into the email header',
'Class:ActionEmail/Attribute:from_label' => 'From (label)',
'Class:ActionEmail/Attribute:from_label+' => 'Sender display name will be sent into the email header',
'Class:ActionEmail/Attribute:reply_to' => 'Reply to (email)',
'Class:ActionEmail/Attribute:reply_to+' => 'Reply to email address Will be sent into the email header',
'Class:ActionEmail/Attribute:reply_to_label' => 'Reply to (label)',
'Class:ActionEmail/Attribute:reply_to_label+' => 'Reply to display name will be sent into the email header',
'Class:ActionEmail/Attribute:to' => 'To',
'Class:ActionEmail/Attribute:to+' => 'Destination of the email',
'Class:ActionEmail/Attribute:cc' => 'Cc',
'Class:ActionEmail/Attribute:cc+' => 'Carbon Copy',
'Class:ActionEmail/Attribute:bcc' => 'Bcc',
'Class:ActionEmail/Attribute:bcc+' => 'Blind Carbon Copy',
'Class:ActionEmail/Attribute:subject' => 'Subject',
'Class:ActionEmail/Attribute:subject+' => 'Title of the email',
'Class:ActionEmail/Attribute:body' => 'Body',
'Class:ActionEmail/Attribute:body+' => 'Contents of the email',
'Class:ActionEmail/Attribute:importance' => 'importance',
'Class:ActionEmail/Attribute:importance+' => 'Importance flag',
'Class:ActionEmail/Attribute:importance/Value:low' => 'low',
'Class:ActionEmail/Attribute:importance/Value:low+' => '',
'Class:ActionEmail/Attribute:importance/Value:normal' => 'normal',
'Class:ActionEmail' => 'Email notification',
'Class:ActionEmail+' => '',
'Class:ActionEmail/Attribute:status+' => 'This status drives who will be notified: just the Test recipient, all (To, cc and Bcc) or no-one',
'Class:ActionEmail/Attribute:status/Value:test+' => 'Only the Test recipient is notified',
'Class:ActionEmail/Attribute:status/Value:enabled+' => 'All To, Cc and Bcc emails are notified',
'Class:ActionEmail/Attribute:status/Value:disabled+' => 'The email notification will not be sent',
'Class:ActionEmail/Attribute:test_recipient' => 'Test recipient',
'Class:ActionEmail/Attribute:test_recipient+' => 'Destination email used when notification is being tested',
'Class:ActionEmail/Attribute:from' => 'From (email)',
'Class:ActionEmail/Attribute:from+' => 'Sender email address will be sent into the email header',
'Class:ActionEmail/Attribute:from_label' => 'From (label)',
'Class:ActionEmail/Attribute:from_label+' => 'Sender display name will be sent into the email header',
'Class:ActionEmail/Attribute:reply_to' => 'Reply to (email)',
'Class:ActionEmail/Attribute:reply_to+' => 'Reply to email address will be sent into the email header',
'Class:ActionEmail/Attribute:reply_to_label' => 'Reply to (label)',
'Class:ActionEmail/Attribute:reply_to_label+' => 'Reply to display name will be sent into the email header',
'Class:ActionEmail/Attribute:to' => 'To',
'Class:ActionEmail/Attribute:to+' => 'Destination of the email',
'Class:ActionEmail/Attribute:cc' => 'Cc',
'Class:ActionEmail/Attribute:cc+' => 'Carbon Copy',
'Class:ActionEmail/Attribute:bcc' => 'Bcc',
'Class:ActionEmail/Attribute:bcc+' => 'Blind Carbon Copy',
'Class:ActionEmail/Attribute:subject' => 'Subject',
'Class:ActionEmail/Attribute:subject+' => 'Title of the email',
'Class:ActionEmail/Attribute:body' => 'Body',
'Class:ActionEmail/Attribute:body+' => 'Contents of the email',
'Class:ActionEmail/Attribute:importance' => 'importance',
'Class:ActionEmail/Attribute:importance+' => 'Importance flag',
'Class:ActionEmail/Attribute:importance/Value:low' => 'Low',
'Class:ActionEmail/Attribute:importance/Value:low+' => '',
'Class:ActionEmail/Attribute:importance/Value:normal' => 'Normal',
'Class:ActionEmail/Attribute:importance/Value:normal+' => '',
'Class:ActionEmail/Attribute:importance/Value:high' => 'high',
'Class:ActionEmail/Attribute:importance/Value:high+' => '',
'Class:ActionEmail/Attribute:importance/Value:high' => 'High',
'Class:ActionEmail/Attribute:importance/Value:high+' => '',
'ActionEmail:main' => 'Message',
'ActionEmail:trigger' => 'Triggers',
'ActionEmail:recipients' => 'Contacts',
));
//

View File

@@ -472,7 +472,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => ' Remove >> ',
'UI:Button:FilterList' => ' Filter... ',
'UI:Button:Create' => ' Create ',
'UI:Button:Delete' => ' Delete ! ',
'UI:Button:Delete' => ' Delete ',
'UI:Button:Rename' => ' Rename... ',
'UI:Button:ChangePassword' => ' Change Password ',
'UI:Button:ResetPassword' => ' Reset Password ',

View File

@@ -516,40 +516,44 @@ Dict::Add('FR FR', 'French', 'Français', array(
//
Dict::Add('FR FR', 'French', 'Français', array(
'Class:ActionEmail' => 'Notification par mél',
'Class:ActionEmail+' => '',
'Class:ActionEmail/Attribute:status+' => 'Cet état définit qui va être notifié: le \'Destinataire de test\', tous les destinataires (A, Copie and Copie Cachée) ou personne',
'Class:ActionEmail/Attribute:status/Value:test+' => 'Seul le destinataire de test est notifié ',
'Class:ActionEmail/Attribute:status/Value:enabled+' => 'Tous les destinataires (A, Copie and Copie Cachée) sont notifiés',
'Class:ActionEmail/Attribute:status/Value:disabled+' => 'La notification n\'est pas envoyée',
'Class:ActionEmail/Attribute:test_recipient' => 'Destinataire de test',
'Class:ActionEmail/Attribute:test_recipient+' => '',
'Class:ActionEmail/Attribute:from' => 'De (mél)',
'Class:ActionEmail/Attribute:from+' => 'Adresse mél qui sera affichés en expéditeur de la notification',
'Class:ActionEmail/Attribute:from_label' => 'De (libellé)',
'Class:ActionEmail/Attribute:from_label+' => 'Le nom de l\'expéditeur sera inclus dans l\'entête du mél',
'Class:ActionEmail/Attribute:reply_to' => 'Répondre à (mél)',
'Class:ActionEmail/Attribute:reply_to+' => 'Adresse mèl qui sera affichée dans le répondre à de la notification',
'Class:ActionEmail/Attribute:reply_to_label' => 'Répondre à (libellé)',
'Class:ActionEmail/Attribute:reply_to_label+' => 'Le nom du destinataire en cas de réponse sera inclus dans l\'entête du mél.',
'Class:ActionEmail/Attribute:to' => 'A',
'Class:ActionEmail/Attribute:to+' => '',
'Class:ActionEmail/Attribute:cc' => 'Copie',
'Class:ActionEmail/Attribute:cc+' => '',
'Class:ActionEmail/Attribute:bcc' => 'Copie Cachée',
'Class:ActionEmail/Attribute:bcc+' => '',
'Class:ActionEmail/Attribute:subject' => 'Sujet',
'Class:ActionEmail/Attribute:subject+' => '',
'Class:ActionEmail/Attribute:body' => 'Message',
'Class:ActionEmail/Attribute:body+' => '',
'Class:ActionEmail/Attribute:importance' => 'Importance',
'Class:ActionEmail/Attribute:importance+' => '',
'Class:ActionEmail/Attribute:importance/Value:low' => 'Basse',
'Class:ActionEmail/Attribute:importance/Value:low+' => '',
'Class:ActionEmail/Attribute:importance/Value:normal' => 'Normale',
'Class:ActionEmail' => 'Notification par mél',
'Class:ActionEmail+' => '',
'Class:ActionEmail/Attribute:status+' => 'Cet état définit qui va être notifié: le \'Destinataire de test\', tous les destinataires (A, Copie and Copie Cachée) ou personne',
'Class:ActionEmail/Attribute:status/Value:test+' => 'Seul le destinataire de test est notifié ',
'Class:ActionEmail/Attribute:status/Value:enabled+' => 'Tous les destinataires (A, Copie and Copie Cachée) sont notifiés',
'Class:ActionEmail/Attribute:status/Value:disabled+' => 'La notification n\'est pas envoyée',
'Class:ActionEmail/Attribute:test_recipient' => 'Destinataire de test',
'Class:ActionEmail/Attribute:test_recipient+' => '',
'Class:ActionEmail/Attribute:from' => 'De (mél)',
'Class:ActionEmail/Attribute:from+' => 'Adresse mél qui sera affichés en expéditeur de la notification',
'Class:ActionEmail/Attribute:from_label' => 'De (libellé)',
'Class:ActionEmail/Attribute:from_label+' => 'Le nom de l\'expéditeur sera inclus dans l\'entête du mél',
'Class:ActionEmail/Attribute:reply_to' => 'Répondre à (mél)',
'Class:ActionEmail/Attribute:reply_to+' => 'Adresse mèl qui sera affichée dans le répondre à de la notification',
'Class:ActionEmail/Attribute:reply_to_label' => 'Répondre à (libellé)',
'Class:ActionEmail/Attribute:reply_to_label+' => 'Le nom du destinataire en cas de réponse sera inclus dans l\'entête du mél.',
'Class:ActionEmail/Attribute:to' => 'A',
'Class:ActionEmail/Attribute:to+' => '',
'Class:ActionEmail/Attribute:cc' => 'Copie',
'Class:ActionEmail/Attribute:cc+' => '',
'Class:ActionEmail/Attribute:bcc' => 'Copie Cachée',
'Class:ActionEmail/Attribute:bcc+' => '',
'Class:ActionEmail/Attribute:subject' => 'Sujet',
'Class:ActionEmail/Attribute:subject+' => '',
'Class:ActionEmail/Attribute:body' => 'Message',
'Class:ActionEmail/Attribute:body+' => '',
'Class:ActionEmail/Attribute:importance' => 'Importance',
'Class:ActionEmail/Attribute:importance+' => '',
'Class:ActionEmail/Attribute:importance/Value:low' => 'Basse',
'Class:ActionEmail/Attribute:importance/Value:low+' => '',
'Class:ActionEmail/Attribute:importance/Value:normal' => 'Normale',
'Class:ActionEmail/Attribute:importance/Value:normal+' => '',
'Class:ActionEmail/Attribute:importance/Value:high' => 'Haute',
'Class:ActionEmail/Attribute:importance/Value:high+' => '',
'Class:ActionEmail/Attribute:importance/Value:high' => 'Haute',
'Class:ActionEmail/Attribute:importance/Value:high+' => '',
'ActionEmail:main' => 'Message',
'ActionEmail:trigger' => 'Conditions de déclenchement',
'ActionEmail:recipients' => 'Contacts',
));
//

View File

@@ -416,7 +416,7 @@ Nous espérons que vous aimerez cette version autant que nous avons eu du plaisi
'UI:Button:RemoveFromList' => ' Enlever >> ',
'UI:Button:FilterList' => ' Filtrer... ',
'UI:Button:Create' => ' Créer ',
'UI:Button:Delete' => ' Supprimer ! ',
'UI:Button:Delete' => ' Supprimer ',
'UI:Button:Rename' => ' Renommer... ',
'UI:Button:ChangePassword' => ' Changer ! ',
'UI:Button:ResetPassword' => ' Ràz du mot de passe ',

View File

@@ -405,7 +405,7 @@ Reméljük, hogy ezt a verziót ugyanúgy kedvelni fogja, mint ahogy mi élvezt
'UI:Button:RemoveFromList' => ' Eltávolítás >> ',
'UI:Button:FilterList' => ' Szűrés... ',
'UI:Button:Create' => ' Létrehozás',
'UI:Button:Delete' => ' Törlés !',
'UI:Button:Delete' => ' Törlés',
'UI:Button:Rename' => ' Átnevezés... ',
'UI:Button:ChangePassword' => ' Jelszó változtatás',
'UI:Button:ResetPassword' => ' Jelszó visszaállítás',

View File

@@ -416,7 +416,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => ' Rimuovi >> ~~',
'UI:Button:FilterList' => ' Filtra... ~~',
'UI:Button:Create' => ' Crea ~~',
'UI:Button:Delete' => ' Cancella ! ~~',
'UI:Button:Delete' => ' Cancella ~~',
'UI:Button:Rename' => ' Rename... ~~',
'UI:Button:ChangePassword' => ' Cambia Password ~~',
'UI:Button:ResetPassword' => ' Resetta Password ~~',

View File

@@ -405,7 +405,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => '削除 >> ',
'UI:Button:FilterList' => ' フィルタ... ',
'UI:Button:Create' => ' 作成 ',
'UI:Button:Delete' => ' 削除! ',
'UI:Button:Delete' => ' 削除 ',
'UI:Button:Rename' => ' 名前変更',
'UI:Button:ChangePassword' => ' パスワード変更 ',
'UI:Button:ResetPassword' => 'パスワードリセット ',

View File

@@ -416,7 +416,7 @@ We hopen dat je even hard van deze versie geniet als dat we zelf ervan hebben ge
'UI:Button:RemoveFromList' => ' Verwijder >> ',
'UI:Button:FilterList' => ' Filter... ',
'UI:Button:Create' => ' Maak aan ',
'UI:Button:Delete' => ' Verwijder ! ',
'UI:Button:Delete' => ' Verwijder ',
'UI:Button:Rename' => ' Hernoem... ',
'UI:Button:ChangePassword' => ' Verander wachtwoord ',
'UI:Button:ResetPassword' => ' Stel wachtwoord opnieuw in ',

View File

@@ -417,7 +417,7 @@ Mamy nadzieję, że spodoba ci się ta wersja tak samo, jak nam się podobało j
'UI:Button:RemoveFromList' => ' Usuń >> ',
'UI:Button:FilterList' => ' Filtruj... ',
'UI:Button:Create' => ' Utwórz ',
'UI:Button:Delete' => ' Usuń ! ',
'UI:Button:Delete' => ' Usuń ',
'UI:Button:Rename' => ' Zmień nazwę... ',
'UI:Button:ChangePassword' => ' Zmień hasło ',
'UI:Button:ResetPassword' => ' Reset hasła ',

View File

@@ -416,7 +416,7 @@ Esperamos que você goste desta versão tanto quanto gostamos de imaginá-la e c
'UI:Button:RemoveFromList' => ' Excluir >> ',
'UI:Button:FilterList' => ' Filtrar... ',
'UI:Button:Create' => ' Criar ',
'UI:Button:Delete' => ' Excluir ! ',
'UI:Button:Delete' => ' Excluir ',
'UI:Button:Rename' => ' Renomear... ',
'UI:Button:ChangePassword' => ' Alterar senha ',
'UI:Button:ResetPassword' => ' Redefinir senha ',

View File

@@ -417,7 +417,7 @@ Dict::Add('RU RU', 'Russian', 'Русский', array(
'UI:Button:RemoveFromList' => ' Удалить >> ',
'UI:Button:FilterList' => ' Фильтр... ',
'UI:Button:Create' => ' Создать ',
'UI:Button:Delete' => ' Удалить ! ',
'UI:Button:Delete' => ' Удалить ',
'UI:Button:Rename' => ' Переименовать...',
'UI:Button:ChangePassword' => ' Изменить пароль ',
'UI:Button:ResetPassword' => ' Сбросить пароль ',

View File

@@ -406,7 +406,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => ' Odstrániť >> ',
'UI:Button:FilterList' => ' Filter... ',
'UI:Button:Create' => ' Vytvoriť ',
'UI:Button:Delete' => ' Vymazať ! ',
'UI:Button:Delete' => ' Vymazať ',
'UI:Button:Rename' => ' Premenovať... ',
'UI:Button:ChangePassword' => ' Zmeniť heslo ',
'UI:Button:ResetPassword' => ' Reset hesla ',

View File

@@ -416,7 +416,7 @@ We hope youll enjoy this version as much as we enjoyed imagining and creating
'UI:Button:RemoveFromList' => ' Sil >> ',
'UI:Button:FilterList' => ' Filtreleme... ',
'UI:Button:Create' => ' Yarat ',
'UI:Button:Delete' => ' Sil ! ',
'UI:Button:Delete' => ' Sil ',
'UI:Button:Rename' => ' Yeniden adlandır... ',
'UI:Button:ChangePassword' => ' Şifre değiştir ',
'UI:Button:ResetPassword' => ' Şifreyi sıfırla ',

View File

@@ -421,7 +421,7 @@ Dict::Add('ZH CN', 'Chinese', '简体中文', array(
'UI:Button:RemoveFromList' => '移除 >>',
'UI:Button:FilterList' => '过滤...',
'UI:Button:Create' => '创建',
'UI:Button:Delete' => '删除!',
'UI:Button:Delete' => '删除',
'UI:Button:Rename' => '重命名...',
'UI:Button:ChangePassword' => '修改密码',
'UI:Button:ResetPassword' => '重置密码',

View File

@@ -190,32 +190,37 @@ class BlockDirectLinkSetEditTable extends UIContentBlock
break;
case LINKSET_EDITMODE_ADDONLY: // The only possible action is to open (in a new window) the form to create a new object
$oActionButtonCreate = ButtonUIBlockFactory::MakeNeutral(Dict::Format('UI:ClickToCreateNew', MetaModel::GetName($this->oAttributeLinkedSet->GetLinkedClass())));
$oActionButtonCreate->AddDataAttribute('action', 'create');
$oActionButtonCreate->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('createRow');");
$oActionButtonCreate = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Create'));
$oActionButtonCreate->SetTooltip(Dict::Format('UI:ClickToCreateNew', MetaModel::GetName($this->oAttributeLinkedSet->GetLinkedClass())))
->AddDataAttribute('action', 'create')
->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('createRow');");
$oToolbar->AddSubBlock($oActionButtonCreate);
break;
case LINKSET_EDITMODE_INPLACE: // The whole linkset can be edited 'in-place'
case LINKSET_EDITMODE_ACTIONS: // Show the usual 'Actions' popup menu
$oActionButtonCreate = ButtonUIBlockFactory::MakeNeutral(Dict::Format('UI:ClickToCreateNew', MetaModel::GetName($this->oAttributeLinkedSet->GetLinkedClass())));
$oActionButtonCreate->AddDataAttribute('action', 'create');
$oActionButtonCreate->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('createRow');");
$oActionButtonCreate = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Create'));
$oActionButtonCreate->SetTooltip(Dict::Format('UI:ClickToCreateNew', MetaModel::GetName($this->oAttributeLinkedSet->GetLinkedClass())))
->AddDataAttribute('action', 'create')
->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('createRow');");
$oToolbar->AddSubBlock($oActionButtonCreate);
$oActionButtonDelete = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Delete'));
$oActionButtonDelete->AddDataAttribute('action', 'delete');
$oActionButtonDelete->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('deleteSelection');");
$oActionButtonDelete = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Delete'));
$oActionButtonDelete->AddDataAttribute('action', 'delete')
->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('deleteSelection');");
$oToolbar->AddSubBlock($oActionButtonDelete);
break;
case LINKSET_EDITMODE_ADDREMOVE: // The whole linkset can be edited 'in-place'
$oActionButtonLink = ButtonUIBlockFactory::MakeNeutral(Dict::Format('UI:AddAnExisting_Class', MetaModel::GetName($this->oAttributeLinkedSet->GetLinkedClass())));
$oActionButtonLink->AddDataAttribute('action', 'add');
$oActionButtonLink->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('selectToAdd');");
$oActionButtonLink = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Add'));
$oActionButtonLink->SetTooltip(Dict::Format('UI:AddAnExisting_Class', MetaModel::GetName($this->oAttributeLinkedSet->GetLinkedClass())))
->AddDataAttribute('action', 'add')
->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('selectToAdd');");
$oToolbar->AddSubBlock($oActionButtonLink);
$oActionButtonUnlink = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Remove'));
$oActionButtonUnlink->AddDataAttribute('action', 'detach');
$oActionButtonUnlink->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('removeSelection');");
$oActionButtonUnlink->AddDataAttribute('action', 'detach')
->SetOnClickJsCode("$('#{$this->oUILinksDirectWidget->GetInputId()}').directlinks('removeSelection');");
$oToolbar->AddSubBlock($oActionButtonUnlink);
break;

View File

@@ -189,13 +189,16 @@ class BlockIndirectLinkSetEditTable extends UIContentBlock
// Toolbar and actions
$oToolbar = ToolbarUIBlockFactory::MakeForButton();
$oActionButtonUnlink = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Remove'));
$oActionButtonUnlink->SetOnClickJsCode("oWidget{$this->oUILinksWidget->GetInputId()}.RemoveSelected();");
$oActionButtonUnlink->AddDataAttribute('action', 'detach');
$oActionButtonUnlink->SetOnClickJsCode("oWidget{$this->oUILinksWidget->GetInputId()}.RemoveSelected();")
->AddDataAttribute('action', 'detach');
$oToolbar->AddSubBlock($oActionButtonUnlink);
$oActionButtonLink = ButtonUIBlockFactory::MakeNeutral(Dict::Format('UI:AddAnExisting_Class', MetaModel::GetName($this->oAttributeLinkedSetIndirect->GetLinkedClass())));
$oActionButtonLink->SetOnClickJsCode("oWidget{$this->oUILinksWidget->GetInputId()}.AddObjects();");
$oActionButtonLink->AddDataAttribute('action', 'add');
$oActionButtonLink = ButtonUIBlockFactory::MakeNeutral(Dict::S('UI:Button:Add'));
$oActionButtonLink->SetTooltip(Dict::Format('UI:AddAnExisting_Class', MetaModel::GetName($this->oAttributeLinkedSetIndirect->GetLinkedClass())))
->SetOnClickJsCode("oWidget{$this->oUILinksWidget->GetInputId()}.AddObjects();")
->AddDataAttribute('action', 'add');
$oToolbar->AddSubBlock($oActionButtonLink);
$oTablePanel->AddToolbarBlock($oToolbar);
$oTablePanel->AddSubBlock($oDataTable);

View File

@@ -56,7 +56,7 @@ class DeadLockInjection
if ($this->iRequestCount == $this->iFailAt) {
echo "Generating a FAKE DEADLOCK\n";
IssueLog::Trace("Generating a FAKE DEADLOCK", 'cmdbsource');
throw new MySQLException("FAKE DEADLOCK", [], new Exception("FAKE DEADLOCK", 1213));
throw new MySQLException("FAKE DEADLOCK", [], new Exception("FAKE DEADLOCK", CMDBSource::MYSQL_ERRNO_DEADLOCK));
}
}
}