Commit 7906dc3f by Javier

Se eliminan registros 016 al consultar

parent 4138d4a2
...@@ -276,6 +276,11 @@ def get_cdrs(phone_number : str, since : datetime = None, upto : datetime = None ...@@ -276,6 +276,11 @@ def get_cdrs(phone_number : str, since : datetime = None, upto : datetime = None
with mariadb.connect(**DB_CREDENTIALS) as cnx: with mariadb.connect(**DB_CREDENTIALS) as cnx:
with cnx.cursor() as cursor: with cnx.cursor() as cursor:
# Se eliminan llamadas a 016
cursor.execute('DELETE FROM mbilling.pkg_cdr WHERE calledstation IN (\'016\', \'34016\')')
# Carga de CDRs
if upto and since: if upto and since:
cursor.execute( cursor.execute(
'SELECT callerid, calledstation dest, destination as description, starttime date, sessiontime duration, ROUND(sessionbill,3) \ 'SELECT callerid, calledstation dest, destination as description, starttime date, sessiontime duration, ROUND(sessionbill,3) \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment