edi deviceList/position template

This commit is contained in:
Francesco Esposito 2019-02-21 12:58:28 +01:00
parent c3cf83c977
commit 85967afb3a
1 changed files with 10 additions and 8 deletions

View File

@ -31,19 +31,21 @@ and run the bot on your local network. 😎`;
}
function templatePosition(data) {
const msg = `📲 📡 ${data.name}
-------------------------------------
- 🏔 Altitude: ${data.position.altitude}
- Speed: ${data.position.speed}
- 📏 Accurancy: ${data.position.accurancy}
- 🔋 Battery: ${data.information.battery}
- 2019-02-18T13:44:01`;
const msg = `📲 📡 *${data.name}*
🏔 _Altitude_: *${data.position.altitude} m.*
_Speed_: *${data.position.speed} m/h*
📏 _Accurancy_: *${data.position.accurancy} m.*
🔋 _Battery_: *${data.information.battery}%*
2019-02-18T13:44:01`;
return msg;
}
function templateDevicesList(data) {
const msg = `📲 ${data.name}
const msg = `📲 *${data.name}*
----
${data._id}`;
return msg;
}