change file names to CamelCase

This commit is contained in:
Bilal Catic
2019-05-16 19:40:26 +02:00
parent 616eddbb19
commit ab681e5eeb
3 changed files with 19 additions and 19 deletions

View File

@@ -1,19 +1,19 @@
const db = require('../models/index');
const realEstateTypes = [
{ ime: "Kuća", id: "kuca" },
{ ime: "Stan", id: "stan" },
{ ime: "Kuća", id: "kuca" },
{ ime: "Stan", id: "stan" },
{ ime: "Vikendica", id: "vikendica" }
];
const getRealEstateTypes = (req,res) => {
const nextStep = req.query.nextStep;
res.render('real_estate_type', {
nextStep,
realEstateTypes: realEstateTypes
const nextStep = req.query.nextStep;
res.render('realEstateType', {
nextStep,
realEstateTypes: realEstateTypes
});
}
};
const postRealEstateTypes = (req, res) => {
let nextStep = req.query.nextStep;
@@ -21,14 +21,13 @@ const postRealEstateTypes = (req, res) => {
realEstateType: req.body.realestatetype
}).then( (result) => {
nextStep = nextStep || `/grad/${result.uniqueId}`;
res.redirect(nextStep);
res.redirect(nextStep);
}).catch( (e) => {
res.send(e);
});
}
});
};
module.exports = {
module.exports = {
getRealEstateTypes,
postRealEstateTypes
};