projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
dd99ab2
)
DataObjects/Core_company.php
author
Edward
<edward@roojs.com>
Thu, 8 Nov 2018 06:34:04 +0000
(14:34 +0800)
committer
Edward
<edward@roojs.com>
Thu, 8 Nov 2018 06:34:04 +0000
(14:34 +0800)
DataObjects/Core_company.php
patch
|
blob
|
history
diff --git
a/DataObjects/Core_company.php
b/DataObjects/Core_company.php
index
d6c2787
..
d352d55
100644
(file)
--- a/
DataObjects/Core_company.php
+++ b/
DataObjects/Core_company.php
@@
-104,13
+104,14
@@
class Pman_Core_DataObjects_Core_Company extends DB_DataObject
) as comptype_display_name
");
) as comptype_display_name
");
- if(!empty($q['query']['name'])){
- $s = $this->escape($q['query']['name']);
+ if(!empty($q['query']['name']) || !empty($q['search']['name'])){
+
+ $s = (!empty($q['query']['name'])) ? $this->escape($q['query']['name']) : $this->escape($q['search']['name']);
$this->whereAdd("
{$tn}.name LIKE '%$s%'
");
}
$this->whereAdd("
{$tn}.name LIKE '%$s%'
");
}
- if(
!empty($q['search']['name'])
){
+ if(){
$s = $this->escape($q['search']['name']);
$this->whereAdd("
{$tn}.name LIKE '%$s%'
$s = $this->escape($q['search']['name']);
$this->whereAdd("
{$tn}.name LIKE '%$s%'