* Finish task #40500.

This commit is contained in:
holan20180123
2021-07-23 10:46:27 +08:00
parent 42829fa597
commit bbd03f9756
9 changed files with 78 additions and 68 deletions
+6
View File
@@ -921,6 +921,12 @@ class doc extends control
$doc = $this->doc->getById($docID, $version, true);
if(!$doc) die(js::error($this->lang->notFound) . js::locate('back'));
if($doc->keywords)
{
$doc->keywords = preg_replace("/(\n)|(\s)|(\t)|(\')|(')|()/", ',', $doc->keywords);
$doc->keywords = explode(',', $doc->keywords);
}
if($doc->contentType == 'markdown')
{
$doc->content = commonModel::processMarkdown($doc->content);
+14 -13
View File
@@ -88,19 +88,20 @@ $lang->doc->cancelCollection = 'Favorit entfernen';
$lang->doc->deleteFile = 'Delete File';
$lang->doc->menuTitle = 'Menu';
$lang->doc->libName = 'Name';
$lang->doc->libType = 'Kategorie';
$lang->doc->custom = 'Eigene Dok Bibliothek';
$lang->doc->customAB = 'Eigene Bibliothek';
$lang->doc->createlib = 'Bibliothek erstellen';
$lang->doc->allLibs = 'Bibliothek';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Bibliothek Liste";
$lang->doc->showFiles = 'Dok Bibliothek';
$lang->doc->editlib = 'Bibliothek bearbeiten';
$lang->doc->deleteLib = 'Bibliothek löschen';
$lang->doc->fixedMenu = 'Im Menü fixieren';
$lang->doc->removeMenu = 'Vom Menü entfernen';
$lang->doc->search = 'Suche';
$lang->doc->libName = 'Name';
$lang->doc->libType = 'Kategorie';
$lang->doc->custom = 'Eigene Dok Bibliothek';
$lang->doc->customAB = 'Eigene Bibliothek';
$lang->doc->createlib = 'Bibliothek erstellen';
$lang->doc->allLibs = 'Bibliothek';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Bibliothek Liste";
$lang->doc->showFiles = 'Dok Bibliothek';
$lang->doc->editlib = 'Bibliothek bearbeiten';
$lang->doc->deleteLib = 'Bibliothek löschen';
$lang->doc->fixedMenu = 'Im Menü fixieren';
$lang->doc->removeMenu = 'Vom Menü entfernen';
$lang->doc->search = 'Suche';
$lang->doc->keywordsTips = 'Please use commas to separate multiple keywords.';
/* 查询条件列表 */
$lang->doc->allProduct = 'Alle' . $lang->productCommon;
+14 -13
View File
@@ -91,19 +91,20 @@ $lang->doc->menuTitle = 'Menu';
$lang->doc->collectAction = 'Add Favorite';
$lang->doc->libName = 'Document Library';
$lang->doc->libType = 'Category';
$lang->doc->custom = 'Custom Document Library';
$lang->doc->customAB = 'Custom Doc Lib';
$lang->doc->createLib = 'Create Document Library';
$lang->doc->allLibs = 'Library List';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Libraries";
$lang->doc->showFiles = 'Attachments';
$lang->doc->editLib = 'Edit Document Library';
$lang->doc->deleteLib = 'Delete Document Library';
$lang->doc->fixedMenu = 'Fix to Menu';
$lang->doc->removeMenu = 'Remove from Menu';
$lang->doc->search = 'Search';
$lang->doc->libName = 'Document Library';
$lang->doc->libType = 'Category';
$lang->doc->custom = 'Custom Document Library';
$lang->doc->customAB = 'Custom Doc Lib';
$lang->doc->createLib = 'Create Document Library';
$lang->doc->allLibs = 'Library List';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Libraries";
$lang->doc->showFiles = 'Attachments';
$lang->doc->editLib = 'Edit Document Library';
$lang->doc->deleteLib = 'Delete Document Library';
$lang->doc->fixedMenu = 'Fix to Menu';
$lang->doc->removeMenu = 'Remove from Menu';
$lang->doc->search = 'Search';
$lang->doc->keywordsTips = 'Please use commas to separate multiple keywords.';
global $config;
/* Query condition list. */
+14 -13
View File
@@ -88,19 +88,20 @@ $lang->doc->cancelCollection = 'Retirer des Favoris';
$lang->doc->deleteFile = 'Supprimer Fichier';
$lang->doc->menuTitle = 'Menu';
$lang->doc->libName = 'Bibliothèque de Documents';
$lang->doc->libType = 'Catégorie';
$lang->doc->custom = 'Personnaliser Bibliothèque de Documents';
$lang->doc->customAB = 'Person. Bib Doc';
$lang->doc->createlib = 'Créer une Bibliothèque';
$lang->doc->allLibs = 'Liste des Bibliothèque';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Bibliothèque";
$lang->doc->showFiles = 'Pièces Jointes';
$lang->doc->editlib = 'Editer Bibliothèque';
$lang->doc->deleteLib = 'Supprimer Bibliothèque';
$lang->doc->fixedMenu = 'Coller au Menu';
$lang->doc->removeMenu = 'Décoller du Menu';
$lang->doc->search = 'Rechercher';
$lang->doc->libName = 'Bibliothèque de Documents';
$lang->doc->libType = 'Catégorie';
$lang->doc->custom = 'Personnaliser Bibliothèque de Documents';
$lang->doc->customAB = 'Person. Bib Doc';
$lang->doc->createlib = 'Créer une Bibliothèque';
$lang->doc->allLibs = 'Liste des Bibliothèque';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Bibliothèque";
$lang->doc->showFiles = 'Pièces Jointes';
$lang->doc->editlib = 'Editer Bibliothèque';
$lang->doc->deleteLib = 'Supprimer Bibliothèque';
$lang->doc->fixedMenu = 'Coller au Menu';
$lang->doc->removeMenu = 'Décoller du Menu';
$lang->doc->search = 'Rechercher';
$lang->doc->keywordsTips = 'Please use commas to separate multiple keywords.';
/* 查询条件列表 */
$lang->doc->allProduct = 'Tous les' . $lang->productCommon . 's';
+14 -13
View File
@@ -88,19 +88,20 @@ $lang->doc->cancelCollection = 'Remove Favorite';
$lang->doc->deleteFile = 'Xóa File';
$lang->doc->menuTitle = 'Menu';
$lang->doc->libName = 'Thư viện tài liệu';
$lang->doc->libType = 'Danh mục';
$lang->doc->custom = 'Tùy biến thư viện tài liệu';
$lang->doc->customAB = 'Tùy biến Doc Lib';
$lang->doc->createlib = 'Tạo thư viện tài liệu';
$lang->doc->allLibs = 'Library danh sách';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Libraries";
$lang->doc->showFiles = 'Attachments';
$lang->doc->editlib = 'Sửa thư viện tài liệu';
$lang->doc->deleteLib = 'Xóa thư viện tài liệu';
$lang->doc->fixedMenu = 'Sửa to Menu';
$lang->doc->removeMenu = 'Remove from Menu';
$lang->doc->search = 'Tìm kiếm';
$lang->doc->libName = 'Thư viện tài liệu';
$lang->doc->libType = 'Danh mục';
$lang->doc->custom = 'Tùy biến thư viện tài liệu';
$lang->doc->customAB = 'Tùy biến Doc Lib';
$lang->doc->createlib = 'Tạo thư viện tài liệu';
$lang->doc->allLibs = 'Library danh sách';
$lang->doc->objectLibs = "{$lang->productCommon}/{$lang->executionCommon} Libraries";
$lang->doc->showFiles = 'Attachments';
$lang->doc->editlib = 'Sửa thư viện tài liệu';
$lang->doc->deleteLib = 'Xóa thư viện tài liệu';
$lang->doc->fixedMenu = 'Sửa to Menu';
$lang->doc->removeMenu = 'Remove from Menu';
$lang->doc->search = 'Tìm kiếm';
$lang->doc->keywordsTips = 'Please use commas to separate multiple keywords.';
/* Query condition list. */
$lang->doc->allProduct = 'All' . $lang->productCommon;
+1
View File
@@ -104,6 +104,7 @@ $lang->doc->deleteLib = '删除文档库';
$lang->doc->fixedMenu = '固定到菜单栏';
$lang->doc->removeMenu = '从菜单栏移除';
$lang->doc->search = '搜索';
$lang->doc->keywordsTips = '多个关键字请用逗号分隔。';
global $config;
/* 查询条件列表 */
+7 -8
View File
@@ -66,6 +66,13 @@ $sessionString .= session_name() . '=' . session_id();
</div>
</div>
<div class="detail-content article-content">
<?php if($doc->keywords):?>
<p>
<?php foreach($doc->keywords as $keywords):?>
<?php if($keywords) echo "<span class='label label-outline'>$keywords</span>";?>
<?php endforeach;?>
</p>
<?php endif;?>
<?php
if($doc->type == 'url')
{
@@ -138,14 +145,6 @@ $sessionString .= session_name() . '=' . session_id();
</details>
</div>
<?php endif;?>
<div class="cell">
<details class="detail" open>
<summary class="detail-title"><?php echo $lang->doc->keywords;?></summary>
<div class="detail-content">
<?php echo !empty($doc->keywords) ? $doc->keywords : "<div class='text-center text-muted'>" . $lang->noData . '</div>';?>
</div>
</details>
</div>
<div class="cell">
<details class="detail" open>
<summary class="detail-title"><?php echo $lang->doc->basicInfo;?></summary>
+1 -1
View File
@@ -58,7 +58,7 @@
</tr>
<tr>
<th><?php echo $lang->doc->keywords;?></th>
<td colspan='2'><?php echo html::input('keywords', '', "class='form-control'");?></td>
<td colspan='2'><?php echo html::input('keywords', '', "class='form-control' placeholder='{$lang->doc->keywordsTips}'");?></td>
</tr>
<tr>
<th><?php echo $lang->doc->type;?></th>
+7 -7
View File
@@ -24,37 +24,37 @@
<div class='pull-right'><?php echo html::a('###', $lang->save, '', 'id="top-submit" class="btn btn-primary"');?></div>
</div>
<form class='load-indicator main-form form-ajax' method='post' enctype='multipart/form-data' id='dataform'>
<table class='table table-form'>
<table class='table table-form'>
<tr>
<th class='w-110px'><?php echo $lang->doc->lib;?></th>
<td> <?php echo html::select('lib', $libs, $doc->lib, "class='form-control chosen' onchange=loadDocModule(this.value)");?> </td><td></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->doc->module;?></th>
<td>
<span id='moduleBox'><?php echo html::select('module', $moduleOptionMenu, $doc->module, "class='form-control chosen'");?></span>
</td><td></td>
</tr>
</tr>
<tr>
<th><?php echo $lang->doc->title;?></th>
<td colspan='2'><?php echo html::input('title', $doc->title, "class='form-control' required");?></td>
</tr>
<tr>
<th><?php echo $lang->doc->keywords;?></th>
<td colspan='2'><?php echo html::input('keywords', $doc->keywords, "class='form-control'");?></td>
<td colspan='2'><?php echo html::input('keywords', $doc->keywords, "class='form-control' placeholder='{$lang->doc->keywordsTips}'");?></td>
</tr>
<tr>
<th><?php echo $lang->doc->type;?></th>
<td><?php echo html::radio('type', $lang->doc->types, $doc->type);?></td>
</tr>
</tr>
<tr id='contentBox' <?php if($doc->type == 'url') echo "class='hidden'"?>>
<th><?php echo $lang->doc->content;?></th>
<td colspan='2'><?php echo html::textarea('content', $doc->type == 'url' ? '' : htmlspecialchars($doc->content), "style='width:100%; height:200px'") . html::hidden('contentType', $doc->contentType);?></td>
</tr>
</tr>
<tr id='urlBox' <?php if($doc->type != 'url') echo "class='hidden'"?>>
<th><?php echo $lang->doc->url;?></th>
<td colspan='2'><?php echo html::input('url', $doc->type == 'url' ? $doc->content : '', "class='form-control'");?></td>
</tr>
</tr>
<tr id='fileBox'>
<th><?php echo $lang->doc->files;?></th>
<td colspan='2'><?php echo $this->fetch('file', 'buildform');?></td>