mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-09-07 02:20:59 +00:00
export options can be get by hook
This commit is contained in:
parent
c8ac16cec3
commit
aa5524ec41
|
@ -58,6 +58,10 @@ $skipdefaultcols = false;
|
|||
if (isset($get["skipdefaultcols"]) && $get["skipdefaultcols"])
|
||||
$skipdefaultcols = true;
|
||||
|
||||
$exportoptions = [];
|
||||
if (isset($get["export_options"]) && $get["export_options"])
|
||||
$exportoptions = $get["export_options"];
|
||||
|
||||
$newowner = null;
|
||||
if (isset($get["newowner"]) && is_numeric($get["newowner"]) && $get['newowner'] > 0) {
|
||||
$newowner = $dms->getUser((int) $get['newowner']);
|
||||
|
@ -637,6 +641,7 @@ if($settings->_showSingleSearchHit && count($entries) == 1) {
|
|||
$view->setParam('query', $query);
|
||||
$view->setParam('includecontent', $includecontent);
|
||||
$view->setParam('skipdefaultcols', $skipdefaultcols);
|
||||
$view->setParam('exportoptions', $exportoptions);
|
||||
$view->setParam('marks', isset($get['marks']) ? $get['marks'] : array());
|
||||
$view->setParam('newowner', $newowner);
|
||||
$view->setParam('newreviewer', $newreviewer);
|
||||
|
|
|
@ -63,6 +63,12 @@ $(document).ready( function() {
|
|||
if(this.checked)
|
||||
values[this.name] = 1;
|
||||
});
|
||||
$('input[name^=\"export_options\"]').each(function() {
|
||||
values[this.name] = this.value;
|
||||
});
|
||||
$('select[name^=\"export_options\"]').each(function() {
|
||||
values[this.name] = this.value;
|
||||
});
|
||||
url += '&'+$.param(values);
|
||||
window.location.href = url;
|
||||
});
|
||||
|
@ -1531,6 +1537,10 @@ $(document).ready(function() {
|
|||
'value'=>1,
|
||||
)
|
||||
);
|
||||
$txt = $this->callHook('searchExportOptions');
|
||||
if(is_string($txt)) {
|
||||
echo $txt;
|
||||
}
|
||||
//$this->formSubmit("<i class=\"fa fa-download\"></i> ".getMLText('export'));
|
||||
print $this->html_link('Search', array_merge($_GET, array('action'=>'export')), array('class'=>'btn btn-primary', 'id'=>'export'), "<i class=\"fa fa-download\"></i> ".getMLText("batch_export"), false, true)."\n";
|
||||
$content = ob_get_clean();
|
||||
|
|
Loading…
Reference in New Issue
Block a user