Open Source Billing
This commit is contained in:
31
modules/export/classes/Model/Export.php
Normal file
31
modules/export/classes/Model/Export.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php defined('SYSPATH') or die('No direct access allowed.');
|
||||
|
||||
/**
|
||||
* This class supports OSB exporting by rending the exportable items.
|
||||
*
|
||||
* @package Export
|
||||
* @category Helpers
|
||||
* @author Deon George
|
||||
* @copyright (c) 2009-2013 Open Source Billing
|
||||
* @license http://dev.osbill.net/license.html
|
||||
*/
|
||||
class Model_Export extends ORM_OSB {
|
||||
protected $_serialize_column = array(
|
||||
'map_data',
|
||||
);
|
||||
|
||||
public function list_itemsnoexport() {
|
||||
$result = array();
|
||||
|
||||
$mo = ORM::factory('Module',array('name'=>'product'));
|
||||
$p = ORM::factory('Product')
|
||||
->order_by('id');
|
||||
|
||||
foreach ($p->find_all() as $po)
|
||||
if (! ORM::factory('Export')->where('module_id','=',$mo->id)->where('item_id','=',$po->id)->find()->loaded())
|
||||
$result[$po->id] = $po;
|
||||
|
||||
return $result;
|
||||
}
|
||||
}
|
||||
?>
|
Reference in New Issue
Block a user