summaryrefslogtreecommitdiffstats
path: root/webui_templates/distro_edit.tmpl
blob: 167f8cb7880e69bce81caef93ee126965370fff4 (plain)
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
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
#extends cobbler.webui.master
#block body

#if $distro
<script language="javascript">
function disablename(value)
{
    document.getElementById("name").disabled=value;
    if (value) {
        document.getElementById("name").value = "$distro.name";
    }
}


</script>
#end if 

<form method="POST" action="$base_url">
<fieldset id="cform">

     
    #if $distro
        <legend>Editing Distro</legend>
        <input type="hidden" name="mode" value="distro_save">
        <input type="hidden" name="new_or_edit" value="edit"/>
        <input type="hidden" name="oldname" value="$distro.name"/>
    #else
        <legend>Adding a Distro</legend>
        <input type="hidden" name="new_or_edit" value="new"/>
    #end if

    <table border=0>

    <tr>
    <td>
    <label for="name">Name</label>
    </td>
    <td>
    #if $distro
    <input type="text" size="128" style="width: 150px;" name="name" id="name" disabled="true"
    #else
    <input type="text" size="128" style="width: 150px;" name="name" id="name"
    #end if
        #if $distro
            value="$distro.name"
        #end if
    />
    <p class="context-tip">Example: RHEL-5-i386</p>
    </td>
    </tr>

    #if $distro
    <tr>
    <td>
    <label for="mode">Edit Mode</label>
    </td>
    <td>
    <input type="radio" name="editmode" value="edit" checked onclick="javascript:disablename(true)">Edit
    <input type="radio" name="editmode" value="rename" onclick="javascript:disablename(false)">Rename + Edit
    <input type="radio" name="editmode" value="copy" onclick="javascript:disablename(false)">Copy + Edit
    <p class="context-tip">How do you want to modify this object?</p>
    </td>
    </tr>
    #end if


    <tr>
    <td>
    <label for="kernel">Kernel</label>
    </td>
    <td>
    <input type="text" size="255" style="width: 400px;" name="kernel" id="kernel"
        #if $distro
            value="$distro.kernel"
        #end if
    />
    <p class="context-tip">Absolute filesystem path to a kernel file</p>
    </td>
    </tr>

    <tr>
    <td>
    <label for="initrd">Initrd</label>
    </td>
    <td>
    <input type="text" size="255" style="width: 400px;" name="initrd" id="initrd"
        #if $distro
            value="$distro.initrd"
        #end if
    />
    <p class="context-tip">Absolute filesystem path to an initrd file</p>
    </td>
    </tr>

    <tr>
    <td>
    <label for="arch">Architecture</label>
    </td>
    <td>
    #if $distro and $distro.arch == "x86"
        <input type="radio"  name="arch" id="arch" value="x86" checked>x86
    #else
        <input type="radio" name="arch" id="arch" value="x86">x86
    #end if
    #if $distro and $distro.arch == "x86_64"
        <input type="radio" name="arch" id="arch" value="x86_64" checked>x86_64
    #else
        <input type="radio" name="arch" id="arch" value="x86_64">x86_64
    #end if
    #if $distro and $distro.arch == "ia64"
        <input type="radio" name="arch" id="arch" value="ia64" checked>ia64
    #else
        <input type="radio" name="arch" id="arch" value="ia64">ia64
    #end if
    <p class="context-tip">This determines what bootloader to use</p> 
    </td>
    </tr>

    <tr>
    <td>
    <label for="kopts">Kernel Options</label>
    </td>
    <td>
    <input type="text" size="255" style="width: 400px;" name="kopts" id="kopts"
        #if $distro
            value="$distro.kernel_options"
        #end if
    />
    <p class="context-tip">Example: noipv6 magic=foo</p>
    </td>
    </tr>

    <tr>
    <td>
    <label for="ksmeta">Kickstart Metadata</label>
    </td>
    <td>
    <input type="text" size="255" style="width: 400px;" name="ksmeta" id="ksmeta"
        #if $distro
            value="$distro.ks_meta"
        #end if
    />
    <p class="context-tip">Example: dog=fido gnome=yes</p>
    </td>
    </tr>

    <tr>
    <td>
    <label for="breed">Breed</label>
    </td>
    <td>
    #if $distro and $distro.breed == "redhat"
        <input type="radio" name="breed" id="breed" value="redhat" checked>Red Hat Based
    #else
        #if $distro and $distro.breed != "redhat"
            <input type="radio" name="breed" id="breed" value="redhat">Red Hat Based
        #else
            <input type="radio"  name="breed" id="breed" value="redhat" checked>Red Hat Based
        #end if
    #end if
    #if $distro and $distro.breed == "debian"
        <input type="radio"  name="breed" id="breed" value="debian" checked>Debian
    #else
        <input type="radio" name="breed" id="breed" value="debian">Debian
    #end if
    #if $distro and $distro.breed == "suse"
        <input type="radio" name="breed" id="breed" value="suse" checked>SuSE
    #else
        <input type="radio" name="breed" id="breed" value="suse">SuSE
    #end if
    <p class="context-tip">This option determines how kernel options are prepared</p>
    </td>
    </tr>

    #if $distro
    <tr>
    <td>
    <label for="delete">Delete</label>
    </td>
    <td>
       <input type="checkbox" name="delete1" value="delete1">Yes
       <input type="checkbox" name="delete2" value="delete2">Really
       <p class="context-tip">Check both buttons and click save to delete this object</p>
    </td>
    </tr>
    #end if

    <tr>
    <td>
    </td>
    <td>
    <input type="submit" name="submit" value="Save"/>
    <input type="reset" name="reset" value="Reset"/>
    </td>
    </tr>

</table>
</fieldset>
</form>
#end block body