* Add export pivot data.

This commit is contained in:
songchenxuan
2024-03-25 10:55:17 +08:00
parent a82fbd7502
commit 896f64fd5b
3 changed files with 12 additions and 9 deletions
+6 -6
View File
@@ -125,6 +125,12 @@ function loadCustomPivot()
postAndLoadPage(link, form, '#table-pivot-preview');
}
exportData = function()
{
const $domObj = $(".table-condensed")[0];
exportFile($domObj);
}
/**
* 把日期字符串转换成日期对象。
* Convert date string to date object.
@@ -227,9 +233,3 @@ getHeight = function(height)
return Math.min(windowHeight - headerHeight - menuHeight - conditionHeight - parentGapHeight - panelHeadingHeight - panelBodyPaddingY, height);
}
exportData = function()
{
const $domObj = $(".table-condensed")[0];
exportFile($domObj);
}
+3 -2
View File
@@ -18,7 +18,7 @@ if(file_exists($viewFile)) include_once $viewFile;
if($this->config->edition != 'open')
{
$pivotPath = $this->app->getModuleExtPath('pivot', 'view');
$pivotPath = $this->app->getModuleExtPath('pivot', 'ui');
include $pivotPath['common'] . 'exportdata.html.php';
}
@@ -43,7 +43,8 @@ if($config->edition != 'open')
'icon' => 'export',
'class' => 'ghost',
'data-target' => '#export',
'data-toggle' => 'modal'
'data-toggle' => 'modal',
'data-size' => 'sm'
))) : null,
hasPriv('pivot', 'browse') ? item(set(array
(
+3 -1
View File
@@ -115,7 +115,9 @@ $generateData = function() use ($lang, $pivotName, $pivot, $filters, $data, $con
div
(
setID('exportData'),
setClass('hidden')
setClass('hidden'),
rawContent(),
$this->pivot->buildPivotTable($data, $configs),
)
)
);