Skip to content
Permalink
Browse files

Merge pull request #618 from directman66/patch-20

Update settings_search.inc.php
  • Loading branch information...
sergejey committed Aug 30, 2019
2 parents aedb5a1 + bf631e5 commit 96dd6a2f5224ffff80bb40c30ec8e5dc4463e0e0
Showing with 16 additions and 2 deletions.
  1. +16 −2 modules/settings/settings_search.inc.php
@@ -41,7 +41,7 @@
'GENERAL_ALICE_NAME'=>'Computer\'s name'
);
foreach($options as $k=>$v) {
$tmp=SQLSelectOne("SELECT ID FROM settings WHERE NAME LIKE '".$k."'");
$tmp=SQLSelectOne("SELECT ID FROM settings WHERE NAME LIKE '".$k."'");
if (!$tmp['ID']) {
$tmp=array();
$tmp['NAME']=$k;
@@ -242,7 +242,16 @@
if ($this->section_title!='') {
$out['SECTION_TITLE']=$this->section_title;
}
if (($this->filter_name=='') and ($this->name=='settings')) {
$qry.=" and NAME IN('APP_CALENDAR_SOONLIMIT','APP_CALENDAR_SHOWDONE','SCENES_WIDTH','SCENES_HEIGHT','VOICE_LANGUAGE','THEME','SPEAK_SIGNAL','HOOK_BEFORE_SAY',
'HOOK_AFTER_SAY','BACKUP_PATH', 'GENERAL_ALICE_NAME','SITE_TIMEZONE','TTS_GOOGLE','SITE_LANGUAGE','HOOK_EVENT_SAY','HOOK_EVENT_HOURLY',
'HOOK_BARCODE', 'HOOK_PLAYMEDIA','HOOK_BEFORE_PLAYSOUND','HOOK_AFTER_PLAYSOUND','HOOK_EVENT_COMMAND','HOOK_EVENT_SAYREPLY','HOOK_EVENT_SAYTO''HOOK_EVENT_ASK')";
}
// QUERY READY
// QUERY READY
@@ -276,7 +285,12 @@
// SEARCH RESULTS
// SEARCH RESULTS
$res=SQLSelect("SELECT * FROM settings WHERE $qry ORDER BY $sortby");
$sql="SELECT * FROM settings WHERE $qry ORDER BY $sortby";
$res=SQLSelect($sql);
debmes($sql,'settings');
if ($res[0]['ID']) {
$total=count($res);
for($i=0;$i<$total;$i++) {

0 comments on commit 96dd6a2

Please sign in to comment.
You can’t perform that action at this time.