Fix password reset and other minor items
This commit is contained in:
parent
951845f6c6
commit
0efd99f194
@ -46,7 +46,7 @@ class Auth_OSB extends Auth_ORM {
|
|||||||
$mo = ORM::factory('Module',array('name'=>Request::current()->controller()));
|
$mo = ORM::factory('Module',array('name'=>Request::current()->controller()));
|
||||||
$mmo = ORM::factory('Module_Method',array(
|
$mmo = ORM::factory('Module_Method',array(
|
||||||
'module_id'=>$mo->id,
|
'module_id'=>$mo->id,
|
||||||
'name'=>Request::current()->directory() ? sprintf('%s_%s',Request::current()->directory(),Request::current()->action()) : Request::current()->action()
|
'name'=>strtolower(Request::current()->directory() ? sprintf('%s:%s',Request::current()->directory(),Request::current()->action()) : Request::current()->action())
|
||||||
));
|
));
|
||||||
|
|
||||||
// Ignore the token if this is not the right method.
|
// Ignore the token if this is not the right method.
|
||||||
@ -81,7 +81,7 @@ class Auth_OSB extends Auth_ORM {
|
|||||||
Session::instance()->set('token',$token);
|
Session::instance()->set('token',$token);
|
||||||
|
|
||||||
$uo = ORM::factory('Account',$mmto->account_id);
|
$uo = ORM::factory('Account',$mmto->account_id);
|
||||||
$uo->log(sprintf('Token %s used for method %s [%s]',$mmto->token,$mmto->module_method->name(),Request::current()->param('id')));
|
$uo->log(sprintf('Token %s used for method %s [%s]',$mmto->token,$mmto->module_method->id,Request::current()->param('id')));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
41
modules/domain/classes/Controller/Reseller/Service/Host.php
Normal file
41
modules/domain/classes/Controller/Reseller/Service/Host.php
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
<?php defined('SYSPATH') or die('No direct access allowed.');
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class provides Reseller Host Service functions
|
||||||
|
*
|
||||||
|
* @package Host
|
||||||
|
* @category Controllers/Reseller
|
||||||
|
* @author Deon George
|
||||||
|
* @copyright (c) 2009-2013 Open Source Billing
|
||||||
|
* @license http://dev.osbill.net/license.html
|
||||||
|
*/
|
||||||
|
class Controller_Reseller_Service_Host extends Controller_Service {
|
||||||
|
protected $secure_actions = array(
|
||||||
|
'list'=>TRUE,
|
||||||
|
);
|
||||||
|
|
||||||
|
public function action_list() {
|
||||||
|
Block::factory()
|
||||||
|
->title('Hosting Services')
|
||||||
|
->title_icon('icon-th-list')
|
||||||
|
->body(Table::factory()
|
||||||
|
->jssort('adsl')
|
||||||
|
->data($this->filter(ORM::factory('Service')->list_byplugin('HOST'),$this->ao->RTM->customers($this->ao->RTM),'account_id','name()'))
|
||||||
|
->columns(array(
|
||||||
|
'id'=>'ID',
|
||||||
|
'name()'=>'Service',
|
||||||
|
'plugin()->display("host_expire")'=>'Expire',
|
||||||
|
'recur_schedule'=>'Billing',
|
||||||
|
'price(TRUE,TRUE)'=>'Price',
|
||||||
|
'account->accnum()'=>'Cust ID',
|
||||||
|
'account->name()'=>'Customer',
|
||||||
|
'date_next_invoice'=>'Next Invoice',
|
||||||
|
'due(TRUE)'=>'Due Invoices',
|
||||||
|
))
|
||||||
|
->prepend(array(
|
||||||
|
'id'=>array('url'=>URL::link('user','service/view/')),
|
||||||
|
))
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
?>
|
@ -611,7 +611,7 @@ class Model_Invoice extends ORM_OSB implements Cartable {
|
|||||||
$result = array();
|
$result = array();
|
||||||
|
|
||||||
foreach ($this->_list_due() as $io)
|
foreach ($this->_list_due() as $io)
|
||||||
if ($io->due_date > time())
|
if (is_null($time) OR $io->due_date > time())
|
||||||
if (is_null($time))
|
if (is_null($time))
|
||||||
array_push($result,$io);
|
array_push($result,$io);
|
||||||
elseif ($io->due_date <= $time)
|
elseif ($io->due_date <= $time)
|
||||||
|
Reference in New Issue
Block a user