- Nella Lavagna, cliccando sul nome dell'invitato, compaiono le sue informazioni sugli step rimasti, in dettaglio.

- Ogni utente puo' cosi scegliere di regalare un proprio invitato, cliccando sull'invitato, scrivendo l'username del destinatario e premendo il bottone 'Regala Invitato'.
Al destinatario gli arriverà un messaggio sul Bot Telegram che indica che gli è stato regalato un'invitato.
This commit is contained in:
Paolo Arena
2020-02-02 04:06:32 +01:00
parent 512a8c14e2
commit e386d2550b
9 changed files with 150 additions and 32 deletions

View File

@@ -258,6 +258,7 @@ router.post('/gettable', authenticate, (req, res) => {
router.patch('/chval', authenticate, (req, res) => {
// const idapp = req.body.idapp;
const id = req.body.data.id;
const idapp = req.body.idapp;
const mydata = req.body.data;
const mytable = getTableByTableName(mydata.table);
@@ -276,7 +277,12 @@ router.patch('/chval', authenticate, (req, res) => {
if (!rec) {
return res.status(404).send();
} else {
if (mydata.notifBot) {
// Send Notification to the BOT
telegrambot.sendMsgTelegram(idapp, mydata.notifBot.un, mydata.notifBot.txt)
}
res.send({ code: server_constants.RIS_CODE_OK, msg: '' });
}
}).catch((e) => {
@@ -625,7 +631,8 @@ router.post('/upload/:dir', authenticate, (req, res) => {
// Move in the folder application !
tools.move(file.path, newname, (err) => {
console.log('err:', err);
if (err)
console.log('err:', err);
res.end();
});