diff options
Diffstat (limited to 'application/views/scripts/pool')
| -rw-r--r-- | application/views/scripts/pool/createpool.phtml | 3 | ||||
| -rw-r--r-- | application/views/scripts/pool/editpool.phtml | 5 | ||||
| -rw-r--r-- | application/views/scripts/pool/index.phtml | 56 | ||||
| -rw-r--r-- | application/views/scripts/pool/linkclient.phtml | 3 | ||||
| -rw-r--r-- | application/views/scripts/pool/unlinkclient.phtml | 1 |
5 files changed, 64 insertions, 4 deletions
diff --git a/application/views/scripts/pool/createpool.phtml b/application/views/scripts/pool/createpool.phtml index 3d7f8ca..305b36e 100644 --- a/application/views/scripts/pool/createpool.phtml +++ b/application/views/scripts/pool/createpool.phtml @@ -1 +1,2 @@ -<br /><br /><center>View script for controller <b>Pool</b> and script/action name <b>createpool</b></center>
\ No newline at end of file +<?php +echo $this->addpool; diff --git a/application/views/scripts/pool/editpool.phtml b/application/views/scripts/pool/editpool.phtml index c70464e..359a5f9 100644 --- a/application/views/scripts/pool/editpool.phtml +++ b/application/views/scripts/pool/editpool.phtml @@ -1 +1,4 @@ -<br /><br /><center>View script for controller <b>Pool</b> and script/action name <b>editpool</b></center>
\ No newline at end of file +<h1>Edit Pool</h1> +<?php + +echo $this->editpoolform; diff --git a/application/views/scripts/pool/index.phtml b/application/views/scripts/pool/index.phtml index 989cf41..25f1528 100644 --- a/application/views/scripts/pool/index.phtml +++ b/application/views/scripts/pool/index.phtml @@ -1,5 +1,13 @@ <h1>Pools</h1> +<a href="<?php echo $this->url( + array( + 'controller' => 'pool', + 'action' => 'createpool' + ), + 'default', + true) ?>">create pool</a> + <?php if ($this->pools): ?> <!-- A table of filters. --> @@ -19,12 +27,56 @@ <td><a href="<?php echo $this->url( array( 'controller' => 'pool', - 'action' => 'removepool', + 'action' => 'editpool', 'poolID' => $pool->getID() ), 'default', - true) ?>">remove pool</a></td> + true) ?>">edit pool</a></td> + <td><a href="<?php echo $this->url( + array( + 'controller' => 'pool', + 'action' => 'deletepool', + 'poolID' => $pool->getID() + ), + 'default', + true) ?>">delete pool</a></td> + <td><a href="<?php echo $this->url( + array( + 'controller' => 'pool', + 'action' => 'linkclient', + 'poolID' => $pool->getID() + ), + 'default', + true) ?>">link client</a></td> + </tr> + <tr> + <td> + </td> + <td colspan=6><table border=1><tr><th>clientID</th><th>mac</th><th>hardwarehash</th></th> + <?php + $poolentriesMapper = new Application_Model_PoolEntriesMapper(); + $clients = $poolentriesMapper->findBy('poolID',$pool->getID()); + foreach ($clients as $client): ?> + <tr> + <td><?php echo $client['clientID'];?></td> + <?php + $cli = new Application_Model_Client(); + $clientMapper = new Application_Model_ClientMapper(); + $clientMapper->find($client['clientID'],$cli); + ?> + <td><?php echo ($cli->macAdress); ?></td> + <td><?php echo ($cli->hardwarehash); ?></td> + <td><a href="<?php echo $this->url( + array( + 'controller' => 'pool', + 'action' => 'unlinkclient', + 'poolentriesID' => $client['poolentriesID'] + ), + 'default', + true) ?>">unlink client</a></td> </tr> + <?php endforeach ?> + </table> <?php endforeach ?> </table> diff --git a/application/views/scripts/pool/linkclient.phtml b/application/views/scripts/pool/linkclient.phtml new file mode 100644 index 0000000..cbd2dd4 --- /dev/null +++ b/application/views/scripts/pool/linkclient.phtml @@ -0,0 +1,3 @@ +<h1>Link Clients</h1> +<?php +echo $this->poolclient; diff --git a/application/views/scripts/pool/unlinkclient.phtml b/application/views/scripts/pool/unlinkclient.phtml new file mode 100644 index 0000000..35aa9c5 --- /dev/null +++ b/application/views/scripts/pool/unlinkclient.phtml @@ -0,0 +1 @@ +<br /><br /><center>View script for controller <b>Pool</b> and script/action name <b>unlinkclient</b></center>
\ No newline at end of file |
