<commit_before><?php
/**
 * @version     $Id$
 * @category	Nooku
 * @package     Nooku_Server
 * @subpackage  Modules
 * @copyright   Copyright (C) 2011 Timble CVBA and Contributors. (http://www.timble.net).
 * @license     GNU GPLv3 <http://www.gnu.org/licenses/gpl.html>
 * @link        http://www.nooku.org
 */

/**
 * Module HTML View Class
 *   
 * @author    	<NAME> <http://nooku.assembla.com/profile/stiandidriksen>
 * @category    Nooku
 * @package     Nooku_Server
 * @subpackage  Modules
 */

class ComModulesViewModuleHtml extends ComDefaultViewHtml
{
	public function display()
	{
		if($this->getLayout() == 'form') {
			$this->positions = $this->getModel()->getPositions();
		} 
		
		if($this->getLayout() == 'list') 
		{
			$this->getToolbar()
			    ->reset()
				->append('next')
				->append('cancel');

			//The model getModules method is different from getList in that its domain is the filesystem not the database
			$this->modules = $this->getModel()->getModules();
		}
		
		return parent::display();
	}
}<commit_msg>re #116 moving getPositions to listbox helper<commit_after><?php
/**
 * @version     $Id$
 * @category	Nooku
 * @package     Nooku_Server
 * @subpackage  Modules
 * @copyright   Copyright (C) 2011 Timble CVBA and Contributors. (http://www.timble.net).
 * @license     GNU GPLv3 <http://www.gnu.org/licenses/gpl.html>
 * @link        http://www.nooku.org
 */

/**
 * Module HTML View Class
 *   
 * @author    	<NAME> <http://nooku.assembla.com/profile/stiandidriksen>
 * @category    Nooku
 * @package     Nooku_Server
 * @subpackage  Modules
 */

class ComModulesViewModuleHtml extends ComDefaultViewHtml
{
	public function display()
	{
		if($this->getLayout() == 'list') 
		{
			$this->getToolbar()
			    ->reset()
				->append('next')
				->append('cancel');

			//The model getModules method is different from getList in that its domain is the filesystem not the database
			$this->modules = $this->getModel()->getModules();
		}
		
		return parent::display();
	}
}
{'fraction_non_alphanumeric': 0.15338645418326693, 'fraction_numerical': 0.006474103585657371, 'mean_word_length': 3.1508264462809916, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 29, 'https://': 0, 'lorem ipsum': 0, 'www.': 6, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '531497', 'n_tokens_mistral': 728, 'n_tokens_neox': 662, 'n_words': 154}