fix: correct TEC shortcode format for event editing form population

- Update includes/class-hvac-shortcodes.php:277 to use [tribe_community_events view="submission_form"]
- Update templates/page-manage-event.php:83 to use correct TEC shortcode format
- Fixes issue where event edit forms appeared blank instead of populated with existing data
- TEC submission_form view automatically detects event_id URL parameters for editing
- Enables proper event creation and editing functionality for trainers

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Ben 2025-08-11 19:42:30 -03:00
parent 98cbe83813
commit 71d25e2023
2 changed files with 5 additions and 4 deletions

View file

@ -272,8 +272,9 @@ class HVAC_Shortcodes {
return '<p>' . __('Event management requires The Events Calendar Community Events add-on.', 'hvac-community-events') . '</p>';
}
// Return the tribe shortcode
return '[tribe_community_events]';
// Return the tribe shortcode with view parameter for submission form
// This enables both new event creation and existing event editing
return '[tribe_community_events view="submission_form"]';
}
/**

View file

@ -79,8 +79,8 @@ get_header();
echo do_shortcode($raw_content);
endwhile;
else:
// Fallback - show the shortcode directly
echo do_shortcode('[tribe_community_events]');
// Fallback - show the shortcode directly with submission form view
echo do_shortcode('[tribe_community_events view="submission_form"]');
endif;
?>
</div>