Created
January 21, 2013 03:58
-
-
Save Fi1osof/4583503 to your computer and use it in GitHub Desktop.
Свич процессоров в процессоре
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
<?php | |
class YleyCompaniesUsersGetListProcessor extends modProcessor{ | |
public static function getInstance(modX &$modx,$className,$properties = array()) { | |
switch($properties['type']){ | |
case 'company__': | |
$className = require_once dirname(__FILE__).'/users/getlist.class.php'; | |
break; | |
default: | |
if($properties['id'] == 'root'){ | |
$className = 'YleyCompaniesGetListProcessor'; | |
} | |
} | |
return new $className($modx, $properties); | |
} | |
public function process() { | |
return $this->failure('Неверные данные'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment