Skip to content

Releases: Comms-Church/comms-church-pco-tec

v1.3.1

Choose a tag to compare

@github-actions github-actions released this 19 Jul 16:44

Full Changelog: v1.3.0...v1.3.1

v1.3.0 — Quality Pass

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 02 Jul 12:58

v1.3.0 — Quality Pass

This release is a focused quality pass with no new features. Every change is a bug fix or structural improvement discovered during a full code audit.

Sync Engine (class-cctec-sync.php)

  • Ticket/price data (fetch_ticket_data) is now only fetched on actual creates and updates — previously it fired an extra PCO API call on every event including unchanged ones, adding hundreds of unnecessary requests per day on active calendars
  • Signup name map is now cached between sync passes — previously re-fetched from PCO on every calendar-mode sync
  • find_post_by_meta() replaces two near-identical duplicate methods
  • delete_stale() now explicitly excludes already-trashed posts from its query — previously it would re-trash them on every sync, inflating the deleted count and writing unnecessary DB rows
  • Registration URL now correctly uses new_registration_url in the calendar-mode name-match path (the registrations-only path was already correct since v1.1.1)
  • Venue creation unified into a single get_or_create_venue_from_attrs() path used by both sync modes
  • no_found_rows => true added to all get_posts() queries to skip unnecessary SQL COUNT
  • Dead code block removed from recurring instance handling
  • run() split into run_registrations() and run_calendar() for clarity

Image Sideloader (class-cctec-images.php)

  • Old featured image is now only deleted after the new download succeeds — previously a failed sideload would wipe the existing image with nothing to replace it

Shortcodes (class-cctec-shortcodes.php)

  • Auto-injected button is now suppressed when [pco_register] is already present in the page content — previously both would render, producing two buttons
  • All three button render paths ([pco_register], [pco_event_card], auto-inject) now share a single default_label() method that reads the cctec_register_label option — previously the event card ignored this setting
  • CSS enqueue check replaced tribe_is_event() with is_singular('tribe_events') for reliability across all themes

Plugin Bootstrap (comms-church-pco-tec.php)

  • cctec_delete_removed and cctec_register_label were never seeded on activation — fresh installs had no stored value, causing get_option() to return false. All 10 plugin options now use add_option() in activate(), which is a no-op on upgrades so existing settings are never overwritten
  • Custom cron interval cctec_every_6_hours moved from admin_init to a top-level add_filter('cron_schedules') — WP requires the interval to be registered on every load, not just in the admin, for scheduled events to fire correctly

Upgrade Notes

Drop-in replacement — no database changes, no settings reset. Existing synced events are unaffected.

Full Changelog: v1.2.2...v1.3.0

v1.2.2 - Page Builder Conflict Resolved

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 18 Jun 20:06

Resolved issue causing some page builders to override the register button.

Full Changelog: v1.2.1...v1.2.2

v1.2.1 - Auto-inject Register Now button on TEC single event pages

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 18 Jun 19:50

Hook tribe_events_single_event_after_the_content to automatically render a Register Now button after the event description, before Add to Calendar — no shortcode or template editing needed
Only renders when the event has a _pco_registration_url (i.e. was synced from PCO with a registration link)
Load front.css on all TEC single event pages, not just pages containing a shortcode
Add cctec_register_label setting to Display & Branding card for global button label control
Add .cctec-single-register wrapper with spacing tuned for the TEC single event layout

Full Changelog: v1.2.0...v1.2.1

v1.2.0 — Images & Registration Shortcodes

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 18 Jun 19:41

What's new
Event images from PCO

The plugin now pulls event header and logo images from Planning Center and saves them as WordPress featured images on each TEC event post. Images are only downloaded when PCO's URL changes — not on every sync — so it's efficient and won't flood your media library. Old images are automatically cleaned up when they're replaced.
New shortcodes
[pco_register id="42"]

Drops a styled Register Now button anywhere on your site — pages, posts, widgets, or inside TEC templates. Reads the registration URL directly from the synced event post. The id attribute is optional inside a TEC single-event context.
[pco_event_card id="42"]

A self-contained event card showing the featured image, title, date, venue, price range, description excerpt, and Register Now button. Every section can be toggled individually (show_image, show_date, show_location, show_price, show_desc).
Brand color setting

Settings → PCO Events Sync now has a Display & Branding section where you can set a global brand color for buttons and card accents. Can be overridden per-shortcode with color="#hex".

Shortcode reference
[pco_register id="42" label="Sign Up" color="#c0392b" new_tab="true"]

[pco_event_card id="42" show_desc="false" label="Reserve Your Spot" image_shape="square"]

Upgrade notes

The first sync after upgrading will attempt to sideload images for all existing events since the _pco_image_url meta won't exist yet. On a large calendar this may take longer than a normal sync. Use Sync Now rather than Force Full Re-sync for the first run. Image sideloading can be disabled under Settings → PCO Events Sync → Display & Branding if needed.

Full Changelog: v1.1.0...v1.2.0

v1.1.0

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 18 Jun 19:23

What's New

Sync Source Control

Choose what gets synced from Planning Center under Settings → PCO Events Sync → "What to Sync":

  • Registrations Only (default) — only events with a linked PCO Signup sync to your site. Recommended for most churches.
  • All Calendar Events — every future event from PCO Calendar, including recurring series.
  • Both — all calendar events with registration data always attempted.

Recurring Event Support

Events with multiple future instances are now grouped as a series using a shared taxonomy term, with per-post series index meta for theme display.

Date & Time Fix

Events were defaulting to today's date due to missing time fields required by The Events Calendar. All six date/time fields are now passed correctly on create and update.

Bug Fixes

  • Fixed memory exhaustion during sync caused by duplicating the included resource index onto every event instance
  • Fixed historical events (some dating to 2014) being pulled on every sync — now always filters to future instances only
  • Fixed registrations mode pulling zero events — was using include=event which the Registrations API does not support; corrected to include=next_signup_time,signup_location
  • Fixed ticket prices always storing as null — field name was amount_cents, correct field is price_cents
  • Fixed registration URL using wrong field — corrected to new_registration_url

Full Changelog: v1.0.1...v1.1.0

fix: resolve memory exhaustion during PCO sync

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 18 Jun 18:56

During sync, the included resource index (event name, location, etc.) was
being duplicated onto every event instance before caching, causing PHP to
exhaust its 512MB memory limit on large calendars. Additionally, historical
events dating back to 2014 were being pulled on every sync because the
future filter was never applied by default.

  • Build included resource index once per page instead of per instance
  • Always apply filter=future on event_instances endpoint

Full Changelog: v1.0.0...v1.0.1

v1.0.0

Choose a tag to compare

@AddisonRoberts AddisonRoberts released this 18 Jun 18:43