mirror of
https://github.com/pluginsGLPI/example.git
synced 2025-05-04 18:08:42 +02:00
Modif mineure pour modif massive
git-svn-id: https://forge.glpi-project.org/svn/example/trunk@28 349b9182-4a13-0410-896f-e5e9767dd1b3
This commit is contained in:
parent
766d279942
commit
48480974d9
2
db.sql
2
db.sql
@ -1,5 +1,5 @@
|
||||
CREATE TABLE `glpi_plugin_example` (
|
||||
`ID` int(11) NOT NULL,
|
||||
`ID` int(11) NOT NULL auto_increment,
|
||||
`name` varchar(255) collate utf8_unicode_ci default NULL,
|
||||
`FK_dropdown` int(11) NOT NULL default '0',
|
||||
`deleted` smallint(6) NOT NULL default '0',
|
||||
|
14
setup.php
14
setup.php
@ -76,10 +76,18 @@ function plugin_init_example() {
|
||||
$PLUGIN_HOOKS['add_javascript']['example']="example.js";
|
||||
$PLUGIN_HOOKS['add_css']['example']="example.css";
|
||||
|
||||
// Params : plugin name - string type - number - tabke - form page
|
||||
pluginNewType('example',"PLUGIN_EXAMPLE_TYPE",1001,"glpi_plugin_example","example.form.php");
|
||||
// Params : plugin name - string type - ID - class - table - form page
|
||||
pluginNewType('example',"PLUGIN_EXAMPLE_TYPE",1001,"pluginExample","glpi_plugin_example","example.form.php");
|
||||
|
||||
}
|
||||
|
||||
class pluginExample extends CommonDBTM {
|
||||
function pluginExample () {
|
||||
$this->table="glpi_plugin_example";
|
||||
$this->type=PLUGIN_EXAMPLE_TYPE;
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
// Get the name and the version of the plugin - Needed
|
||||
function plugin_version_example(){
|
||||
@ -395,4 +403,6 @@ function plugin_central_action_example(){
|
||||
function cron_plugin_example(){
|
||||
echo "tttt";
|
||||
}
|
||||
|
||||
|
||||
?>
|
||||
|
Loading…
x
Reference in New Issue
Block a user