summaryrefslogtreecommitdiffstats
path: root/webui_templates
diff options
context:
space:
mode:
authorroot <root@mdehaan.rdu.redhat.com>2007-10-11 11:41:11 -0400
committerroot <root@mdehaan.rdu.redhat.com>2007-10-11 11:41:11 -0400
commit23c7807c07a2badfd8f38d7c351a15b3235651ca (patch)
treefe6c568b92f51c88fffbe9dc007e93f339c08c1e /webui_templates
parent08bd3ff156fe7bd20ce83529190c3a1793ba3c0a (diff)
downloadthird_party-cobbler-23c7807c07a2badfd8f38d7c351a15b3235651ca.tar.gz
third_party-cobbler-23c7807c07a2badfd8f38d7c351a15b3235651ca.tar.xz
third_party-cobbler-23c7807c07a2badfd8f38d7c351a15b3235651ca.zip
Working on adding subprofile creation support to the WebUI, as well as adding new fields to the profiles page for virt-bridge and virt-cpus.
Diffstat (limited to 'webui_templates')
-rw-r--r--webui_templates/master.tmpl1
-rw-r--r--webui_templates/profile_edit.tmpl101
-rw-r--r--webui_templates/profile_list.tmpl8
3 files changed, 88 insertions, 22 deletions
diff --git a/webui_templates/master.tmpl b/webui_templates/master.tmpl
index 9c58fe9..b5b1fcf 100644
--- a/webui_templates/master.tmpl
+++ b/webui_templates/master.tmpl
@@ -41,6 +41,7 @@
<li>ADD</li>
<li><a href="$base_url/distro_edit" class="menu">Distro</a></li>
<li><a href="$base_url/profile_edit" class="menu">Profile</a></li>
+ <li><a href="$base_url/subprofile_edit" class="menu">Subprofile</a></li>
<li><a href="$base_url/system_edit" class="menu">System</a></li>
<li><a href="$base_url/repo_edit" class="menu">Repo</a></li>
<li><hr/><br/></li>
diff --git a/webui_templates/profile_edit.tmpl b/webui_templates/profile_edit.tmpl
index 28af17e..547ad0d 100644
--- a/webui_templates/profile_edit.tmpl
+++ b/webui_templates/profile_edit.tmpl
@@ -31,6 +31,18 @@ function disablename(value)
<input type="hidden" name="new_or_edit" value="new"/>
#end if
+ #if $profile
+ #if $profile.distro == "<<inherit>>"
+ #set $subprofile = 1
+ <input type="hidden" name="subprofile" value="1"/>
+ #else
+ #set $subprofile = 0
+ <input type="hidden" name="subprofile" value="0"/>
+ #end if
+ #else
+ <input type="hidden" name="subprofile" value="$subprofile"/>
+ #end
+
<table border=0>
<tr>
@@ -65,24 +77,45 @@ function disablename(value)
</tr>
#end if
- <tr>
- <td>
- <label for="distro">Distribution</label>
- </td>
- <td>
- <select name="distro" id="distro">
- #for $distro in $distros:
- <option name="$distro.name"
- #if $profile and $profile.distro == $distro.name
- selected="true"
- #end if
- >$distro.name
- </option>
- #end for
- </select>
- <p class="context-tip">What OS is this profile based on?</p>
- </td>
- </tr>
+ #if $subprofile
+ <tr>
+ <td>
+ <label for="distro">Parent</label>
+ </td>
+ <td>
+ <select name="parent" id="parent">
+ #for $parentobj in $profiles:
+ <option name="$parentobj.name"
+ #if $profile and $profile.parent == $parentobj.name
+ selected="true"
+ #end if
+ >$parentobj.name
+ </option>
+ #end for
+ </select>
+ <p class="context-tip">Inherit parameters from what profile?</p>
+ </td>
+ </tr>
+ #else
+ <tr>
+ <td>
+ <label for="distro">Distribution</label>
+ </td>
+ <td>
+ <select name="distro" id="distro">
+ #for $distro in $distros:
+ <option name="$distro.name"
+ #if $profile and $profile.distro == $distro.name
+ selected="true"
+ #end if
+ >$distro.name
+ </option>
+ #end for
+ </select>
+ <p class="context-tip">What OS is this profile based on?</p>
+ </td>
+ </tr>
+ #end
<!-- should allow freeform input but still show a list of choices? -->
<!-- probably should implement a combo box eventually -->
@@ -131,7 +164,7 @@ function disablename(value)
<tr>
<td>
- <label for="virtfilesize">Virt File Size (GB)</label>
+ <label for="virtfilesize">Virt Disk (GB)</label>
</td>
<td>
<input type="text" size="5" style="width: 150px;" name="virtfilesize" id="virtfilesize"
@@ -201,7 +234,35 @@ function disablename(value)
<tr>
<td>
- <label for="repos">Repo Names</label>
+ <label for="virtpath">Virt Bridge</label>
+ </td>
+ <td>
+ <input type="text" size="255" style="width: 150px;" name="virtbridge" id="virtbridge"
+ #if $profile
+ value="$profile.virt_bridge"
+ #end if
+ />
+ <p class="context-tip">Overrides the virtual networking bridge choice in settings.</p>
+ </td>
+ </tr>
+
+ <tr>
+ <td>
+ <label for="virtpath">Virt CPUs</label>
+ </td>
+ <td>
+ <input type="text" size="255" style="width: 150px;" name="virtcpus" id="virtcpus"
+ #if $profile
+ value="$profile.virt_cpus"
+ #end if
+ />
+ <p class="context-tip">How many virtual CPUs? This is an integer.</p>
+ </td>
+ </tr>
+
+ <tr>
+ <td>
+ <label for="repos">Yum Repos</label>
</td>
<td>
diff --git a/webui_templates/profile_list.tmpl b/webui_templates/profile_list.tmpl
index 09e3678..1ccbf31 100644
--- a/webui_templates/profile_list.tmpl
+++ b/webui_templates/profile_list.tmpl
@@ -6,7 +6,7 @@
<caption>Cobbler Profiles</caption>
<tr>
<th class="text">Name</th>
- <th class="text">Distribution</th>
+ <th class="text">Parent</th>
<th class="text">Kickstart</th>
</tr>
</thead>
@@ -25,7 +25,11 @@
<a href="$base_url/profile_edit?name=$profile.name">$profile.name</a>
</td>
<td>
- <a href="$base_url/distro_edit?name=$profile.distro">$profile.distro</a>
+ #if $profile.distro != "<<inherit>>"
+ <a href="$base_url/distro_edit?name=$profile.distro">$profile.distro</a>
+ #else
+ <a href="$base_url/profile_edit?name=$profile.parent">$profile.parent</A>
+ #end if
</td>
<td>$profile.kickstart</td>
</tr>