summaryrefslogblamecommitdiffstats
path: root/application/modules/user/views/scripts/preboot/index.phtml
blob: 620fb4faa72e96fed9da2171446dda9a7a2bc84b (plain) (tree)
1
2
3
4
5
6
7
8
9

                                                                 
                                

                                        
                                                                       
                                                                                                                                                 

                                                                                  

                                                                
                                                                      
                                                                                                                                        
                                                                                  
              









                                                                  
                                                          
                             



                                                              

                                                        






































                                                                                                                                


                                                                                                   


                                                                                                               




                                                                                                                         
                      

      
                                






                                                               
                                                               



                   
<h1>Preboot</h1>
<?php if($this->notification != ''){echo $this->notification;} ?>
<?php echo $this->searchform; ?>

<?php if(Pbs_Acl::checkRight('pru')): ?>
<?php echo $this->formButton('checkupdate', 'Check for Updates', array(
							'onclick' => 'self.location="/user/preboot/index/checkupdate/true/page/'.$this->page.'"',
							'class' => 'updatebutton',
							))?>
<?php endif;?>							
<?php if(Pbs_Acl::checkRight('prc')): ?>
<?php echo $this->formButton('createpreboot', 'Create PreBoot', array(
							'onclick' => 'self.location="/user/preboot/createpreboot/page/'.$this->page.'"',
							'class' => 'addbutton'))?>
<?php endif;?>
<div class='searchvars'>
	<div class='head'>Available searchfilter:</div>
	<div class='code'>prebootID</div>
	<div class='code'>title</div>
	<div class='code'>path_preboot</div>
</div>

<div class='listelement'>
	<?php if(count($this->prebootlist)==0)
  		echo "There are no Preboot entries to display." ?>
  <?php foreach ($this->prebootlist as $k => $preboot): ?>
	<div class='element'>
  		<div class='number'>
			<div class='smallnumber'>Preboot</div>
  			<?php echo $k+1 ?>
  		</div>
  		<div class='content'>  			
	  		<div class='actions'>
	  			<?php if(Pbs_Acl::checkRight('pru')): ?>
		  			<?php if($this->update[$preboot->getID()]==true): ?><a href="<?php echo $this->url(
						array(
							'module'	=> 'user',
							'controller' => 'preboot',
							'action'     => 'updatepreboot',
							'prebootID'   =>  $preboot->getID(),
							'page'		=> $this->page
						),
						'default',
						true, false) ?>"><img src='/media/img/update.png' alt='Updates available' /></a>
					<?php else: ?>
						<a><img src='/media/img/update_grey.png' alt='No updates available' /></a>	
					<?php endif; ?>	
				<?php endif; ?>
				<?php if(Pbs_Acl::checkRight('pre') || Pbs_Acl::checkRight('prem')): ?>
			  		<a href="<?php echo $this->url(
						array(
							'module'	=> 'user',
							'controller' => 'preboot',
							'action'     => 'editpreboot',
							'prebootID'   =>  $preboot->getID(),
							'page'		=> $this->page
						),
						'default',
						true, false) ?>"><img src='/media/img/edit.png' alt='Edit Preboot' /></a>
				<?php endif; ?>
				<?php if(Pbs_Acl::checkRight('prd')): ?>
					<a href="<?php echo $this->url(
						array(
							'module'	=> 'user',
							'controller' => 'preboot',
							'action'     => 'deletepreboot',
							'prebootID'   =>  $preboot->getID(),
							'page'		=> $this->page
						),
						'default',
						true) ?>"><img src='/media/img/delete.png' alt='Delete Preboot'/></a>
				<?php endif; ?>
	  		</div>  
	  		<div class='title'><?php echo $this->escape($preboot->getTitle()); ?></div>
	  		<div class='details'>
		  		<label>PrebootID</label>
		  			<div class='item'><?php echo $this->escape($preboot->getID()); ?></div>
	  			<label>Prebootpath</label>
	  				<div class='item'><?php echo $this->escape($preboot->getPath_preboot()); ?></div>
	  		</div>
  		</div>
  		<div class='clear'></div>
	</div>
  <?php endforeach; ?>
</div>

<?php echo $this->pagination; ?>

<script>
$(document).ready(function(){
	if($('.element').find('.dispnone').length >= 1){
		$(this).find('.title').css('cursor','pointer');
		
		$('.title').click(function(){
			$(this).siblings('.dispnone').toggle();
		});
	}
});
</script>