32
1
mirror of https://github.com/joomla-extensions/weblinks.git synced 2024-12-26 18:10:11 +00:00

Replace deprecated castAsChar with castAs

This commit is contained in:
Tuan Pham Ngoc 2021-07-17 11:58:17 +07:00
parent 01bc443bc0
commit 8b9d34ca7d
3 changed files with 6 additions and 6 deletions

View File

@ -70,7 +70,7 @@ class WeblinksHelper
$case_when1 = ' CASE WHEN ';
$case_when1 .= $query->charLength('a.alias', '!=', '0');
$case_when1 .= ' THEN ';
$a_id = $query->castAsChar('a.id');
$a_id = $query->castAs('CHAR', 'a.id');
$case_when1 .= $query->concatenate(array($a_id, 'a.alias'), ':');
$case_when1 .= ' ELSE ';
$case_when1 .= $a_id . ' END as slug';
@ -78,7 +78,7 @@ class WeblinksHelper
$case_when2 = ' CASE WHEN ';
$case_when2 .= $query->charLength('c.alias', '!=', '0');
$case_when2 .= ' THEN ';
$c_id = $query->castAsChar('c.id');
$c_id = $query->castAs('CHAR', 'c.id');
$case_when2 .= $query->concatenate(array($c_id, 'c.alias'), ':');
$case_when2 .= ' ELSE ';
$case_when2 .= $c_id . ' END as catslug';

View File

@ -337,7 +337,7 @@ class PlgFinderWeblinks extends Adapter
$case_when_item_alias = ' CASE WHEN ';
$case_when_item_alias .= $query->charLength('a.alias', '!=', '0');
$case_when_item_alias .= ' THEN ';
$a_id = $query->castAsChar('a.id');
$a_id = $query->castAs('CHAR', 'a.id');
$case_when_item_alias .= $query->concatenate(array($a_id, 'a.alias'), ':');
$case_when_item_alias .= ' ELSE ';
$case_when_item_alias .= $a_id . ' END as slug';
@ -346,7 +346,7 @@ class PlgFinderWeblinks extends Adapter
$case_when_category_alias = ' CASE WHEN ';
$case_when_category_alias .= $query->charLength('c.alias', '!=', '0');
$case_when_category_alias .= ' THEN ';
$c_id = $query->castAsChar('c.id');
$c_id = $query->castAs('CHAR', 'c.id');
$case_when_category_alias .= $query->concatenate(array($c_id, 'c.alias'), ':');
$case_when_category_alias .= ' ELSE ';
$case_when_category_alias .= $c_id . ' END as catslug';

View File

@ -180,7 +180,7 @@ class PlgSearchWeblinks extends CMSPlugin
$case_when = ' CASE WHEN ';
$case_when .= $query->charLength('a.alias', '!=', '0');
$case_when .= ' THEN ';
$a_id = $query->castAsChar('a.id');
$a_id = $query->castAs('CHAR', 'a.id');
$case_when .= $query->concatenate(array($a_id, 'a.alias'), ':');
$case_when .= ' ELSE ';
$case_when .= $a_id . ' END as slug';
@ -188,7 +188,7 @@ class PlgSearchWeblinks extends CMSPlugin
$case_when1 = ' CASE WHEN ';
$case_when1 .= $query->charLength('c.alias', '!=', '0');
$case_when1 .= ' THEN ';
$c_id = $query->castAsChar('c.id');
$c_id = $query->castAs('CHAR', 'c.id');
$case_when1 .= $query->concatenate(array($c_id, 'c.alias'), ':');
$case_when1 .= ' ELSE ';
$case_when1 .= $c_id . ' END as catslug';