Added Invoice/SSL download recording, other misc fixes
This commit is contained in:
@@ -22,6 +22,7 @@ class Model_Service extends ORM_OSB {
|
||||
'invoice_item'=>array('far_key'=>'id'),
|
||||
'invoice'=>array('through'=>'invoice_item'),
|
||||
'service_change'=>array('far_key'=>'id'),
|
||||
'service_memo'=>array('far_key'=>'id'),
|
||||
);
|
||||
protected $_belongs_to = array(
|
||||
'product'=>array(),
|
||||
@@ -292,8 +293,8 @@ class Model_Service extends ORM_OSB {
|
||||
public function list_byplugin($plugin) {
|
||||
return $this
|
||||
->join('product')
|
||||
->on($this->table_name().'.site_id','=','product.site_id') // @todo This should be automatic
|
||||
->on($this->table_name().'.product_id','=','product.id')
|
||||
->on($this->table_name().'.site_id','=','product.site_id') // @todo This should be automatic
|
||||
->on($this->table_name().'.product_id','=','product.id')
|
||||
->where('prod_plugin_file','=',$plugin)
|
||||
->and_where('service.status','=',TRUE)
|
||||
->find_all();
|
||||
|
30
modules/service/classes/Model/Service/Memo.php
Normal file
30
modules/service/classes/Model/Service/Memo.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php defined('SYSPATH') or die('No direct access allowed.');
|
||||
|
||||
/**
|
||||
* This class supports Service Memos.
|
||||
*
|
||||
* @package Service
|
||||
* @category Models
|
||||
* @author Deon George
|
||||
* @copyright (c) 2009-2013 Open Source Billing
|
||||
* @license http://dev.osbill.net/license.html
|
||||
*/
|
||||
class Model_Service_Memo extends ORM_OSB {
|
||||
// Relationships
|
||||
protected $_belongs_to = array(
|
||||
'service'=>array(),
|
||||
);
|
||||
protected $_has_one = array(
|
||||
'account'=>array('foreign_key'=>'id'),
|
||||
);
|
||||
|
||||
/**
|
||||
* Filters used to format the display of values into friendlier values
|
||||
*/
|
||||
protected $_display_filters = array(
|
||||
'date_orig'=>array(
|
||||
array('Config::datetime',array(':value')),
|
||||
),
|
||||
);
|
||||
}
|
||||
?>
|
Reference in New Issue
Block a user