def api_getAll(self): self.setCordsHeaders() usuarios = Usuario.all() self.context['data'] = usuarios
def api_list(self): self.response.headers['Access-Control-Allow-Origin'] = '*' self.response.headers['Access-Control-Allow-Methods'] = 'POST, GET, PUT, DELETE, OPTIONS' usuarios = Usuario.all() self.context['data'] = usuarios