Skip to content

Instantly share code, notes, and snippets.

@brenooandrade
Created December 20, 2020 05:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save brenooandrade/7bc0a1e02372a8fbf6e6dcbb10e5c52c to your computer and use it in GitHub Desktop.
Save brenooandrade/7bc0a1e02372a8fbf6e6dcbb10e5c52c to your computer and use it in GitHub Desktop.
myKnextify API
/* ## MAPEAMENTO DE ROTAS PARA CRUDS DE TABELAS CONFORME NECESSIDADE ## */
//CRUD tabela aluguel
CRUD = require('../routes/CRUD');
CRUD(server, knex, errs, comum, 'aluguel', 'aluguel_id');
//CRUD tabela ator
CRUD = require('../routes/CRUD');
CRUD(server, knex, errs, comum, 'ator', 'ator_id');
/* ## ROTA DE CONSULTA VIA QUERY, ENVIO DE EMAIL DENTRE OUTROS ENDPOINTS POSSÍVEIS DE CRIAÇÃO ## */
//mylib - Lib interna com funções "comuns"
mylib = require('../comum/mylib');
mylib(server, comum);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment