| Total Complexity | 2 |
| Total Lines | 43 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 12 | class Cash extends Client |
||
| 13 | { |
||
| 14 | /** |
||
| 15 | * @var string |
||
| 16 | */ |
||
| 17 | protected $namespace = __CLASS__; |
||
| 18 | |||
| 19 | /** |
||
| 20 | * Get a list of checkouts |
||
| 21 | * |
||
| 22 | * @link https://api.u-on.ru/{key}/cash.{_format} |
||
| 23 | * |
||
| 24 | * @param array $parameters List of parameters ['id', 'name', 'name_en'] |
||
| 25 | * |
||
| 26 | * @return null|object|\Uon\Interfaces\ClientInterface |
||
| 27 | */ |
||
| 28 | public function get(array $parameters = []) |
||
| 29 | { |
||
| 30 | // Set HTTP params |
||
| 31 | $this->type = 'get'; |
||
| 32 | $this->endpoint = 'cash'; |
||
| 33 | $this->params = $parameters; |
||
| 34 | |||
| 35 | return $this->done(); |
||
| 36 | } |
||
| 37 | |||
| 38 | /** |
||
| 39 | * Add new cashbox |
||
| 40 | * |
||
| 41 | * @link https://api.u-on.ru/{key}/cash/create.{_format} |
||
| 42 | * |
||
| 43 | * @param array $parameters List of parameters ['name'] |
||
| 44 | * |
||
| 45 | * @return null|object|\Uon\Interfaces\ClientInterface |
||
| 46 | */ |
||
| 47 | public function create(array $parameters) |
||
| 55 | } |
||
| 56 | } |
||
| 57 |