diff --git a/capitulo_5/capitulo_5.8/controllers/StormtropperController_class.js b/capitulo_5/capitulo_5.8/controllers/StormtropperController_class.js new file mode 100644 index 0000000..4488f3d --- /dev/null +++ b/capitulo_5/capitulo_5.8/controllers/StormtropperController_class.js @@ -0,0 +1,19 @@ +class StormtrooperController { + getAll(request, response, next) { + response.send('get all stormtroopers'); + }; + getById(request, response, next) { + response.send('get a specific stormtrooper by id'); + }; + create(request, response, next) { + response.send('create a new stormtroopers'); + }; + update(request, response, next) { + response.send('update a stormtrooper'); + }; + remove(request, response, next) { + response.send('remove a stormtrooper'); + }; +} + +module.exports = new StormtrooperController(); diff --git a/capitulo_5/capitulo_5.8/controllers/StormtropperController_json.js b/capitulo_5/capitulo_5.8/controllers/StormtropperController_json.js new file mode 100644 index 0000000..4ee7e93 --- /dev/null +++ b/capitulo_5/capitulo_5.8/controllers/StormtropperController_json.js @@ -0,0 +1,21 @@ +'use strict'; + +let StormtrooperController = { + getAll: function(request, response, next) { + response.send('get all stormtroopers'); + }, + getById: function(request, response, next) { + response.send('get a specific stormtrooper by id'); + }, + create: function(request, response, next) { + response.send('create a new stormtroopers'); + }, + update: function(request, response, next) { + response.send('update a stormtrooper'); + }, + remove: function(request, response, next) { + response.send('remove a stormtrooper'); + } +}; + +module.exports = StormtrooperController;