commit f08746f666647fac6c653d54f30c6db7a4d10bf9 Author: topaLE <63888024+topa-LE@users.noreply.github.com> Date: Fri May 8 18:56:44 2020 +0200 Initial commit diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..dfe0770 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,2 @@ +# Auto detect text files and perform LF normalization +* text=auto diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..aaf95a8 --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2020 topaLE + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..529e768 --- /dev/null +++ b/README.md @@ -0,0 +1,52 @@ +# seafile-Blue-Dark-Theme +For the cloud software seafile a custom theme in Dark Blue ;-) + +

Usage / Installation

+Switch to user seafile and create the folder custom and folder img: +

+
+sudo su seafile
+cd
+mkdir /home/seafile/sea-hub/custom
+mkdir /home/seafile/seahub-data/img
+
+ +

Create Symlinks

+ln -s /home/seafile/seahub-data/custom /home/seafile/seafile-server-latest/seahub/media/custom +
+ln -s /home/seafile/seahub-data/img /home/seafile/seafile-server-latest/seahub/media/images +

+

Procedure

+Copy the entire contents of the custom and img folder to the seahub-data/custom and seahub-data/img. The Owner of these folders and files must be seafile. +

+Edit the File: conf/seahub_settings.py + +
+BRANDING_CSS = 'custom/custom.css'
+FILE_SERVER_ROOT = 'https://your_ip_adresse_or_dyndns.com/seafhttp'
+FAVICON_PATH = 'custom/favicon.png'
+LOGO_PATH = 'custom/custom-logo.png'
+LOGO_WIDTH = 160
+LOGO_HEIGHT = 40
+
+ +Optionally you can use the logo/favicon or login background or your own picture. Alternatively, you can use the folder file folder-192.png and copy from /img to: +
/home/seafile/seafile-server-latest/seahub/media/img/
+ +Then the Seafile server and Seahub must be restarted. +
+sudo systemctl restart seafile.service
+sudo systemctl restart seahub.service
+
+ +Have Fun ;-) + +

Screenshots

