From 0ebbcfdb83b749793b1f1dc7631dbb9a7dd1c8c1 Mon Sep 17 00:00:00 2001 From: Chuck Scott Date: Tue, 25 Oct 2016 09:39:17 -0400 Subject: [PATCH] Added two general list options - Show member Logo for Mobile & Reagion Search Added Options to dataSettingsGeneral.php Updated database version in index.php Added new options to create_database Moved create_database and drop_database to V1.1.22 Updated dbVersions with new database version entry Updated view for Member List Options to include new options --- classes/data/settings/dataSettingsGeneral.php | 17 +++++++++++++- index.php | 2 +- ...1.1.21.sql => create_database_V1.1.22.sql} | 2 ++ setup/databaseScripts/dbVersions.php | 3 ++- ..._V1.1.21.sql => drop_database_V1.1.22.sql} | 0 .../update_database_V1.1.22.sql | 22 +++++++++++++++++++ views/admin/management/index.html | 2 ++ 7 files changed, 45 insertions(+), 3 deletions(-) rename setup/databaseScripts/{create_database_V1.1.21.sql => create_database_V1.1.22.sql} (99%) rename setup/databaseScripts/{drop_database_V1.1.21.sql => drop_database_V1.1.22.sql} (100%) create mode 100644 setup/databaseScripts/update_database_V1.1.22.sql diff --git a/classes/data/settings/dataSettingsGeneral.php b/classes/data/settings/dataSettingsGeneral.php index c7f8cb58..b815811f 100644 --- a/classes/data/settings/dataSettingsGeneral.php +++ b/classes/data/settings/dataSettingsGeneral.php @@ -298,6 +298,14 @@ class GlmDataSettingsGeneral extends GlmDataAbstract 'use' => 'a' ), + // Front-end Listings - Show Search Amenities + 'list_show_search_region' => array( + 'field' => 'list_show_search_region', + 'type' => 'checkbox', + 'default' => false, + 'use' => 'a' + ), + // Front-end Listings - Show Search Alpha 'list_show_search_alpha' => array( 'field' => 'list_show_search_alpha', @@ -340,6 +348,13 @@ class GlmDataSettingsGeneral extends GlmDataAbstract 'use' => 'a' ), + // Front-end Listings - Show Logo for Mobile + 'list_logo_for_mobile' => array( + 'field' => 'list_logo_for_mobile', + 'type' => 'checkbox', + 'use' => 'a' + ), + // Front-end Listings - Show Logo Filler 'list_show_logo_filler' => array( 'field' => 'list_show_logo_filler', @@ -490,7 +505,7 @@ class GlmDataSettingsGeneral extends GlmDataAbstract 'default' => false, 'use' => 'a' ), - + // Front-end Member List - Show Live Cam 'list_show_live_cam' => array( 'field' => 'list_show_live_cam', diff --git a/index.php b/index.php index c78a12db..3bfe60fb 100644 --- a/index.php +++ b/index.php @@ -39,7 +39,7 @@ */ define('GLM_MEMBERS_PLUGIN_VERSION', '2.8.0'); -define('GLM_MEMBERS_PLUGIN_DB_VERSION', '1.1.21'); +define('GLM_MEMBERS_PLUGIN_DB_VERSION', '1.1.22'); // Check if plugin version is not current in WordPress option and if needed updated it if (GLM_MEMBERS_PLUGIN_VERSION != get_option('glmMembersDatabasePluginVersion')) { diff --git a/setup/databaseScripts/create_database_V1.1.21.sql b/setup/databaseScripts/create_database_V1.1.22.sql similarity index 99% rename from setup/databaseScripts/create_database_V1.1.21.sql rename to setup/databaseScripts/create_database_V1.1.22.sql index 3366e099..62a437ec 100644 --- a/setup/databaseScripts/create_database_V1.1.21.sql +++ b/setup/databaseScripts/create_database_V1.1.22.sql @@ -278,12 +278,14 @@ CREATE TABLE {prefix}settings_general ( list_show_search_text BOOLEAN DEFAULT '1', list_show_search_category BOOLEAN DEFAULT '1', list_show_search_amenities BOOLEAN DEFAULT '1', + list_show_search_region BOOLEAN DEFAULT '1', list_show_search_alpha BOOLEAN DEFAULT '1', list_floating_search BOOLEAN DEFAULT '0', list_floating_search_distance_top INTEGER DEFAULT '0', -- How far from the top the sticky Search/Filters box should hover list_show_detail_link BOOLEAN DEFAULT '1', list_show_logo BOOLEAN DEFAULT '1', list_logo_size TINYTEXT NULL, + list_logo_for_mobile BOOLEAN DEFAULT '1', list_show_address BOOLEAN DEFAULT '1', list_show_street BOOLEAN DEFAULT '1', list_show_citystatezip BOOLEAN DEFAULT '1', diff --git a/setup/databaseScripts/dbVersions.php b/setup/databaseScripts/dbVersions.php index 6335ec4f..6a88ebe2 100644 --- a/setup/databaseScripts/dbVersions.php +++ b/setup/databaseScripts/dbVersions.php @@ -52,7 +52,8 @@ $glmMembersDbVersions = array( '1.1.18' => array('version' => '1.1.18', 'tables' => 18, 'date' => '9/16/16'), '1.1.19' => array('version' => '1.1.19', 'tables' => 18, 'date' => '9/20/16'), '1.1.20' => array('version' => '1.1.20', 'tables' => 18, 'date' => '10/18/16'), - '1.1.21' => array('version' => '1.1.21', 'tables' => 18, 'date' => '10/20/16') + '1.1.21' => array('version' => '1.1.21', 'tables' => 18, 'date' => '10/20/16'), + '1.1.22' => array('version' => '1.1.22', 'tables' => 18, 'date' => '10/25/16') ); diff --git a/setup/databaseScripts/drop_database_V1.1.21.sql b/setup/databaseScripts/drop_database_V1.1.22.sql similarity index 100% rename from setup/databaseScripts/drop_database_V1.1.21.sql rename to setup/databaseScripts/drop_database_V1.1.22.sql diff --git a/setup/databaseScripts/update_database_V1.1.22.sql b/setup/databaseScripts/update_database_V1.1.22.sql new file mode 100644 index 00000000..da6350e3 --- /dev/null +++ b/setup/databaseScripts/update_database_V1.1.22.sql @@ -0,0 +1,22 @@ +-- Gaslight Media Members Database +-- File Created: 10/25/16 10:14:00 +-- Database Version: 1.1.22 +-- Database Update From Previous Version Script +-- +-- To permit each query below to be executed separately, +-- all queries must be separated by a line with four dashes +-- Sets which character to use to separate phone numbers + +ALTER TABLE {prefix}settings_general ADD COLUMN list_show_search_region BOOLEAN NULL; + +---- + +UPDATE {prefix}settings_general SET list_show_search_region = true; + +---- + +ALTER TABLE {prefix}settings_general ADD COLUMN list_logo_for_mobile BOOLEAN NULL; + +---- + +UPDATE {prefix}settings_general SET list_logo_for_mobile = true; diff --git a/views/admin/management/index.html b/views/admin/management/index.html index 5c1d0f90..fae4d30e 100644 --- a/views/admin/management/index.html +++ b/views/admin/management/index.html @@ -183,6 +183,7 @@ Show Member Name as Link to Detail: List Header Text: Show Member Logo: + Show Member Logo for Mobile: Logo Size: @@ -278,6 +279,7 @@ Show Search Form:Text Search: Category Search: Amenities Search: + Regions Search: Show Alpha Index: Filter Box Opened by Default: Floating Search Box: -- 2.17.1