|
|
|
|
@ -12,28 +12,7 @@ class PostfixAdminUser extends Shell {
|
|
|
|
|
var $tasks = array('Add', 'Update', 'Delete', 'Password', 'View');
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Starts up the the Shell
|
|
|
|
|
* allows for checking and configuring prior to command or main execution
|
|
|
|
|
* can be overriden in subclasses
|
|
|
|
|
*
|
|
|
|
|
* @access public
|
|
|
|
|
*/
|
|
|
|
|
function startup() {
|
|
|
|
|
$this->_welcome();
|
|
|
|
|
$CONF = Config::read('all');
|
|
|
|
|
}
|
|
|
|
|
/**
|
|
|
|
|
* Displays a header for the shell
|
|
|
|
|
*
|
|
|
|
|
* @access protected
|
|
|
|
|
*/
|
|
|
|
|
function _welcome() {
|
|
|
|
|
$this->out("\nWelcome to Postfixadmin-CLI v" . $this->Dispatch->version);
|
|
|
|
|
$this->out("---------------------------------------------------------------");
|
|
|
|
|
$this->out('Path: '. PATH);
|
|
|
|
|
$this->hr();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Show help for this shell.
|
|
|
|
|
@ -157,7 +136,7 @@ class AddTask extends Shell {
|
|
|
|
|
$handler = new UserHandler($address);
|
|
|
|
|
$return = $handler->add($pw, $name, $quota, true, true );
|
|
|
|
|
|
|
|
|
|
if( ! $return) {
|
|
|
|
|
if( $return == false ) {
|
|
|
|
|
$this->err(join("\n", $handler->errormsg));
|
|
|
|
|
} else {
|
|
|
|
|
$this->out("");
|
|
|
|
|
|