Bug 33540 - Add death date for deceased patron
Summary: Add death date for deceased patron
Status: NEW
Alias: None
Product: Koha
Classification: Unclassified
Component: Patrons (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement (vote)
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-16 07:34 UTC by giuseppe.angilella
Modified: 2023-04-17 06:31 UTC (History)
4 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description giuseppe.angilella 2023-04-16 07:34:58 UTC
When a patron dies, one shouldn't simply remove the patron from the database, in order to keep track of the patron's past circulation history. However, setting the expiration date to the patron's death date doesn't prevent the system from increasing the patron's age (indefinitely, as time passes), which is then displayed in the patron's details.

I would then suggest to introduce some "death_date" additional field to the patrons table, and modify moremember.pl to compute the final age using death_date rather than the current (today's) date, whenever death_date is nonempty.
Comment 1 Katrin Fischer 2023-04-16 10:09:51 UTC
I wonder about this in terms of data privacy and GDPR, I'd say we should delete this data once all outstanding checkouts/fines have been taken care of. And I am not sure if we should encourage libraries to keep this kind of data by adding a specified field. It sounds like you would like to freeze the age, so a patron attribute would not quite work for you. Would be interesting to get some more input here.
Comment 2 giuseppe.angilella 2023-04-16 14:20:21 UTC
How about then computing the patron's age until the patron's expiration date, if nonempty?

This wouldn't require adding any field (and associate it to any specific event, such as the patron's death), but would prevent the system showing ages in principle increasing indefinitely.
Comment 3 Katrin Fischer 2023-04-16 14:48:37 UTC
Let's take a step back: why is the computing of the age important?

I don't think we should stop for expired accounts, it's still a good information in most use cases. And expiration and age are not really linked in any way.
Comment 4 giuseppe.angilella 2023-04-16 15:11:42 UTC
I think that originally the reason why the age of a patron should be displayed was to help the librarian to identify the patron as an adult or otherwise, and therefore to conclude whether restrictions should be applied.
Comment 5 Katrin Fischer 2023-04-16 15:48:24 UTC
I assume you wouldn't keep the data of deceased patrons very long. Also you wouldn't want to check out any new items, so circulation rules would be irrelevant.

What I would probably do is to create a restriction of type "DECEASED" and set that. That would restrict the account and at the same time make it clear what happened. It would also be easily possible to use that in reports and the like.
Comment 6 David Cook 2023-04-17 01:07:44 UTC
Technically speaking, if the patron is deleted, they'd still be in the deletedborrowers table, so you could delete patrons who have died and just write SQL reports to show any relevant information. 

Giuseppe, is this a hypothetical issue or is this coming from an existing library? I didn't notice a Koha on the Internet for your organisation.
Comment 7 David Cook 2023-04-17 01:12:52 UTC
I was just looking at the function for getting age for unrelated reasons, so this is on my mind a bit.

Looking at the patron details in the staff interface in English, it doesn't technically say the age of the patron. It just notes how many years ago they were born. 

It's not uncommon to celebrate the birthdays of famous people many years after their deaths, so I don't think there is an issue with the year displayed continuing to increment. 

For display purposes, if an attribute of DECEASED were added, you could also use Javascript to dynamically update the display accordingly.