Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

routes.php 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?php
  2. use App\Http\DBO\CamotionPermissions;
  3. use Luticate\Auth\Business\LuticateBusiness;
  4. use Luticate\Doc\Business\LuDocBusiness;
  5. use Luticate\Utils\LuRoute;
  6. $route = LuRoute::getInstance();
  7. $int = LuRoute::REG_INT;
  8. $host_id = "{host_id:$int}";
  9. $camera_id = "{camera_id:$int}";
  10. $sensor_id = "{sensor_id:$int}";
  11. LuticateBusiness::setupAuth();
  12. LuticateBusiness::setupRoutes();
  13. LuDocBusiness::setupRoutes("/camotion");
  14. $route->get("/hosts", "Hosts", "getAll", CamotionPermissions::HOST_GET);
  15. $route->get("/hosts/$host_id", "Hosts", "get", CamotionPermissions::HOST_GET);
  16. $route->post("/hosts/add", "Hosts", "add", array(CamotionPermissions::HOST_GET, CamotionPermissions::HOST_ADD));
  17. $route->post("/hosts/$host_id/edit", "Hosts", "edit", array(CamotionPermissions::HOST_GET, CamotionPermissions::HOST_EDIT));
  18. $route->post("/hosts/$host_id/del", "Hosts", "del", array(CamotionPermissions::HOST_GET, CamotionPermissions::HOST_DEL));
  19. $route->get("/cameras/types", "Cameras", "getAllTypes", array(CamotionPermissions::CAMERA_GET, CamotionPermissions::CAMERA_ADD));
  20. $route->get("/cameras", "Cameras", "getAll", CamotionPermissions::CAMERA_GET);
  21. $route->get("/cameras/$camera_id", "Cameras", "get", CamotionPermissions::CAMERA_GET);
  22. $route->post("/cameras/add", "Cameras", "add", array(CamotionPermissions::CAMERA_GET, CamotionPermissions::CAMERA_ADD));
  23. $route->post("/cameras/$camera_id/edit", "Cameras", "edit", array(CamotionPermissions::CAMERA_GET, CamotionPermissions::CAMERA_EDIT));
  24. $route->post("/cameras/$camera_id/del", "Cameras", "del", array(CamotionPermissions::CAMERA_GET, CamotionPermissions::CAMERA_DEL));
  25. $route->get("/sensors/types", "Sensors", "getAllTypes", array(CamotionPermissions::SENSOR_GET, CamotionPermissions::SENSOR_ADD));
  26. $route->get("/sensors", "Sensors", "getAll", CamotionPermissions::SENSOR_GET);
  27. $route->get("/sensors/$sensor_id", "Sensors", "get", CamotionPermissions::SENSOR_GET);
  28. $route->post("/sensors/add", "Sensors", "add", array(CamotionPermissions::SENSOR_GET, CamotionPermissions::SENSOR_ADD));
  29. $route->post("/sensors/$sensor_id/edit", "Sensors", "edit", array(CamotionPermissions::SENSOR_GET, CamotionPermissions::SENSOR_EDIT));
  30. $route->post("/sensors/$sensor_id/del", "Sensors", "del", array(CamotionPermissions::SENSOR_GET, CamotionPermissions::SENSOR_DEL));
  31. //sleep(1);