* [task#133002,doing,0.5h] show pivot table in pivot-versions.

This commit is contained in:
zhouxin
2024-11-22 09:19:04 +08:00
committed by 綦新志
parent 11d9b24e62
commit d2016bd638
2 changed files with 13 additions and 2 deletions
+6 -2
View File
@@ -71,16 +71,20 @@ class pivot extends control
* 透视表版本列表。
* Show versions of a pivot.
*
* @param int $groupID
* @param int $pivotID
* @param string $version
* @access public
* @return void
*/
public function versions(int $pivotID, string $version = 'newest')
public function versions(int $groupID, int $pivotID, string $version = 'newest')
{
$pivot = $this->pivot->getByID($pivotID);
$this->pivotZen->show($groupID, $pivotID, '', $version);
$this->view->versionSpecs = $this->pivot->getPivotVersions($pivotID);
$this->view->version = $version == 'newest' ? $this->pivot->getMaxVersion($pivotID) : $version;
$this->view->pivot = $this->pivot->getByID($pivotID);
$this->view->pivot = $pivot;
$this->display();
}
+7
View File
@@ -9,6 +9,7 @@ declare(strict_types = 1);
* @link https://www.zentao.net
*/
namespace zin;
include_once 'show.html.php';
$versionsTableBody = array();
foreach($versionSpecs as $versionSpec)
@@ -45,5 +46,11 @@ panel
h::th($lang->pivot->desc)
),
$versionsTableBody
),
div
(
setID('pivotContent'),
setClass('flex col gap-4 w-full'),
$generateData()
)
);