From: Steve Sutton Date: Thu, 9 Aug 2018 17:51:33 +0000 (-0400) Subject: Order the options by how they were added. X-Git-Url: http://cvs2.gaslightmedia.com/gitweb/index.cgi?a=commitdiff_plain;h=aea84a32fc71efc8dc0c107b142786fd08bf6b08;p=WP-Plugins%2Fglm-member-db-fields.git Order the options by how they were added. Use id for order by. --- diff --git a/models/admin/entity/fields.php b/models/admin/entity/fields.php index ea4f9f4..910bea1 100644 --- a/models/admin/entity/fields.php +++ b/models/admin/entity/fields.php @@ -187,7 +187,7 @@ class GlmMembersAdmin_entity_fields extends GlmDataFieldsCustomFields "SELECT * FROM " . GLM_MEMBERS_FIELDS_PLUGIN_DB_PREFIX . "custom_field_options WHERE field_id = %d - ORDER BY option_text", + ORDER BY id", $field['id'] ), ARRAY_A diff --git a/models/admin/management/fields.php b/models/admin/management/fields.php index d0c7588..a727387 100644 --- a/models/admin/management/fields.php +++ b/models/admin/management/fields.php @@ -430,7 +430,7 @@ class GlmMembersAdmin_management_fields extends GlmDataFieldsCustomFields "SELECT * FROM " . GLM_MEMBERS_FIELDS_PLUGIN_DB_PREFIX . "custom_field_options WHERE field_id = %d - ORDER BY option_text", + ORDER BY id", $field['id'] ), ARRAY_A diff --git a/setup/adminHooks.php b/setup/adminHooks.php index 053d3cf..3c08f3b 100644 --- a/setup/adminHooks.php +++ b/setup/adminHooks.php @@ -151,7 +151,7 @@ $parts = array(); "SELECT * FROM " . GLM_MEMBERS_FIELDS_PLUGIN_DB_PREFIX . "custom_field_options WHERE field_id = %d - ORDER BY option_text", + ORDER BY id", $field['id'] ), ARRAY_A