Search by

uams-web / aether-classifieds

joshdaughertybpmore

Classified listings for Statamic: the classifieds content model and its Control Panel and front-end tooling.

Package info

github.com/UAMS-Web/aether-classifieds

Type:statamic-addon

pkg:composer/uams-web/aether-classifieds

Statistics

Installs: 1

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 4

v0.1.0 2026-11-29 04:24 UTC

README

A Statamic add-on that serves a classifieds board: the classifieds collection's blueprint, the board's templates, the signed-in poster's pages (post, edit and remove a listing), the posting rate limits, and the job that unpublishes and announces expired listings. The code was moved out of the UAMS site's host application (UAMS-Web/uams-statamic#1606 and UAMS-Web/uams-statamic#1608 record the decision), and every handle, route and route name is unchanged.

Status

Not released. Nothing here is installable from Packagist yet. The floors it needs are under Requirements.

Requirements

  • PHP 8.4 or later
  • Statamic 6.35 or later (statamic/cms)

Installation

Once the add-on is published, require it in the host application:

composer require uams-web/aether-classifieds

Statamic discovers the add-on from the package, and it appears under Addons in the Control Panel.

What it serves

  • The classified blueprint for the classifieds collection, read from the add-on in place of the host's resources/blueprints/collections/classifieds/. A blueprint saved in the Control Panel is written to the host's resources/blueprints/vendor/collections/classifieds/, which wins. Serving a collection's blueprint from an add-on needs the statamic/cms patch in UAMS-Web/patches-statamic-cms (statamic-blueprint-namespace-slash.patch, upstream statamic/cms#15881) until Statamic ships the fix.
  • The board's templates: classifieds/index, show, my_listings, post_form, _card and _listing, and the expiry notice emails/classifieds/listing-expired. They are added after the host's views, so a host copy of any of them wins.
  • The poster's pages under <classifieds site URL>/my-listings, named classifieds.listings.index, create, store, edit, update and destroy, registered ahead of Statamic's catch-all.
  • The classifieds-post and classifieds-edit rate limiters, keyed by account and then by address.
  • The live_classifieds query scope and the is_expired computed field, which share one definition of expiry.
  • The expiry job, UnpublishExpiredClassifieds, scheduled in the display timezone.

What the host keeps

The host owns the content and the pieces the board renders through:

  • the classifieds collection and the classified_categories taxonomy definitions, and the taxonomy's blueprint;
  • the site the pages belong to (inside_classifieds by default);
  • the images asset container the poster's uploads go to;
  • the fieldsets the blueprint imports (uamsweb_common and uamsweb_common_images) and the layout partials the templates render through (layout/article, layout/entry-content and page_builder/components/container_row);
  • the layout view (resources/views/layout.antlers.html), which Statamic renders every page template inside. classifieds/index, show, my_listings and post_form fill it through {{ template_content }}, so a host without one answers each of their pages with a 500 and View [layout] not found.;
  • the civil_date modifier, which classifieds/show and classifieds/my_listings format a listing's expiration date with. A host without it answers both pages with a 500 and Modifier [civil_date] not found, at render time and not at install.

A host that adopts the add-on removes its own copies of what the add-on now registers, in the same change that requires it: the my-listings route group in routes/web.php, the classifieds-post and classifieds-edit limiters, the expiry schedule in routes/console.php, the is_expired registration in the host's computed-properties provider, and the moved classes, views, config file and collection blueprint. Left in place they register twice, and Laravel refuses php artisan route:cache while two routes share a name. The host also carries uams-web/patches-statamic-cms (~1.1.0 for statamic/cms 6.40.0) before it deletes its blueprint copy, because only a root package's patches apply.

Configuration

The defaults merge under the classifieds config key. Publish them to change them:

php artisan vendor:publish --tag=aether-classifieds-config

listing_days, images, throttle and expiry are described in config/classifieds.php. site names the site the poster's pages belong to, and middleware lists what runs before them (by default statamic.web, then a redirect of a visitor who is not signed in to the front-end login page).

License

MIT. See LICENSE.

Development

Developing against a host application is covered in the development guide, and the Packagist and Marketplace steps in the submission checklist. The decisions behind the add-on are in docs/DECISIONS.md.