Skip to content
Snippets Groups Projects
Commit ff81c901 authored by ems19's avatar ems19
Browse files

[FIX] Date

parent fbd69d77
No related branches found
No related tags found
4 merge requests!379homologa -> master,!378dev -> homologa,!375Prd migration,!374Prd migration
...@@ -115,6 +115,11 @@ activityApp.get('/:id', (req, res, next) => { ...@@ -115,6 +115,11 @@ activityApp.get('/:id', (req, res, next) => {
res.json({ msg: "A atividade não está cadastrada" }); res.json({ msg: "A atividade não está cadastrada" });
} else { } else {
let actJSON = act.toJSON(); let actJSON = act.toJSON();
//transform data yyyy-mm-dd to dd/mm/yyyy
let date = actJSON.date.split('-');
let date_headline = actJSON.date_headline.split('-');
actJSON.date = date[2] + '/' + date[1] + '/' + date[0];
actJSON.date_headline = date_headline[2] + '/' + date_headline[1] + '/' + date_headline[0];
req.result = actJSON; req.result = actJSON;
next(); next();
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment