Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adding the views for modules and relating the modules to routes so yo…
…u will eventualy show models based on the page you are on
- Loading branch information
1 parent
85f94b7
commit f50aef8
Showing
6 changed files
with
228 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
<?php | ||
/** | ||
* Management Config admin edit post. | ||
* | ||
* this page is for admin to manage the setup of the site | ||
* | ||
* Copyright (c) 2009 Carl Sutton ( dogmatic69 ) | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright (c) 2009 Carl Sutton ( dogmatic69 ) | ||
* @link http://www.dogmatic.co.za | ||
* @package management | ||
* @subpackage management.views.configs.admin_edit | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
*/ | ||
|
||
echo $this->Core->adminOtherHead( $this ); | ||
echo $this->Form->create( 'Module' ); | ||
echo $this->Form->input( 'name' ); | ||
echo $this->Form->input( 'module' ); | ||
echo $this->Form->input( 'position_id' ); | ||
echo $this->Form->input( 'group_id' ); | ||
echo $this->Form->input( 'active' ); | ||
echo $this->Form->input( 'show_heading' ); | ||
echo $this->Form->input( 'core' ); | ||
echo $this->Form->input( 'author' ); | ||
echo $this->Form->input( 'url' ); | ||
echo $this->Form->input( 'update_url' ); | ||
echo $this->Form->input( 'licence' ); | ||
|
||
echo $this->Form->input( 'content', array('class' => 'title') ); | ||
echo $this->Form->input( 'config', array('class' => 'title') ); | ||
echo $this->Form->end( 'Save Module' ); | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<?php | ||
/** | ||
* Management Config admin edit post. | ||
* | ||
* this page is for admin to manage the setup of the site | ||
* | ||
* Copyright (c) 2009 Carl Sutton ( dogmatic69 ) | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright (c) 2009 Carl Sutton ( dogmatic69 ) | ||
* @link http://www.dogmatic.co.za | ||
* @package management | ||
* @subpackage management.views.configs.admin_edit | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
*/ | ||
|
||
echo $this->Core->adminOtherHead( $this ); | ||
echo $this->Form->create( 'Theme' ); | ||
echo $this->Form->input( 'id' ); | ||
echo $this->Form->input( 'name' ); | ||
echo $this->Form->input( 'author' ); | ||
echo $this->Form->input( 'url' ); | ||
echo $this->Form->input( 'update_url' ); | ||
echo $this->Form->input( 'licence' ); | ||
echo $this->Form->input( 'active' ); | ||
echo $this->Form->input( 'core' ); | ||
echo $this->Core->wysiwyg( 'Theme.description' ); | ||
echo $this->Form->end( 'Save Theme' ); | ||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,116 @@ | ||
<?php | ||
/** | ||
* Comment Template. | ||
* | ||
* @todo -c Implement .this needs to be sorted out. | ||
* | ||
* Copyright (c) 2009 Carl Sutton ( dogmatic69 ) | ||
* | ||
* Licensed under The MIT License | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @filesource | ||
* @copyright Copyright (c) 2009 Carl Sutton ( dogmatic69 ) | ||
* @link http://www.dogmatic.co.za | ||
* @package sort | ||
* @subpackage sort.comments | ||
* @license http://www.opensource.org/licenses/mit-license.php The MIT License | ||
* @since 0.5a | ||
*/ | ||
|
||
echo $this->Form->create( 'Module', array( 'url' => array( 'controller' => 'modules', 'action' => 'mass', 'admin' => 'true' ) ) ); | ||
|
||
$massActions = $this->Core->massActionButtons( | ||
array( | ||
'add', | ||
'edit', | ||
'copy', | ||
'delete' | ||
) | ||
); | ||
echo $this->Core->adminIndexHead( $this, $paginator, null, $massActions ); | ||
?> | ||
<div class="table"> | ||
<?php echo $this->Core->adminTableHeadImages(); ?> | ||
<?php ?> | ||
<table class="listing" cellpadding="0" cellspacing="0"> | ||
<?php | ||
echo $this->Core->adminTableHeader( | ||
array( | ||
$this->Form->checkbox( 'all' ) => array( | ||
'class' => 'first', | ||
'style' => 'width:25px;' | ||
), | ||
$this->Paginator->sort( 'name' ), | ||
$this->Paginator->sort( 'author' ), | ||
$this->Paginator->sort( 'licence' ), | ||
$this->Paginator->sort( 'Position', 'Position.Name' ) => array( | ||
'style' => 'width:75px;' | ||
), | ||
$this->Paginator->sort( 'Group', 'Group.Name' ) => array( | ||
'style' => 'width:75px;' | ||
), | ||
$this->Paginator->sort( 'Locked', true ) => array( | ||
'style' => 'width:50px;' | ||
), | ||
$this->Paginator->sort( 'Order', true ) => array( | ||
'style' => 'width:50px;' | ||
), | ||
$this->Paginator->sort( 'core', true ) => array( | ||
'style' => 'width:50px;' | ||
), | ||
$this->Paginator->sort( 'active', true ) => array( | ||
'style' => 'width:50px;' | ||
) | ||
) | ||
); | ||
|
||
$i = 0; | ||
foreach ( $modules as $module ) | ||
{ | ||
?> | ||
<tr class="<?php echo $this->Core->rowClass( $i ); ?>"> | ||
<td><?php echo $this->Form->checkbox( $module['Module']['id'] ); ?> </td> | ||
<td> | ||
<?php echo $this->Html->link( Inflector::humanize($module['Module']['name']), array('action' => 'edit', $module['Module']['id'])); ?> | ||
</td> | ||
<td> | ||
<?php echo $module['Position']['name']; ?> | ||
</td> | ||
<td> | ||
<?php | ||
if (!empty($module['Module']['url'])) { | ||
echo $this->Html->link($module['Module']['author'], $module['Module']['url'], array('target' => '_blank')); | ||
} | ||
else | ||
{ | ||
echo $module['Module']['author']; | ||
} | ||
?> | ||
</td> | ||
<td> | ||
<?php echo $module['Module']['licence']; ?> | ||
</td> | ||
<td> | ||
<?php echo $module['Group']['name']; ?> | ||
</td> | ||
<td> | ||
<?php echo $this->Status->locked($module['Module']['locked']); ?> | ||
</td> | ||
<td> | ||
<?php echo $this->Core->ordering($module['Module']['order']); ?> | ||
</td> | ||
<td> | ||
<?php echo $this->Status->status( $theme['Theme']['core'] ); ?> | ||
</td> | ||
<td> | ||
<?php echo $this->Status->status( $theme['Theme']['active'] ); ?> | ||
</td> | ||
</tr> | ||
<?php | ||
} | ||
?> | ||
</table> | ||
<?php echo $this->Form->end(); ?> | ||
</div> | ||
<?php echo $this->element( 'pagination/navigation' ); ?> |