diff --git a/README.md b/README.md
index 2f0117a..015a832 100644
--- a/README.md
+++ b/README.md
@@ -1,2 +1,9 @@
# Services
GLPI ITIL Services project
+
+The goal of this plugin is to associate servers, devices, printers, ... to a specific service based on ITIL concepts.
+
+This include
+ - TCO association for costs redistributions between entities
+ - Information related to disaster recovery (date, plan, doc, ...)
+ - Ownership of service within an enterprise
\ No newline at end of file
diff --git a/ajax/dropdownTypeServices.php b/ajax/dropdownTypeServices.php
index ba3430d..ac0c27a 100644
--- a/ajax/dropdownTypeServices.php
+++ b/ajax/dropdownTypeServices.php
@@ -9,7 +9,7 @@
-------------------------------------------------------------------------
LICENSE
-
+
This file is part of Services.
Services is free software; you can redistribute it and/or modify
@@ -32,8 +32,8 @@
header("Content-Type: text/html; charset=UTF-8");
Html::header_nocache();
}
-
-Session::checkCentralAccess();
+Session::checkLoginUser();
+//Session::checkCentralAccess();
// Make a select box
if (isset($_POST["servicetype"])) {
diff --git a/front/serviceservertype.form.php b/front/serviceservertype.form.php
new file mode 100644
index 0000000..92a490b
--- /dev/null
+++ b/front/serviceservertype.form.php
@@ -0,0 +1,35 @@
+.
+ --------------------------------------------------------------------------
+ */
+
+include ('../../../inc/includes.php');
+
+$dropdown = new PluginServicesServiceServerType();
+include (GLPI_ROOT . "/front/dropdown.common.form.php");
+
+?>
\ No newline at end of file
diff --git a/front/serviceservertype.php b/front/serviceservertype.php
new file mode 100644
index 0000000..b67cc8b
--- /dev/null
+++ b/front/serviceservertype.php
@@ -0,0 +1,35 @@
+.
+ --------------------------------------------------------------------------
+ */
+
+include ('../../../inc/includes.php');
+
+$dropdown = new PluginServicesServiceServerType();
+include (GLPI_ROOT . "/front/dropdown.common.php");
+
+?>
\ No newline at end of file
diff --git a/hook.php b/hook.php
index e6404b3..8029645 100644
--- a/hook.php
+++ b/hook.php
@@ -33,11 +33,13 @@ function plugin_services_install() {
include_once (GLPI_ROOT."/plugins/services/inc/profile.class.php");
$update = false;
- if (TableExists("glpi_plugin_services_services")){
+ if (!TableExists("glpi_application")
+ && !TableExists("glpi_plugin_appweb")
+ && !TableExists("glpi_plugin_services_services")) {
$DB->runFile(GLPI_ROOT ."/plugins/services/sql/empty-1.0.0.sql");
- } /* else {
+ } else {
if (TableExists("glpi_application") && !TableExists("glpi_plugin_appweb")) {
$update = true;
@@ -80,7 +82,29 @@ function plugin_services_install() {
}
}
-
+ if (TableExists("glpi_plugin_services_profiles")) {
+
+ $notepad_tables = array('glpi_plugin_services_services');
+
+ foreach ($notepad_tables as $t) {
+ // Migrate data
+ if (FieldExists($t, 'notepad')) {
+ $query = "SELECT id, notepad
+ FROM `$t`
+ WHERE notepad IS NOT NULL
+ AND notepad <>'';";
+ foreach ($DB->request($query) as $data) {
+ $iq = "INSERT INTO `glpi_notepads`
+ (`itemtype`, `items_id`, `content`, `date`, `date_mod`)
+ VALUES ('".getItemTypeForTable($t)."', '".$data['id']."',
+ '".addslashes($data['notepad'])."', NOW(), NOW())";
+ $DB->queryOrDie($iq, "0.85 migrate notepad data");
+ }
+ $query = "ALTER TABLE `glpi_plugin_services_services` DROP COLUMN `notepad`;";
+ $DB->query($query);
+ }
+ }
+ }
if ($update) {
$query_= "SELECT *
@@ -98,7 +122,7 @@ function plugin_services_install() {
$query = "ALTER TABLE `glpi_plugin_services_profiles`
DROP `name` ;";
- $result = $DB->query($query); */
+ $result = $DB->query($query);
Plugin::migrateItemType(array(1300 => 'PluginServicesService'),
array("glpi_bookmarks", "glpi_bookmarks_users",
@@ -108,11 +132,11 @@ function plugin_services_install() {
Plugin::migrateItemType(array(1200 => "PluginAppliancesAppliance"),
array("glpi_plugin_services_services_items"));
-
+ }
PluginServicesProfile::initProfile();
PluginServicesProfile::createFirstAccess($_SESSION['glpiactiveprofile']['id']);
- $migration = new Migration("1.0.0");
+ $migration = new Migration("2.0.0");
$migration->dropTable('glpi_plugin_services_profiles');
return true;
@@ -127,15 +151,25 @@ function plugin_services_uninstall() {
$tables = array("glpi_plugin_services_services",
"glpi_plugin_services_servicetypes",
- "glpi_plugin_services_servicesupports",
"glpi_plugin_services_serviceservertypes",
- "glpi_plugin_services_servicetiers",
+ "glpi_plugin_services_servicesupports",
+ "glpi_plugin_services_servicetiers",
+ //"glpi_plugin_services_servicetechnics",
"glpi_plugin_services_services_items");
foreach($tables as $table) {
$DB->query("DROP TABLE IF EXISTS `$table`;");
}
+ //old versions
+ $tables = array("glpi_plugin_appweb",
+ "glpi_dropdown_plugin_appweb_type",
+ "glpi_dropdown_plugin_appweb_server_type",
+ "glpi_dropdown_plugin_appweb_technic",
+ "glpi_plugin_appweb_device",
+ "glpi_plugin_appweb_profiles",
+ "glpi_plugin_services_profiles");
+
foreach($tables as $table) {
$DB->query("DROP TABLE IF EXISTS `$table`;");
}
@@ -153,7 +187,11 @@ function plugin_services_uninstall() {
FROM `$table_glpi`
WHERE `itemtype` LIKE 'PluginServices%'");
}
-
+
+ if (class_exists('PluginDatainjectionModel')) {
+ PluginDatainjectionModel::clean(array('itemtype' => 'PluginServicesService'));
+ }
+
//Delete rights associated with the plugin
$profileRight = new ProfileRight();
foreach (PluginServicesProfile::getAllRights() as $right) {
@@ -166,44 +204,6 @@ function plugin_services_uninstall() {
}
-/* // Define dropdown relations
-function plugin_services_getDatabaseRelations() {
-
- $plugin = new Plugin();
-
- if ($plugin->isActivated("services")) {
- return array("glpi_plugin_services_servicetypes"
- => array("glpi_plugin_services_services"
- => "plugin_services_servicetypes_id"),
- "glpi_plugin_services_servicesupports"
- => array("glpi_plugin_services_services"
- => "plugin_services_servicesupports_id"),
- "glpi_plugin_services_serviceservertypes"
- => array("glpi_plugin_services_services"
- =>"plugin_services_serviceservertypes_id"),
- "glpi_plugin_services_servicetiers"
- => array("glpi_plugin_services_services"
- =>"plugin_services_servicetiers_id"),
- "glpi_users"
- => array("glpi_plugin_services_services" => "users_id_tech"),
- "glpi_groups"
- => array("glpi_plugin_services_services" => "groups_id_tech"),
- "glpi_suppliers"
- => array("glpi_plugin_services_services" => "suppliers_id"),
- "glpi_manufacturers"
- => array("glpi_plugin_services_services" => "manufacturers_id"),
- "glpi_locations"
- => array("glpi_plugin_services_services" => "locations_id"),
- "glpi_plugin_services_services"
- => array("glpi_plugin_services_services_items"
- => "plugin_services_services_id"),
- "glpi_entities"
- => array("glpi_plugin_services_services" => "entities_id",
- "glpi_plugin_services_servicetypes" => "entities_id",
- "glpi_plugin_services_servicesupports" => "entities_id"));
- }
- return array();
-} */
// Define dropdown relations
function plugin_services_getDatabaseRelations() {
@@ -239,20 +239,25 @@ function plugin_services_getDatabaseRelations() {
return array();
}
+
// Define Dropdown tables to be manage in GLPI :
function plugin_services_getDropdown() {
$plugin = new Plugin();
if ($plugin->isActivated("services")) {
- return array('PluginServicesServiceType'
- => PluginServicesServiceType::getTypeName(2),
-/* 'PluginServicesServiceServerType'
- => PluginServicesServiceServerType::getTypeName(2), */
- 'PluginServicesServiceSupport'
+ return array( 'PluginServicesServiceBusPriority'
+ => PluginServicesServiceBusPriority::getTypeName(2),
+ 'PluginServicesServiceBusRisk'
+ => PluginServicesServiceBusRisk::getTypeName(2),
+ 'PluginServicesServiceSupport'
=> PluginServicesServiceSupport::getTypeName(2),
- 'PluginServicesServiceTechnic'
- => PluginServicesServiceTechnic::getTypeName(2));
+ 'PluginServicesServiceRto'
+ => PluginServicesServiceRto::getTypeName(2),
+ 'PluginServicesServiceRpo'
+ => PluginServicesServiceRpo::getTypeName(2),
+ 'PluginServicesServiceType'
+ => PluginServicesServiceType::getTypeName(2));
}
return array();
}
@@ -276,75 +281,33 @@ function plugin_services_getAddSearchOptions($itemtype) {
if (in_array($itemtype, PluginServicesService::getTypes(true))) {
if (Session::haveRight("plugin_services", READ)) {
- $sopt[1310]['table'] = 'glpi_plugin_services_services';
- $sopt[1310]['field'] = 'name';
- $sopt[1310]['name'] = PluginServicesService::getTypeName(2)." - ".
+ $sopt[1410]['table'] = 'glpi_plugin_services_services';
+ $sopt[1410]['field'] = 'name';
+ $sopt[1410]['name'] = PluginServicesService::getTypeName(2)." - ".
__('Name');
- $sopt[1310]['forcegroupby'] = true;
- $sopt[1310]['datatype'] = 'itemlink';
- $sopt[1310]['massiveaction'] = false;
- $sopt[1310]['itemlink_type'] = 'PluginServicesService';
- $sopt[1310]['joinparams'] = array('beforejoin'
+ $sopt[1410]['forcegroupby'] = true;
+ $sopt[1410]['datatype'] = 'itemlink';
+ $sopt[1410]['massiveaction'] = false;
+ $sopt[1410]['itemlink_type'] = 'PluginServicesService';
+ $sopt[1410]['joinparams'] = array('beforejoin'
=> array('table' => 'glpi_plugin_services_services_items',
'joinparams' => array('jointype' => 'itemtype_item')));
- $sopt[1311]['table'] = 'glpi_plugin_services_servicetypes';
- $sopt[1311]['field'] = 'name';
- $sopt[1311]['name'] = PluginServicesService::getTypeName(2)." - ".
+ $sopt[1411]['table'] = 'glpi_plugin_services_servicetypes';
+ $sopt[1411]['field'] = 'name';
+ $sopt[1411]['name'] = PluginServicesService::getTypeName(2)." - ".
PluginServicesServiceType::getTypeName(1);
- $sopt[1311]['forcegroupby'] = true;
- $sopt[1311]['datatype'] = 'dropdown';
- $sopt[1311]['massiveaction'] = false;
- $sopt[1311]['joinparams'] = array('beforejoin' => array(
+ $sopt[1411]['forcegroupby'] = true;
+ $sopt[1411]['datatype'] = 'dropdown';
+ $sopt[1411]['massiveaction'] = false;
+ $sopt[1411]['joinparams'] = array('beforejoin' => array(
array('table' => 'glpi_plugin_services_services',
- 'joinparams' => $sopt[1310]['joinparams'])));
+ 'joinparams' => $sopt[1410]['joinparams'])));
}
}
return $sopt;
}
-/* function plugin_services_getAddSearchOptions($itemtype) {
-
- $sopt = array();
-
- if (in_array($itemtype, PluginServicesService::getTypes(true))) {
-
- if (Session::haveRight("plugin_services", READ)) {
- $sopt[1310]['table'] = 'glpi_plugin_services_services';
- $sopt[1310]['field'] = 'name';
- $sopt[1310]['name'] = PluginServicesService::getTypeName(2)." - ". __('Name');
- $sopt[1310]['forcegroupby'] = true;
- $sopt[1310]['datatype'] = 'itemlink';
- $sopt[1310]['massiveaction'] = false;
- $sopt[1310]['itemlink_type'] = 'PluginServicesService';
- $sopt[1310]['joinparams'] = array('beforejoin'
- => array('table' => 'glpi_plugin_services_services_items',
- 'joinparams' => array('jointype' => 'itemtype_item')));
-
- $sopt[1311]['table'] = 'glpi_plugin_services_servicetypes';
- $sopt[1311]['field'] = 'name';
- $sopt[1311]['name'] = PluginServicesService::getTypeName(2)." - ". PluginServicesServiceType::getTypeName(1);
- $sopt[1311]['forcegroupby'] = true;
- $sopt[1311]['datatype'] = 'dropdown';
- $sopt[1311]['massiveaction'] = false;
- $sopt[1311]['joinparams'] = array('beforejoin' => array(
- array('table' => 'glpi_plugin_services_services',
- 'joinparams' => $sopt[1310]['joinparams'])));
-
-/* $sopt[1312]['table'] = 'glpi_plugin_services_servicesupports';
- $sopt[1312]['field'] = 'name';
- $sopt[1312]['name'] = PluginServicesService::getTypeName(2)." - ". PluginServicesServiceSupport::getTypeName(1);
- $sopt[1312]['forcegroupby'] = true;
- $sopt[1312]['datatype'] = 'dropdown';
- $sopt[1312]['massiveaction'] = false;
- $sopt[1312]['joinparams'] = array('beforejoin' => array(
- array('table' => 'glpi_plugin_services_services',
- 'joinparams' => $sopt[1310]['joinparams']))); */
-/* }
- }
-
- return $sopt;
-} */
//display custom fields in the search
function plugin_services_giveItem($type, $ID, $data, $num) {
@@ -445,12 +408,55 @@ function plugin_services_MassiveActions($type) {
if (in_array($type,PluginServicesService::getTypes(true))) {
return array('PluginServicesService'.MassiveAction::CLASS_ACTION_SEPARATOR.'plugin_services_add_item' =>
- __('Associate a Itil Service', 'services'));
+ __('Associate a ITIL Service', 'ITIL Services'));
}
return array();
}
+/*
+function plugin_services_MassiveActionsDisplay($options=array()) {
+
+ $web = new PluginServicesService();
+
+ if (in_array($options['itemtype'], PluginServicesService::getTypes(true))) {
+ $web->dropdownWebApplications("plugin_services_services_id");
+ echo "";
+ }
+ return "";
+}
+
+function plugin_services_MassiveActionsProcess($data) {
+
+ $web_item = new PluginServicesService_Item();
+
+ $res = array('ok' => 0,
+ 'ko' => 0,
+ 'noright' => 0);
+
+ switch ($data['action']) {
+ case "plugin_services_add_item":
+ foreach ($data["item"] as $key => $val) {
+ if ($val == 1) {
+ $input = array('plugin_services_services_id' => $data['plugin_services_services_id'],
+ 'items_id' => $key,
+ 'itemtype' => $data['itemtype']);
+ if ($web_item->can(-1,'w',$input)) {
+ if ($web_item->add($input)){
+ $res['ok']++;
+ } else {
+ $res['ko']++;
+ }
+ } else {
+ $res['noright']++;
+ }
+ }
+ }
+ break;
+ }
+ return $res;
+}
+*/
function plugin_services_postinit() {
global $CFG_GLPI, $PLUGIN_HOOKS;
@@ -465,4 +471,10 @@ function plugin_services_postinit() {
}
}
+function plugin_datainjection_populate_services() {
+ global $INJECTABLE_TYPES;
+
+ $INJECTABLE_TYPES['PluginServicesServiceInjection'] = 'services';
+}
+
?>
\ No newline at end of file
diff --git a/inc/service.class.php b/inc/service.class.php
index 09dfe3b..ec5975b 100644
--- a/inc/service.class.php
+++ b/inc/service.class.php
@@ -318,9 +318,9 @@ function prepareInputForAdd($input) {
if (isset($input['date_query'])
&& empty($input['date_query']))
$input['date_query']='NULL';
- if (isset($input['date_expiration'])
- && empty($input['date_expiration']))
- $input['date_expiration']='NULL';
+ if (isset($input['date_next_dr'])
+ && empty($input['date_next_dr']))
+ $input['date_next_dr']='NULL';
return $input;
}
@@ -330,9 +330,9 @@ function prepareInputForUpdate($input) {
if (isset($input['date_query'])
&& empty($input['date_query']))
$input['date_query']='NULL';
- if (isset($input['date_expiration'])
- && empty($input['date_expiration']))
- $input['date_expiration']='NULL';
+ if (isset($input['date_next_dr'])
+ && empty($input['date_next_dr']))
+ $input['date_next_dr']='NULL';
return $input;
}
@@ -451,14 +451,6 @@ function showForm($ID, $options=array()) {
echo "
".__('Owner information', 'Services')." | ";
echo "";
- //Technical owner
- echo "".__('Technical owner')." | ";
- User::dropdown(array('name' => "users_id_tech",
- 'value' => $this->fields["users_id_tech"],
- 'entity' => $this->fields["entities_id"],
- 'right' => 'interface'));
- echo " | ";
-
//application specialist
echo "".__('Application specialist')." | ";
User::dropdown(array('name' => "users_id_app",
@@ -466,18 +458,18 @@ function showForm($ID, $options=array()) {
'entity' => $this->fields["entities_id"],
'right' => 'interface'));
echo " | ";
-
- // ---- End of 2 -----
- echo "";
- //secondary Technical owner
- echo "".__('Secondary Technical owner')." | ";
- User::dropdown(array('name' => "users_id_sectech",
- 'value' => $this->fields["users_id_sectech"],
+ //Technical owner
+ echo " | ".__('Technical owner')." | ";
+ User::dropdown(array('name' => "users_id_tech",
+ 'value' => $this->fields["users_id_tech"],
'entity' => $this->fields["entities_id"],
'right' => 'interface'));
echo " | ";
+ // ---- End of 2 -----
+ echo "
";
+
//secondary application specialist
echo "".__('Secondary Application specialist')." | ";
User::dropdown(array('name' => "users_id_secapp",
@@ -486,6 +478,14 @@ function showForm($ID, $options=array()) {
'right' => 'interface'));
echo " | ";
+ //secondary Technical owner
+ echo "".__('Secondary Technical owner')." | ";
+ User::dropdown(array('name' => "users_id_sectech",
+ 'value' => $this->fields["users_id_sectech"],
+ 'entity' => $this->fields["entities_id"],
+ 'right' => 'interface'));
+ echo " | ";
+
// ---- End of 2 -----
echo "
";
diff --git a/inc/service_item.class.php b/inc/service_item.class.php
index 0a8efa1..4139c8c 100644
--- a/inc/service_item.class.php
+++ b/inc/service_item.class.php
@@ -451,7 +451,7 @@ static function showForItem(CommonDBTM $item, $withtemplate='') {
'used' => $used));
echo "";
echo "";
+ __s('Associate a service', 'services')."\" class='submit'>";
echo " | ";
echo "
";
echo "";
@@ -821,7 +821,7 @@ static function PdfFromItems(PluginPdfSimplePDF $pdf, CommonGLPI $item){
global $DB,$CFG_GLPI;
$pdf->setColumnsSize(100);
- $pdf->displayTitle(''._n('Associated web application','Associated web applications',2, 'services').'');
+ $pdf->displayTitle(''._n('Associated service','Associated services',2, 'services').'');
$ID = $item->getField('id');
$itemtype = get_Class($item);
diff --git a/inc/serviceservertype.class.php b/inc/serviceservertype.class.php
new file mode 100644
index 0000000..2b21314
--- /dev/null
+++ b/inc/serviceservertype.class.php
@@ -0,0 +1,44 @@
+.
+ --------------------------------------------------------------------------
+ */
+
+if (!defined('GLPI_ROOT')) {
+ die("Sorry. You can't access directly to this file");
+}
+
+class PluginServicesServiceServerType extends CommonDropdown {
+
+ static $rightname = "plugin_services";
+ var $can_be_translated = true;
+
+ static function getTypeName($nb=0) {
+
+ return _n('Type of treatment server','Types of treatment server',$nb, 'webapplications');
+ }
+}
+?>
\ No newline at end of file
diff --git a/locales/en_GB.mo b/locales/en_GB.mo
deleted file mode 100644
index 9c0321b..0000000
Binary files a/locales/en_GB.mo and /dev/null differ
diff --git a/locales/en_GB.po b/locales/en_GB.po
deleted file mode 100644
index b02230c..0000000
--- a/locales/en_GB.po
+++ /dev/null
@@ -1,57 +0,0 @@
-# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR Webapplications Development Team
-# This file is distributed under the same license as the PACKAGE package.
-#
-# Translators:
-msgid ""
-msgstr ""
-"Project-Id-Version: GLPI Project - webapplications plugin\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2013-02-19 15:53+0100\n"
-"PO-Revision-Date: 2013-11-20 09:39+0000\n"
-"Last-Translator: Xavier CAILLAUD \n"
-"Language-Team: English (United Kingdom) (http://www.transifex.com/projects/p/GLPI_webapplications/language/en_GB/)\n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"Language: en_GB\n"
-"Plural-Forms: nplurals=2; plural=(n != 1);\n"
-
-#: hook.php:356 inc/webapplication_item.class.php:413
-msgid "Associate a web application"
-msgstr "Associate a TC application"
-
-#: setup.php:131 inc/webapplication.class.php:43
-msgid "Web application"
-msgid_plural "Web applications"
-msgstr[0] "TC application"
-msgstr[1] "TC applications"
-
-#: setup.php:145
-msgid "This plugin requires GLPI >= 0.84"
-msgstr "This plugin requires GLPI >= 0.84"
-
-#: inc/profile.class.php:37 inc/profile.class.php:133
-msgid "Rights management"
-msgstr "Rights management"
-
-#: inc/webapplication.class.php:154 inc/webapplication.class.php:331
-msgid "Backoffice URL"
-msgstr "Sharepoint URL"
-
-#: inc/webapplication.class.php:167 inc/webapplication.class.php:310
-#: inc/webapplication.class.php:455
-msgid "Editor"
-msgstr "Editor"
-
-#: inc/webapplication_item.class.php:763
-msgid "Associated web application"
-msgid_plural "Associated web applications"
-msgstr[0] "Associated TC application"
-msgstr[1] "Associated TC applications"
-
-#: inc/webapplicationtype.class.php:39
-msgid "Category"
-msgid_plural "Categories"
-msgstr[0] "Category"
-msgstr[1] "Categories"
diff --git a/locales/fr_FR.mo b/locales/fr_FR.mo
deleted file mode 100644
index f94dc1e..0000000
Binary files a/locales/fr_FR.mo and /dev/null differ
diff --git a/locales/fr_FR.po b/locales/fr_FR.po
deleted file mode 100644
index 468726f..0000000
--- a/locales/fr_FR.po
+++ /dev/null
@@ -1,65 +0,0 @@
-# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR Webapplications Development Team
-# This file is distributed under the same license as the PACKAGE package.
-#
-# Translators:
-# Xavier CAILLAUD , 2012
-# Xavier CAILLAUD , 2013
-msgid ""
-msgstr ""
-"Project-Id-Version: GLPI Project - webapplications plugin\n"
-"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2013-02-19 15:53+0100\n"
-"PO-Revision-Date: 2013-11-20 09:39+0000\n"
-"Last-Translator: Xavier CAILLAUD \n"
-"Language-Team: French (France) (http://www.transifex.com/projects/p/GLPI_webapplications/language/fr_FR/)\n"
-"MIME-Version: 1.0\n"
-"Content-Type: text/plain; charset=UTF-8\n"
-"Content-Transfer-Encoding: 8bit\n"
-"Language: fr_FR\n"
-"Plural-Forms: nplurals=2; plural=(n > 1);\n"
-
-#: hook.php:356 inc/webapplication_item.class.php:413
-msgid "Associate a web application"
-msgstr "Associer une application TC"
-
-#: setup.php:131 inc/webapplication.class.php:43
-msgid "Web application"
-msgid_plural "Web applications"
-msgstr[0] "Application TC"
-msgstr[1] "Applications TC"
-
-#: setup.php:145
-msgid "This plugin requires GLPI >= 0.84"
-msgstr " Ce plugin nécessite GLPI >= 0.84"
-
-#: inc/profile.class.php:37 inc/profile.class.php:133
-msgid "Rights management"
-msgstr "Gestion des droits"
-
-#: inc/webapplication.class.php:154 inc/webapplication.class.php:331
-msgid "Backoffice URL"
-msgstr "URL Sharepoint"
-
-#: inc/webapplication.class.php:167 inc/webapplication.class.php:310
-#: inc/webapplication.class.php:455
-msgid "Editor"
-msgstr "Manufacturier "
-
-#: inc/webapplication_item.class.php:763
-msgid "Associated web application"
-msgid_plural "Associated web applications"
-msgstr[0] "Application TC associée"
-msgstr[1] "Applications TC associées"
-
-#: inc/webapplicationtechnic.class.php:38
-msgid "Language of treatment"
-msgid_plural "Languages of treatment"
-msgstr[0] "Site Principal"
-msgstr[1] "Sites Principal"
-
-#: inc/webapplicationtype.class.php:39
-msgid "Category"
-msgid_plural "Categories"
-msgstr[0] "Catégorie"
-msgstr[1] "Catégories"
diff --git a/locales/glpi.pot b/locales/glpi.pot
index 9de47bf..fc68dc3 100644
--- a/locales/glpi.pot
+++ b/locales/glpi.pot
@@ -19,13 +19,13 @@ msgstr ""
"Plural-Forms: nplurals=INTEGER; plural=EXPRESSION;\n"
#: hook.php:403 inc/service_item.class.php:454
-msgid "Associate a web application"
+msgid "Associate an ITIL Service"
msgstr ""
#: setup.php:99 inc/menu.class.php:35 inc/profile.class.php:146
#: inc/service.class.php:45
-msgid "Web application"
-msgid_plural "Web applications"
+msgid "ITIL Service"
+msgid_plural "ITIL Services"
msgstr[0] ""
msgstr[1] ""
@@ -43,8 +43,14 @@ msgid "Editor"
msgstr ""
#: inc/service_item.class.php:814
-msgid "Associated web application"
-msgid_plural "Associated web applications"
+msgid "Associated ITIL Service"
+msgid_plural "Associated ITIL Services"
+msgstr[0] ""
+msgstr[1] ""
+
+#: inc/serviceservertype.class.php:41
+msgid "Type of treatment server"
+msgid_plural "Types of treatment server"
msgstr[0] ""
msgstr[1] ""
diff --git a/services.xml b/services.xml
index bbce3ea..f939c8a 100644
--- a/services.xml
+++ b/services.xml
@@ -3,7 +3,7 @@
ITIL Services
service
stable
- https://raw.githubusercontent.com/bacus99/Services/screeshots/services.png
+ https://raw.githubusercontent.com/bacus99/Services/master/screenshots/services.png
@@ -28,9 +28,7 @@ This plugin allow adding informations to services based on ITIL concepts (DR, Ow
- 1.0.1
- 0.85
- 0.90
+ 1.0.6
9.1
diff --git a/setup.php b/setup.php
index 3279816..972379e 100644
--- a/setup.php
+++ b/setup.php
@@ -42,6 +42,11 @@ function plugin_init_services() {
'initProfile');
$PLUGIN_HOOKS['assign_to_ticket']['services'] = true;
+ if (class_exists('PluginServicesService_Item')) { // only if plugin activated
+ $PLUGIN_HOOKS['plugin_datainjection_populate']['services']
+ = 'plugin_datainjection_populate_services';
+ }
+
// Params : plugin name - string type - number - class - table - form page
Plugin::registerClass('PluginServicesService',
array('linkgroup_tech_types' => true,
@@ -54,8 +59,39 @@ function plugin_init_services() {
Plugin::registerClass('PluginServicesProfile', array('addtabon' => array('Profile')));
- // Display a menu entry ?
- $PLUGIN_HOOKS['menu_toadd']['services'] = array('plugins' => 'PluginServicesMenu');
+ if (class_exists('PluginAccountsAccount')) {
+ PluginAccountsAccount::registerType('PluginServicesService');
+ }
+
+ if (class_exists('PluginCertificatesCertificate')) {
+ PluginCertificatesCertificate::registerType('PluginServicesService');
+ }
+
+ //if glpi is loaded
+ if (Session::getLoginUserID()) {
+
+ //if environment plugin is installed
+ $plugin = new Plugin();
+ if (!$plugin->isActivated('environment')
+ && Session::haveRight("plugin_services", READ)) {
+
+ $PLUGIN_HOOKS['menu_toadd']['services'] = array('plugins' => 'PluginServicesMenu');
+ }
+
+ if (Session::haveRight("plugin_services", UPDATE)) {
+ $PLUGIN_HOOKS['use_massive_action']['services']=1;
+ }
+
+ if (Session::haveRight("plugin_services", READ)
+ || Session::haveRight("config",UPDATE)) {
+ }
+
+ // Import from Data_Injection plugin
+// $PLUGIN_HOOKS['migratetypes']['services']
+ // = 'plugin_datainjection_migratetypes_services';
+ $PLUGIN_HOOKS['plugin_pdf']['PluginServicesService']
+ = 'PluginServicesServicePDF';
+ }
// End init, when all types are registered
$PLUGIN_HOOKS['post_init']['services'] = 'plugin_services_postinit';
@@ -66,7 +102,7 @@ function plugin_init_services() {
function plugin_version_services() {
return array('name' => _n('ITIL Service' , 'ITIL Services' ,2, 'services'),
- 'version' => '1.0.1',
+ 'version' => '1.0.6',
'license' => 'GPLv2+',
'author' => "Christian Bernard, based on WebApplications plugin",
'minGlpiVersion' => '9.1');
diff --git a/sql/empty-1.0.0.sql b/sql/empty-1.0.0.sql
index cd245af..5497823 100644
--- a/sql/empty-1.0.0.sql
+++ b/sql/empty-1.0.0.sql
@@ -1,189 +1,120 @@
-DROP TABLE IF EXISTS `glpi_plugin_services_servicebuspriorities`;
---
--- Table structure for table `glpi_plugin_services_servicebuspriorities`
+-- Table structure for table `glpi_plugin_services_servicetypes`
--
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicebuspriorities` (
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicetypes` (
`id` int(11) NOT NULL,
+ `entities_id` int(11) NOT NULL DEFAULT '0',
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
---
--- Dumping data for table `glpi_plugin_services_servicebuspriorities`
---
+) ENGINE=MyISAM AUTO_INCREMENT=141 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-INSERT INTO `glpi_plugin_services_servicebuspriorities` (`id`, `name`, `comment`) VALUES
-(2, 'P1', ''),
-(3, 'P2', ''),
-(4, 'P3', ''),
-(5, 'P4', NULL),
-(1, 'P0', NULL);
-
---
--- Indexes for dumped tables
---
-
---
--- Indexes for table `glpi_plugin_services_servicebuspriorities`
+-- Indexes for table `glpi_plugin_services_servicetypes`
--
-ALTER TABLE `glpi_plugin_services_servicebuspriorities`
+ALTER TABLE `glpi_plugin_services_servicetypes`
ADD PRIMARY KEY (`id`),
- ADD KEY `name` (`name`);
+ ADD KEY `name` (`name`),
+ ADD KEY `entities_id` (`entities_id`);
--
-- AUTO_INCREMENT for dumped tables
--
--
--- AUTO_INCREMENT for table `glpi_plugin_services_servicebuspriorities`
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicetypes`
--
-ALTER TABLE `glpi_plugin_services_servicebuspriorities`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=6;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
+ALTER TABLE `glpi_plugin_services_servicetypes`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=141;
-DROP TABLE IF EXISTS `glpi_plugin_services_servicebusrisks`;
--- Table structure for table `glpi_plugin_services_servicebusrisks`
+
+--
+-- Table structure for table `glpi_plugin_services_servicetiers`
--
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicebusrisks` (
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicetiers` (
`id` int(11) NOT NULL,
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
---
--- Dumping data for table `glpi_plugin_services_servicebusrisks`
---
-
-INSERT INTO `glpi_plugin_services_servicebusrisks` (`id`, `name`, `comment`) VALUES
-(1, 'Low', ''),
-(2, 'Medium', ''),
-(3, 'High', '');
+) ENGINE=MyISAM AUTO_INCREMENT=8 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
---
--- Indexes for dumped tables
---
+INSERT INTO `glpi_plugin_services_servicetiers` (`id`, `name`, `comment`) VALUES
+(1, 'Tier 0', ''),
+(2, 'Tier 1', ''),
+(3, 'Tier 2', ''),
+(4, 'Tier 3', NULL);
--
--- Indexes for table `glpi_plugin_services_servicebusrisks`
+-- Indexes for table `glpi_plugin_services_servicetiers`
--
-ALTER TABLE `glpi_plugin_services_servicebusrisks`
+ALTER TABLE `glpi_plugin_services_servicetiers`
ADD PRIMARY KEY (`id`),
ADD KEY `name` (`name`);
-
---
--- AUTO_INCREMENT for dumped tables
+
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicetiers`
--
+ALTER TABLE `glpi_plugin_services_servicetiers`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=8;
---
--- AUTO_INCREMENT for table `glpi_plugin_services_servicebusrisks`
---
-ALTER TABLE `glpi_plugin_services_servicebusrisks`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=4;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
--- Table structure for table `glpi_plugin_services_servicerpos`
---
-DROP TABLE IF EXISTS `glpi_plugin_services_servicerpos`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicerpos` (
- `id` int(11) NOT NULL,
- `name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
- `comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=11 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
---
--- Dumping data for table `glpi_plugin_services_servicerpos`
+-- Table structure for table `glpi_plugin_services_services_items`
--
-INSERT INTO `glpi_plugin_services_servicerpos` (`id`, `name`, `comment`) VALUES
-(5, '48h', ''),
-(4, '> 48h', ''),
-(6, 'ND', ''),
-(7, '4h', ''),
-(8, '8h', ''),
-(9, '24h', ''),
-(10, '2h', '');
-
---
--- Indexes for dumped tables
---
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_services_items` (
+ `id` int(11) NOT NULL,
+ `plugin_services_services_id` int(11) NOT NULL DEFAULT '0' COMMENT 'RELATION to glpi_plugin_services_services (id)',
+ `items_id` int(11) NOT NULL DEFAULT '0' COMMENT 'RELATION to various tables, according to itemtype (id)',
+ `itemtype` varchar(100) COLLATE utf8_unicode_ci NOT NULL COMMENT 'see .class.php file'
+) ENGINE=MyISAM AUTO_INCREMENT=7955 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+-- Indexes for table `glpi_plugin_services_services_items`
--
--- Indexes for table `glpi_plugin_services_servicerpos`
---
-ALTER TABLE `glpi_plugin_services_servicerpos`
+ALTER TABLE `glpi_plugin_services_services_items`
ADD PRIMARY KEY (`id`),
- ADD KEY `name` (`name`);
-
---
--- AUTO_INCREMENT for dumped tables
---
+ ADD UNIQUE KEY `unicity` (`plugin_services_services_id`,`items_id`,`itemtype`),
+ ADD KEY `FK_device` (`items_id`,`itemtype`),
+ ADD KEY `item` (`itemtype`,`items_id`);
+ -- AUTO_INCREMENT for table `glpi_plugin_services_services_items`
--
--- AUTO_INCREMENT for table `glpi_plugin_services_servicerpos`
---
-ALTER TABLE `glpi_plugin_services_servicerpos`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=11;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
+ALTER TABLE `glpi_plugin_services_services_items`;
--- Table structure for table `glpi_plugin_services_servicertos`
+-- Table structure for table `glpi_plugin_services_servicesupports`
--
-DROP TABLE IF EXISTS `glpi_plugin_services_servicertos`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicertos` (
+
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicesupports` (
`id` int(11) NOT NULL,
+ `entities_id` int(11) NOT NULL DEFAULT '0',
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=11 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--
--- Dumping data for table `glpi_plugin_services_servicertos`
+-- Dumping data for table `glpi_plugin_services_servicesupports`
--
-INSERT INTO `glpi_plugin_services_servicertos` (`id`, `name`, `comment`) VALUES
-(5, '48h', ''),
-(4, '> 48h', ''),
-(6, 'ND', ''),
-(7, '4h', ''),
-(8, '8h', ''),
-(9, '24h', ''),
-(10, '2h', '');
-
---
--- Indexes for dumped tables
---
+INSERT INTO `glpi_plugin_services_servicesupports` (`id`, `entities_id`, `name`, `comment`) VALUES
+(1, 0, '24/7', NULL),
+(2, 0, '8x5', '');
+-- Indexes for table `glpi_plugin_services_servicesupports`
--
--- Indexes for table `glpi_plugin_services_servicertos`
---
-ALTER TABLE `glpi_plugin_services_servicertos`
+ALTER TABLE `glpi_plugin_services_servicesupports`
ADD PRIMARY KEY (`id`),
- ADD KEY `name` (`name`);
-
---
--- AUTO_INCREMENT for dumped tables
+ ADD KEY `name` (`name`),
+ ADD KEY `entities_id` (`entities_id`);
+
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicesupports`
--
+ALTER TABLE `glpi_plugin_services_servicesupports`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=3;
+
---
--- AUTO_INCREMENT for table `glpi_plugin_services_servicertos`
---
-ALTER TABLE `glpi_plugin_services_servicertos`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=11;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
+
-- Table structure for table `glpi_plugin_services_services`
--
-DROP TABLE IF EXISTS `glpi_plugin_services_services`;
+
CREATE TABLE IF NOT EXISTS `glpi_plugin_services_services` (
`id` int(11) NOT NULL,
`entities_id` int(11) NOT NULL DEFAULT '0',
@@ -218,16 +149,8 @@ CREATE TABLE IF NOT EXISTS `glpi_plugin_services_services` (
`is_disaster_recovery` int(5) NOT NULL DEFAULT '0',
`is_disaster_recovery_documented` int(5) NOT NULL,
`dr_docs_url` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL
-) ENGINE=MyISAM AUTO_INCREMENT=465 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
---
--- Dumping data for table `glpi_plugin_services_services`
---
---
--- Indexes for dumped tables
---
+) ENGINE=MyISAM AUTO_INCREMENT=482 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
---
-- Indexes for table `glpi_plugin_services_services`
--
ALTER TABLE `glpi_plugin_services_services`
@@ -246,232 +169,145 @@ ALTER TABLE `glpi_plugin_services_services`
ADD KEY `is_helpdesk_visible` (`is_helpdesk_visible`),
ADD KEY `is_deleted` (`is_deleted`);
---
--- AUTO_INCREMENT for dumped tables
---
-
---
+ --
-- AUTO_INCREMENT for table `glpi_plugin_services_services`
--
ALTER TABLE `glpi_plugin_services_services`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=465;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=482;
--- Table structure for table `glpi_plugin_services_servicesupports`
+
+
+-- Table structure for table `glpi_plugin_services_servicertos`
--
-DROP TABLE IF EXISTS `glpi_plugin_services_servicesupports`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicesupports` (
+
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicertos` (
`id` int(11) NOT NULL,
- `entities_id` int(11) NOT NULL DEFAULT '0',
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=3 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+) ENGINE=MyISAM AUTO_INCREMENT=11 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--
--- Dumping data for table `glpi_plugin_services_servicesupports`
+-- Dumping data for table `glpi_plugin_services_servicertos`
--
-INSERT INTO `glpi_plugin_services_servicesupports` (`id`, `entities_id`, `name`, `comment`) VALUES
-(1, 0, '24/7', NULL),
-(2, 0, '8x5', '');
+INSERT INTO `glpi_plugin_services_servicertos` (`id`, `name`, `comment`) VALUES
+(5, '48h', ''),
+(4, '> 48h', ''),
+(6, 'ND', ''),
+(7, '4h', ''),
+(8, '8h', ''),
+(9, '24h', ''),
+(10, '2h', '');
---
--- Indexes for dumped tables
---
+-- Indexes for table `glpi_plugin_services_servicertos`
--
--- Indexes for table `glpi_plugin_services_servicesupports`
---
-ALTER TABLE `glpi_plugin_services_servicesupports`
+ALTER TABLE `glpi_plugin_services_servicertos`
ADD PRIMARY KEY (`id`),
- ADD KEY `name` (`name`),
- ADD KEY `entities_id` (`entities_id`);
-
---
--- AUTO_INCREMENT for dumped tables
---
-
---
--- AUTO_INCREMENT for table `glpi_plugin_services_servicesupports`
---
-ALTER TABLE `glpi_plugin_services_servicesupports`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=3;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-
--- Table structure for table `glpi_plugin_services_services_items`
---
-DROP TABLE IF EXISTS `glpi_plugin_services_services_items`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_services_items` (
- `id` int(11) NOT NULL,
- `plugin_services_services_id` int(11) NOT NULL DEFAULT '0' COMMENT 'RELATION to glpi_plugin_services_services (id)',
- `items_id` int(11) NOT NULL DEFAULT '0' COMMENT 'RELATION to various tables, according to itemtype (id)',
- `itemtype` varchar(100) COLLATE utf8_unicode_ci NOT NULL COMMENT 'see .class.php file'
-) ENGINE=MyISAM AUTO_INCREMENT=6651 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
-
---
--- Dumping data for table `glpi_plugin_services_services_items`
---
-
---
--- Indexes for dumped tables
---
-
+ ADD KEY `name` (`name`);
+
--
--- Indexes for table `glpi_plugin_services_services_items`
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicertos`
--
-ALTER TABLE `glpi_plugin_services_services_items`
- ADD PRIMARY KEY (`id`),
- ADD UNIQUE KEY `unicity` (`plugin_services_services_id`,`items_id`,`itemtype`),
- ADD KEY `FK_device` (`items_id`,`itemtype`),
- ADD KEY `item` (`itemtype`,`items_id`);
+ALTER TABLE `glpi_plugin_services_servicertos`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=11;
---
--- AUTO_INCREMENT for dumped tables
---
+
+-- Table structure for table `glpi_plugin_services_servicerpos`
--
--- AUTO_INCREMENT for table `glpi_plugin_services_services_items`
---
-ALTER TABLE `glpi_plugin_services_services_items`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=6651;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
--- Table structure for table `glpi_plugin_services_servicetechnics`
---
-DROP TABLE IF EXISTS `glpi_plugin_services_servicetechnics`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicetechnics` (
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicerpos` (
`id` int(11) NOT NULL,
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=5 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+) ENGINE=MyISAM AUTO_INCREMENT=12 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--
--- Dumping data for table `glpi_plugin_services_servicetechnics`
+-- Dumping data for table `glpi_plugin_services_servicerpos`
--
-INSERT INTO `glpi_plugin_services_servicetechnics` (`id`, `name`, `comment`) VALUES
-(1, 'Tier 0', ''),
-(2, 'Tier 1', ''),
-(3, 'Tier 2', ''),
-(4, 'Tier 3', NULL);
-
---
--- Indexes for dumped tables
---
+INSERT INTO `glpi_plugin_services_servicerpos` (`id`, `name`, `comment`) VALUES
+(5, '48h', ''),
+(4, '> 48h', ''),
+(6, 'ND', ''),
+(7, '4h', ''),
+(8, '8h', ''),
+(9, '24h', ''),
+(10, '2h', ''),
+(11, '15 Min', '');
+-- Indexes for table `glpi_plugin_services_servicerpos`
--
--- Indexes for table `glpi_plugin_services_servicetechnics`
---
-ALTER TABLE `glpi_plugin_services_servicetechnics`
+ALTER TABLE `glpi_plugin_services_servicerpos`
ADD PRIMARY KEY (`id`),
ADD KEY `name` (`name`);
+ --
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicerpos`
--
--- AUTO_INCREMENT for dumped tables
---
+ALTER TABLE `glpi_plugin_services_servicerpos`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=12;
---
--- AUTO_INCREMENT for table `glpi_plugin_services_servicetechnics`
---
-ALTER TABLE `glpi_plugin_services_servicetechnics`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=5;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
--- Table structure for table `glpi_plugin_services_servicetiers`
+-- Table structure for table `glpi_plugin_services_servicebusrisks`
--
-DROP TABLE IF EXISTS `glpi_plugin_services_servicetiers`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicetiers` (
+
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicebusrisks` (
`id` int(11) NOT NULL,
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=8 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--
--- Dumping data for table `glpi_plugin_services_servicetiers`
+-- Dumping data for table `glpi_plugin_services_servicebusrisks`
--
-INSERT INTO `glpi_plugin_services_servicetiers` (`id`, `name`, `comment`) VALUES
-(1, 'Tier 0', ''),
-(2, 'Tier 1', ''),
-(3, 'Tier 2', ''),
-(4, 'Tier 3', NULL);
-
---
--- Indexes for dumped tables
---
+INSERT INTO `glpi_plugin_services_servicebusrisks` (`id`, `name`, `comment`) VALUES
+(1, 'Low', ''),
+(2, 'Medium', ''),
+(3, 'High', '');
+-- Indexes for table `glpi_plugin_services_servicebusrisks`
--
--- Indexes for table `glpi_plugin_services_servicetiers`
---
-ALTER TABLE `glpi_plugin_services_servicetiers`
+ALTER TABLE `glpi_plugin_services_servicebusrisks`
ADD PRIMARY KEY (`id`),
ADD KEY `name` (`name`);
--
--- AUTO_INCREMENT for dumped tables
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicebusrisks`
--
+ALTER TABLE `glpi_plugin_services_servicebusrisks`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=4;
+
+-- Table structure for table `glpi_plugin_services_servicebuspriorities`
--
--- AUTO_INCREMENT for table `glpi_plugin_services_servicetiers`
---
-ALTER TABLE `glpi_plugin_services_servicetiers`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=8;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-
--- Table structure for table `glpi_plugin_services_servicetypes`
---
-DROP TABLE IF EXISTS `glpi_plugin_services_servicetypes`;
-CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicetypes` (
+CREATE TABLE IF NOT EXISTS `glpi_plugin_services_servicebuspriorities` (
`id` int(11) NOT NULL,
- `entities_id` int(11) NOT NULL DEFAULT '0',
`name` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
`comment` text COLLATE utf8_unicode_ci
-) ENGINE=MyISAM AUTO_INCREMENT=120 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
+) ENGINE=MyISAM AUTO_INCREMENT=6 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
--
--- Dumping data for table `glpi_plugin_services_servicetypes`
+-- Dumping data for table `glpi_plugin_services_servicebuspriorities`
--
---
--- Indexes for dumped tables
---
+INSERT INTO `glpi_plugin_services_servicebuspriorities` (`id`, `name`, `comment`) VALUES
+(2, 'P1', ''),
+(3, 'P2', ''),
+(4, 'P3', ''),
+(5, 'P4', NULL),
+(1, 'P0', NULL);
+-- Indexes for table `glpi_plugin_services_servicebuspriorities`
--
--- Indexes for table `glpi_plugin_services_servicetypes`
---
-ALTER TABLE `glpi_plugin_services_servicetypes`
+ALTER TABLE `glpi_plugin_services_servicebuspriorities`
ADD PRIMARY KEY (`id`),
- ADD KEY `name` (`name`),
- ADD KEY `entities_id` (`entities_id`);
-
---
--- AUTO_INCREMENT for dumped tables
---
-
+ ADD KEY `name` (`name`);
--
--- AUTO_INCREMENT for table `glpi_plugin_services_servicetypes`
+-- AUTO_INCREMENT for table `glpi_plugin_services_servicebuspriorities`
--
-ALTER TABLE `glpi_plugin_services_servicetypes`
- MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=120;
-/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
-/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
-/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
-
-
-
-INSERT INTO `glpi_displaypreferences` VALUES (NULL,'PluginServicesService','2','2','0');
-INSERT INTO `glpi_displaypreferences` VALUES (NULL,'PluginServicesService','3','4','0');
-INSERT INTO `glpi_displaypreferences` VALUES (NULL,'PluginServicesService','6','5','0');
-INSERT INTO `glpi_displaypreferences` VALUES (NULL,'PluginServicesService','7','6','0');
-INSERT INTO `glpi_displaypreferences` VALUES (NULL,'PluginServicesService','8','7','0');
\ No newline at end of file
+ALTER TABLE `glpi_plugin_services_servicebuspriorities`
+ MODIFY `id` int(11) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=6;