- Remove hardcoded template override in class-hvac-community-events.php forcing old shortcode-based template - Update dashboard to use refactored page-trainer-dashboard.php template with proper WordPress integration - Fix navigation menu rendering by removing conflicting HVAC_NAV_RENDERED constant checks - Add missing hvac-menu-system.css file to resolve navigation styling - Update deployment script to automatically assign correct page template - Clean up template files to use consistent navigation rendering approach - Update documentation with dashboard refactoring details The dashboard now displays correctly with working navigation across all trainer pages. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
		
			
				
	
	
		
			45 lines
		
	
	
		
			No EOL
		
	
	
		
			1.5 KiB
		
	
	
	
		
			Bash
		
	
	
		
			Executable file
		
	
	
	
	
			
		
		
	
	
			45 lines
		
	
	
		
			No EOL
		
	
	
		
			1.5 KiB
		
	
	
	
		
			Bash
		
	
	
		
			Executable file
		
	
	
	
	
| #!/bin/bash
 | |
| 
 | |
| # Fix Dashboard Template Assignment
 | |
| # This script ensures the dashboard page uses the correct page template
 | |
| 
 | |
| source .env
 | |
| 
 | |
| echo "=== Fixing Dashboard Template Assignment ==="
 | |
| echo "Target: Staging Server"
 | |
| 
 | |
| # SSH into staging and update the page template
 | |
| ssh -o StrictHostKeyChecking=no "${UPSKILL_STAGING_SSH_USER}@${UPSKILL_STAGING_IP}" << 'EOF'
 | |
| cd /home/974670.cloudwaysapps.com/uberrxmprk/public_html
 | |
| 
 | |
| echo "Finding dashboard page..."
 | |
| wp post list --post_type=page --name=dashboard --field=ID --path=/home/974670.cloudwaysapps.com/uberrxmprk/public_html
 | |
| 
 | |
| echo "Updating dashboard page template..."
 | |
| # Find the page ID
 | |
| PAGE_ID=$(wp post list --post_type=page --name=dashboard --field=ID --path=/home/974670.cloudwaysapps.com/uberrxmprk/public_html | head -1)
 | |
| 
 | |
| if [ ! -z "$PAGE_ID" ]; then
 | |
|     echo "Found page ID: $PAGE_ID"
 | |
|     
 | |
|     # Update the template
 | |
|     wp post meta update $PAGE_ID _wp_page_template templates/page-trainer-dashboard.php --path=/home/974670.cloudwaysapps.com/uberrxmprk/public_html
 | |
|     
 | |
|     echo "Template updated to: templates/page-trainer-dashboard.php"
 | |
|     
 | |
|     # Verify the update
 | |
|     echo "Verifying template assignment..."
 | |
|     wp post meta get $PAGE_ID _wp_page_template --path=/home/974670.cloudwaysapps.com/uberrxmprk/public_html
 | |
|     
 | |
|     # Clear cache
 | |
|     echo "Clearing cache..."
 | |
|     wp cache flush --path=/home/974670.cloudwaysapps.com/uberrxmprk/public_html
 | |
|     
 | |
|     echo "✅ Dashboard template fixed!"
 | |
| else
 | |
|     echo "❌ Dashboard page not found!"
 | |
| fi
 | |
| 
 | |
| EOF
 | |
| 
 | |
| echo "=== Template Fix Complete ===" |