From c7f587ef5a4d807a8c78795e84b32c71e92b6f87 Mon Sep 17 00:00:00 2001 From: hufangzhou Date: Fri, 12 Aug 2022 15:05:00 +0800 Subject: [PATCH] * Fix bug #26359. Optimize detail styles for creating documents. --- module/doc/lang/de.php | 1 + module/doc/lang/en.php | 1 + module/doc/lang/fr.php | 1 + module/doc/lang/zh-cn.php | 1 + module/doc/view/createtexttype.html.php | 18 ++++-------------- module/doc/view/edittexttype.html.php | 22 ++++------------------ module/upgrade/model.php | 22 ++++++++++++++++++++++ 7 files changed, 34 insertions(+), 32 deletions(-) diff --git a/module/doc/lang/de.php b/module/doc/lang/de.php index 1bda5ad37e..285060e931 100644 --- a/module/doc/lang/de.php +++ b/module/doc/lang/de.php @@ -154,6 +154,7 @@ $lang->doc->allCollections = 'All Collections'; $lang->doc->keywordsTips = 'Please use commas to separate multiple keywords.'; $lang->doc->sortLibs = 'Sort Libs'; $lang->doc->titlePlaceholder = 'Please enter the title'; +$lang->doc->confirm = 'Confirm'; global $config; /* Query condition list. */ diff --git a/module/doc/lang/en.php b/module/doc/lang/en.php index b719793600..db444b059f 100644 --- a/module/doc/lang/en.php +++ b/module/doc/lang/en.php @@ -154,6 +154,7 @@ $lang->doc->allCollections = 'All Collections'; $lang->doc->keywordsTips = 'Please use commas to separate keywords.'; $lang->doc->sortLibs = 'Sort Libs'; $lang->doc->titlePlaceholder = 'Please enter the title'; +$lang->doc->confirm = 'Confirm'; global $config; /* Query condition list. */ diff --git a/module/doc/lang/fr.php b/module/doc/lang/fr.php index f544dd2113..cb11214407 100644 --- a/module/doc/lang/fr.php +++ b/module/doc/lang/fr.php @@ -154,6 +154,7 @@ $lang->doc->allCollections = 'All Collections'; $lang->doc->keywordsTips = 'Please use commas to separate multiple keywords.'; $lang->doc->sortLibs = 'Sort Libs'; $lang->doc->titlePlaceholder = 'Veuillez saisir le titre'; +$lang->doc->confirm = 'Confirm'; global $config; /* Query condition list. */ diff --git a/module/doc/lang/zh-cn.php b/module/doc/lang/zh-cn.php index ca2ba27227..35f81e9190 100644 --- a/module/doc/lang/zh-cn.php +++ b/module/doc/lang/zh-cn.php @@ -154,6 +154,7 @@ $lang->doc->allCollections = '查看全部收藏文档'; $lang->doc->keywordsTips = '多个关键字请用逗号分隔。'; $lang->doc->sortLibs = '文档库排序'; $lang->doc->titlePlaceholder = '请输入标题'; +$lang->doc->confirm = '确认'; global $config; /* 查询条件列表 */ diff --git a/module/doc/view/createtexttype.html.php b/module/doc/view/createtexttype.html.php index b6d140b42d..af17839cb6 100644 --- a/module/doc/view/createtexttype.html.php +++ b/module/doc/view/createtexttype.html.php @@ -46,12 +46,7 @@ #noticeAcl {margin-left: 10px; vertical-align: middle;} -#moreList {display: inline-block; padding: 7px;} -#moreList .icon-more-circle {font-size: 20px;} -#moreList ul.dropdown-menu {left: -77px;} - -#backBtn {border: unset;} -#backBtn i {font-size: 20px;} +#basicInfoLink {border: unset;} .modal-title {font-size: 14px !important; font-weight: 700 !important;} @@ -64,16 +59,11 @@ - + @@ -154,7 +144,7 @@ - +
", $backLink, 'self', "id='backBtn'");?> ' . $lang->goback, '', "class='btn btn-secondary' id='backBtn'");?> doc->titlePlaceholder}' class='form-control' required");?> - + " . $lang->settings, '', "data-toggle='modal' id='basicInfoLink' class='btn'");?>
close, '', "class='btn btn-primary btn-wide'");?>doc->confirm, '', "class='btn btn-primary btn-wide'");?>
diff --git a/module/doc/view/edittexttype.html.php b/module/doc/view/edittexttype.html.php index fa3b18a86e..137a001a85 100644 --- a/module/doc/view/edittexttype.html.php +++ b/module/doc/view/edittexttype.html.php @@ -49,12 +49,7 @@ #noticeAcl {margin-left: 10px; vertical-align: middle;} -#moreList {display: inline-block; padding: 7px;} -#moreList .icon-more-circle {font-size: 20px;} -#moreList ul.dropdown-menu {left: -77px;} - -#backBtn {border: unset;} -#backBtn i {font-size: 20px;} +#basicInfoLink {border: unset;} .modal-title {font-size: 14px !important; font-weight: 700 !important;} @@ -64,20 +59,11 @@ - - - - - + @@ -155,7 +141,7 @@ - +
", $backLink, 'self', "id='backBtn'");?>", "id='backBtn'", '');?> " . $lang->goback, "id='backBtn'", 'btn btn-secondary');?> title, "placeholder='{$lang->doc->titlePlaceholder}' class='form-control' required");?> - + " . $lang->settings, '', "data-toggle='modal' id='basicInfoLink' class='btn'");?>
close, '', "class='btn btn-primary btn-wide'");?>doc->confirm, '', "class='btn btn-primary btn-wide'");?>
diff --git a/module/upgrade/model.php b/module/upgrade/model.php index d58fe72362..5346f4ee33 100644 --- a/module/upgrade/model.php +++ b/module/upgrade/model.php @@ -532,6 +532,15 @@ class upgradeModel extends model break; case '17_4': $this->updateSearchIndex(); + if(!$executedXuanxuan) + { + $table = $this->config->db->prefix . 'im_chat'; + $result = $this->checkFieldsExists($table, 'adminInvite'); + if($result->rowCount() == 0) + { + $this->dbh->query("ALTER TABLE $table ADD `adminInvite` enum('0','1') NOT NULL DEFAULT '0' AFTER `mergedChats`"); + } + } break; } @@ -7036,4 +7045,17 @@ class upgradeModel extends model return !dao::isError(); } + + /** + * Check whether the field exists. + * + * @param string $table + * @param string $field + * @access public + * @return object + */ + public function checkFieldsExists($table, $field) + { + return $this->dbh->query("show columns from `$table` like '$field'"); + } }