Implement launch blockers and MLS state filter

- Add MLS state filter for MN/IA only queries
- Add property inquiry form auto-population with read-only display
- Update broker info and office hours in footer
- Remove Bridge Realty text from about page
- Update service area to Minnesota and Iowa
- Add HomeProz listing identification (is_homeproz column)
- Add dynamic featured listings on front page
- Add gallery thumbnail preloading and loading spinners
- Update FEATURES_PENDING with completion status

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

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Hanson.xyz Dev
2025-12-16 13:07:12 -06:00
parent 15449b9131
commit 07a8d1756e
21 changed files with 680 additions and 91 deletions
@@ -11,9 +11,9 @@ class MLS_DB {
/**
* Schema version for index migrations
* Increment this when adding new indexes
* Increment this when adding new indexes or columns
*/
const SCHEMA_VERSION = 2;
const SCHEMA_VERSION = 3;
/**
* Get table name with prefix
@@ -126,6 +126,7 @@ class MLS_DB {
list_office_key VARCHAR(50) DEFAULT NULL,
list_office_mls_id VARCHAR(50) DEFAULT NULL,
list_office_name VARCHAR(150) DEFAULT NULL,
is_homeproz TINYINT(1) NOT NULL DEFAULT 0,
photos_count INT(5) DEFAULT 0,
modification_timestamp DATETIME NOT NULL,
@@ -332,8 +333,41 @@ class MLS_DB {
update_option('mls_schema_version', 2);
}
// Migration to schema version 3: Add is_homeproz column and index
if ($current_schema < 3) {
$table_properties = $wpdb->prefix . MLS_TABLE_PROPERTIES;
// Check if column exists
$column_exists = $wpdb->get_var($wpdb->prepare(
"SELECT COUNT(*) FROM INFORMATION_SCHEMA.COLUMNS
WHERE TABLE_SCHEMA = %s AND TABLE_NAME = %s AND COLUMN_NAME = 'is_homeproz'",
DB_NAME,
$table_properties
));
if (!$column_exists) {
$wpdb->query("ALTER TABLE {$table_properties} ADD COLUMN is_homeproz TINYINT(1) NOT NULL DEFAULT 0 AFTER list_office_name");
}
// Add index if not exists
$existing_indexes = self::get_existing_indexes($table_properties);
if (!isset($existing_indexes['idx_is_homeproz'])) {
$wpdb->query("ALTER TABLE {$table_properties} ADD INDEX idx_is_homeproz (is_homeproz)");
}
// Update existing HomeProz listings
if (defined('MLS_HOMEPROZ_OFFICE_ID')) {
$wpdb->query($wpdb->prepare(
"UPDATE {$table_properties} SET is_homeproz = 1 WHERE list_office_mls_id = %s",
MLS_HOMEPROZ_OFFICE_ID
));
}
update_option('mls_schema_version', 3);
}
// Future migrations go here:
// if ($current_schema < 3) { ... }
// if ($current_schema < 4) { ... }
}
/**