Past Due Reminder is sent automatically next, day, after sending initial email vie "Send Email" button. #9313
-
Setup
Interface
Checklist
Describe the bugWhen I finish creating a quote, or an invoice and hit send email button - with consequent sending the document via email within invoice ninja. Second email being sent by the system automatically (no schedule setup, see screenshots below). But the second email is sent as a Past Due reminder. Steps To ReproduceSet up reminders in Settings => Send Reminders. Expected BehaviorCheck if initial email was sent and adhere to reminder schedule - if set time for reminder didn't pass after the initial email sent - don't send email at ( Settings => Email Settings => Send Time) time. Additional contextNo other schedulers are setup for emails, other then Mandatory Settings => Email Settings => Send Time. ScreenshotsReminder settings - not due for 14 days after initial email Current Mandatory send time settings False reminder sent at 6am - Ignoring reminders settings LogsLogs are in the screenshot.
|
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 19 replies
-
You'll want to inspect your configuration of timezones. After creating an invoice, in the Invoices table, you'll see a field next_send_date This is the UTC time that the server has calculated - based on your reminder schedule - to fire the next invoice. If you want to share your full configuration. Timezone And full reminder schedule, I can run a test case to calculate the next send date. |
Beta Was this translation helpful? Give feedback.
-
Timezone - EST Full reminder schedule as in Settings => Templates & Reminders
I can attach screenshots, or somehow export config if youd' like. |
Beta Was this translation helpful? Give feedback.
-
After some investigation, I found undocumented env variable SERVER_TIMEZONE in app.php
Setting this variable in .env file for docker container like so
Forces the laravel app to accept set timezone instead of standard declared value - UTC. This can be verified with date_default_timezone_get(); after docker container is recreated:
This could possibly be added to documentation to avoid additional INI files (they don't work for setting the timezone in laravel any way) - https://invoiceninja.github.io/en/env-variables/ |
Beta Was this translation helpful? Give feedback.
-
@turbo124 Attaching screenshots of timezone in php artisan tinker No changes to schedulers, everything as in the first post - #9313 (comment) And I still get "First reminder" sent out to clients next day 6am after I sent initial invoice manually. This reminder should go out 14 days Prior to Due Date, not next day. Maybe I'm missing something, but the timezone fix seems to have no effect on things. No way I'm alone with this, I only noticed it when one of my clients called me back asking to stop reminders... |
Beta Was this translation helpful? Give feedback.
I've just noticed. Why do you have a third reminder of
Third reminder - 1 day after the invoice date - send email.
this sounds like the issue?