public function __construct($data = array(), $status = 200, $headers = array())
 {
     parent::__construct(['rows' => $data], $status, $headers);
 }
Пример #2
0
 /**
  * @param array|stdClass $data Note: $data will pass to response output without any checks
  * @param type $recordsFiltered
  * @param type $recordsTotal
  */
 public function __construct($data = array(), $recordsFiltered = NULL, $recordsTotal = NULL)
 {
     parent::__construct($data, self::DATATABLES);
     if ($recordsFiltered !== NULL && $recordsTotal !== NULL && intval($recordsFiltered) && intval($recordsTotal)) {
         $this->recordsFiltered = $recordsFiltered;
         $this->recordsTotal = $recordsTotal;
     }
 }
Пример #3
0
 /**  */
 public function __construct()
 {
     parent::__construct();
     $this->responseObject->status = 'success';
 }
 public function __construct($data = array(), $status = 200, $headers = array())
 {
     parent::__construct(['data' => $data, 'success' => true], $status, $headers);
 }