systopia / de.systopia.birthdays

CiviCRM extension to deal with birthdays
Other
4 stars 9 forks source link

When I filter with Next calendar month in the report, I would only get those records with people born next month #26

Open bjendres opened 2 years ago

bjendres commented 2 years ago

@timindaburgh writes on CiviCRM mattermost:

When I filter with Next calendar month in the report, I would only get those records with people born next month

I haven't looked at this extension in a long time, but that sounds weird. HERE it tries to use the birthday rather then the birth date for the filter.

Could you try to post the generated SQL (by adding Civi::log()->debug($sql); HERE)?

bjendres commented 2 years ago

And: how do you even have contacts in the database born next month? :)

timindaburgh commented 2 years ago

And: how do you even have contacts in the database born next month? :) Indeed... we don't - would take a wizard.

When I select Next calendar month in the field labeled Birthday, the report shows no matches even though I have many records of people born in previous years within the month of June. However, if I add no filter to Birthday and refresh the report, I get the full list of birthdays for the whole calendar year beginning a record of someone celebrating a birthday tomorrow, i.e. Name, May 6th, 2022.

On a bit of a tangent, the birthday shown would make more sense to me if it was written as May 6th and not May 6th, 2022. The date of the report already dictates 2022 and showing a birthday in that format may be confused with the Date of birth of someone with that record.

As a newbie in code, how would I generate the SQL as mentioned with adding Civi::log()->debug($sql);