Skip to content

Commit e1e41d4

Browse files
Merge pull request #2915 from carpentries/feature/2576-update-member-code-docs
[Docs] Update member code docs, add some docs for the Offering project
2 parents 2b30c42 + 80790f2 commit e1e41d4

File tree

4 files changed

+80
-1
lines changed

4 files changed

+80
-1
lines changed

docs/design/database_models.md

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,10 @@ organisations) in The Carpentries project. Memberships can be paid. With
151151
each membership comes a number of fields defining perks like allowable
152152
number of centrally-organised workshops that don't need to pay fee.
153153

154+
Includes a `registration_code` field — a unique code shared with member organisations
155+
and used by trainees and workshop requesters to identify their membership when submitting
156+
forms (see [Member Code Enforcement](./projects/2023_member_code_enforcement.md)).
157+
154158
### `Airport`
155159
Represents an airport (used for example to locate instructors).
156160

@@ -198,6 +202,10 @@ Represents a knowledge domain (like High Performance Computing) a person is enga
198202
Represents a request for instructor training. Usually these requests come from people
199203
who are not AMY users.
200204

205+
Includes a `member_code` field (the registration code entered by the applicant), which is validated against active memberships, partnerships or account benefits, and a
206+
`member_code_override` boolean field, which records whether the applicant chose to
207+
submit despite an invalid member code (see [Member Code Enforcement](./projects/2023_member_code_enforcement.md)).
208+
201209
This model falls into `external requests` domain, which also includes `WorkshopRequest`,
202210
`WorkshopInquiryRequest`, and `SelfOrganisedSubmission`.
203211

@@ -242,6 +250,10 @@ some common parts were extracted into `CommonRequest` abstract model (mixin).
242250
### `WorkshopRequest`
243251
Represents a request for teaching a Carpentries workshop.
244252

253+
Includes a `member_code` field for the registration code entered by the requester, which
254+
is validated against active memberships, partnerships or account benefits when member code enforcement is
255+
enabled (see [Member Code Enforcement](./projects/2023_member_code_enforcement.md)).
256+
245257
This model falls into `external requests` domain.
246258

