Skip to content

Commit

Permalink
activated service
Browse files Browse the repository at this point in the history
  • Loading branch information
aabduvak committed Jan 7, 2024
1 parent 2346609 commit 8b00a6c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions api/management/commands/send_message.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@ def send_messages():
debt = get_debt_list(branch_id=branch, customer_id=customer.smartup_id)
message = prepare_message(customer, payment, debt)

#state = send_message(customer.phone[1:], message, token)
#if state and state['status'].upper() in STATUS_LIST:
# data['success'] += 1
#else:
# data['error'] += 1
state = send_message(customer.phone[1:], message, token)
if state and state['status'].upper() in STATUS_LIST:
data['success'] += 1
else:
data['error'] += 1

success_handler('Отправлено сообщение клиентам, у которых есть оплата', data, token)
delete_token(token)
Expand Down

0 comments on commit 8b00a6c

Please sign in to comment.