Added template content for API resource controllers.
This commit is contained in:
parent
ac7d877411
commit
cf0cbaf75c
1 changed files with 48 additions and 6 deletions
|
@ -11,20 +11,62 @@
|
||||||
* @since v1.2.0
|
* @since v1.2.0
|
||||||
* ---------------------------------------------------------------------------- */
|
* ---------------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
require_once __DIR__ . '/API_V1_Controller.php';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Appointments Controller
|
* Appointments Controller
|
||||||
*
|
*
|
||||||
* @package Controllers
|
* @package Controllers
|
||||||
* @subpackage API
|
* @subpackage API
|
||||||
*/
|
*/
|
||||||
class Appointments extends CI_Controller {
|
class Appointments extends API_V1_Controller {
|
||||||
|
/**
|
||||||
public function get($id = null) {
|
* Class Constructor
|
||||||
echo 'hello ' . $id;
|
*/
|
||||||
|
public function __construct() {
|
||||||
|
parent::__construct();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* GET API Method
|
||||||
|
*
|
||||||
|
* @param int $id Optional (null), the record ID to be returned.
|
||||||
|
*
|
||||||
|
* @return \Engine\Api\V1\Response Returns data response.
|
||||||
|
*/
|
||||||
|
public function get($id = null) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* POST API Method
|
||||||
|
*
|
||||||
|
* @return @return \Engine\Api\V1\Response Returns data response.
|
||||||
|
*/
|
||||||
public function post() {
|
public function post() {
|
||||||
echo 'post';
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* PUT API Method
|
||||||
|
*
|
||||||
|
* @param int $id The record ID to be updated.
|
||||||
|
*
|
||||||
|
* @return @return \Engine\Api\V1\Response Returns data response.
|
||||||
|
*/
|
||||||
|
public function put($id) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* DELETE API Method
|
||||||
|
*
|
||||||
|
* @param int $id The record ID to be deleted.
|
||||||
|
*
|
||||||
|
* @return @return \Engine\Api\V1\Response Returns data response.
|
||||||
|
*/
|
||||||
|
public function delete($id) {
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue