diff --git a/livesupport/modules/htmlUI/var/formmask/general.inc.php b/livesupport/modules/htmlUI/var/formmask/general.inc.php
index 4a37d2857..c0d7f8597 100755
--- a/livesupport/modules/htmlUI/var/formmask/general.inc.php
+++ b/livesupport/modules/htmlUI/var/formmask/general.inc.php
@@ -26,7 +26,7 @@ $ui_fmask = array(
),
array(
'rule' => 'nopunctuation',
- 'element' => 'maxfilesize',
+ 'element' => 'stationMaxfilesize',
),
array(
'element' => 'stationFrequency',
@@ -327,7 +327,7 @@ $ui_fmask = array(
array(
'element' => 'act',
'type' => 'hidden',
- 'constant' => 'SEARCH.newsearch'
+ 'constant' => 'SEARCH.newSearch'
),
array(
'element' => 'id',
@@ -429,8 +429,97 @@ $ui_fmask = array(
)
)
),
+ 'browse' => array(
+ array(
+ 'element' => 'act',
+ 'type' => 'hidden',
+ ),
+ array(
+ 'element' => 'id',
+ 'type' => 'hidden'
+ ),
+ 'form' => array(
+ 'element' => 'col',
+ 'type' => 'hidden'
+ ),
+ 'category' => array(
+ 'element' => 'category',
+ 'type' => 'select',
+ 'label' => 'Category',
+ 'attributes'=> array('onChange' => 'this.form.act.value="BROWSE.setCategory"; this.form.submit()')
+ ),
+ 'value' => array(
+ 'element' => 'value',
+ 'type' => 'select',
+ 'multiple' => TRUE,
+ 'attributes'=> array(
+ 'size' => 10,
+ 'STYLE' => 'width: 220px',
+ 'onChange' => 'this.form.act.value="BROWSE.setValue"; this.form.submit()')
+ )
+ /*
+ array(
+ 'element' => 'operator',
+ 'type' => 'select',
+ 'label' => 'Operator',
+ 'options' => array(
+ 'or' => 'Or',
+ 'and' => 'And',
+ )
+ ),
+ array(
+ 'element' => 'filetype',
+ 'type' => 'select',
+ 'label' => 'Filetype',
+ 'options' => array(
+ 'File' => '*',
+ 'audioclip' => 'Audioclip',
+ 'webstream' => 'Webstream',
+ 'playlist' => 'Playlist'
+ )
+ ),
+ array(
+ 'element' => 'limit',
+ 'type' => 'select',
+ 'label' => 'Rows per Page',
+ 'options' => array(
+ 1 => 1,
+ 5 => 5,
+ 10 => 10,
+ 25 => 25,
+ 50 => 50,
+ 100 => 100
+ )
+ ),
+ array(
+ 'element' => 'clear',
+ 'type' => 'button',
+ 'label' => 'Clear',
+ 'attributes' => array('onClick' => "this.form.reset(); hpopup('".UI_HANDLER."?act=SEARCH.clear', 'SF')"),
+ 'groupit' => TRUE,
+ ),
+ array(
+ 'element' => 'addrow',
+ 'type' => 'button',
+ 'label' => 'One more Row',
+ 'attributes' => array('onClick' => 'SearchForm_addRow()'),
+ 'groupit' => TRUE,
+ ),
+ array(
+ 'element' => 'submit',
+ 'type' => 'submit',
+ 'label' => 'Submit',
+ 'groupit' => TRUE,
+ ),
+ array('group' => array('clear', 'addrow', 'submit')
+ ), */
+ ),
'PL.changeTransition' => array(
'transition' => array(
+ array(
+ 'element' => 'headline',
+ 'type' => 'static'
+ ),
array(
'element' => 'type',
'type' => 'radio',
@@ -443,6 +532,10 @@ $ui_fmask = array(
)
),
'fadeIn' => array(
+ array(
+ 'element' => 'headline',
+ 'type' => 'static'
+ ),
array(
'element' => 'type',
'type' => 'radio',
@@ -452,13 +545,17 @@ $ui_fmask = array(
)
),
'fadeOut' => array(
- array(
+ array(
+ 'element' => 'headline',
+ 'type' => 'static'
+ ),
+ array(
'element' => 'type',
'type' => 'radio',
'label' => 'Type',
'options' => array('fadeOut' => 'Fade out'),
'default' => 'fadeOut'
- )
+ )
),
'all' => array(
array(
diff --git a/livesupport/modules/htmlUI/var/html/ui_browser.php b/livesupport/modules/htmlUI/var/html/ui_browser.php
index 9531bcd08..461b2f789 100644
--- a/livesupport/modules/htmlUI/var/html/ui_browser.php
+++ b/livesupport/modules/htmlUI/var/html/ui_browser.php
@@ -55,6 +55,7 @@ if ($uiBrowser->userid) {
$Smarty->assign('SCRATCHPAD', $uiBrowser->SCRATCHPAD->get());
$Smarty->assign('PLid', $uiBrowser->PLAYLIST->activeId);
$Smarty->register_object('PL', $uiBrowser->PLAYLIST);
+ $Smarty->register_object('BROWSE', $uiBrowser->BROWSE);
switch ($_REQUEST['act']){
case "fileBrowse":
@@ -105,15 +106,27 @@ if ($uiBrowser->userid) {
case "SEARCH":
+ if (is_array($uiBrowser->SEARCH->criteria['form']) ){
+ $Smarty->assign('searchResults', $uiBrowser->SEARCH->results);
+ $Smarty->assign('showSearchResults', TRUE);
+ };
+
+ $Smarty->assign('searchForm', $uiBrowser->SEARCH->form($uiBrowser->id, $ui_fmask));
+ $Smarty->assign('showLibrary', TRUE);
+
+ break;
+
+ case "BROWSE":
+ /*
if (is_array($uiBrowser->SEARCH->criteria) ){
$Smarty->assign('searchres', $uiBrowser->SEARCH->results);
$Smarty->assign('showSearchRes', TRUE);
- };
+ }; */
- $Smarty->assign('searchform', $uiBrowser->SEARCH->form($uiBrowser->id, $ui_fmask));
- $Smarty->assign('showSearchForm', TRUE);
+ $Smarty->assign('browseForm', $uiBrowser->BROWSE->browseForm($uiBrowser->id, $ui_fmask));
+ $Smarty->assign('showLibrary', TRUE);
- break;
+ break;
case "subjects":
case "addUser":
@@ -159,9 +172,10 @@ if ($uiBrowser->userid) {
break;
case "PL.simpleManagement":
- if ($_REQUEST['createNew']) {
- $uiBrowser->PLAYLIST->testNew();
- #$Smarty->assign('PLAYLIST', $uiBrowser->PLAYLIST->get());
+ if ($uiBrowser->PLAYLIST->get() === FALSE) {
+ if (($ui_tmpid = $uiBrowser->PLAYLIST->create($_REQUEST['id'])) !== FALSE) {
+ $uiBrowser->SCRATCHPAD->addItem($ui_tmpid);
+ }
}
$Smarty->assign('PL_simpleManagement', TRUE);
break;
diff --git a/livesupport/modules/htmlUI/var/html/ui_handler.php b/livesupport/modules/htmlUI/var/html/ui_handler.php
index 3a724ab6d..5e77a936d 100644
--- a/livesupport/modules/htmlUI/var/html/ui_handler.php
+++ b/livesupport/modules/htmlUI/var/html/ui_handler.php
@@ -131,8 +131,8 @@ switch($_REQUEST['act']){
$uiHandler->SCRATCHPAD->setReload();
break;
- case "SEARCH.newsearch":
- $uiHandler->SEARCH->newsearch($_REQUEST);
+ case "SEARCH.newSearch":
+ $uiHandler->SEARCH->newSearch($_REQUEST);
break;
case "SEARCH.reOrder":
@@ -147,6 +147,14 @@ switch($_REQUEST['act']){
$uiHandler->SEARCH->setOffset($_REQUEST['page']);
break;
+ case "BROWSE.setCategory":
+ $uiHandler->BROWSE->setCategory($_REQUEST);
+ break;
+
+ case "BROWSE.setValue":
+ $uiHandler->BROWSE->setValue($_REQUEST);
+ break;
+
case "PL.activate":
$uiHandler->PLAYLIST->setReload();
if ($uiHandler->PLAYLIST->activate($_REQUEST['id']) === TRUE) {
@@ -177,6 +185,11 @@ switch($_REQUEST['act']){
$uiHandler->PLAYLIST->setReload();
break;
+ case "PL.save":
+ $uiHandler->PLAYLIST->save();
+ $uiHandler->PLAYLIST->setReload();
+ break;
+
case "PL.revert":
$uiHandler->PLAYLIST->revert();
$uiHandler->PLAYLIST->setReload();
diff --git a/livesupport/modules/htmlUI/var/templates/masterpanel.tpl b/livesupport/modules/htmlUI/var/templates/masterpanel.tpl
index 30e479682..6b4b0b203 100755
--- a/livesupport/modules/htmlUI/var/templates/masterpanel.tpl
+++ b/livesupport/modules/htmlUI/var/templates/masterpanel.tpl
@@ -20,8 +20,8 @@
{include file="fileBrowse/fileBrowse.tpl"}
{/if}
-{if ($showSearchForm || $showSearchRes)}
- {include file="search/search.tpl"}
+{if $showLibrary}
+ {include file="library/main.tpl"}
{/if}
{if $showSubjects}
@@ -44,7 +44,7 @@
{include file="changeStationPrefs.tpl"}
{/if}
-{if $PL_simpleManagement}
+{if $PL_simpleManagement}
{include file="playlist/simpleManagement.tpl"}
{/if}
diff --git a/livesupport/modules/htmlUI/var/templates/menu_top.tpl b/livesupport/modules/htmlUI/var/templates/menu_top.tpl
index 2e0536e27..9e8bd721b 100755
--- a/livesupport/modules/htmlUI/var/templates/menu_top.tpl
+++ b/livesupport/modules/htmlUI/var/templates/menu_top.tpl
@@ -6,6 +6,7 @@
[PL Editor]
[Create new folder]
[Search]
+ [Browse]
{tra 0='[User/Groups]'}
[StationPrefs]
diff --git a/livesupport/modules/htmlUI/var/templates/playlist/editor.tpl b/livesupport/modules/htmlUI/var/templates/playlist/editor.tpl
index eeb4af445..ee950187d 100755
--- a/livesupport/modules/htmlUI/var/templates/playlist/editor.tpl
+++ b/livesupport/modules/htmlUI/var/templates/playlist/editor.tpl
@@ -31,6 +31,6 @@
- |
+ |
|
diff --git a/livesupport/modules/htmlUI/var/templates/search/browseForm.tpl b/livesupport/modules/htmlUI/var/templates/search/browseForm.tpl
new file mode 100755
index 000000000..158d38223
--- /dev/null
+++ b/livesupport/modules/htmlUI/var/templates/search/browseForm.tpl
@@ -0,0 +1,34 @@
+{*Smarty template*}
+
+{* {include file="script/search.js.tpl"} *}
+
+
+{literal}
+
+{/literal}
+
{include file="sub/x.tpl"}
- {foreach from=$searchform item=dynform}
+ {foreach from=$searchForm item=dynform}
{include file="sub/dynForm_plain.tpl"}
{/foreach}
diff --git a/livesupport/modules/htmlUI/var/templates/search/results.tpl b/livesupport/modules/htmlUI/var/templates/search/searchResults.tpl
similarity index 80%
rename from livesupport/modules/htmlUI/var/templates/search/results.tpl
rename to livesupport/modules/htmlUI/var/templates/search/searchResults.tpl
index 76fafd8c2..9cf56a04a 100755
--- a/livesupport/modules/htmlUI/var/templates/search/results.tpl
+++ b/livesupport/modules/htmlUI/var/templates/search/searchResults.tpl
@@ -1,8 +1,8 @@
{*Smarty template*}
-
+
-{if $searchres.count > 0}
+{if $searchResults.count > 0}
{tra 0=Title} |
@@ -10,7 +10,7 @@
{tra 0=Duration} |
{tra 0=Type} |
- {foreach from=$searchres.items item=i}
+ {foreach from=$searchResults.items item=i}
{if $PLAYLIST.id == $i.id}
@@ -32,17 +32,17 @@
{/foreach}
|
- {if $searchres.prev}back{/if}
+ {if $searchResults.prev}back{/if}
|
- count: {$searchres.count} |
+ count: {$searchResults.count} |
go:
- {foreach from=$searchres.pages item=p key=k}
+ {foreach from=$searchResults.pages item=p key=k}
{$p}
{/foreach}
|
- {if $searchres.next}forward{/if}
+ {if $searchResults.next}forward{/if}
|
diff --git a/livesupport/modules/htmlUI/var/ui_base.inc.php b/livesupport/modules/htmlUI/var/ui_base.inc.php
index c636f5c7f..4fd5f978e 100644
--- a/livesupport/modules/htmlUI/var/ui_base.inc.php
+++ b/livesupport/modules/htmlUI/var/ui_base.inc.php
@@ -105,6 +105,7 @@ class uiBase
$this->STATIONPREFS =& $_SESSION[UI_STATIONINFO_SESSNAME];
$this->SCRATCHPAD =& new uiScratchPad($this);
$this->SEARCH =& new uiSearch($this);
+ $this->BROWSE =& new uiBrowse($this);
$this->PLAYLIST =& new uiPlaylist($this);
}
@@ -257,16 +258,14 @@ class uiBase
if ($format=='text') {
return "".var_export($ia, TRUE)." ";
} elseif ($format=='xml') {
- return
- '
-
-
+ return '
+
+
'.$this->_getFileTitle($id).'
'.date('H:i:s', round($s)-date('Z')).substr(number_format($s, 6), strpos(number_format($s, 6), '.')).'
diff --git a/livesupport/modules/htmlUI/var/ui_browse.class.php b/livesupport/modules/htmlUI/var/ui_browse.class.php
new file mode 100755
index 000000000..bd40bd5b3
--- /dev/null
+++ b/livesupport/modules/htmlUI/var/ui_browse.class.php
@@ -0,0 +1,124 @@
+Base =& $uiBase;
+ $this->col =& $_SESSION[UI_BROWSE_SESSNAME]['col'];
+ $this->reloadUrl = UI_BROWSER.'?popup[]=_reload_parent&popup[]=_close';
+
+ if (!is_array($this->col)) {
+ $this->col[1]['category'] = 'dc:title';
+ $this->col[2]['category'] = 'dc:creator';
+ $this->col[3]['category'] = 'dc:source';
+ $this->setCategory(array('col' => 1, 'category' => $this->col[1]['category']));
+ }
+ #print_r($this->col);
+ }
+
+ function setReload()
+ {
+ $this->Base->redirUrl = $this->reloadUrl;
+ }
+
+
+
+ function browseForm($id, $mask2)
+ {
+ include dirname(__FILE__).'/formmask/metadata.inc.php';
+ foreach ($mask['pages'] as $key=>$val) {
+ foreach ($mask['pages'][$key] as $v){
+ if (!$v['rule']) $mask2['browse']['category']['options'][$this->Base->_formElementEncode($v['element'])] = $v['label'];
+ }
+ };
+
+ for($n=1; $n<=3; $n++) {
+ $form = new HTML_QuickForm('col'.$n, UI_STANDARD_FORM_METHOD, UI_HANDLER);
+ $form->setConstants(array('id' => $id, 'col' => $n, 'category' => $this->Base->_formElementEncode($this->col[$n]['category'])));
+ $mask2['browse']['value']['options'] = $this->_options($this->col[$n]['values']['results']);
+ $mask2['browse']['value']['default'] = $this->col[$n]['form_value'];
+ $this->Base->_parseArr2Form($form, $mask2['browse']);
+ $form->validate();
+ $renderer =& new HTML_QuickForm_Renderer_Array(true, true);
+ $form->accept($renderer);
+ $output[$n]['dynform'] = $renderer->toArray();
+ }
+ #print_r($output);
+ return $output;
+ }
+
+
+ function setCategory($formdata)
+ {
+ $which = $formdata['col'];
+ $this->col[$which]['category'] = $this->Base->_formElementDecode($formdata['category']);
+ $this->col[$which]['values'] = $this->Base->gb->browseCategory($this->col[$which]['category'], $this->col[$which]['criteria'], $this->Base->sessid);
+
+ $this->Base->redirUrl = UI_BROWSER.'?act=BROWSE';
+
+ $this->clearHierarchy($which);
+ #print_r($this->col);
+ }
+
+ function setValue($formdata)
+ {
+ $which = $formdata['col'];
+ $next = $which + 1;
+ $this->col[$which]['form_value'] = $formdata['value'][0];
+ if ($formdata['value'][0] == '%%all%%') {
+ $this->col[$next]['criteria'] = NULL;
+ } else {
+ $this->col[$next]['criteria'] = array('conditions' =>
+ array(
+ array('cat' => $this->Base->_formElementDecode($formdata['category']),
+ 'op' => '=',
+ 'val' => $formdata['value'][0]
+ )
+ )
+ );
+ }
+ $this->col[$next]['values'] = $this->Base->gb->browseCategory($this->col[$next]['category'], $this->col[$next]['criteria'], $this->Base->sessid);
+
+ #echo "cat: ".$this->col[$next]['category']."\n";
+ #echo "criteria: "; print_r($this->col[$next]['criteria']);
+ #echo "\nvalues: "; print_r($this->col[$next]['values']);
+
+ $this->clearHierarchy($next);
+ $this->Base->redirUrl = UI_BROWSER.'?act=BROWSE';
+ }
+
+
+ function _options($arr)
+ { $ret['%%all%%'] = '---all---';
+ if (is_array($arr)) {
+ foreach ($arr as $val)
+ $ret[$val] = $val;
+ }
+
+ return $ret;
+ }
+
+ function clearHierarchy($which)
+ {
+ $this->col[$which]['form_value'] = NULL;
+ $which++;
+ for ($col=$which; $col<=3; $col++) {
+ #$this->col[$col]['criteria'] = NULL;
+ $this->col[$col]['values'] = NULL;
+ $this->col[$col]['form_value'] = NULL;
+ }
+ }
+
+
+ function endResult()
+ {
+ for($col=1; $col<=3; $col++) {
+ #print_r($this->col[$col]);
+ }
+ #$this->result = $this->Base->gb->localSearch($this->col[3]['criteria'], $this->Base->sessid);
+ #print_r($this->result);
+
+ }
+
+}
+?>
diff --git a/livesupport/modules/htmlUI/var/ui_browser_init.php b/livesupport/modules/htmlUI/var/ui_browser_init.php
index 955c3efd5..61febde86 100644
--- a/livesupport/modules/htmlUI/var/ui_browser_init.php
+++ b/livesupport/modules/htmlUI/var/ui_browser_init.php
@@ -8,6 +8,7 @@ require_once dirname(__FILE__).'/ui_browser.class.php';
require_once dirname(__FILE__).'/ui_scratchpad.class.php';
require_once dirname(__FILE__).'/ui_playlist.class.php'; #
require_once dirname(__FILE__).'/ui_search.class.php';
+require_once dirname(__FILE__).'/ui_browse.class.php';
require_once dirname(__FILE__).'/../../storageServer/var/GreenBox.php';
require_once dirname(__FILE__).'/formmask/general.inc.php';
diff --git a/livesupport/modules/htmlUI/var/ui_handler_init.php b/livesupport/modules/htmlUI/var/ui_handler_init.php
index a53870e1b..438a4d480 100644
--- a/livesupport/modules/htmlUI/var/ui_handler_init.php
+++ b/livesupport/modules/htmlUI/var/ui_handler_init.php
@@ -9,6 +9,7 @@ require_once dirname(__FILE__).'/ui_handler.class.php';
require_once dirname(__FILE__).'/ui_scratchpad.class.php';
require_once dirname(__FILE__).'/ui_playlist.class.php';
require_once dirname(__FILE__).'/ui_search.class.php';
+require_once dirname(__FILE__).'/ui_browse.class.php';
require_once dirname(__FILE__).'/../../storageServer/var/GreenBox.php';
require_once dirname(__FILE__).'/formmask/general.inc.php';
diff --git a/livesupport/modules/htmlUI/var/ui_playlist.class.php b/livesupport/modules/htmlUI/var/ui_playlist.class.php
index 271cb8d12..38973b6e0 100755
--- a/livesupport/modules/htmlUI/var/ui_playlist.class.php
+++ b/livesupport/modules/htmlUI/var/ui_playlist.class.php
@@ -23,7 +23,7 @@ class uiPlaylist
return $this->Base->gb->getPlaylistArray($this->activeId, $this->Base->sessid);
}
- function activate($plid)
+ function activate($plid, $msg=TRUE)
{
# test if PL available
# look PL
@@ -40,11 +40,11 @@ class uiPlaylist
$this->token = $this->Base->gb->lockPlaylistForEdit($plid, $this->Base->sessid);
$this->Base->gb->savePref($this->Base->sessid, UI_PL_ACCESSTOKEN_KEY, $plid.':'.$this->token);
$this->activeId = $plid;
- $this->Base->_retMsg('Playlist "$1" activated', $this->Base->_getMDataValue($plid, UI_MDATA_KEY_TITLE));
+ if ($msg) $this->Base->_retMsg('Playlist "$1" activated', $this->Base->_getMDataValue($plid, UI_MDATA_KEY_TITLE));
return TRUE;
}
- function release()
+ function release($msg=TRUE)
{
# get token from ls_pref
# release PL
@@ -59,7 +59,7 @@ class uiPlaylist
$this->Base->_retMsg('Unable to release Playlist');
return FALSE;
}
- $this->Base->_retMsg('Playlist "$1" released', $this->Base->_getMDataValue($this->Base->gb->_idFromGunid($plgunid), UI_MDATA_KEY_TITLE));
+ if($msg) $this->Base->_retMsg('Playlist "$1" released', $this->Base->_getMDataValue($this->Base->gb->_idFromGunid($plgunid), UI_MDATA_KEY_TITLE));
$this->activeId = NULL;
$this->token = NULL;
$this->Base->gb->delPref($this->Base->sessid, UI_PL_ACCESSTOKEN_KEY);
@@ -67,6 +67,17 @@ class uiPlaylist
}
+ function save()
+ {
+ $tmpid = $this->activeId;
+ $this->release(FALSE);
+ $this->activate($tmpid, FALSE);
+ $this->Base->_retMsg('Playlist "$1" saved', $this->Base->_getMDataValue($tmpid, UI_MDATA_KEY_TITLE));
+
+ return TRUE;
+ }
+
+
function revert()
{
if(!$this->token) {
@@ -78,10 +89,12 @@ class uiPlaylist
$this->Base->_retMsg('Unable to revert to looked state');
return FALSE;
}
- $this->Base->_retMsg('Playlist "$1" reverted and released', $this->Base->_getMDataValue($this->Base->gb->_idFromGunid($plgunid), UI_MDATA_KEY_TITLE));
+ $this->Base->_retMsg('Playlist "$1" reverted', $this->Base->_getMDataValue($this->Base->gb->_idFromGunid($plgunid), UI_MDATA_KEY_TITLE));
$this->activeId = NULL;
$this->token = NULL;
$this->Base->gb->delPref($this->Base->sessid, UI_PL_ACCESSTOKEN_KEY);
+
+ $this->activate($this->Base->gb->_idFromGunid($plgunid), FALSE);
return TRUE;
}
@@ -101,8 +114,8 @@ class uiPlaylist
function addItem($id)
{
- if ($this->Base->gb->addAudioClipToPlaylist($this->token, $id, $this->Base->sessid) === FALSE) {
- $this->Base_retMsg('Cannot add Item to Playlist');
+ if (PEAR::isError($this->Base->gb->addAudioClipToPlaylist($this->token, $id, $this->Base->sessid))) {
+ $this->Base->_retMsg('Cannot add Item to Playlist');
return FALSE;
}
return TRUE;
@@ -257,24 +270,30 @@ class uiPlaylist
function changeTransitionForm($id, $type, &$mask)
{
+ $form = new HTML_QuickForm('PL_changeTransition', UI_STANDARD_FORM_METHOD, UI_HANDLER);
+ $s = $this->getCurrElement($id);
switch ($type) {
case "fadeIn":
$d = $this->getCurrElement($id);
$duration = $d['fadein_ms'];
+ $form->setConstants(array('headline' => ''.$s['title'].''));
break;
case "transition":
$d = $this->getPrevElement($id);
- $duration = $d['fadein_ms'];
+ $duration = $d['fadeout_ms'];
+ $form->setConstants(array('headline' => ''.$d['title'].' <-> '.$s['title'].''));
break;
case "fadeOut":
$d = $this->getCurrElement($id);
$duration = $d['fadeout_ms'];
+ $form->setConstants(array('headline' => ''.$s['title'].''));
break;
}
- $form = new HTML_QuickForm('PL_changeTransition', UI_STANDARD_FORM_METHOD, UI_HANDLER);
+
$form->setConstants(array('id' => $id,
- 'duration' => $duration));
+ 'duration' => $duration)
+ );
$this->Base->_parseArr2Form($form, $mask[$type]);
$this->Base->_parseArr2Form($form, $mask['all']);
$renderer =& new HTML_QuickForm_Renderer_Array(true, true);
diff --git a/livesupport/modules/htmlUI/var/ui_search.class.php b/livesupport/modules/htmlUI/var/ui_search.class.php
index 3c04701eb..69b94347a 100755
--- a/livesupport/modules/htmlUI/var/ui_search.class.php
+++ b/livesupport/modules/htmlUI/var/ui_search.class.php
@@ -20,13 +20,15 @@ class uiSearch
$form = new HTML_QuickForm('search', UI_STANDARD_FORM_METHOD, UI_HANDLER);
$form->setConstants(array('id'=>$id, 'counter'=>$this->criteria['counter'] ? $this->criteria['counter'] : UI_SEARCH_MIN_ROWS));
- foreach ($mask['pages'] as $k=>$v) {
- foreach ($mask['pages'][$k] as $val){
- $col1[$this->Base->_formElementEncode($val['element'])] = $val['label'];
- if (isset($val['relation']))
- $col2[$this->Base->_formElementEncode($val['element'])] = $mask2['relations'][$val['relation']];
- else
- $col2[$this->Base->_formElementEncode($val['element'])] = $mask2['relations']['standard'];
+ foreach ($mask['pages'] as $key=>$val) {
+ foreach ($mask['pages'][$key] as $v){
+ if (!$v['rule']) {
+ $col1[$this->Base->_formElementEncode($v['element'])] = $v['label'];
+ if (isset($val['relation']))
+ $col2[$this->Base->_formElementEncode($v['element'])] = $mask2['relations'][$v['relation']];
+ else
+ $col2[$this->Base->_formElementEncode($v['element'])] = $mask2['relations']['standard'];
+ }
};
};
for($n=1; $n<=UI_SEARCH_MAX_ROWS; $n++) {
@@ -52,7 +54,7 @@ class uiSearch
}
- function newsearch(&$formdata)
+ function newSearch(&$formdata)
{
$this->results = NULL;
$this->criteria['conditions'] = NULL;
|