| Conditions | 3 | 
| Paths | 4 | 
| Total Lines | 15 | 
| Code Lines | 9 | 
| Lines | 0 | 
| Ratio | 0 % | 
| Changes | 1 | ||
| Bugs | 0 | Features | 0 | 
| 1 | <?php | ||
| 46 | public function OrderPaginatedList(HTTPRequest $request = null) | ||
| 47 |     { | ||
| 48 |         if (!$request instanceof HTTPRequest) { | ||
| 49 | $request = $this->getRequest(); | ||
| 50 | } | ||
| 51 | $orders = $this->data()->getOrderList(); | ||
| 52 |         $start = ($request->getVar('start')) ? (int)$request->getVar('start') : 0; | ||
| 53 | $records = PaginatedList::create($orders, $request); | ||
| 54 | $records->setPageStart($start); | ||
| 55 | $records->setPageLength($this->data()->PerPage); | ||
| 56 | |||
| 57 | // allow $records to be updated via extension | ||
| 58 |         $this->extend('updateOrderPaginatedList', $records); | ||
| 59 | |||
| 60 | return $records; | ||
| 61 | } | ||
| 63 |