+Folder + +Folder + +Folder + +
You can find more screens in the folder: Screenshots
+ diff --git a/Saira Font.zip b/Saira Font.zip new file mode 100644 index 0000000..83fc18d Binary files /dev/null and b/Saira Font.zip differ diff --git a/Screenshots/screen-1.png b/Screenshots/screen-1.png new file mode 100644 index 0000000..0b6674c Binary files /dev/null and b/Screenshots/screen-1.png differ diff --git a/Screenshots/screen-2.png b/Screenshots/screen-2.png new file mode 100644 index 0000000..08ffc71 Binary files /dev/null and b/Screenshots/screen-2.png differ diff --git a/Screenshots/screen-3.png b/Screenshots/screen-3.png new file mode 100644 index 0000000..e20fbc7 Binary files /dev/null and b/Screenshots/screen-3.png differ diff --git a/Screenshots/screen-4.png b/Screenshots/screen-4.png new file mode 100644 index 0000000..d6bebfc Binary files /dev/null and b/Screenshots/screen-4.png differ diff --git a/Screenshots/screen-5.png b/Screenshots/screen-5.png new file mode 100644 index 0000000..1a16459 Binary files /dev/null and b/Screenshots/screen-5.png differ diff --git a/Screenshots/screen-6.png b/Screenshots/screen-6.png new file mode 100644 index 0000000..74f34da Binary files /dev/null and b/Screenshots/screen-6.png differ diff --git a/Screenshots/screen-7.png b/Screenshots/screen-7.png new file mode 100644 index 0000000..a771eef Binary files /dev/null and b/Screenshots/screen-7.png differ diff --git a/Screenshots/screen-8.png b/Screenshots/screen-8.png new file mode 100644 index 0000000..2cef791 Binary files /dev/null and b/Screenshots/screen-8.png differ diff --git a/custom/custom-logo.png b/custom/custom-logo.png new file mode 100644 index 0000000..99c65b2 Binary files /dev/null and b/custom/custom-logo.png differ diff --git a/custom/custom.css b/custom/custom.css new file mode 100644 index 0000000..1e65464 --- /dev/null +++ b/custom/custom.css @@ -0,0 +1,954 @@ +/** Seafile Themes Blue Dark +*** Developer tpDEsign 2020 +*/ + +/* +@import url('https://fonts.googleapis.com/css?family=Play&display=swap'); +@import url('https://fonts.googleapis.com/css2?family=Saira+Condensed:wght@300&display=swap'); +*/ + +body { +margin: 0; +font-family: 'Saira Condensed', 'Play', Roboto, "Helvetica Neue", Helvetica, Arial, sans-serif; +font-size: 0.9995rem; +font-weight: 300 !important; +line-height: 1.5; +color: #212529; +text-align: left; +background-color: #0e1621; +} + +a:focus, a:hover { +color: #f6964c; +} + +a { +color: #f3f3f3; +} + +.grid-item:hover a { +color: #fb9e56; +} + +.grid-file-name-link { +color: #fff; +font-size: 15px; +} + +.grid-selected-active { +background-color:#0e1621; +} + +.grid-item:hover .grid-file-img-link { + background:#0e1621; +} + +.grid-drop-show { +background:#0e1621; +} + +#header { +background: #0e1621; +width: 100%; +height: 55px; +font-size: 15px; +padding: 8px 16px 4px; +display: flex; +justify-content: space-between; +flex-shrink: 0; +border-bottom: none !important; +border-radius: 5px !important; +margin: 5px; +} + +.shared-file-view-md-header { +background: #0e1621; +height: 55px; +border-bottom: none !important; +padding: 8px 16px 4px; +-ms-flex-pack: justify; +justify-content: space-between; +} + +.shared-file-view-md-main { +height: calc(100% - 55px); +} + +.shared-file-view-head h2 { +color: #fb9e56; +font-size: 20px; +} + +.shared-file-view-head .share-by { +color: #fff; +} + +#viewerContainer { +background: #16212f; +} + +.top-header { +background: #0e1621; +width: 100%; +height: 55px; +font-size: 15px; +padding: .5rem 1rem; +-ms-flex-negative: 0; +flex-shrink: 0; +border-bottom: none !important; +} + +.hide { +display: none !important; +} + +.side-panel-north { +background: #0e1621; +border-bottom: none !important; +} + +.main-panel-north { +background: #0e1621; +border-bottom: none !important; +} + +.border-left-show:before { +position:absolute; +top:10px; +left:0; +width:0px; +height:30px; +content:""; +background-color:#0e1621; +} + +/* Navbar */ +.side-panel-center { +background-color: #16212f !important; +margin: 10px; +border-radius: 5px !important; +border-right: none !important; +} + +.side-panel.o-auto { +background-color: #16212f !important; +margin: 10px 10px 10px 10px; +border-radius: 5px !important; +border-right: none !important; +} + +.side-panel-footer { +border-right: none !important; +} + +.side-nav-footer { +padding: 12px 20px 16px; +background: #0e1621; +border-top: none !important; +font-size: 16px; +} + +.side-nav-footer .item { +color: #fb9e56 !important; +font-weight: normal; +margin-right: 11px; +} + +.side-panel { +background-color: #0e1621; +border-right: none !important; +} + +.side-nav-con { +padding: 15px; +color: #fff !important; +background-color: #16212f !important; +margin: 10px; +border-radius: 5px !important; +border-right: none !important; +} + +.side-textnav-tabs .tab-cur a, .side-textnav-tabs .tab a:hover { +color: #fb9e56; +text-decoration: none; +} + +.side-textnav-tabs .tab a { +border-bottom: 1px solid #0e1621; +margin-bottom: 3px; +} + +.nav-pills .nav-item .nav-link.active { +background-color: #212d3d !important; +color: #fff; +border: none; +} + +.nav-pills .nav-item .nav-link:hover { +color: #fff; +background-color: #212d3d; +} + +.side-nav-con .nav .nav-item, .side-nav-con .nav .nav-item .nav-link { +color: #fff; +} + +.side-tabnav-tabs .tab a:hover { +background-color: #0e1621; +text-decoration: none; +} + +.side-nav-con [class^="sf2-icon-"], .side-nav-con [class^="sf3-font-"] { +color: #fb9e56; +} + +.share-dialog .nav .nav-item .nav-link { +padding: .3125rem 1rem .3125rem .25rem; +color: #fb9e56; +} + +.side-nav { +padding: 0; +overflow: hidden; +border-right: 0px solid #eee; +} + +.side-textnav .hd, +.side-info .hd { +padding:4px; +background: #0e1621; +border-bottom: none !important; +margin-bottom:1em; +border-radius: 3px; +} + +.tp-side-nav-sys { +background-color: #16212f !important; +margin: 10px; +border-radius: 5px !important; +border-right: none !important; +} + +.side-nav-con .sub-nav .nav-link { +padding: 0; +display: block; +font-size: 0.875rem; +line-height: 1.5rem; +} + +.side-tabnav-tabs .tab a { +display: block; +font-size: 19px; +padding: 4px 4px 4px 0; +color: #fff; +font-weight: normal; +} + +.side-tabnav-tabs .tab-cur a, .side-tabnav-tabs .tab-cur a:hover { +background-color: #0e1621; +} +/* Navbar */ + +.add-tag-link:hover { +color: #fff; +background: #293749; +} + +p.tip { +color: #fff; +} + +.group-list-panel .group-item-empty-tip { +text-align: center; +padding: 4px 0; +border-bottom: 1px solid #12151e; +} + +.group-list-panel .group-item-heading { +font-size: 1rem; +font-weight: 400; +padding: .25rem; +border-bottom: 1px solid #12151e; +margin: .75rem 0 0; +} + +.account-popup .sf-popover-con { +padding: 0; +font-size: 16px; +background-color: #e0e9f7; +} + +/* Login */ + +.login-panel { +background: #0e1621; +border-radius: 4px; +padding: 20px 60px; +width: 390px; +margin: 0 auto; +/* box-shadow: 0 0 8px #a7a6a9; */ +box-shadow: 0 0 8px #f6964c; +} + +.login-panel-hd { +font-size: 20px; +color: #fff; +} + +span.vam { +color: #fff; +} + +.text-logout-color { +font-size: 22px; +color: #fff; +} + +.tp-reg-label { +color: #fff; +} + +/* Login */ + +.btn-primary:hover { +color: #fff; +background-color: #e6904e; +border-color: #ed7b16; +} + +.btn-primary { +color: #fff; +background-color: #f6964c; +border-color: #f6964c; +} + +.btn { +font-weight: 600; +letter-spacing: 0.06em; +font-size: 18px; +min-width: 6.375rem; +} + +.btn-outline-primary { +color: #f6964c; +background-color: #0e1621; +background-image: none; +border-color: #fbc79a; +} + +.btn-white { +height: 35px; +font-size: 19px; +} + +.sf-heading { +font-size: 20px; +color: #fb9e56; +font-weight: normal; +line-height: 1.5; +} + +.block-tp-settings-layout { +background-color: #16212f !important; +padding: 10px; +border-radius: 5px !important; +} + +.cur-view-path { +padding: 8px 16px; +max-height: 40px; +background: #16212f !important; +margin: 8px; +border-radius: 5px !important; +position:inherit; +} + +.cur-view-content { +background: #16212f !important; +margin: 8px; +padding: 8px; +border-radius: 5px !important; +} + +.cur-view-container .fa-star.fas { +color: #fb9e56; +} + +.dir-content-nav { +background-color: #16212f; +border-right: 1px solid #0e1621; +} + +.tree-node-inner .tree-node-text { +font-size: 18px; +color: #fff; +} + +.tree-node-inner-hover { +background-color:#0e1621; +} + +.uploader-list-header { +background-color: #0e1621; +padding: .375rem .625rem; +font-size: 19px; +line-height: 1.5; +color: #fb9e56; +display: -ms-flexbox; +display: flex; +-ms-flex-pack: justify; +justify-content: space-between; +min-height: 2.25rem; +} + +.uploader-list-view { +display: -ms-flexbox; +display: flex; +-ms-flex-direction: column; +flex-direction: column; +position: fixed; +right: 50px; +bottom: 50px; +width: 720px; +height: 20rem; +border: 1px solid #0c0c0b; +border-radius: 3px; +-webkit-box-shadow: 0 0 6px #fb9e56; +box-shadow: 0 0 6px #171614; +background-color: #0e1621; +z-index: 1050; +} + +.uploader-list-content { +padding: 0 1rem 1.25rem; +background-color: #111a26; +overflow: auto; +} + +.upload-operation .saving { +color: #fb9e56; +} + +.file-chooser-item .item-active { +background:#fb9e56 !important; +color:#fff; +} + +.file-chooser-item .item-info:hover { + background:#fb9e56; +} + +.list-view-header:hover { +background-color: #16212f; +color: #fff; +} + +table thead tr { +height: 3.0rem; +} + +table td { +padding: 0.5rem 0.1875rem; +padding-left: 0.1875rem; +border-bottom: 1px solid #0e1621; +color: #fff; +font-size: 18px; +word-break: break-all; +} + +table th { +padding: 0.3125rem 0.1875rem; +border-bottom: 1px solid #16212f; +text-align: left; +font-weight: normal; +font-size: 20px; +line-height: 1.7; +color: #9c9c9c; +} + +.tr-active { +background-color: #0e1621 !important; +} + +.tr-highlight { +background-color: #0e1621; +} + +.empty-tip { +margin: 5.5em 1em; +border: 2px solid #0b1319; +border-radius: 8px; +padding: 28px; +background-color: #151d28; +text-align: center; +} + +.empty-tip h2 { +font-size: 1.325rem; +text-align: center; +color: #fb9e56; +font-weight: bold; +} + +.empty-tip p { +color: #fff; +} + +#notifications .sf2-icon-bell { +font-size: 24px; +line-height: 1; +color: #fb9e56; +} + +.nav .nav-item .nav-link.active { +color: #fb9e56; +text-decoration: none; +border-bottom: none; +} + +.nav .nav-item .nav-link { +padding: 0.5rem 2; +margin-right: 0.5rem; +color: #f3f3f3; +} + +.tabnav { +padding: 8px 10px; +padding-bottom: 3px; +background: #16212f; +margin-bottom: .5em; +border-radius: 3px; +border: 1px solid #3c3f43; +} + +.tabnav-tab-cur a, .tabnav-tab a:hover { +color: #fb9e56; +text-decoration: none; +border-bottom-color: #fb9e56; +font-size: 18px; +} + +.tabnav button { +height: 29px; +background: #fff; +line-height: 17px; +font-size: 17px; +} + +.tabnav-tab-cur a, .tabnav-tab a { +color: #f3f3f3; +font-size: 18px; +} + +button { +font-size: 16px; +} + +.input, .textarea { +width: 300px; +padding: 2px 3px; +border-radius: 2px; +margin-bottom: 5px; +} + +.input-tip { +padding-top: calc(.375rem + 1px); +color: #a6a4a4; +font-size: 17px; +} + +.hl { +background-color: #131d29; +} + +.file-title { +color: #fff; +} + +#paginator { +text-align: center; +font-size: 17px; +color: #fb9e56; +} + +.side-tabnav h3.hd { +font-size: 19px; +color: #fb9e56; +font-weight: normal; +} + +.meta-info { +font-size: 15px; +color: #fff; +} + +.header-bar { +padding: 9px 10px; +padding-bottom: 9px; +background: #16212f; +margin-bottom: .5em; +border-radius: 3px; +border: 1px solid #3c3f43; +padding-bottom: 0; +height: 48px; +overflow: hidden; +} + +dd { +margin-bottom: .8em; +color: #fb9e56; +} + +dt { +color: #c1c6cc; +margin: 24px 0 2px; +font-weight: normal; +font-size: 20px; +} + +#right-panel .hd { +background: #16212f; +margin-bottom: .5em; +border-radius: 3px; +border: 1px solid #3c3f43; +} + +#right-panel .hd .ui-state-active .a, #right-panel .hd .a:hover { +color: #fb9e56; +text-decoration: none; +border-bottom-color: #fb9e56; +font-size: 20px; +} + +#right-panel .hd .a { +font-size: 20px; +color: #fff; +} + +#right-panel .hd, .tabnav, .wiki-top { +padding-bottom: 0; +height: 62px; +} + +#right-panel .hd h3, #right-panel h3.hd { +line-height: 41px; +margin-bottom: 0; +} + +.tp-font-settings { +font-size: 17px !important; +color: #fff !important; +text-align: justify !important; +margin-top: 5px; +margin-bottom: 5px; +} + +.side-search-form .input { +width: calc(100% - 12px); +padding: 3px 6px; +background: #f3f3f3; +box-shadow: inset 0 1px 2px rgba(0,0,0,0.075); +font-size: 18px; +} + +h2 { +color: #fff !important; +font-weight: 300 !important; +} + +h3 { +font-size: 20px; +color: #f3f3f3; +font-weight: normal; +} + +h4 { +font-size: 17px; +color: #f3f3f3 !important; +} + +h5 { +font-size: 19px; +} + +li { +color: #fff; +} + +.op-bar { +padding: 9px 10px; +background: #16212f; +border-radius: 2px; +} + +.op-target { +color: #fb9e56; +word-wrap: break-word; +} + +p.m-0 { +color: #fff; +font-size: 18px; +} + +.messages .success { +padding: 7px; +background: #569D27; +margin: 0; +} + +.web-setting-name { +width: 200px; +padding: 0 10px; +vertical-align: top; +font-weight: normal; +line-height: 28px; +color: #fff; +} + +.web-setting-name, .web-setting-input .input { +margin: 0; +font-size: 19px; +} + +.block-tp-settings-untertext { +font-size: 15px; +color: #fff; +} + +.seahub-web-settings h4 { +background: #16212f; +margin-bottom: .5em; +border-radius: 3px; +border: 1px solid #3c3f43; +color: #fff; +} + +.side-tabnav-tabs .tab [class^="sf2-icon-"] { +display: inline-block; +width: 42px; +margin-right: 5px; +text-align: center; +vertical-align: middle; +font-size: 24px; +line-height: 1; +color: #fb9e56; +} + +#main p { +font-size: 18px; +color: #fb9e56; +} + +.sf-popover { +width: 250px; +background: #e0e9f7; +border: 1px solid #c9c9c9; +border-radius: 3px; +box-shadow: 0 0 4px #ccc; +position: absolute; +z-index: 20; +} + +.up-outer-caret .inner-caret { +border-bottom-color: #e0e9f7; +top: 1px; +left: -10px; +} + +#notice-popover .view-all { +display: block; +padding: 7px 0; +text-align: center; +color: #fb9e56; +} + +label { +display: inline-block; +margin: 4px 0px; +} + +.uploader-list-header { +background-color: #0e1621; +padding: .375rem .625rem; +font-size: 19px; +line-height: 1.5; +color: #fb9e56; +display: -ms-flexbox; +display: flex; +-ms-flex-pack: justify; +justify-content: space-between; +min-height: 2.25rem; +} + +.file-view-content { +padding: 30px 0; +background: #16212f; +border-right: 4px solid transparent; +} + +.file-view-header { +padding: 4px 10px; +border-bottom: 2px solid #fb9e56; +} + +.modal-content { +background-color: #e0e9f7; +background-clip: padding-box; +/* border: 1px solid rgba(0, 0, 0, 0.2); */ +border: 2px solid #16212f; +border-radius: 4px; +} + +.modal-content a { +color: #fb9e56; +} + +.modal-title { +margin-bottom: 0; +line-height: 1.5; +color: #16212f; +font-size: 20px; +font-weight: 200; +} + +.tip { +color: #16212f; +} + +.file-star:focus, .file-star:hover { +text-decoration: none; +color: #fb9e56; +} + +.seafile-comment { +border-left: 1px solid #16212f; +} + +.path-container { +color: #fff; +} + +.path-link { +color: #fb9e56 !important; +} + +.path-toolbar .toolbar-item a:hover { +color: #fb9e56; +} + +.path-toolbar .toolbar-item a { +color: #f3f3f3; +} + +.detail-container { +border-left: 2px solid #0e1621; +background: #16212f !important; +} + +.dirent-table-container th { +font-size: 14px; +text-align: left; +font-weight: 400; +color: #f3f3f3; +} + +.dirent-table-container td { +font-size: 16px; +color: #fb9e56; +word-break: break-all; +} + +.detail-header { +background-color: #0e1621; +border-bottom: 1px solid #0e1621; +height: 40px; +} + +.detail-header .detail-title .name { +margin: 0 .5rem 0 .25rem; +line-height: 1.5rem; +vertical-align: middle; +font-size: 18px; +color: #fb9e56; +} + +.user-setting-nav .nav-item .nav-link { +color: #fff; +font-size: 19px; +} + +.user-setting-nav .nav-item.active .nav-link { +color: #fb9e56; +border-color: #fb9e56; +} + +.user-setting-nav .nav-item .nav-link:hover { +color: #fb9e56; +} + +.heading { +padding: 8px 16px; +background: #16212f !important; +margin: 8px; +border-radius: 5px !important; +font-size: 20px; +color: #fff; +font-weight: 400; +line-height: 1.5; +} + +.content.position-relative { +background: #16212f !important; +margin: 10px; +border-radius: 5px !important; +font-size: 20px; +color: #fb9e56; +width: 97%; +} + +.setting-item-heading { +font-size: 19px; +color: #f3f3f3; +font-weight: 200; +padding-bottom: .2em; +border-bottom: none !important; +} + +#quota-bar { +display: block; +height: 1em; +border: 1px solid #1d2939; +margin: 5px 0; +border-radius: 2px; +overflow: hidden; +} + +.old-history-main .file-name { +color: #fb9e56; +word-wrap: break-word; +} + +.old-history-main h2 { +font-size: 1.5em; +color: #f3f3f3; +font-weight: 200; +line-height: 1.5; +} + +.old-history-main .commit-list .username { +vertical-align: middle; +color: #fb9e56; +text-decoration: none; +font-weight: 700; +} + +#right-panel.help-con .hd { +font-weight: normal; +margin-bottom: 15px; +color: #fff; +} + +.col-form-label { +font-size: 17px; +} diff --git a/custom/favicon.ico b/custom/favicon.ico new file mode 100644 index 0000000..dc8d1c2 Binary files /dev/null and b/custom/favicon.ico differ diff --git a/custom/templates/base.html b/custom/templates/base.html new file mode 100644 index 0000000..e5bbbae --- /dev/null +++ b/custom/templates/base.html @@ -0,0 +1,266 @@ +{% load seahub_tags avatar_tags group_avatar_tags i18n staticfiles %} + + + + +{% block sub_title %}{% endblock %}{{ site_title }} + + +{% block viewport %} + +{% endblock %} + + +{% block extra_base_style %} + +{% endblock %} + + + + + + + +{% block extra_style %}{% endblock %} +{% if branding_css != '' %}{% endif %} +{% if enable_branding_css %}{% endif %} + + + +
+ {% block info_bar_message %} + {% if request.user.is_authenticated and request.cur_note %} +
+

{{ request.cur_note.message|urlize }}

+ +
+ {% endif %} + {% endblock info_bar_message %} + + + +
{# since #wrapper is `d-flex`, 'w100' is necessary here. #} + {% block main_content %} +
+
+ {% block main_panel %}{% endblock %} +
+
+ {% endblock %} +
+ + {% if messages %} + + {% endif %} + +
+
+ + +
+
+ +{# 'id="jquery"' is for pdf file view with pdf2html #} + + + + + +{% block extra_script %}{% endblock %} + + diff --git a/custom/templates/home_base.html b/custom/templates/home_base.html new file mode 100644 index 0000000..7d86271 --- /dev/null +++ b/custom/templates/home_base.html @@ -0,0 +1,124 @@ +{% extends "base.html" %} +{% load i18n %} + +{% block main_class %}d-flex ovhd{% endblock %} + +{% block main_content %} +
{# 'ovhd' is for Firefox #} +
+ + {% block left_panel %} +

{% trans "Files" %}

+ + +
+

{% trans "Tools" %}

+
+ + {% endblock %} +
+ +
+ {% block right_panel %}{% endblock %} +
+ + {% if user.permissions.can_add_repo %} +
{% csrf_token%} +

{% trans "Enable Modules"%}

+ + +
+ {% endif %} + +
+{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/js/sysadmin-templates.html b/custom/templates/js/sysadmin-templates.html new file mode 100644 index 0000000..652281e --- /dev/null +++ b/custom/templates/js/sysadmin-templates.html @@ -0,0 +1,1030 @@ +{% load avatar_tags i18n %} + + + + + + + + + + + + + + + +{% include "trusted_ip/sysadmin-templates_trusted_ip.html" %} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/custom/templates/registration/login.html b/custom/templates/registration/login.html new file mode 100644 index 0000000..a8c2780 --- /dev/null +++ b/custom/templates/registration/login.html @@ -0,0 +1,170 @@ +{% extends "base.html" %} +{% load i18n %} + +{% block sub_title %}{% trans "Log In" %} - {% endblock %} + +{% block header_css_class %}hide{% endblock %} + +{% block extra_base_style %} + +{% endblock %} + +{% block extra_style %} + +{% endblock %} + +{% block main_content %} +
+
+

{% trans "Log In" %}

+
{% csrf_token %} +
+ + + {% if form.captcha %} +
+ + {{ form.captcha }} +
+ {% endif %} + + + {% if form.errors %} + {% if form.captcha.errors %} + {{ form.captcha.errors}} + {% elif form.errors.freeze_account %} +

{{ form.errors.freeze_account }}

+ {% elif form.errors.inactive %} +

{{ form.errors.inactive }}

+ {% elif form.errors.not_found %} +

{{ form.errors.not_found }}

+ {% else %} +

{% trans "Incorrect email or password" %}

+ {% endif %} + {% else %} +

+ {% endif %} + + + {% trans "Forgot password?" %} + + +
+ + {% if enable_sso %} + {% trans "Single Sign-On" %} + {% endif %} + + +
+
+{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/registration/logout.html b/custom/templates/registration/logout.html new file mode 100644 index 0000000..8a42b9a --- /dev/null +++ b/custom/templates/registration/logout.html @@ -0,0 +1,13 @@ +{% extends "base.html" %} +{% load i18n %} + +{% block sub_title %}{% trans "Log Out" %} - {% endblock %} + +{% block main_content %} +
+ +

{% trans "Thanks for your participation! " %}

+
+{% trans "Log in again" %} +
+{% endblock %} diff --git a/custom/templates/registration/registration_form.html b/custom/templates/registration/registration_form.html new file mode 100644 index 0000000..5921e8d --- /dev/null +++ b/custom/templates/registration/registration_form.html @@ -0,0 +1,110 @@ +{% extends "registration/login.html" %} +{% load i18n %} +{% block sub_title %}{% trans "Signup" %} - {% endblock %} + +{% block extra_style %}{{block.super}} + +{% endblock %} + +{% block main_content %} +
+
+

{% trans "Signup" %}

+ {% if request.user.is_authenticated %} +

{% trans "Welcome back, you are already signed in." %}

+ {% else %} +
{% csrf_token %} + {% if form.name.field.required %} + + {{ form.name }} {{ form.name.errors }} + {% endif %} + + + {{ form.email }} {{ form.email.errors }} + + {{ form.password1 }} {{ form.password1.errors }} +
+ + {{ form.password2 }} {{ form.password2.errors }} + + {% if form.department.field.required %} + + {{ form.department }} {{ form.department.errors }} + {% endif %} + + {% if form.telephone.field.required %} + + {{ form.telephone }} {{ form.telephone.errors }} + {% endif %} + + {% if form.note.field.required %} + + {{ form.note }} {{ form.note.errors }} + {% endif %} + +

+ +
+ + {% endif %} +
+
+{% endblock %} + +{% block extra_script %}{{ block.super }} + + +{% endblock %} diff --git a/custom/templates/sysadmin/base.html b/custom/templates/sysadmin/base.html new file mode 100644 index 0000000..b7b471d --- /dev/null +++ b/custom/templates/sysadmin/base.html @@ -0,0 +1,151 @@ +{% extends "base.html" %} +{% load i18n %} + +{% block top_search %}{% endblock %} {# no 'file search' for system admin pages #} +{% block main_class %}d-flex ovhd{% endblock %} + +{% block admin_link %} + {% trans "Exit System Admin" %} +{% endblock %} + +{% block main_content %} +
+
+ +
+ {% block left_panel %} +

{% trans "System Admin" %}

+ + {% endblock %} +
+
+ +
+ {% block right_panel %}{% endblock %} +
+
+{% endblock %} diff --git a/custom/templates/sysadmin/settings.html b/custom/templates/sysadmin/settings.html new file mode 100644 index 0000000..172a670 --- /dev/null +++ b/custom/templates/sysadmin/settings.html @@ -0,0 +1,362 @@ +{% extends "sysadmin/base.html" %} +{% load seahub_tags i18n %} + +{% block cur_settings %}tab-cur{% endblock %} +{% block right_panel %} +

{% trans "Settings" %}

+ + + +
+ + + +
+{% trans "Note: Settings via web interface are saved in database table (seahub-db/constance_config). They have a higher priority over the settings in config files." %}
+ +

URL Definitionen

+ + + +{% with type="input" setting_display_name="SERVICE_URL" setting_name="SERVICE_URL" setting_val=config_dict.SERVICE_URL %} +{% trans "The URL of the server, like https://seafile.example.com or http://192.168.1.2:8000" as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="input" setting_display_name="FILE_SERVER_ROOT" setting_name="FILE_SERVER_ROOT" setting_val=config_dict.FILE_SERVER_ROOT %} +{% trans "The internal URL for downloading/uploading files. Users will not be able to download/upload files if this is not set correctly. If you config Seafile behind Nginx/Apache, it should be SERVICE_URL/seafhttp, like https://seafile.example.com/seafhttp ." as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + + + +

{% trans "Branding" %}

+ + + +{% with type="input" setting_display_name="SITE_TITLE" setting_name="SITE_TITLE" setting_val=config_dict.SITE_TITLE %} +{% trans "Site title shown in a browser tab" as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="input" setting_display_name="SITE_NAME" setting_name="SITE_NAME" setting_val=config_dict.SITE_NAME %} +{% trans "Site name used in email sending" as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="file" setting_display_name="Logo" setting_name="logo" file_path=logo_path file_width=256 file_height=64 help_tip="logo.png, 256px * 64px" %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="file" setting_display_name="Favicon" setting_name="favicon" file_path=favicon_path file_width=32 file_height=32 help_tip="favicon.ico, 32px * 32px" %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="file" setting_name="login_bg_image" file_path=login_bg_image_path file_width=240 file_height=160 help_tip="login-bg.jpg, 2400px * 1600px" %} +{% trans "Login Background Image" as setting_display_name %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="checkbox" setting_name="ENABLE_BRANDING_CSS" setting_val=config_dict.ENABLE_BRANDING_CSS %} +{% trans "ENABLE_BRANDING_CSS" as setting_display_name %} +{% trans "Use custom CSS" as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="code-textarea" setting_name="CUSTOM_CSS" setting_val=config_dict.CUSTOM_CSS %} +{% trans "Custom CSS" as setting_display_name %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + + + +

{% trans "User" %}

+ + + +{% with type="checkbox" setting_name="ENABLE_SIGNUP" setting_val=config_dict.ENABLE_SIGNUP %} +{% trans "allow new registrations" as setting_display_name %} +{% trans "Allow new user registrations. Uncheck this to prevent anyone from creating a new account." as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="checkbox" setting_name="ACTIVATE_AFTER_REGISTRATION" setting_val=config_dict.ACTIVATE_AFTER_REGISTRATION %} +{% trans "activate after registration" as setting_display_name %} +{% trans "Activate user immediately after registration. If unchecked, a user need to be activated by administrator or via activation email" as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="checkbox" setting_name="REGISTRATION_SEND_MAIL" setting_val=config_dict.REGISTRATION_SEND_MAIL %} +{% trans "send activation email" as setting_display_name %} +{% trans "Send activation Email after user registration." as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="input" setting_name="LOGIN_REMEMBER_DAYS" setting_val=config_dict.LOGIN_REMEMBER_DAYS %} +{% trans "keep sign in" as setting_display_name %} +{% trans "Number of days that keep user sign in." as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="input" setting_display_name="LOGIN_ATTEMPT_LIMIT" setting_name="LOGIN_ATTEMPT_LIMIT" setting_val=config_dict.LOGIN_ATTEMPT_LIMIT %} +{% trans "The maximum number of failed login attempts before showing CAPTCHA." as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + +{% with type="checkbox" setting_display_name="FREEZE_USER_ON_LOGIN_FAILED" setting_name="FREEZE_USER_ON_LOGIN_FAILED" setting_val=config_dict.FREEZE_USER_ON_LOGIN_FAILED %} +{% trans "Freeze user account when failed login attempts exceed limit." as help_tip %} +{% include "snippets/web_settings_form.html" %} +{% endwith %} + + + +

{% trans "Groups" %}

+ + {% with type="checkbox" setting_display_name="ENABLE_SHARE_TO_ALL_GROUPS" setting_name="ENABLE_SHARE_TO_ALL_GROUPS" setting_val=config_dict.ENABLE_SHARE_TO_ALL_GROUPS %} + {% trans "Enable users to share libraries to any groups in the system." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + +

{% trans "Password" %}

+ + {% with type="checkbox" setting_name="USER_STRONG_PASSWORD_REQUIRED" setting_val=config_dict.USER_STRONG_PASSWORD_REQUIRED %} + {% trans "strong password" as setting_display_name %} + {% trans "Force user to use a strong password when sign up or change password." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="checkbox" setting_name="FORCE_PASSWORD_CHANGE" setting_val=config_dict.FORCE_PASSWORD_CHANGE %} + {% trans "force password change" as setting_display_name %} + {% trans "Force user to change password when account is newly added or reset by admin" as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="input" setting_name="USER_PASSWORD_MIN_LENGTH" setting_val=config_dict.USER_PASSWORD_MIN_LENGTH %} + {% trans "password minimum length" as setting_display_name %} + {% trans "The least number of characters an account password should include." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="input" setting_name="USER_PASSWORD_STRENGTH_LEVEL" setting_val=config_dict.USER_PASSWORD_STRENGTH_LEVEL %} + {% trans "password strength level" as setting_display_name %} + {% trans "The level(1-4) of an account password's strength. For example, '3' means password must have at least 3 of the following: num, upper letter, lower letter and other symbols" as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="checkbox" setting_name="ENABLE_TWO_FACTOR_AUTH" setting_val=config_dict.ENABLE_TWO_FACTOR_AUTH %} + {% trans "enable two factor authentication" as setting_display_name %} + {% trans "Enable two factor authentication" as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + +

{% trans "Library" %}

+ + {% with type="checkbox" setting_name="ENABLE_REPO_HISTORY_SETTING" setting_val=config_dict.ENABLE_REPO_HISTORY_SETTING %} + {% trans "library history" as setting_display_name %} + {% trans "Allow user to change library history settings" as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="checkbox" setting_name="ENABLE_ENCRYPTED_LIBRARY" setting_val=config_dict.ENABLE_ENCRYPTED_LIBRARY %} + {% trans "encrypted library" as setting_display_name %} + {% trans "Allow user to create encrypted libraries" as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="input" setting_name="REPO_PASSWORD_MIN_LENGTH" setting_val=config_dict.REPO_PASSWORD_MIN_LENGTH %} + {% trans "library password minimum length" as setting_display_name %} + {% trans "The least number of characters an encrypted library password should include." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="input" setting_name="SHARE_LINK_PASSWORD_MIN_LENGTH" setting_val=config_dict.SHARE_LINK_PASSWORD_MIN_LENGTH %} + {% trans "download/upload link password minimum length" as setting_display_name %} + {% trans "The least number of characters a download/upload link password should include." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="checkbox" setting_display_name="ENABLE_USER_CREATE_ORG_REPO" setting_name="ENABLE_USER_CREATE_ORG_REPO" setting_val=config_dict.ENABLE_USER_CREATE_ORG_REPO %} + {% trans "Allow user to add organization libraries. Otherwise, only system admin can add organization libraries." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + {% with type="checkbox" setting_display_name="ENABLE_USER_CLEAN_TRASH" setting_name="ENABLE_USER_CLEAN_TRASH" setting_val=config_dict.ENABLE_USER_CLEAN_TRASH %} + {% trans "Allow user to clean library trash" as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + +

{% trans "Online Preview" %}

+ + {% with type="textarea" setting_name="TEXT_PREVIEW_EXT" setting_val=config_dict.TEXT_PREVIEW_EXT %} + {% trans "text file extensions" as setting_display_name %} + {% trans "Extensions of text files that can be online previewed, each suffix is separated by a comma." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + +

{% trans "Sync" %}

+ + {% with type="checkbox" setting_display_name="DISABLE_SYNC_WITH_ANY_FOLDER" setting_name="DISABLE_SYNC_WITH_ANY_FOLDER" setting_val=config_dict.DISABLE_SYNC_WITH_ANY_FOLDER %} + {% trans "If turn on, the desktop clients will not be able to sync a folder outside the default Seafile folder." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + +

{% trans "Terms" %}

+ + {% with type="checkbox" setting_display_name="ENABLE_TERMS_AND_CONDITIONS" setting_name="ENABLE_TERMS_AND_CONDITIONS" setting_val=config_dict.ENABLE_TERMS_AND_CONDITIONS %} + {% trans "Enable system admin to add Terms and Conditions, and all users will have to accept the terms." as help_tip %} + {% include "snippets/web_settings_form.html" %} + {% endwith %} + + + + + + +
+{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/sysadmin/sys_inst_info_admins.html b/custom/templates/sysadmin/sys_inst_info_admins.html new file mode 100644 index 0000000..acc7e54 --- /dev/null +++ b/custom/templates/sysadmin/sys_inst_info_admins.html @@ -0,0 +1,62 @@ +{% extends "sysadmin/sys_inst_info_base.html" %} +{% load i18n seahub_tags %} + +{% block right_panel %} +
+ +
+ +{% if admins %} + + + + + + + + + + {% for user in admins %} + + + + + + + + {% endfor %} +
{% trans "Email" %}{% trans "Status" %}{% trans "Space Used" %}{% trans "Create At / Last Login" %}{% trans "Operations" %}
{{ user.email }} +
+ {% if user.is_active %} + {% trans "Active" %} + {% else %} + {% trans "Inactive" %} + {% endif %} +
+
+

{{ user.space_usage|seahub_filesizeformat }} {% if user.space_quota > 0 %} / {{ user.space_quota|seahub_filesizeformat }} {% endif %}

+
+ {{ user.ctime|tsstr_sec }} / {% if user.last_login %}{{user.last_login|translate_seahub_time}} {% else %} -- {% endif %} + + {% trans "Revoke Admin" %} +
+{% else %} +

{% trans "Empty" %}

+{% endif %} + +{% endblock %} + +{% block extra_script %}{{ block.super }} + +{% endblock %} diff --git a/custom/templates/sysadmin/sys_inst_info_user.html b/custom/templates/sysadmin/sys_inst_info_user.html new file mode 100644 index 0000000..a1a3158 --- /dev/null +++ b/custom/templates/sysadmin/sys_inst_info_user.html @@ -0,0 +1,182 @@ +{% extends "sysadmin/sys_inst_info_base.html" %} +{% load i18n seahub_tags %} +{% load staticfiles %} + +{% block extra_style %} + + +{% endblock %} + +{% block right_panel %} +
+ +
+ +
+
+ +
+

{% trans "Add Members" %}

+
+
+

+ +
+{% if users %} + + + + + + + + + + {% for user in users %} + + + + + + + + {% endfor %} +
{% trans "Email" %}{% trans "Status" %}{% trans "Space Used" %}{% trans "Create At / Last Login" %}{% trans "Operations" %}
{{ user.email }} +
+ {% if user.is_active %} + {% trans "Active" %} + {% else %} + {% trans "Inactive" %} + {% endif %} +
+
+ {{ user.space_usage|seahub_filesizeformat }} {% if user.space_quota > 0 %} / {{ user.space_quota|seahub_filesizeformat }} {% endif %} + + {{ user.ctime|tsstr_sec }} / {% if user.last_login %}{{user.last_login|translate_seahub_time}} {% else %} -- {% endif %} + + {% if user.inst_admin %}{% trans "Revoke Admin" %}{% else %}{% trans "Set Admin" %}{% endif %} +
+{% include "snippets/admin_paginator.html" %} +{% else %} +

{% trans "Empty" %}

+{% endif %} + +
+

{% trans "Activating..., please wait" %}

+
+ +{% endblock %} + +{% block extra_script %}{{ block.super }} + + + +{% endblock %} diff --git a/custom/templates/sysadmin/sys_inst_search_user.html b/custom/templates/sysadmin/sys_inst_search_user.html new file mode 100644 index 0000000..b9fa543 --- /dev/null +++ b/custom/templates/sysadmin/sys_inst_search_user.html @@ -0,0 +1,62 @@ +{% extends "sysadmin/sys_inst_info_base.html" %} +{% load i18n seahub_tags %} + +{% block right_panel %} +

{% trans "Search User"%}

+ +
+
+
+ +
+

{% trans "Result"%}

+ +{% if users %} + + + + + + + + + + {% for user in users %} + + + + + + + + {% endfor %} +
{% trans "Email" %}{% trans "Status" %}{% trans "Space Used" %}{% trans "Create At / Last Login" %}{% trans "Operations" %}
{{ user.email }} +
+ {% if user.is_active %} + {% trans "Active" %} + {% else %} + {% trans "Inactive" %} + {% endif %} +
+
+

{{ user.space_usage|seahub_filesizeformat }} {% if user.space_quota > 0 %} / {{ user.space_quota|seahub_filesizeformat }} {% endif %}

+
+ {{ user.ctime|tsstr_sec }} / {% if user.last_login %}{{user.last_login|translate_seahub_time}} {% else %} -- {% endif %} + + {% if user.inst_admin %}{% trans "Revoke Admin" %}{% else %}{% trans "Set Admin" %}{% endif %} +
+{% else %} +

{% trans "No result" %}

+{% endif %} + +{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/sysadmin/sys_org_info_library.html b/custom/templates/sysadmin/sys_org_info_library.html new file mode 100644 index 0000000..99990da --- /dev/null +++ b/custom/templates/sysadmin/sys_org_info_library.html @@ -0,0 +1,61 @@ +{% extends "sysadmin/sys_org_info_base.html" %} +{% load i18n seahub_tags %} + +{% block right_panel %} +
+ {% with cur_tab='library' %} + {% include 'sysadmin/snippets/sys_org_info_nav.html' %} + {% endwith %} +
+ +{% if org_repos %} + + + + + + + + + {% for repo in org_repos %} + + {% if repo.encrypted %} + + {% else %} + + {% endif %} + + + + + + {% endfor %} +
{% trans "Name" %}ID{% trans "Owner" %}{% trans "Operations" %}
{% trans {% trans {{ repo.name }}{{ repo.id }} + {% if repo.owner %} + {{ repo.owner}} + {% else %} + -- + {% endif %} + +
+ {% trans "Delete" %} +
+
+{% else %} +
+

{% trans "This organization doesn't have any libraries" %}

+
+{% endif %} + +{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/sysadmin/sys_org_info_user.html b/custom/templates/sysadmin/sys_org_info_user.html new file mode 100644 index 0000000..4b23075 --- /dev/null +++ b/custom/templates/sysadmin/sys_org_info_user.html @@ -0,0 +1,253 @@ +{% extends "sysadmin/sys_org_info_base.html" %} +{% load i18n seahub_tags %} + +{% block right_panel %} +
+ {% with cur_tab='user' %} + {% include 'sysadmin/snippets/sys_org_info_nav.html' %} + {% endwith %} +
+ +
+
+ + + + + + + + + + + {% for user in users %} + + + + + + + + {% endfor %} +
{% trans "Email" %}{% trans "Status" %}{% trans "Space Used" %}{% trans "Create At / Last Login" %}{% trans "Operations" %}
{{ user.email }} +
+ {% if user.is_active %} + {% trans "Active" %} + {% else %} + {% trans "Inactive" %} + {% endif %} + +
+ +
+ {{ user.self_usage|seahub_filesizeformat }} {% if user.quota > 0 %} / {{ user.quota|seahub_filesizeformat }} {% endif %} + + {{ user.ctime|tsstr_sec }} / {% if user.last_login %}{{user.last_login|translate_seahub_time}} {% else %} -- {% endif %} + + {% if not user.is_self %} + {% trans "Delete" %} + {% trans "ResetPwd" %} + {% endif %} +
+ +
+

{% trans "Activating..., please wait" %}

+
+ +
{% csrf_token %} +

{% trans "Add user" %}

+
+
+ +
+
+ + +
+ + + +
+
+
+

+ +
+{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/sysadmin/sys_useradmin_ldap.html b/custom/templates/sysadmin/sys_useradmin_ldap.html new file mode 100644 index 0000000..8510540 --- /dev/null +++ b/custom/templates/sysadmin/sys_useradmin_ldap.html @@ -0,0 +1,54 @@ +{% extends "sysadmin/base.html" %} +{% load seahub_tags i18n %} + +{% block cur_users %}tab-cur{% endblock %} + +{% block left_panel %}{{block.super}} +
+ +
+{% endblock %} + +{% block right_panel %} +
+ +
+ + + + + + + + + {% for user in users %} + + + + + + {% endfor %} +
{% trans "Email" %}{% trans "Space Used / Quota" %}{% trans "Create At / Last Login" %}
{{ user.email }} + {{ user.space_usage|seahub_filesizeformat }} / + {% if user.space_quota > 0 %} + {{ user.space_quota|seahub_filesizeformat }} + {% else %} + -- + {% endif %} + -- / {% if user.last_login %}{{user.last_login|translate_seahub_time}} {% else %} -- {% endif %}
+ +{% include "sysadmin/useradmin_paginator.html" %} +{% endblock %} + +{% block extra_script %} + +{% endblock %} diff --git a/custom/templates/sysadmin/useradmin_table.html b/custom/templates/sysadmin/useradmin_table.html new file mode 100644 index 0000000..07de2fb --- /dev/null +++ b/custom/templates/sysadmin/useradmin_table.html @@ -0,0 +1,165 @@ +{% load seahub_tags i18n %} + + + + {% if is_pro %} + + + + {% else %} + + + {% endif %} + {% if show_institution %} + + + + + {% else %} + + + + {% endif %} + + + {% for user in users %} + + + + + {% if is_pro %} + + {% endif %} + + + {% if show_institution %} + + {% endif %} + + + + + {% endfor %} +
ID / {% trans "Name" %} / {% trans "Contact Email" %}{% trans "Status" %}{% trans "Role" %}ID / {% trans "Name" %} / {% trans "Contact Email" %}{% trans "Status" %}{% trans "Space Used / Quota" %}{% trans "Institution" %}{% trans "Create At / Last Login" %}{% trans "Space Used / Quota" %}{% trans "Create At / Last Login" %}
+ {{ user.email|email2nickname }} + {% if user.contact_email %}
{{ user.contact_email }}{% endif %} + {% if not is_admin_page %} + {% if user.org %} +

({{user.org.org_name}})

+ {% endif %} + {% if user.trial_info %} +

(Trial  X)

+ {% endif %} + {% endif %} +
+
+ {% if user.is_active %} + {% trans "Active" %} + {% else %} + {% trans "Inactive" %} + {% endif %} + +
+ +
+ {% if not is_admin_page %} +
+ {% if user.is_guest %} + {% trans "Guest" %} + {% elif user.is_default %} + {% trans "Default" %} + {% else %} + {{user.role}} + {% endif %} + +
+ + + {% else %} {# else for `if not is_admin_page` #} +
+ {% if user.admin_role == default_admin %} + {% trans "Default Admin" context "Default Administrator" %} + {% elif user.admin_role == system_admin %} + {% trans "System Admin" context "System Administrator" %} + {% elif user.admin_role == daily_admin %} + {% trans "Daily Admin" context "Daily Administrator" %} + {% elif user.admin_role == audit_admin %} + {% trans "Audit Admin" context "Audit Administrator" %} + {% else %} + {{user.admin_role}} + {% endif %} + +
+ + {% endif %} +
+ {{ user.space_usage|seahub_filesizeformat }} / + + {% if user.space_quota >= 0 %} + {{ user.space_quota|seahub_filesizeformat }} + {% elif user.space_quota == -2 %} + -- + {% else %} + {% trans "Error" %} + {% endif %} + + + +
+ {{ user.institution }} + +
+ +
+ {% if user.source == "DB" %} + {{ user.ctime|tsstr_sec }} /
+ {% else %} + -- / + {% endif %} + {% if user.last_login %}{{user.last_login|translate_seahub_time}} {% else %} -- {% endif %} +
+ {% if not user.is_self %} + {% trans "Delete" %} +
+ {% if user.source == "DB" %} + {% trans "ResetPwd" %} + {% endif %} +
+ {% if is_admin_page %} + {% trans "Revoke Admin" %} + {% endif %} + {% endif %} +
+ +
{% csrf_token %} +

{% trans "Set quota" %}

+ MB +

+ {% trans "An integer that is greater than or equal to 0." %}
+ {% trans "Tip: 0 means default limit" %} +

+

+ +
diff --git a/img/folder-192.png b/img/folder-192.png new file mode 100644 index 0000000..d4b032d Binary files /dev/null and b/img/folder-192.png differ diff --git a/img/login-bg.jpg b/img/login-bg.jpg new file mode 100644 index 0000000..76d8020 Binary files /dev/null and b/img/login-bg.jpg differ