diff --git a/livesupport/modules/htmlUI/var/SmartyExtensions.inc.php b/livesupport/modules/htmlUI/var/SmartyExtensions.inc.php index f92855cbc..87f2fbd56 100644 --- a/livesupport/modules/htmlUI/var/SmartyExtensions.inc.php +++ b/livesupport/modules/htmlUI/var/SmartyExtensions.inc.php @@ -2,7 +2,7 @@ $Smarty->register_object('UIBROWSER', $uiBrowser); $Smarty->register_object('BROWSE', $uiBrowser->BROWSE); $Smarty->register_object('SEARCH', $uiBrowser->SEARCH); -$Smarty->assign_by_ref ('PL', $uiBrowser->PLAYLIST); +$Smarty->assign_by_ref ('PL', $uiBrowser->PLAYLIST); $Smarty->assign_by_ref ('SCHEDULER', $uiBrowser->SCHEDULER); $Smarty->register_function('str_repeat', 'S_str_repeat'); diff --git a/livesupport/modules/htmlUI/var/formmask/general.inc.php b/livesupport/modules/htmlUI/var/formmask/general.inc.php index 8b2921f05..21a5490a9 100755 --- a/livesupport/modules/htmlUI/var/formmask/general.inc.php +++ b/livesupport/modules/htmlUI/var/formmask/general.inc.php @@ -21,7 +21,7 @@ $ui_fmask = array( 'attributes' => array( 'onClick' => 'alert ("Note: System Maximum is set to '. ini_get('upload_max_filesize') - .' in php.ini\n You can just reduce this amount this here.")' + .' in php.ini\n You can just reduce this amount here.")' ) ), array( @@ -76,10 +76,9 @@ $ui_fmask = array( 'type' => 'select', 'label' => 'Maximun length of ScratchPad', 'options' => array( - 0 => '--', 5 => 5, 10 => 10, - 20 => 20 + 25 => 25 ) ), array( @@ -278,10 +277,21 @@ $ui_fmask = array( 'required' => TRUE, 'requiredmsg'=> 'please select Media file' ), + array( + 'element' => 'cancel', + 'type' => 'button', + 'label' => 'Cancel', + 'attributes'=> array('onClick' => "location.href='".UI_BROWSER."'"), + 'groupit' => TRUE + ), array( 'element' => 'Submit', 'type' => 'submit', - 'label' => 'Submit' + 'label' => 'Submit', + 'groupit' => TRUE + ), + array( + 'group' => array('cancel', 'Submit') ) ), @@ -320,10 +330,21 @@ $ui_fmask = array( 'label' => 'Length
Leave zero for Live Stream', 'options' => array('format' => 'His'), ), + array( + 'element' => 'cancel', + 'type' => 'button', + 'label' => 'Cancel', + 'attributes'=> array('onClick' => "location.href='".UI_BROWSER."'"), + 'groupit' => TRUE + ), array( 'element' => 'Submit', 'type' => 'submit', - 'label' => 'Submit' + 'label' => 'Submit', + 'groupit' => TRUE + ), + array( + 'group' => array('cancel', 'Submit') ) ), @@ -371,12 +392,11 @@ $ui_fmask = array( 'type' => 'select', 'label' => 'Rows per Page', 'options' => array( - 2 => 2, - 5 => 5, - 10 => 10, - 25 => 25, - 50 => 50, - 100 => 100 + 5 => 5, + 10 => 10, + 25 => 25, + 50 => 50, + 100 => 100 ) ), array( @@ -461,9 +481,10 @@ $ui_fmask = array( 'type' => 'select', 'multiple' => TRUE, 'attributes'=> array( - 'size' => 10, - 'STYLE' => 'width: 220px', - 'onChange' => 'this.form.act.value="BROWSE.setValue"; this.form.submit()') + 'size' => 10, + 'STYLE' => 'width: 220px', + 'onChange' => 'this.form.act.value="BROWSE.setValue"; this.form.submit()' + ) ) ), @@ -489,117 +510,185 @@ $ui_fmask = array( 'type' => 'select', 'label' => 'Rows per Page', 'options' => array( - 2 => 2, - 5 => 5, - 10 => 10, - 25 => 25, - 50 => 50, - 100 => 100 + 5 => 5, + 10 => 10, + 25 => 25, + 50 => 50, + 100 => 100 ), 'attributes'=> array('onChange' => 'hpopup("'.UI_HANDLER.'?act=BROWSE.setLimit&limit=" + this.form.limit.value)') ) ), + 'simplesearch' => array( + array( + 'element' => 'act', + 'type' => 'hidden', + 'constant' => 'SEARCH.simpleSearch' + ), + array( + 'element' => 'criterium', + 'type' => 'text', + 'label' => NULL, + 'groupit' => TRUE + ), + array( + 'element' => 'submit', + 'type' => 'submit', + 'label' => 'Search', + 'groupit' => TRUE + ), + array( + 'group' => array('criterium', 'submit') + ) + ), + 'PL.changeTransition' => array( 'transition' => array( - array( - 'element' => 'headline', - 'type' => 'static' - ), - array( - 'element' => 'type', - 'type' => 'radio', - 'label' => 'Type', - 'options' => array( - 'fadeX' => 'Crossfade', - 'pause' => 'Pause' - ), - 'default' => 'fadeX' - ) + array( + 'element' => 'headline', + 'type' => 'static' + ), + array( + 'element' => 'type', + 'type' => 'radio', + 'label' => 'Type', + 'options' => array( + 'fadeX' => 'Crossfade', + 'pause' => 'Pause' + ), + 'default' => 'fadeX' + ) ), 'fadeIn' => array( - array( - 'element' => 'headline', - 'type' => 'static' - ), - array( - 'element' => 'type', - 'type' => 'radio', - 'label' => 'Type', - 'options' => array('fadeIn' => 'Fade in'), - 'default' => 'fadeIn' - ) + array( + 'element' => 'headline', + 'type' => 'static' + ), + array( + 'element' => 'type', + 'type' => 'radio', + 'label' => 'Type', + 'options' => array('fadeIn' => 'Fade in'), + 'default' => 'fadeIn' + ) ), 'fadeOut' => array( - array( - 'element' => 'headline', - 'type' => 'static' - ), - array( - 'element' => 'type', - 'type' => 'radio', - 'label' => 'Type', - 'options' => array('fadeOut' => 'Fade out'), - 'default' => 'fadeOut' - ) - ), - 'all' => array( - array( - 'element' => 'act', - 'type' => 'hidden', - 'constant' => 'PL.changeTransition' - ), - array( - 'element' => 'id', - 'type' => 'hidden' - ), - array( - 'element' => 'duration', - 'type' => 'text', - 'rule' => 'numeric', - 'attributes'=> array('size' => 4, 'maxlength' => 4), - 'groupit' => TRUE - ), - array( - 'element' => 'switchdown', - 'type' => 'button', - 'label' => '-', - 'attributes'=> array('onClick' => 'pl_switchDown()', 'onMousedown' => 'pl_start("Down")', 'onMouseUp' => "pl_stop()", 'onMouseOut' => "pl_stop()"), - 'groupit' => TRUE - ), - array( - 'element' => 'switchup', - 'type' => 'button', - 'label' => '+', - 'attributes'=> array('onClick' => 'pl_switchUp()', 'onMousedown' => 'pl_start("Up")', 'onMouseUp' => "pl_stop()", 'onMouseOut' => "pl_stop()"), - 'groupit' => TRUE - ), - array( - 'group' => array('duration', 'switchdown', 'switchup'), - 'label' => 'Duration' - ), - array( - 'element' => 'cancel', - 'type' => 'button', - 'label' => 'Cancel', - 'attributes'=> array('onClick' => 'window.close()'), - 'groupit' => TRUE, - ), - array( - 'element' => 'reset', - 'type' => 'reset', - 'label' => 'Reset', - 'groupit' => TRUE, - ), - array( - 'element' => 'submit', - 'type' => 'submit', - 'label' => 'Submit', - 'groupit' => TRUE, - ), - array( - 'group' => array('cancel', 'reset', 'submit') - ) + array( + 'element' => 'headline', + 'type' => 'static' + ), + array( + 'element' => 'type', + 'type' => 'radio', + 'label' => 'Type', + 'options' => array('fadeOut' => 'Fade out'), + 'default' => 'fadeOut' ) + ), + 'all' => array( + array( + 'element' => 'act', + 'type' => 'hidden', + 'constant' => 'PL.changeTransition' + ), + array( + 'element' => 'id', + 'type' => 'hidden' + ), + array( + 'element' => 'duration', + 'type' => 'text', + 'rule' => 'numeric', + 'attributes'=> array('size' => 4, 'maxlength' => 4), + 'groupit' => TRUE + ), + array( + 'element' => 'switchdown', + 'type' => 'button', + 'label' => '-', + 'attributes'=> array('onClick' => 'pl_switchDown()', 'onMousedown' => 'pl_start("Down")', 'onMouseUp' => "pl_stop()", 'onMouseOut' => "pl_stop()"), + 'groupit' => TRUE + ), + array( + 'element' => 'switchup', + 'type' => 'button', + 'label' => '+', + 'attributes'=> array('onClick' => 'pl_switchUp()', 'onMousedown' => 'pl_start("Up")', 'onMouseUp' => "pl_stop()", 'onMouseOut' => "pl_stop()"), + 'groupit' => TRUE + ), + array( + 'group' => array('duration', 'switchdown', 'switchup'), + 'label' => 'Duration' + ), + array( + 'element' => 'cancel', + 'type' => 'button', + 'label' => 'Cancel', + 'attributes'=> array('onClick' => 'window.close()'), + 'groupit' => TRUE, + ), + array( + 'element' => 'reset', + 'type' => 'reset', + 'label' => 'Reset', + 'groupit' => TRUE, + ), + array( + 'element' => 'submit', + 'type' => 'submit', + 'label' => 'Submit', + 'groupit' => TRUE, + ), + array( + 'group' => array('cancel', 'reset', 'submit') + ) + ) + ), + 'schedule' => array( + array( + 'element' => 'act', + 'type' => 'hidden', + 'constant' => 'SCHEDULER.uploadPlaylistMethod' + ), + 'date' => array( + 'element' => 'date', + 'type' => 'date', + 'label' => 'Date', + 'options' => array('format' => 'Ymd'), + ), + 'time' => array( + 'element' => 'time', + 'type' => 'date', + 'label' => 'Time', + 'options' => array('format' => 'His'), + ), + 'playlist' => array( + 'element' => 'playlist', + 'type' => 'select', + 'label' => 'Playlist', + 'required' => TRUE, + ), + array( + 'element' => 'cancel', + 'type' => 'button', + 'label' => 'Cancel', + 'groupit' => TRUE + ), + array( + 'element' => 'reset', + 'type' => 'reset', + 'label' => 'Reset', + 'groupit' => TRUE + ), + array( + 'element' => 'submit', + 'type' => 'submit', + 'label' => 'Submit', + 'groupit' => TRUE + ), + array( + 'group' => array('cancel', 'reset', 'submit') + ) ) ); diff --git a/livesupport/modules/htmlUI/var/formmask/metadata.inc.php b/livesupport/modules/htmlUI/var/formmask/metadata.inc.php index 49ca1659d..0828a304e 100755 --- a/livesupport/modules/htmlUI/var/formmask/metadata.inc.php +++ b/livesupport/modules/htmlUI/var/formmask/metadata.inc.php @@ -21,6 +21,13 @@ $mask = array( 'label' =>'Reset', 'groupit' => TRUE, ), + array( + 'element' => 'cancel', + 'type' => 'button', + 'label' => 'Cancel', + 'attributes'=> array('onClick' => "location.href='".UI_BROWSER."'"), + 'groupit' => TRUE + ), array( 'element' =>'button', 'type' =>'button', @@ -31,7 +38,7 @@ $mask = array( ), ), array( - 'group' => array('reset', 'button'), + 'group' => array('reset', 'cancel', 'button'), ) ), 'tabs' => array( diff --git a/livesupport/modules/htmlUI/var/html/styles.css b/livesupport/modules/htmlUI/var/html/styles.css index 2f0b2cfa7..24afcb479 100755 --- a/livesupport/modules/htmlUI/var/html/styles.css +++ b/livesupport/modules/htmlUI/var/html/styles.css @@ -163,4 +163,11 @@ a { border-style : dotted; padding : 5px; margin-top: 10px; +} + +#simplesearchform { + width: 400px; + border-style : dotted; + padding : 5px; + margin-top: 10px; } \ No newline at end of file diff --git a/livesupport/modules/htmlUI/var/html/ui_browser.php b/livesupport/modules/htmlUI/var/html/ui_browser.php index 4fe3dcb43..92fcc2748 100644 --- a/livesupport/modules/htmlUI/var/html/ui_browser.php +++ b/livesupport/modules/htmlUI/var/html/ui_browser.php @@ -55,25 +55,24 @@ if (is_array($_REQUEST['popup'])){ }; if ($uiBrowser->userid) { - $Smarty->assign('showMenuTop', TRUE); - $Smarty->assign('SCRATCHPAD', $uiBrowser->SCRATCHPAD->get()); - #$Smarty->assign('PLid', $uiBrowser->PLAYLIST->activeId); + $Smarty->assign('showMenuTop', TRUE); + $Smarty->assign('SCRATCHPAD', $uiBrowser->SCRATCHPAD->get()); - switch ($_REQUEST['act']){ + switch ($_REQUEST['act']){ case "fileList": $Smarty->assign('structure', $uiBrowser->getStructure($uiBrowser->fid)); - $Smarty->assign('fileList', TRUE); + if ($_REQUEST['tree']=='Y') $Smarty->assign('showTree', TRUE); else $Smarty->assign('showObjects', TRUE); + $Smarty->assign('delOverride', $_REQUEST['delOverride']); break; case "permissions": $Smarty->assign('structure', $uiBrowser->getStructure($uiBrowser->id)); - $Smarty->assign('permissions', $uiBrowser->permissions($uiBrowser->id)); $Smarty->assign('fileList', TRUE); break; @@ -81,7 +80,6 @@ if ($uiBrowser->userid) { case "uploadFileM": $Smarty->assign('structure', $uiBrowser->getStructure($uiBrowser->id)); - $Smarty->assign('uploadform', $uiBrowser->uploadFileM($ui_fmask['uploadFileM'], $uiBrowser->id)); break; @@ -103,13 +101,11 @@ if ($uiBrowser->userid) { case "SEARCH": $Smarty->assign('searchForm', $uiBrowser->SEARCH->searchForm($uiBrowser->id, $ui_fmask)); $Smarty->assign('showLibrary', TRUE); - break; case "BROWSE": $Smarty->assign('browseForm', $uiBrowser->BROWSE->browseForm($uiBrowser->id, $ui_fmask)); $Smarty->assign('showLibrary', TRUE); - break; case "subjects": @@ -168,7 +164,10 @@ if ($uiBrowser->userid) { case "SCHEDULER": $Smarty->assign('showScheduler', TRUE); break; - } + } + + if ($_REQUEST['act'] != 'SCHEDULER') + $Smarty->assign('simpleSearchForm', $uiBrowser->SEARCH->simpleSearchForm($ui_fmask['simplesearch'])); } $Smarty->display('main.tpl'); diff --git a/livesupport/modules/htmlUI/var/html/ui_handler.php b/livesupport/modules/htmlUI/var/html/ui_handler.php index e9049365b..70726e2f9 100644 --- a/livesupport/modules/htmlUI/var/html/ui_handler.php +++ b/livesupport/modules/htmlUI/var/html/ui_handler.php @@ -132,6 +132,10 @@ switch($_REQUEST['act']){ $uiHandler->SEARCH->newSearch($_REQUEST); break; + case "SEARCH.simpleSearch": + $uiHandler->SEARCH->simpleSearch($_REQUEST); + break; + case "SEARCH.reOrder": $uiHandler->SEARCH->reOrder($_REQUEST['by']); break; diff --git a/livesupport/modules/htmlUI/var/templates/header.tpl b/livesupport/modules/htmlUI/var/templates/header.tpl index 4501933e1..0f204a514 100755 --- a/livesupport/modules/htmlUI/var/templates/header.tpl +++ b/livesupport/modules/htmlUI/var/templates/header.tpl @@ -7,7 +7,6 @@ {include file="script/basics.js.tpl"} {include file="script/contextMenue.js.tpl"} {include file="script/collector.js.tpl"} - {include file="script/mouseOver.js.tpl"} \ No newline at end of file diff --git a/livesupport/modules/htmlUI/var/templates/library/browseForm.tpl b/livesupport/modules/htmlUI/var/templates/library/browseForm.tpl index 28c675b25..895045b6e 100755 --- a/livesupport/modules/htmlUI/var/templates/library/browseForm.tpl +++ b/livesupport/modules/htmlUI/var/templates/library/browseForm.tpl @@ -1,8 +1,3 @@ -{*Smarty template*} - -{* {include file="script/search.js.tpl"} *} - - {literal}