obtener todos los status
This commit is contained in:
+2
-1
@@ -5,7 +5,8 @@
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
"test": "node ./server/config/test.js",
|
||||
"db:install": "node ./server/db/install"
|
||||
"db:install": "node ./server/db/install",
|
||||
"dev": "nodemon ./server/app"
|
||||
},
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
const Status = require('../../db/tablas/Status');
|
||||
|
||||
const get = () => {
|
||||
return Status.findAll().then((res) => {
|
||||
return res;
|
||||
});
|
||||
};
|
||||
|
||||
module.exports = get;
|
||||
@@ -1,7 +1,7 @@
|
||||
const express = require('express');
|
||||
const app = express();
|
||||
const route = '/tipo_cuarto';
|
||||
const get = require('../controller/TipoCuarto/get');
|
||||
const route = '/status';
|
||||
const get = require('../controller/Status/get');
|
||||
|
||||
app.get(`${route}`, (req, res) => {
|
||||
return get()
|
||||
@@ -2,7 +2,7 @@ const express = require('express');
|
||||
const app = express();
|
||||
|
||||
// app.use(require('./'))
|
||||
app.use(require('./TipoCuarto'));
|
||||
app.use(require('./Usuario'));
|
||||
app.use(require('./Status'));
|
||||
// app.use(require('./Usuario'));
|
||||
|
||||
module.exports = app;
|
||||
|
||||
Reference in New Issue
Block a user