Bug 6759

Summary: Use a different account type for account renewals than for new accounts
Product: Koha Reporter: Savitra Sirohi <savitra.sirohi>
Component: Fines and feesAssignee: Martin Renvoize <martin.renvoize>
Status: CLOSED FIXED QA Contact: Tomás Cohen Arazi <tomascohen>
Severity: enhancement    
Priority: P5 - low CC: gmcharlt, katrin.fischer, kohapatch, martin.renvoize, maryse.simard, nick, tomascohen
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Small patch
Documentation contact: Documentation submission:
Text to go in the release notes:
This enhancement makes account renewal charges distinct from initial account registration charges. **Reports note**: Prior to this patch both account creations and account renewals would result in an accountline with accounttype `A`; After this patch account creations will result in an accountline with accounttype `ACCOUNT` and account renewals will result in ana ccountline with accounttype `ACCOUNT_RENEW`.
Version(s) released in:
19.11.00
Bug Depends on: 11573    
Bug Blocks: 23321    
Attachments: Bug 6759: Split account creation and renewal charges
Bug 6759: Update existing accountlines for 'A'
Bug 6759: Split account creation and renewal charges
Bug 6759: Update existing accountlines for 'A'
Bug 6759: Split account creation and renewal charges
Bug 6759: Update existing accountlines for 'A'
Bug 6759: Split account creation and renewal charges
Bug 6759: Update existing accountlines for 'A'
Bug 6759: Split account creation and renewal charges
Bug 6759: Update existing accountlines for 'A'
Bug 6759: (QA follow-up) Unit tests

Description Savitra Sirohi 2011-08-22 04:31:54 UTC
Currently accounttype is set to 'A' for both new registrations and renewals, reporting separately on renewals is not possible as a result.
Comment 1 Owen Leonard 2016-06-23 12:08:41 UTC
I'm updating the version information for this report because I assume this hasn't been implemented yet.

This bug has been "assigned" for a long time. Is someone really working on it?
Comment 2 Katrin Fischer 2016-08-14 14:36:58 UTC
Resetting to default - please take the bug if you intend to work on it.
Comment 3 Martin Renvoize 2019-04-24 11:18:00 UTC
Created attachment 88614 [details] [review]
Bug 6759: Split account creation and renewal charges

Test plan:
1. Enable charging for patron enrolement
2. Add a new patron where the category is charged for
3. Note the charge of type 'Account management fee'
4. Renew the patron
5. Note the next charge of type 'Account management fee'
6. Apply patch
7. Repeat steps 1-6 and note the first charge will be of type 'Account
creation fee' and the second of type 'Account renewal fee'
8. Bonus points, enable 'FeeOnChangePatronCategory' and check that when
changing a patron from a free category to a charged one that a new
'Account renewal fee' is charged.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 4 Martin Renvoize 2019-04-24 11:18:03 UTC
Created attachment 88615 [details] [review]
Bug 6759: Update existing accountlines for 'A'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 5 Martin Renvoize 2019-04-25 09:17:22 UTC
Created attachment 88731 [details] [review]
Bug 6759: Split account creation and renewal charges

Test plan:
1. Enable charging for patron enrolement
2. Add a new patron where the category is charged for
3. Note the charge of type 'Account management fee'
4. Renew the patron
5. Note the next charge of type 'Account management fee'
6. Apply patch
7. Repeat steps 1-6 and note the first charge will be of type 'Account
creation fee' and the second of type 'Account renewal fee'
8. Bonus points, enable 'FeeOnChangePatronCategory' and check that when
changing a patron from a free category to a charged one that a new
'Account renewal fee' is charged.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 6 Martin Renvoize 2019-04-25 09:17:25 UTC
Created attachment 88732 [details] [review]
Bug 6759: Update existing accountlines for 'A'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 7 Martin Renvoize 2019-07-15 14:49:14 UTC
Created attachment 91533 [details] [review]
Bug 6759: Split account creation and renewal charges

Test plan:
1. Enable charging for patron enrolement
2. Add a new patron where the category is charged for
3. Note the charge of type 'Account management fee'
4. Renew the patron
5. Note the next charge of type 'Account management fee'
6. Apply patch
7. Repeat steps 1-6 and note the first charge will be of type 'Account
creation fee' and the second of type 'Account renewal fee'
8. Bonus points, enable 'FeeOnChangePatronCategory' and check that when
changing a patron from a free category to a charged one that a new
'Account renewal fee' is charged.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 8 Martin Renvoize 2019-07-15 14:49:18 UTC
Created attachment 91534 [details] [review]
Bug 6759: Update existing accountlines for 'A'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 9 Maryse Simard 2019-07-19 19:06:22 UTC
Created attachment 91662 [details] [review]
Bug 6759: Split account creation and renewal charges

Test plan:
1. Enable charging for patron enrolement
2. Add a new patron where the category is charged for
3. Note the charge of type 'Account management fee'
4. Renew the patron
5. Note the next charge of type 'Account management fee'
6. Apply patch
7. Repeat steps 1-6 and note the first charge will be of type 'Account
creation fee' and the second of type 'Account renewal fee'
8. Bonus points, enable 'FeeOnChangePatronCategory' and check that when
changing a patron from a free category to a charged one that a new
'Account renewal fee' is charged.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Comment 10 Maryse Simard 2019-07-19 19:06:26 UTC
Created attachment 91663 [details] [review]
Bug 6759: Update existing accountlines for 'A'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Comment 11 Tomás Cohen Arazi 2019-09-12 18:16:59 UTC
Created attachment 92765 [details] [review]
Bug 6759: Split account creation and renewal charges

Test plan:
1. Enable charging for patron enrolement
2. Add a new patron where the category is charged for
3. Note the charge of type 'Account management fee'
4. Renew the patron
5. Note the next charge of type 'Account management fee'
6. Apply patch
7. Repeat steps 1-6 and note the first charge will be of type 'Account
creation fee' and the second of type 'Account renewal fee'
8. Bonus points, enable 'FeeOnChangePatronCategory' and check that when
changing a patron from a free category to a charged one that a new
'Account renewal fee' is charged.

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 12 Tomás Cohen Arazi 2019-09-12 18:17:06 UTC
Created attachment 92766 [details] [review]
Bug 6759: Update existing accountlines for 'A'

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 13 Tomás Cohen Arazi 2019-09-12 18:17:11 UTC
Created attachment 92767 [details] [review]
Bug 6759: (QA follow-up) Unit tests

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 14 Martin Renvoize 2019-09-13 07:07:15 UTC
Nice work!

Pushed to master for 19.11.00