Installation

After decompressing the archive into the plugin folder of GLPI, log on as administrator:

Menu: Configuration / Plugins / manufacturersimports/ Installation

This will create the tables used by the extension.

Prerequisite

(This is a reproduction of the file prerequis.txt which is in the plugin directory manufacturersimports)

  • Dell
  • The equipment must have the serial number field filled with Dell tag
  • The equipment must have the GLPI financial information activated
  • The equipment shall have the right manufacturer (Dell - see config)
  • HP
  • The equipment must have the serial number field filled with HP tag
  • The equipment must have the Model Number field equipment filled with HP tag (tab Imports manufacturers)
  • The equipment must have the GLPI financial information activated
  • The equipment shall have the right manufacturer (HP - see config)
  • Fujitsu-Siemens
  • The equipment must have the serial number field filled with fujitsu-siemens tag
  • The equipment must have the financial information of activated
  • The equipment shall have the right manufacturer (fujitsu-siemens - see config)
  • Toshiba
  • The equipment must have the serial number field filled with Toshiba tag
  • The equipment must have the Model Number field equipment filled with Toshiba tag (tab Imports manufacturers)
  • The equipment must have GLPI financial information activated
  • The equipment shall have the right manufacturer (Toshiba - see config)

Configuration

Rights Management

This step allows you to define user profiles that can use the extension.

  • 0.72 :

Menu: Administration / Profiles / Imports manufacturers Tab

  • 0.71 :

Menu: Configuration / Plugins / Suppliertag / Management rights profile

Automatic calculation of the warranty period (Dell) - GLPI 0.70.X

=== For GLPI 0.72, the code has been integrated into the plugin. To enable automatic recovery, set the warranty period defaults to zero in the configuration of the plugin (for the vendor "Dell" and "HP") ===

This change in code will allow you to automatically obtain the warranty period for your Dell machines. (will take into account any extensions of coverage that may be applicable).

The logic is to determine the warranty period by calculating the number of months between the date of delivery and the highest date found on the page.

To enable automatic recovery, set the warranty period defaults to zero in the configuration of the plugin (for the vendor "Dell").

File: (glpi_home) / plugins / suppliertag / inc / plugin_suppliertag.functions_display.php

Code to be inserted immediately after the following line: No. 909 ($maDate = years."-".months."-".days;)

//
// C. Pierron, TCS
// Recherche automatique de la date de fin de garantie
// (si la duree de garantie a ete parametree a zero dans
//  l'interface utilisateur)
if ( $warranty == 0 )
{
  $masque='([0-9]{2}/[0-9]{2}/[0-9]{4})';

  preg_match_all ($masque, $contents, $liste_resultat);
  $maDateFin = $maDate;

  foreach ($liste_resultat[0] as $occurence)
  {
    $maCandidate = str_replace ('/', '-', $occurence);
    list ($jour, $mois, $annee) = explode ('-', $maCandidate);
    $maCandidate = $annee."-".$mois."-".$jour;

    if ( $maCandidate > $maDateFin )
      $maDateFin = $maCandidate;
  }

  $maDateFin = date ("Y-m-d", strtotime ($maDateFin) + 86400);

  list ($adebut, $mdebut, $jdebut) = explode ('-', $maDate);
  list ($afin, $mfin, $jfin) = explode ('-', $maDateFin);

  $maGarantie = ($afin * 12 + $mfin) - ($adebut * 12 + $mdebut);
  $warranty = $maGarantie;
}