Profile search now matches username, not full profile URL #60
3 changed files with 9 additions and 1 deletions
|
@ -69,7 +69,7 @@ class Search extends BaseController
|
|||
}
|
||||
|
||||
} else {
|
||||
$sql_where = "MATCH (p.`name`, p.`pdesc`, p.`profile_url`, p.`locality`, p.`region`, p.`country`, p.`tags` )
|
||||
$sql_where = "MATCH (p.`name`, p.`pdesc`, p.`username`, p.`locality`, p.`region`, p.`country`, p.`tags` )
|
||||
AGAINST (:query IN BOOLEAN MODE)";
|
||||
}
|
||||
|
||||
|
|
4
src/sql/migrations/down/0007.sql
Normal file
4
src/sql/migrations/down/0007.sql
Normal file
|
@ -0,0 +1,4 @@
|
|||
BEGIN;
|
||||
ALTER TABLE `profile` DROP KEY `profile-ft`;
|
||||
ALTER TABLE `profile` ADD FULLTEXT KEY `profile-ft` (`name`, `pdesc`, `profile_url`, `locality`, `region`, `country`);
|
||||
COMMIT;
|
4
src/sql/migrations/up/0008.sql
Normal file
4
src/sql/migrations/up/0008.sql
Normal file
|
@ -0,0 +1,4 @@
|
|||
BEGIN;
|
||||
ALTER TABLE `profile` DROP KEY `profile-ft`;
|
||||
ALTER TABLE `profile` ADD FULLTEXT KEY `profile-ft` (`name`, `pdesc`, `username`, `locality`, `region`, `country`);
|
||||
COMMIT;
|
Loading…
Reference in a new issue