247259
----------------------------------------------------------------------------------------
@@ -256,6 +268,21 @@ Simple model, represents person role within a membership (see
256268
Similar to [`Task`](#task) model, but it's for a person task within a membership. Links
257269
to `MembershipPersonRole`.
258270

271+
### `Consortium`
272+
Represents a consortium of multiple organisations. A consortium can be the partner in a
273+
[`Partnership`](#partnership).
274+
275+
### `PartnershipTier`
276+
Represents a tier level for a partnership (e.g. "Bronze", "Silver", "Gold"), with an
277+
associated credit count.
278+
279+
### `Partnership`
280+
Represents a service partnership between The Carpentries and an organisation or
281+
consortium. A follow-up to the [`Membership`](#membership) model, introduced as part of
282+
the [Service Offering 2025 project](./projects/2025_service_offering.md).
283+
284+
Includes a `registration_code` field — a unique code used to identify the partnership in trainee applications or workshop requests (see also [Member Code Enforcement](./projects/2023_member_code_enforcement.md)).
285+
259286
----------------------------------------------------------------------------------------
260287

261288
## External requests application - `extrequests/models.py`
@@ -375,3 +402,31 @@ be sent by the email worker.
375402
### `ScheduledEmailLog`
376403
Represents a log entry for a scheduled email. This is used to track the status changes
377404
of an email.
405+
406+
----------------------------------------------------------------------------------------
407+
408+
## Offering application - `offering/models.py`
409+
410+
The offering application models support the [Service Offering 2025](./projects/2025_service_offering.md) project. They represent
411+
the purchasing and allocation of benefits to partner organisations and individuals.
412+
413+
### `Account`
414+
Represents the individual or organisation that purchases benefits. An `Account` is linked
415+
to a `Person`, `Organization`, or `Consortium` via a generic foreign key.
416+
417+
### `AccountOwner`
418+
Represents a person appointed as the owner of an account. Stores the permission type
419+
(owner, programmatic contact, or billing contact).
420+
421+
### `Benefit`
422+
Represents a single good available to be purchased for an account (e.g. training seats
423+
or workshop events). Stores a unit type and credit count.
424+
425+
### `AccountBenefitDiscount`
426+
Simple model representing a discount that can be applied to an account benefit purchase. The discount is just a text, no logic is applied to it in AMY, but it can be used for reporting and tracking purposes.
427+
428+
### `AccountBenefit`
429+
Represents a single benefit purchased for an account. Links an [`Account`](#account) to
430+
a [`Benefit`](#benefit), optionally via a [`Partnership`](#partnership). Stores
431+
allocation, date range, and a unique `registration_code` used to identify the benefit in
432+
training requests and workshop requests (see [Member Code Enforcement](./projects/2023_member_code_enforcement.md)).
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Service Offering Model (2025)
2+
3+
[GitHub project](https://github.com/orgs/carpentries/projects/20).
4+
5+
"Offering" or "Partnership Model" for short.
6+
7+
TBC.

docs/design/projects/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,6 @@ Documentation provided for each of the functional projects.
1313
* [Instructor Selection](./2021_instructor_selection.md)
1414
* [Single Instructor Badge](./2021_single_instructor_badge.md)
1515
* [Automated emails v2 (2023)](./2023_automated_emails/index.md)
16+
* [Instructor Checkout Changes (2023)](./2023_instructor_checkout_changes.md)
17+
* [Member Code Enforcement (2023)](./2023_member_code_enforcement.md)
18+
* [Service Offering (2025)](./2025_service_offering.md)

docs/users_guide/admin_index.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,8 +199,16 @@ A workshop can be requested from a host site, and this information can be used t
199199

200200
This will take you to a summary view of the workshop requests, workshop inquiries, or self-organised submissions. Click on the "information" icon at the right of each row to see more details.
201201

202+
The workshop requests list includes a filter to find requests submitted by a member organisation that did not include a member code.
203+
202204
![AMY workshop request list](images/workshop_requests.png)
203205

206+
!!! note "Member code validation on workshop requests"
207+
208+
Workshop requests include a field for a registration (member) code. The code is validated against active memberships, partnerships and account benefits. If the code is invalid or inactive, the form displays an error — unlike training requests, there is no option for the submitter to override an invalid code.
209+
210+
When viewing a workshop request detail page, an info box shows the membership associated with the submitted member code (if applicable) and the number of workshops remaining for that membership. If the request is submitted with a member code from a partnership or account benefit, then a link to that model is shown.
211+
204212
At the bottom of the request information page, the user has the option to accept or discard the request. All requests should be accepted (unless spam or otherwise inappropriate) so The Carpentries can maintain a history of workshop requests. Events can later be tagged as stalled or cancelled. Choosing "Change state to Accepted" will mark it as accepted in the workshop request list but will not create a new event. Select "Accept and create a new event" to create a new event from this request.
205213

206214
This will open a page with a side by side view of the request details and view to create a new event, similar to the general new event page. The new event can be created [manually](#creating-a-new-event-manually) or if available, [from the URL](#creating-a-new-event-from-url), as described above.
@@ -350,16 +358,22 @@ See [section above](#adding-bulk-person-records).
350358

351359
#### Accepting Trainee Applications
352360

353-
In addition to tracking workshops, AMY also allows us to track applications to instructor training events. [The public facing application is here](https://amy.carpentries.org/forms/request_training/). Applicants are given a registration code if participating in a member training event and should select "Profile Creation for Pre-approved Trainees" using this code. Open applicants will not have a registration code.
361+
In addition to tracking workshops, AMY also allows us to track applications to instructor training events. [The public facing application is here](https://amy.carpentries.org/forms/request_training/). Applicants are given a registration code if participating in a member training event. Open applicants will not have a registration code.
354362

355363
Once an individual submits the form, they receive an email that confirms their application has been received and includes a copy of the individual's responses. An admin user can then view the record by going to Requests --> [Training Requests](https://amy.carpentries.org/requests/training_requests/).
356364

357365
![Training request menu](images/training_request_menu.png)
358366

359367
This will display a list of all applications that are *Pending or Accepted* and *Unmatched* to an existing person. Applications can then be searched by individual name, email address, group (registration code), status (pending, accepted, discarded, or withdrawn), affiliation, or location. Affiliation and location searches rely on text strings, so *UCLA* will not return *University of California Los Angeles* and *Joburg ZA* will not return *Johannesburg* or *South Africa*.
360368

369+
There is also a filter to show only applications where the applicant submitted with an invalid registration code using the override option (see below). This can be used to manually check these applications.
370+
361371
![Training request list view](images/amy_training_requests.png)
362372

373+
!!! note "Member code validation on training requests"
374+
375+
AMY validates the registration code entered by applicants. If the code is invalid, inactive, or has no seats remaining (applicable for memberships), the form will display an error. However, applicants may check a box labelled "Continue with registration code marked as invalid" to submit the application anyway.
376+
363377
Some trainees will already be in AMY. If there is a record with a matching name and email address, they will show up with a "matched trainee" when you search for them. You can match the application to this trainee, or if the match was incorrect, search for a different Person record or create a new Person.
364378

365379
![Match trainee to person](images/match_trainee.png)

0 commit comments

Comments
 (0)