# Features — permits.magus.events

Evidence date: 2026-10-07. Source revision: `master` at `4617ab1` (2022-06-01). No feature list existed in the repository.

Status words used here:

- **Current** — present on `master` and reachable from a controller that Zend will dispatch for the PIN session, or from an anonymous action that does not require that session.
- **Present, not dispatched** — code exists, but init always redirects, the class name does not match the file, or the action reads an identity the PIN login never sets.
- **Documented only** — described in email or FAQ copy, with no action in this repository.
- **Unused model** — a `Zend_Db_Table` class that no controller in this tree constructs.

## Current features

| Feature | What the user can do | Where |
|---|---|---|
| Shared-secret gate | One posted value opens the desk for event id `45` | `LoginController::indexAction`, `login/index.phtml` |
| Event switch | Set `EVENT.EID` from the query string and open `/walkins` | `LoginController::externalAction` |
| Logout | Clear `Zend_Auth` and destroy the session, then `/login` | `LoginController::logoutAction` |
| Company picker | List companies on the session event; search by name, type, reference, or admin name | `WalkinsController::indexAction`, `searchAction`, `walkins/index.phtml` |
| Company passkey | Browser compares the modal value to `passkey`; the server repeats the check | `walkins/index.phtml`, `WalkinsController::newAction`, `CompanyEvents::getRow` |
| New permit form | Load-in or load-out, service, date, 30-minute times, vehicle, driver, staff | `walkins/new.phtml` |
| Create permit | Insert status `2`, number `PM` plus padded id | `PermitsController::addpermitAction` |
| Permit profile by id | View any permit id while the event session exists | `PermitsController::profileAction`, `getPermit_admin` |
| FAQ page | Fixed questions and answers | `PermitsController::questionsAction` |
| Supplier registration | Create company and administrator, attach event `44` | `RegisterController` |
| Email confirmation on this host | Set `AllowLogin` and `Email_Confirmed` when the key matches | `RegisterController::validateemailAction` |
| Forgot password | Email a reset link when the address exists on `Company_Members` | `LoginController::forgotAction` |
| Reset password | Store an MD5 password and email it in clear text | `LoginController::resetAction` |
| Company logo by id | Return `{id}_image.jpg` from `public/archives/companies/`, or a built-in image | `LoginController::companypicAction` |
| Remote logo upload | Write a company image from posted base64 with no session check | `LoginController::uploadremotecompanyAction` |
| Layout chrome | Title from accreditation name, link "Permits Area", logout, Sun International footer | `application/layouts/default.phtml` |

## Present, disconnected from the PIN login

| Feature | Why it does not run in the desk session | Where |
|---|---|---|
| Operations dashboard | `IndexController::init` redirects to `/walkins` whenever `EID` is set, and to `/login/` when it is not | `IndexController::indexAction`, `index/index.phtml` |
| Dashboard refresh | Same init redirect. `getdataAction` never runs | `IndexController::getdataAction` |
| Permit PDF | Same init redirect. Also uses undefined `AC_PATH` | `IndexController::getpermitpdfAction` |
| Identity probe | Same init redirect. Queries `Company_Members` by a hardcoded identity number | `IndexController::testAction` |
| Email and password login | `LoginNow` and `CompaniesLogin` are never called by the login form | `LoginController::LoginNow`, `getAuthAdapter` |
| Company profile | Requires `Zend_Auth`. The PIN login does not create it, and `/login` then bounces back to the desk | `CompanyController` |
| Company logo upload while signed in | Same auth gate | `CompanyController::uploadAction` |
| Staff list, add, edit | Same auth gate. Roles are a fixed list. New passwords are MD5 of 3 random bytes | `UsersController` |
| Second permit form | `permits/create.phtml` posts to `/permits/addpermit/` without `cid`. Not linked from walk-ins | `PermitsController::createAction` |
| Save permit | Updates the row, then reads `$this->identity->MID`, which is never set | `PermitsController::savepermitAction`, `permits/profile.phtml` |
| Duplicate permit | Copies the row and reads `$this->identity`. No view in the walk-in flow posts to it | `PermitsController::duplicatepermitAction` |
| Cancel permit | Sets status `5` and reads `$this->identity`. The cancel button lives on the unreachable dashboard. The comment about email is not followed by a send | `PermitsController::cancelAction`, `index/index.phtml` |
| Profile test | Loads a permit with `$this->identity->CID` | `PermitsController::profiletestAction` |
| Mail test | Sends a message to a hardcoded mailbox. Needs the event session | `PermitsController::emailtestAction` |
| Alternate permit mail | Function exists. The call is commented out | `PermitsController::postEmailToFp` |

## Unused or stub features in this tree

| Item | Evidence |
|---|---|
| `AuthonController` | Empty `indexAction` and `newcompanyAction`. Views `authon/register.phtml`, `test.phtml`, `validateemail.phtml` exist |
| `OrgController.php` | Class name is `Company_OrgController`, so Zend will not dispatch it as `OrgController`. `indexAction` is empty |
| `OrganisationController` | `profileAction` is empty. View `organisation/profile.phtml` exists |
| `EventsController.php` | Class name is `Companies_EventsController`. Init redirects to `/companies/login/`, which is not a controller in this tree. `indexAction` prints `AccreditationList::getEvents(2)` |
| `CompanyController::getmembersAction` | Empty |
| Module bootstrap | `application/modules/default/controllers/Bootstrap.php` class `Default_Bootstrap` has no resource methods |
| Application bootstrap | `_initDbAdapter` is empty. The ini file still configures the database resource |
| Layouts named in ini | `admin`, `union`, `referee`, `gir`, `accreditations` have no layout files and no modules. Only `default.phtml` and `layout.phtml` exist. `LayoutPicker` forces the layout name to the module name `default` |
| Rugby and venue models | `Fixture`, `Copy of Fixture`, `FixtureScores`, `Squad`, `Tournament`, `TournamentFoodSession`, `FoodSessionItems`, `Allergens`, `Nutritions`, `MenuVenues`, `MatchReport`, `NewsArticles`, `Positions`, `GirProfile`, `Profile`, `Unions`, `Ethnicity`, `Logs`, `ComentryAndCiting` are not constructed by any controller |
| WordPress tree | `public/wp-content` and `public/wp-includes` are files on disk. The Zend front controller does not bootstrap WordPress |
| Messages menu | `menu/nevigation.phtml` shows a static "Victoria" user and demo messages. It is a theme sample |

## Planned features

None found. No issue tracker, milestone, or TODO document is in the repository.

Commented blocks (maintenance page in `public/index.php`, dashboard counts in `IndexController::indexAction`, footprint email post) are disabled code, not a stated plan.

## Recently changed

The only application commit is `4617ab1` (2022-06-01), which added the whole tree. There is no later change to compare.

## Deprecated or removed

Nothing in Git history shows a removed feature. The parent commit `c779b77` contains only `.gitignore`.

## Not features of this product

These are in the tree and are not actions of the permit desk:

- Match-report PDFs and tournament JSON under `public/archives/`.
- A second copy of dompdf under `public/FILESTO DOWNLOAD`.
- `library/Zend` (framework) and `library/PG` helpers that the walk-in controllers do not call (`MatchReport`, `fpdf`, `html2fpdf`).

## Related documentation

`permits.mypass.zone` in Silicon Ark describes the same walk-in behaviour at a later revision that adds CodeDeploy. This repository does not contain that deploy set. Treat the two documents as separate products until a human confirms they are one deployment.
