File tree 4 files changed +66
-12
lines changed
4 files changed +66
-12
lines changed Original file line number Diff line number Diff line change 31
31
* ---------------------------------------------------------------------
32
32
*/
33
33
34
- include ("../../../inc/includes.php " );
35
-
34
+ include ('../../../inc/includes.php ' );
36
35
$ dropdown = new PluginGlpiinventoryCredential ();
37
- include (GLPI_ROOT . "/front/dropdown.common.form.php " );
36
+
37
+ if (!empty ($ _POST ) || isset ($ _GET ['_in_modal ' ])) {
38
+ include (GLPI_ROOT . "/front/dropdown.common.form.php " );
39
+ } else {
40
+ Html::header (
41
+ __ ('GLPI Inventory ' , 'glpiinventory ' ),
42
+ $ _SERVER ["PHP_SELF " ],
43
+ "admin " ,
44
+ "pluginglpiinventorymenu " ,
45
+ "credential "
46
+ );
47
+ PluginGlpiinventoryMenu::displayMenu ("mini " );
48
+ //If there is no form to submit, display the form
49
+ $ dropdown ->display ($ _GET );
50
+ Html::footer ();
51
+ }
38
52
39
53
if (isset ($ _GET ['popup ' ])) {
40
54
Ajax::refreshDropdownPopupInMainWindow ();
Original file line number Diff line number Diff line change 33
33
34
34
include ("../../../inc/includes.php " );
35
35
36
- $ dropdown = new PluginGlpiinventoryCredential ();
37
- include (GLPI_ROOT . "/front/dropdown.common.php " );
36
+ Html::header (
37
+ __ ('GLPI Inventory ' , 'glpiinventory ' ),
38
+ $ _SERVER ["PHP_SELF " ],
39
+ "admin " ,
40
+ "pluginglpiinventorymenu " ,
41
+ "credential "
42
+ );
43
+
44
+ Session::checkRight ('plugin_glpiinventory_iprange ' , READ );
45
+
46
+ PluginGlpiinventoryMenu::displayMenu ("mini " );
47
+
48
+ Search::show ('PluginGlpiinventoryCredential ' );
49
+
50
+ Html::footer ();
Original file line number Diff line number Diff line change 31
31
* ---------------------------------------------------------------------
32
32
*/
33
33
34
- include ("../../../inc/includes.php " );
34
+ include ('../../../inc/includes.php ' );
35
+ $ dropdown = new PluginGlpiinventoryCredentialIP ();
35
36
36
- $ dropdown = new PluginGlpiinventoryCredentialIp ();
37
- if (empty ($ _POST ['plugin_glpiinventory_credentials_id ' ])) {
38
- $ _POST ['plugin_glpiinventory_credentials_id ' ] = 0 ;
37
+ if (!empty ($ _POST ) || isset ($ _GET ['_in_modal ' ])) {
38
+ if (empty ($ _POST ['plugin_glpiinventory_credentials_id ' ])) {
39
+ $ _POST ['plugin_glpiinventory_credentials_id ' ] = 0 ;
40
+ }
41
+ include (GLPI_ROOT . "/front/dropdown.common.form.php " );
42
+ } else {
43
+ Html::header (
44
+ __ ('GLPI Inventory ' , 'glpiinventory ' ),
45
+ $ _SERVER ["PHP_SELF " ],
46
+ "admin " ,
47
+ "pluginglpiinventorymenu " ,
48
+ "credentialip "
49
+ );
50
+ PluginGlpiinventoryMenu::displayMenu ("mini " );
51
+ //If there is no form to submit, display the form
52
+ $ dropdown ->display ($ _GET );
53
+ Html::footer ();
39
54
}
40
- include (GLPI_ROOT . "/front/dropdown.common.form.php " );
Original file line number Diff line number Diff line change 33
33
34
34
include ("../../../inc/includes.php " );
35
35
36
- $ dropdown = new PluginGlpiinventoryCredentialIp ();
37
- include (GLPI_ROOT . "/front/dropdown.common.php " );
36
+ Html::header (
37
+ __ ('GLPI Inventory ' , 'glpiinventory ' ),
38
+ $ _SERVER ["PHP_SELF " ],
39
+ "admin " ,
40
+ "pluginglpiinventorymenu " ,
41
+ "credentialip "
42
+ );
43
+
44
+ Session::checkRight ('plugin_glpiinventory_iprange ' , READ );
45
+
46
+ PluginGlpiinventoryMenu::displayMenu ("mini " );
47
+
48
+ Search::show ('PluginGlpiinventoryCredentialIp ' );
49
+
50
+ Html::footer ();
You can’t perform that action at this time.
0 commit comments