Overview
  • Namespace
  • Class

Namespaces

  • rpf
    • api
      • module
    • extension
      • module
    • system
      • module

Classes

  • rpf\api\api
  • rpf\api\apiModule
  • rpf\api\bbRpc
  • rpf\api\module\bbCustomer_getFreeOrdNr
  • rpf\api\module\bbCustomer_readAddress
  • rpf\api\module\bbCustomer_readDiscount
  • rpf\api\module\bbCustomer_readEntry
  • rpf\api\module\bbCustomer_readPayment
  • rpf\api\module\bbCustomer_readTitle
  • rpf\api\module\bbCustomer_saveAdress
  • rpf\api\module\bbCustomer_validateAddress
  • rpf\api\module\bbCustomer_validateEntry
  • rpf\api\module\bbCustomer_validatePayinfo
  • rpf\api\module\bbDomain_readEntry
  • rpf\api\module\bbDomain_readFrontpage
  • rpf\api\module\bbDomain_readHandles
  • rpf\api\module\bbDomain_readPhpini
  • rpf\api\module\bbDomain_readSettings
  • rpf\api\module\bbDomain_readSubdomain
  • rpf\api\module\bbDomain_readWebalizerSettings
  • rpf\api\module\bbDomain_searchEntry
  • rpf\api\module\bbEmail_readAccount
  • rpf\api\module\bbMysql_inuseEntry
  • rpf\api\module\bbMysql_makeBackup
  • rpf\api\module\bbMysql_readEntry
  • rpf\api\module\bbOrder_readAccountAddress
  • rpf\api\module\bbOrder_readAccountEntry
  • rpf\api\module\bbOrder_readDisposition
  • rpf\api\module\bbOrder_readEntry
  • rpf\api\module\bbQuota_readEntry
  • rpf\api\module\customer
  • rpf\api\module\email
  • rpf\api\module\order
  • rpf\api\module\placeholder
  • rpf\api\module\user
  • rpf\extension\extension
  • rpf\extension\extensionModule
  • rpf\extension\invoiceTextExport
  • rpf\extension\mailExport
  • rpf\extension\module\domainExport
  • rpf\extension\module\index
  • rpf\extension\module\mgntRatioExport
  • rpf\system\module
  • rpf\system\module\log
  • rpf\system\module\moduleManager
  • rpf\system\rpf

Exceptions

  • rpf\system\module\exception
 1 <?php
 2 
 3 namespace rpf\api\module;
 4 use rpf\api\apiModule;
 5 
 6 class order extends apiModule
 7 {
 8 
 9     protected $disposition = array();
10 
11     /**
12      * Returns a array with the previous load data, sorted by oeid
13      *
14      * @return array $order['oeid'][$key] = [$value]
15      */
16     public function getOrders()
17     {
18         return $this->orders;
19     }
20 
21     /**
22      * Returns a array with the previous load data
23      *
24      * @return array
25      */
26     public function getData()
27     {
28         return $this->data;
29     }
30 
31 
32     /*public function loadOrdersAdresses()
33     {
34         $result = $this->system->call('bbCustomer::readEntry', ['return_array' => 1, 'return_orders' => 1, 'return_adress' => 1]);
35         foreach ($result as $id => &$row)
36         {
37             $this->data[$row['cusnr']] = &$row;
38         }
39         return $this;
40     }*/
41 
42     /**
43      * @param (array) $param['accounting']
44      * @param bool $runOnce
45      * @return $this
46      */
47     public function loadAll($param = array(), $runOnce = true)
48     {
49 
50         if ($runOnce && !$this->runOnce(__METHOD__)) return $this;
51 
52         if (empty($param)) {
53             $this->data = $this->system->call('bbOrder::readEntry', ['return_array' => 1]); //, 'return_adress' => 1
54         }
55 
56         else if (isset($param['accounting']))
57         {
58             $this->data = $this->system->call('bbOrder::readEntry', ['return_active' => 1, 'return_dispositions' => 1, 'return_account_entrys' => 1, 'return_array' => 1]); //, 'return_adress' => 1
59         }
60         return $this;
61     }
62 
63     public function load($ordNr, $param = array(), $runOnce = true)
64     {
65         if ($runOnce && !$this->runOnce(__METHOD__)) return $this;
66 
67         if (empty($param)) {
68             $this->data[$ordNr] = $this->system->call('bbOrder::readEntry', ['return_active' => 1, 'return_dispositions' => 1, 'return_customer' => 1, 'return_adress' => 1, 'ordnr' => $ordNr]);
69         }
70         return $this;
71     }
72 
73 
74 
75     public function getDisposition($ordNr = false)
76     {
77         if ($ordNr !== false && isset($this->disposition[$ordNr]))
78         {
79             return $this->disposition[$ordNr];
80         }
81         else if (!empty($this->disposition))
82         {
83             return $this->disposition;
84         }
85         else
86         {
87             throw new \Exception('We don\'t have any dispositions', 404);
88         }
89     }
90 
91 
92 
93 
94 
95 
96 }
API documentation generated by ApiGen