From 28b43d1d5627101daf73d3191c6d6c4ef3c41c96 Mon Sep 17 00:00:00 2001 From: shekhar-cis Date: Wed, 29 Jun 2022 19:46:36 +0530 Subject: [PATCH] Update helper_sent --- src/helper_sent.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/helper_sent.py b/src/helper_sent.py index 2996939e..05b17f7f 100644 --- a/src/helper_sent.py +++ b/src/helper_sent.py @@ -7,7 +7,7 @@ import uuid from addresses import decodeAddress from bmconfigparser import config from helper_ackPayload import genAckPayload -from helper_sql import sqlExecute +from helper_sql import sqlExecute, sqlQuery # pylint: disable=too-many-arguments @@ -51,3 +51,11 @@ def insert(msgid=None, toAddress='[Broadcast subscribers]', fromAddress=None, su def delete(ack_data): """Perform Delete query""" sqlExecute("DELETE FROM sent WHERE ackdata = ?", ack_data) + + +def retrieve_message_details(ack_data): + """Retrieving Message details""" + data = sqlQuery( + "select toaddress, fromaddress, subject, message, received from inbox where msgid = ?", ack_data + ) + return data