From 91024aa911b0549afe1cb2b7f188b445e1d85f92 Mon Sep 17 00:00:00 2001 From: sunhao Date: Wed, 4 Sep 2024 08:48:56 +0800 Subject: [PATCH] + [ui] add doc app view. --- module/doc/control.php | 17 +++++++++++++++++ module/doc/ui/app.html.php | 23 +++++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 module/doc/ui/app.html.php diff --git a/module/doc/control.php b/module/doc/control.php index 99d9bfe9fe..ba13d363dd 100755 --- a/module/doc/control.php +++ b/module/doc/control.php @@ -1356,6 +1356,23 @@ class doc extends control if(isset($this->lang->doc->whitelistDeny['doc'])) return printf($this->lang->doc->whitelistDeny['doc'], implode('、', $denyUsers)); } + /** + * Doc app view. + * 文档应用视图。 + * + * @param string $type + * @param int $space + * @access public + * @return void + */ + public function app(string $type = 'mine', int $spaceID = 0) + { + $this->view->type = $type; + $this->view->spaceID = $spaceID; + $this->view->title = $this->lang->doc->spaceList[$type]; + $this->display(); + } + /** * Ajax: Get doc space data. * Ajax: 获取文档空间数据。 diff --git a/module/doc/ui/app.html.php b/module/doc/ui/app.html.php new file mode 100644 index 0000000000..fdc46d1fbb --- /dev/null +++ b/module/doc/ui/app.html.php @@ -0,0 +1,23 @@ + + * @package doc + * @link https://www.zentao.net + */ +namespace zin; + +zui::docApp +( + set::_class('shadow rounded ring canvas'), + set::_style(array('height' => 'calc(100vh - 72px)')), + set::spaceType($type), + set::spaceID($spaceID), + set::fetcher(createLink('doc', 'ajaxGetSpaceData', 'type={spaceType}&spaceID={spaceID}')), + set::docFetcher(createLink('doc', 'ajaxGetDoc', 'docID={docID}')), + set::width('100%'), + set::height('100%') +);