emi420 / hmap

The goal of this project is to create an easy-to-use humanitarian map for work before, during and disaster events.
GNU General Public License v3.0
0 stars 1 forks source link

API: Implement endpoint to list all accessibles layers. #6

Closed pedrodef closed 2 years ago

pedrodef commented 2 years ago
  1. API definitions
  2. Serializer, view and routher.
  3. Basic tests.
pedrodef commented 2 years ago

Traer todas las layers visibles para el usuario.

GET /layers/

┌──── │ │ [ │ { │ "id": 1, │ "name": "layer name", │ "description": "layer description", │ "is_public": true, │ }, │ ] └────

Las siguientes tienen checkeo de permisos al objeto que se intenta leer, cada una trae un archivo asociado a la layer.

Traer el geojson asociado a la layer: GET /layers//geojson/

Traer el archivo de estilo asociado a la layer: GET /layers//styles/

Traer el archivo fuente asociado a la layer (con el que se creó): GET /layers//source-file/