From 82da4b23ffe68d59c430ea33977c5abf1b0010e2 Mon Sep 17 00:00:00 2001 From: Lance Edgar Date: Wed, 18 Mar 2020 11:31:23 -0500 Subject: [PATCH] Add CORE Office URL to context for member data in profile view --- tailbone_corepos/views/people.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/tailbone_corepos/views/people.py b/tailbone_corepos/views/people.py index 8b171c2..e5432ac 100644 --- a/tailbone_corepos/views/people.py +++ b/tailbone_corepos/views/people.py @@ -71,3 +71,12 @@ class PersonView(base.PeopleView): self.rattail_config, customer['number']) return data + + def get_context_member(self, member): + data = super(PersonView, self).get_context_member(member) + + # add CORE Office URL for member account + data['view_corepos_url'] = core_office_customer_account_url( + self.rattail_config, member['id']) + + return data