2024-12-22_16-44-53Z_Sunday

This commit is contained in:
Ken Fallon 2024-12-22 17:44:53 +01:00
parent 1c27172a33
commit 16586c74d0

View File

@ -14,11 +14,11 @@ This process involves requesting a slot and verifying that the request is valid.
- The host fills in the form which executes [upload_confirm.php](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/upload_confirm.php). - The host fills in the form which executes [upload_confirm.php](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/upload_confirm.php).
- The host receives a confirmation email. - The host receives a confirmation email.
# Sequence Diagram Requesting a slot # Selecting a slot
## Picking a slot > The Host wishes to upload a show and wants to pick a date.
The Host wishes to upload a show and wants to pick a date. [`calendar.php`](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/calendar.php)
```mermaid ```mermaid
sequenceDiagram sequenceDiagram
@ -28,14 +28,17 @@ sequenceDiagram
HPR->>HPR: Remove any requests from this IP older than 15min HPR->>HPR: Remove any requests from this IP older than 15min
HPR->>Host: Display Calendar page HPR->>Host: Display Calendar page
``` ```
The website provides a Calendar with a list of available slots. > The website provides a Calendar with a list of available slots.
![The Calendar page](calendar.png) ![The Calendar page](calendar.png)
---
## Requesting a slot # Requesting a slot
The Host picks a slot and wants to reserve it. > The Host decides on a slot and wants to reserve it.
[`request.php`](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/request.php)
```mermaid ```mermaid
sequenceDiagram sequenceDiagram
@ -76,8 +79,7 @@ sequenceDiagram
end end
HPR->>Host: Thank You page HPR->>Host: Thank You page
``` ```
> If an error occurs one of the following error codes will be returned.
### Checks in request.php and request_confirm.php
| 412 Error Code | Check | | 412 Error Code | Check |
| --- | ------ | | --- | ------ |
@ -107,12 +109,19 @@ sequenceDiagram
| 434cb53552ce1e2708e74a42f438028c | Problem mapping the date to the episode number | | 434cb53552ce1e2708e74a42f438028c | Problem mapping the date to the episode number |
| c7405e79b54f582e8db46c69ec4b0f24 | Problem writing to the database | | c7405e79b54f582e8db46c69ec4b0f24 | Problem writing to the database |
The website provides a "Thank You" page notifying the Host that the email is sent. > The website provides a "Thank You" page notifying the Host that the email is sent.
![The email confirmation page](request_slot_thank_you.png) ![The email confirmation page](request_slot_thank_you.png)
## Sequence Diagram uploading a show # Sequence Diagram uploading a show
[`request_confirm.php`](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/request_confirm.php)
`email`
[`upload.php`](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/upload.php)
[`upload_confirm.php`](https://repo.anhonesthost.net/HPR/hpr_hub/src/branch/main/hub/upload_confirm.php)
`email`
```mermaid ```mermaid
sequenceDiagram sequenceDiagram
@ -121,10 +130,15 @@ sequenceDiagram
alt If check fails alt If check fails
HPR->>HPR: Log Error HPR->>HPR: Log Error
HPR->>host: 412 ${error_code} HPR->>host: 412 ${error_code}
else All checks passed
HPR->>host: Webform
end end
end end
HPR->>host: Upload Webform
```
```mermaid
sequenceDiagram
host->>HPR: Uploads show host->>HPR: Uploads show
loop Preform Checks loop Preform Checks
alt If check fails alt If check fails
@ -138,7 +152,6 @@ sequenceDiagram
end end
``` ```
### Checks in upload.php
| 412 Error Code | Check | | 412 Error Code | Check |
| --- | ------ | | --- | ------ |
@ -150,7 +163,6 @@ end
| 066c518314f0d3b1ad3e4af60fcf36ce | Unable to remove temporary lock | | 066c518314f0d3b1ad3e4af60fcf36ce | Unable to remove temporary lock |
| 5cb513b590ab5859bf7603b79402a5cb | Could not find Host in Database | | 5cb513b590ab5859bf7603b79402a5cb | Could not find Host in Database |
### Checks in upload_confirm.php
| 412 Error Code | Check | | 412 Error Code | Check |
| --- | ------ | | --- | ------ |