Skip to content

Move legacy SimplyRETS page management into settings - #306

Merged
CodyReichert merged 1 commit into
codex_admin-settings-uifrom
codex_legacy-pages-transition
Oct 10, 2026
Merged

CodyReichert merged 1 commit into
codex_admin-settings-uifrom
codex_legacy-pages-transition

Conversation

@CodyReichert

Copy link
Copy Markdown
Member

Overview

New installations should use SimplyRETS shortcodes on ordinary WordPress pages. This first deprecation phase hides the legacy SimplyRETS page editor from the admin sidebar while keeping existing pages accessible and supported.

  • Hide only the sr-listings sidebar menu. Keep the registered post type, management/edit screens, creation through existing screens, saved pages, filters, templates, URLs, and shared listing-detail/search/open-house routing and rendering.
  • Add Legacy Pages near the bottom of the redesigned settings navigation, with deprecation guidance, a shortcode example, documentation, and Manage existing pages.
  • Show the tab and transition notice only when persisted legacy pages exist and the current user has both settings and page-editing permissions. Published, scheduled, pending, draft, private, and trashed pages count; automatic drafts and synthesized dynamic posts do not.
  • Add a nonce-protected dismissible transition notice linking directly to the tab. Dismissal persists per user and site, including on multisite, without requiring activation hooks during updates.
  • Support direct section links and retain the no-JavaScript fallback.

This phase does not convert or delete pages, remove editor/rendering internals, disable legacy page creation, or change frontend behavior.

Dependent base

Targets codex_admin-settings-ui, which contains the admin redesign in #305. After that PR merges, retarget this PR to master. The redesign branch and master were not modified by this work.

Validation

  • Added nine regression cases in src/tests/test-legacy-pages.php.
  • Ran those cases against the local WordPress APIs with a supplemental smoke harness: all nine passed. Disposable posts/users were cleaned up.
  • PHP lint, JavaScript syntax, and git diff --check passed.
  • Verified desktop/mobile layout, notice-to-tab navigation, safe fallback when legacy pages are absent, persistent notice dismissal through the real endpoint, and access to the management list and editor. Both legacy meta boxes remain present.
  • PHPUnit and its WordPress test library are unavailable locally; the PHPUnit suite itself was not run. Older PHP/WordPress runtimes, multisite runtime behavior, additional themes, and full frontend rendering were not tested.
  • The editor displays an existing warning in unchanged src/simply-rets-post-pages.php:460 when reading an ID from a null queried object; this PR leaves that unrelated code unchanged.

Screenshots

Captured with a disposable legacy draft on the local WordPress site using OceanWP. The draft was removed after verification. Images are documentation assets outside the installable plugin source.

Desktop

Legacy Pages desktop

Mobile

Legacy Pages mobile

@CodyReichert CodyReichert added merge This PR can be merged by a maintainer documentation The addresses or improves documentation labels Oct 6, 2026
@CodyReichert CodyReichert self-assigned this Oct 6, 2026
@CodyReichert
CodyReichert added this pull request to stack #307 October 6, 2026 17:13
@CodyReichert
CodyReichert force-pushed the codex_legacy-pages-transition branch from cb4ceab to 1344bbb Compare October 7, 2026 00:34
@CodyReichert
CodyReichert merged commit e368a10 into master Oct 10, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation The addresses or improves documentation merge This PR can be merged by a maintainer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant