diff app/views/storage/edit_pool.ctp @ 1:eb4fee3d9bb8

added StoragePools management functions (storage_controller)
author Shoshi TAMAKI <shoshi@cr.ie.u-ryukyu.ac.jp>
date Wed, 27 Jul 2011 00:00:25 +0900
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/app/views/storage/edit_pool.ctp	Wed Jul 27 00:00:25 2011 +0900
@@ -0,0 +1,47 @@
+<h2>StoragePool::EditPool</h2>
+<h3><?php echo $pool["name"]; ?></h3>
+<h4>StoragePool Information</h4>
+<?php echo $this->element("storage/poolinfo",array("pool" => $pool)); ?>
+<h4>Volumes</h4>
+<?php echo $this->element("storage/volumeinfotable",array("volumes" => $pool["volumes"])); ?>
+<h4>Add New Volume</h4>
+<form method="post" action="AddVolume">
+<input name="id" type="hidden" value="<?php echo $pool["id"]; ?>"/>
+<table>
+	<tr>
+		<th>Volume Name</th>
+		<th>Capacity (MiB)</th>
+		<th>Allocate (MiB)</th>
+	</tr>
+	<tr>
+		<td><input type="text" name="name"/></td>
+		<td><input type="text" name="capacity"/></td>
+		<td><input type="text" name="allocate"/></td>
+	</tr>
+</table>
+<input type="submit" value="AddVolume"/>
+</form>
+<br/>
+<h4>Delete Volume</h4>
+<form method="post" action="DeleteVolume">
+<input type="hidden" name="pid" value="<?php echo $pool["id"]; ?>"/>
+<table>
+	<tr>
+		<th>Volume Name</th>
+	</tr>
+	<tr>
+		<td>
+			<select name="vname">
+<?php 
+	foreach($pool["volumes"] as $volume){
+		echo "<option value=\"".$volume["name"]."\">".$volume["name"]."</option>";
+	}
+?>
+			</select>
+		</td>
+	</tr>
+</table>
+<?php echo $this->Form->end("DeleteVolume"); ?>
+</form>
+<p><a href="./">Back</a></p>
+