-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathconfig.html.twig
More file actions
114 lines (101 loc) · 3.83 KB
/
config.html.twig
File metadata and controls
114 lines (101 loc) · 3.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
{#
# -------------------------------------------------------------------------
# TreeView plugin for GLPI
# -------------------------------------------------------------------------
#
# LICENSE
#
# This file is part of TreeView.
#
# TreeView is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# TreeView is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with TreeView. If not, see <http://www.gnu.org/licenses/>.
# -------------------------------------------------------------------------
# @copyright Copyright (C) 2007-2023 by Teclib'.
# @license GPLv2 https://www.gnu.org/licenses/gpl-2.0.html
# @link https://github.com/pluginsGLPI/treeview
# -------------------------------------------------------------------------
#}
{% import "components/form/fields_macros.html.twig" as fields %}
<div class="hr-text">
<i class="fa-2x ti ti-sitemap"></i>
<span>{{ __('Treeview - Configuration', 'treeview') }}</span>
</div>
<form name='form' action='{{ action }}' method='post' class='left'>
<input type="hidden" name="id" value="1">
<input type="hidden" name="_glpi_csrf_token" value="{{ csrf_token() }}">
{{ fields.dropdownArrayField(
'target',
current_config['target'],
{
'_blank': __('New window', 'treeview'),
'right': __('The central console', 'treeview')
},
__('Target for all the nodes', 'treeview')
) }}
{{ fields.checkboxField(
'folderLinks',
current_config['folderLinks'],
__('Should folders be links', 'treeview')
) }}
{{ fields.checkboxField(
'useSelection',
current_config['useSelection'],
__('Nodes can be highlighted', 'treeview')
) }}
{{ fields.checkboxField(
'useLines',
current_config['useLines'],
__('Tree is drawn with lines', 'treeview')
) }}
{{ fields.checkboxField(
'useIcons',
current_config['useIcons'],
__('Tree is drawn with icons', 'treeview')
) }}
{{ fields.checkboxField(
'closeSameLevel',
current_config['closeSameLevel'],
__('Only one node within a parent', 'treeview') ~ ' ' ~ __('can be expanded at the same time.', 'treeview')
) }}
{{ fields.dropdownArrayField(
'itemName',
current_config['itemName'],
{
'0': __('Name'),
'1': __('Inventory number'),
'2': __('%1$s / %2$s', {'%1$s': __('Name'), '%2$s': __('Inventory number')}),
'3': __('%1$s / %2$s', {'%1$s': __('Inventory number'), '%2$s': __('Name')})
},
__('Item name', 'treeview')
) }}
{{ fields.dropdownArrayField(
'locationName',
current_config['locationName'],
{
'0': __('Short name', 'treeview'),
'1': __('Long name', 'treeview'),
'2': __('%1$s / %2$s', {'%1$s': __('Short name', 'treeview'), '%2$s': __('Comment', 'treeview')}),
'3': __('%1$s / %2$s', {'%1$s': __('Long name', 'treeview'), '%2$s': __('Comment', 'treeview')})
},
__('Location name', 'treeview')
) }}
<div class="hr"></div>
<div class="hstack gap-1">
<div class="pe-5 ms-auto">
<button class="btn btn-primary" type="submit" name="update" value="1">
<i class="ti ti-device-floppy"></i>
<span>{{ _x('button', 'Save') }}</span>
</button>
</div>
</div>
</form>