Exemplo n.º 1
0
 
     case 'issued':
       require_once('Models/BookIssue.php');
       $S = new BookIssue();
       echo json_encode($S->issued());
       break;*/
 // Books related api
 case 'add':
     require_once 'Models/Books.php';
     $S = new Books();
     echo json_encode($S->add($D));
     break;
 case 'remove':
     require_once 'Models/Books.php';
     $S = new Books();
     echo json_encode($S->remove($D['bookid']));
     break;
 case 'update':
     require_once 'Models/Books.php';
     $S = new Books();
     echo json_encode($S->update($D['id'], $D));
     break;
     // User related api
     /*case 'info':
       require_once('Models/User.php');
       $S = new User();
       echo json_encode($S->info());
       break;*/
 // User related api
 /*case 'info':
   require_once('Models/User.php');