settingBody.jade 21 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477
  1. template(name="setting")
  2. .setting-content
  3. unless currentUser.isAdmin
  4. | {{_ 'error-notAuthorized'}}
  5. else
  6. .content-title.ext-box
  7. if isGeneralSetting
  8. span
  9. | 🔑
  10. | {{_ 'registration'}}
  11. else if isEmailSetting
  12. span
  13. | ✉️
  14. | {{_ 'email'}}
  15. else if isAccountSetting
  16. span
  17. | 👥
  18. | {{_ 'accounts'}}
  19. else if isTableVisibilityModeSetting
  20. span
  21. | 👁️
  22. | {{_ 'tableVisibilityMode'}}
  23. else if isAnnouncementSetting
  24. span
  25. | 📢
  26. | {{_ 'admin-announcement'}}
  27. else if isAccessibilitySetting
  28. span
  29. | ♿
  30. | {{_ 'accessibility'}}
  31. else if isLayoutSetting
  32. span
  33. | 🔗
  34. | {{_ 'layout'}}
  35. else if isWebhookSetting
  36. span
  37. | 🌐
  38. | {{_ 'global-webhook'}}
  39. else if isAttachmentSettings
  40. span
  41. | 📎
  42. | {{_ 'attachments'}}
  43. else if isCronSettings
  44. span
  45. | ⏰
  46. | {{_ 'cron'}}
  47. .content-body
  48. .side-menu
  49. ul
  50. li(class="{{#if isGeneralSetting}}active{{/if}}")
  51. a.js-setting-menu(data-id="registration-setting")
  52. | 🔑
  53. | {{_ 'registration'}}
  54. unless isSandstorm
  55. li(class="{{#if isEmailSetting}}active{{/if}}")
  56. a.js-setting-menu(data-id="email-setting")
  57. | ✉️
  58. | {{_ 'email'}}
  59. li(class="{{#if isAccountSetting}}active{{/if}}")
  60. a.js-setting-menu(data-id="account-setting")
  61. | 👥
  62. | {{_ 'accounts'}}
  63. li(class="{{#if isTableVisibilityModeSetting}}active{{/if}}")
  64. a.js-setting-menu(data-id="tableVisibilityMode-setting")
  65. | 👁️
  66. | {{_ 'tableVisibilityMode'}}
  67. li(class="{{#if isAnnouncementSetting}}active{{/if}}")
  68. a.js-setting-menu(data-id="announcement-setting")
  69. | 📢
  70. | {{_ 'admin-announcement'}}
  71. li(class="{{#if isAccessibilitySetting}}active{{/if}}")
  72. a.js-setting-menu(data-id="accessibility-setting")
  73. | ♿
  74. | {{_ 'accessibility'}}
  75. li(class="{{#if isLayoutSetting}}active{{/if}}")
  76. a.js-setting-menu(data-id="layout-setting")
  77. | 🔗
  78. | {{_ 'layout'}}
  79. li(class="{{#if isWebhookSetting}}active{{/if}}")
  80. a.js-setting-menu(data-id="webhook-setting")
  81. | 🌐
  82. | {{_ 'global-webhook'}}
  83. li(class="{{#if isAttachmentSettings}}active{{/if}}")
  84. a.js-setting-menu(data-id="attachment-settings")
  85. | 📎
  86. | {{_ 'attachments'}}
  87. li(class="{{#if isCronSettings}}active{{/if}}")
  88. a.js-setting-menu(data-id="cron-settings")
  89. | ⏰
  90. | {{_ 'cron'}}
  91. .main-body
  92. if isLoading
  93. +spinner
  94. else if isAttachmentSettings
  95. ul#attachment-setting.setting-detail
  96. li
  97. h3 {{_ 'attachment-storage-configuration'}}
  98. .form-group
  99. label {{_ 'writable-path'}}
  100. input.wekan-form-control#filesystem-path(type="text" value="{{filesystemPath}}" readonly)
  101. small.form-text.text-muted {{_ 'filesystem-path-description'}}
  102. .form-group
  103. label {{_ 'attachments-path'}}
  104. input.wekan-form-control#attachments-path(type="text" value="{{attachmentsPath}}" readonly)
  105. small.form-text.text-muted {{_ 'attachments-path-description'}}
  106. .form-group
  107. label {{_ 'avatars-path'}}
  108. input.wekan-form-control#avatars-path(type="text" value="{{avatarsPath}}" readonly)
  109. small.form-text.text-muted {{_ 'avatars-path-description'}}
  110. li
  111. h3 {{_ 'mongodb-gridfs-storage'}}
  112. .form-group
  113. label {{_ 'gridfs-enabled'}}
  114. input.wekan-form-control#gridfs-enabled(type="checkbox" checked="{{gridfsEnabled}}" disabled)
  115. small.form-text.text-muted {{_ 'gridfs-enabled-description'}}
  116. li
  117. h3 {{_ 's3-minio-storage'}}
  118. .form-group
  119. label {{_ 's3-enabled'}}
  120. input.wekan-form-control#s3-enabled(type="checkbox" checked="{{s3Enabled}}" disabled)
  121. small.form-text.text-muted {{_ 's3-enabled-description'}}
  122. .form-group
  123. label {{_ 's3-endpoint'}}
  124. input.wekan-form-control#s3-endpoint(type="text" value="{{s3Endpoint}}" readonly)
  125. small.form-text.text-muted {{_ 's3-endpoint-description'}}
  126. .form-group
  127. label {{_ 's3-bucket'}}
  128. input.wekan-form-control#s3-bucket(type="text" value="{{s3Bucket}}" readonly)
  129. small.form-text.text-muted {{_ 's3-bucket-description'}}
  130. .form-group
  131. label {{_ 's3-region'}}
  132. input.wekan-form-control#s3-region(type="text" value="{{s3Region}}" readonly)
  133. small.form-text.text-muted {{_ 's3-region-description'}}
  134. .form-group
  135. label {{_ 's3-access-key'}}
  136. input.wekan-form-control#s3-access-key(type="text" placeholder="{{_ 's3-access-key-placeholder'}}" readonly)
  137. small.form-text.text-muted {{_ 's3-access-key-description'}}
  138. .form-group
  139. label {{_ 's3-secret-key'}}
  140. input.wekan-form-control#s3-secret-key(type="password" placeholder="{{_ 's3-secret-key-placeholder'}}")
  141. small.form-text.text-muted {{_ 's3-secret-key-description'}}
  142. .form-group
  143. label {{_ 's3-ssl-enabled'}}
  144. input.wekan-form-control#s3-ssl-enabled(type="checkbox" checked="{{s3SslEnabled}}" disabled)
  145. small.form-text.text-muted {{_ 's3-ssl-enabled-description'}}
  146. .form-group
  147. label {{_ 's3-port'}}
  148. input.wekan-form-control#s3-port(type="number" value="{{s3Port}}" readonly)
  149. small.form-text.text-muted {{_ 's3-port-description'}}
  150. .form-group
  151. button.js-test-s3-connection.btn.btn-secondary {{_ 'test-s3-connection'}}
  152. button.js-save-s3-settings.btn.btn-primary {{_ 'save-s3-settings'}}
  153. else if isCronSettings
  154. ul#cron-setting.setting-detail
  155. li
  156. h3 {{_ 'cron-migrations'}}
  157. .form-group
  158. label {{_ 'migration-status'}}
  159. .status-indicator
  160. span.status-label {{_ 'status'}}:
  161. span.status-value {{migrationStatus}}
  162. .progress-section
  163. .progress
  164. .progress-bar(role="progressbar" style="width: {{migrationProgress}}%" aria-valuenow="{{migrationProgress}}" aria-valuemin="0" aria-valuemax="100")
  165. | {{migrationProgress}}%
  166. .progress-text
  167. | {{migrationProgress}}% {{_ 'complete'}}
  168. .form-group
  169. button.js-start-all-migrations.btn.btn-primary {{_ 'start-all-migrations'}}
  170. button.js-pause-all-migrations.btn.btn-warning {{_ 'pause-all-migrations'}}
  171. button.js-stop-all-migrations.btn.btn-danger {{_ 'stop-all-migrations'}}
  172. li
  173. h3 {{_ 'board-operations'}}
  174. .form-group
  175. label {{_ 'scheduled-board-operations'}}
  176. button.js-schedule-board-cleanup.btn.btn-primary {{_ 'schedule-board-cleanup'}}
  177. button.js-schedule-board-archive.btn.btn-warning {{_ 'schedule-board-archive'}}
  178. button.js-schedule-board-backup.btn.btn-info {{_ 'schedule-board-backup'}}
  179. li
  180. h3 {{_ 'cron-jobs'}}
  181. .form-group
  182. label {{_ 'active-cron-jobs'}}
  183. each cronJobs
  184. .job-item
  185. .job-info
  186. .job-name {{name}}
  187. .job-schedule {{schedule}}
  188. .job-description {{description}}
  189. .job-actions
  190. button.js-pause-job.btn.btn-sm.btn-warning(data-job-id="{{_id}}") {{_ 'pause'}}
  191. button.js-delete-job.btn.btn-sm.btn-danger(data-job-id="{{_id}}") {{_ 'delete'}}
  192. .add-job-section
  193. button.js-add-cron-job.btn.btn-success {{_ 'add-cron-job'}}
  194. else if isGeneralSetting
  195. +general
  196. else if isEmailSetting
  197. unless isSandstorm
  198. +email
  199. else if isAccountSetting
  200. +accountSettings
  201. else if isTableVisibilityModeSetting
  202. +tableVisibilityModeSettings
  203. else if isAnnouncementSetting
  204. +announcementSettings
  205. else if isAccessibilitySetting
  206. +accessibilitySettings
  207. else if isLayoutSetting
  208. +layoutSettings
  209. else if isWebhookSetting
  210. +webhookSettings
  211. template(name="webhookSettings")
  212. span
  213. +outgoingWebhooksPopup
  214. template(name="general")
  215. ul#registration-setting.setting-detail
  216. li
  217. a.flex.js-toggle-forgot-password
  218. .materialCheckBox(class="{{#if currentSetting.disableForgotPassword}}is-checked{{/if}}")
  219. span {{_ 'disable-forgot-password'}}
  220. li
  221. a.flex.js-toggle-registration
  222. .materialCheckBox(class="{{#if currentSetting.disableRegistration}}is-checked{{/if}}")
  223. span {{_ 'disable-self-registration'}}
  224. li
  225. .invite-people(class="{{#if currentSetting.disableRegistration}}{{else}}hide{{/if}}")
  226. ul
  227. li
  228. .title {{_ 'invite-people'}}
  229. textarea#email-to-invite.wekan-form-control(rows='5', placeholder="{{_ 'email-addresses'}}")
  230. li
  231. .title {{_ 'to-boards'}}
  232. .bg-white
  233. each boards
  234. a.option.flex.js-toggle-board-choose(id= _id)
  235. .materialCheckBox(data-id= _id)
  236. span= title
  237. li
  238. button.js-email-invite.primary {{_ 'invite'}}
  239. template(name='email')
  240. ul#email-setting.setting-detail
  241. //if isSandstorm
  242. // li.smtp-form
  243. // .title {{_ 'smtp-host'}}
  244. // .description {{_ 'smtp-host-description'}}
  245. // .form-group
  246. // input.wekan-form-control#mail-server-host(type="text", placeholder="smtp.domain.com" value="{{currentSetting.mailServer.host}}")
  247. // li.smtp-form
  248. // .title {{_ 'smtp-port'}}
  249. // .description {{_ 'smtp-port-description'}}
  250. // .form-group
  251. // input.wekan-form-control#mail-server-port(type="text", placeholder="25" value="{{currentSetting.mailServer.port}}")
  252. // li.smtp-form
  253. // .title {{_ 'smtp-username'}}
  254. // .form-group
  255. // input.wekan-form-control#mail-server-u"accounts-allowUserNameChange": "Allow Username Change",sername(type="text", placeholder="{{_ 'username'}}" value="{{currentSetting.mailServer.username}}")
  256. // li.smtp-form
  257. // .title {{_ 'smtp-password'}}
  258. // .form-group
  259. // input.wekan-form-control#mail-server-password(type="password", placeholder="{{_ 'password'}}" value="")
  260. // li.smtp-form
  261. // .title {{_ 'smtp-tls'}}
  262. // .form-group
  263. // a.flex.js-toggle-tls
  264. // .materialCheckBox#mail-server-tls(class="{{#if currentSetting.mailServer.enableTLS}}is-checked{{/if}}")
  265. //
  266. // span {{_ 'smtp-tls-description'}}
  267. //
  268. // li.smtp-form
  269. // .title {{_ 'send-from'}}
  270. // .form-group
  271. // input.wekan-form-control#mail-server-from(type="email", placeholder="no-reply@domain.com" value="{{currentSetting.mailServer.from}}")
  272. //
  273. // li
  274. // button.js-save.primary {{_ 'save'}}
  275. li
  276. button.js-send-smtp-test-email.primary {{_ 'send-smtp-test'}}
  277. template(name='tableVisibilityModeSettings')
  278. ul#tableVisibilityMode-setting.setting-detail
  279. li.tableVisibilityMode-form
  280. .title {{_ 'tableVisibilityMode-allowPrivateOnly'}}
  281. .form-group.flex
  282. input.wekan-form-control#accounts-allowPrivateOnly(type="radio" name="allowPrivateOnly" value="true" checked="{{#if allowPrivateOnly}}checked{{/if}}")
  283. label {{_ 'yes'}}
  284. input.wekan-form-control#accounts-allowPrivateOnly(type="radio" name="allowPrivateOnly" value="false" checked="{{#unless allowPrivateOnly}}checked{{/unless}}")
  285. label {{_ 'no'}}
  286. button.js-tableVisibilityMode-save.primary {{_ 'save'}}
  287. template(name='accountSettings')
  288. ul#account-setting.setting-detail
  289. li.accounts-form
  290. .title {{_ 'accounts-allowEmailChange'}}
  291. .form-group.flex
  292. input.wekan-form-control#accounts-allowEmailChange(type="radio" name="allowEmailChange" value="true" checked="{{#if allowEmailChange}}checked{{/if}}")
  293. label {{_ 'yes'}}
  294. input.wekan-form-control#accounts-allowEmailChange(type="radio" name="allowEmailChange" value="false" checked="{{#unless allowEmailChange}}checked{{/unless}}")
  295. label {{_ 'no'}}
  296. .title {{_ 'accounts-allowUserNameChange'}}
  297. .form-group.flex
  298. input.wekan-form-control#accounts-allowUserNameChange(type="radio" name="allowUserNameChange" value="true" checked="{{#if allowUserNameChange}}checked{{/if}}")
  299. label {{_ 'yes'}}
  300. input.wekan-form-control#accounts-allowUserNameChange(type="radio" name="allowUserNameChange" value="false" checked="{{#unless allowUserNameChange}}checked{{/unless}}")
  301. label {{_ 'no'}}
  302. .title {{_ 'accounts-allowUserDelete'}}
  303. .form-group.flex
  304. input.wekan-form-control#accounts-allowUserDelete(type="radio" name="allowUserDelete" value="true" checked="{{#if allowUserDelete}}checked{{/if}}")
  305. label {{_ 'yes'}}
  306. input.wekan-form-control#accounts-allowUserDelete(type="radio" name="allowUserDelete" value="false" checked="{{#unless allowUserDelete}}checked{{/unless}}")
  307. label {{_ 'no'}}
  308. button.js-accounts-save.primary {{_ 'save'}}
  309. // Brute force lockout settings moved to People/Locked Users section
  310. template(name='announcementSettings')
  311. ul#announcement-setting.setting-detail
  312. li
  313. a.flex.js-toggle-activemessage
  314. .materialCheckBox(class="{{#if currentAnnouncements.enabled}}is-checked{{/if}}")
  315. span {{_ 'admin-announcement-active'}}
  316. li
  317. .admin-announcement(class="{{#if currentAnnouncements.enabled}}{{else}}hide{{/if}}")
  318. ul
  319. li
  320. .title {{_ 'admin-announcement-title'}}
  321. textarea#admin-announcement.wekan-form-control= currentAnnouncements.body
  322. li
  323. button.js-announcement-save.primary {{_ 'save'}}
  324. template(name='accessibilitySettings')
  325. ul#accessibility-setting.setting-detail
  326. li
  327. a(href="/accessibility" style="text-decoration: underline; color: blue;") {{_ 'accessibility'}}
  328. li
  329. a.flex.js-toggle-accessibility
  330. .materialCheckBox(class="{{#if currentAccessibility.enabled}}is-checked{{/if}}")
  331. span {{_ 'accessibility-page-enabled'}}
  332. li
  333. .accessibility-content(class="{{#if currentAccessibility.enabled}}{{else}}hide{{/if}}")
  334. ul
  335. li
  336. .title {{_ 'accessibility-title'}}
  337. textarea#admin-accessibility-title.wekan-form-control= currentAccessibility.title
  338. li
  339. .title {{_ 'accessibility-content'}}
  340. textarea#admin-accessibility-content.wekan-form-control= currentAccessibility.body
  341. li
  342. button.js-accessibility-save.primary {{_ 'save'}}
  343. template(name='layoutSettings')
  344. ul#layout-setting.setting-detail
  345. li
  346. button.js-all-boards-hide-activities.primary {{_ 'hide-activities-of-all-boards'}}
  347. li.layout-form
  348. .title {{_ 'oidc-button-text'}}
  349. .form-group
  350. input.wekan-form-control#oidcBtnTextvalue(type="text", placeholder="" value="{{currentSetting.oidcBtnText}}")
  351. li.layout-form
  352. .title {{_ 'can-invite-if-same-mailDomainName'}}
  353. .form-group
  354. input.wekan-form-control#mailDomainNamevalue(type="text", placeholder="" value="{{currentSetting.mailDomainName}}")
  355. li.layout-form
  356. .title {{_ 'custom-legal-notice-link-url'}}
  357. .form-group
  358. input.wekan-form-control#legalNoticevalue(type="text", placeholder="" value="{{currentSetting.legalNotice}}")
  359. li.layout-form
  360. .title {{_ 'display-authentication-method'}}
  361. .form-group.flex
  362. input.wekan-form-control#display-authentication-method(type="radio" name="displayAuthenticationMethod" value="true" checked="{{#if currentSetting.displayAuthenticationMethod}}checked{{/if}}")
  363. label {{_ 'yes'}}
  364. input.wekan-form-control#display-authentication-method(type="radio" name="displayAuthenticationMethod" value="false" checked="{{#unless currentSetting.displayAuthenticationMethod}}checked{{/unless}}")
  365. label {{_ 'no'}}
  366. li.layout-form
  367. .title {{_ 'default-authentication-method'}}
  368. +selectAuthenticationMethod(authenticationMethod=currentSetting.defaultAuthenticationMethod)
  369. li.layout-form
  370. .title {{_ 'wait-spinner'}}
  371. +selectSpinnerName(spinnerName=currentSetting.spinnerName)
  372. li.layout-form
  373. .title {{_ 'custom-product-name'}}
  374. .form-group
  375. input.wekan-form-control#product-name(type="text", placeholder="" value="{{currentSetting.productName}}")
  376. li.layout-form
  377. .title {{_ 'hide-logo'}}
  378. .form-group.flex
  379. input.wekan-form-control#hide-logo(type="radio" name="hideLogo" value="true" checked="{{#if currentSetting.hideLogo}}checked{{/if}}")
  380. label {{_ 'yes'}}
  381. input.wekan-form-control#hide-logo(type="radio" name="hideLogo" value="false" checked="{{#unless currentSetting.hideLogo}}checked{{/unless}}")
  382. label {{_ 'no'}}
  383. li.layout-form
  384. .title {{_ 'custom-login-logo-image-url'}}
  385. .form-group
  386. input.wekan-form-control#custom-login-logo-image-url(type="text", placeholder="" value="{{currentSetting.customLoginLogoImageUrl}}")
  387. li.layout-form
  388. .title {{_ 'custom-login-logo-link-url'}}
  389. .form-group
  390. input.wekan-form-control#custom-login-logo-link-url(type="text", placeholder="" value="{{currentSetting.customLoginLogoLinkUrl}}")
  391. li.layout-form
  392. .title {{_ 'custom-help-link-url'}}
  393. .form-group
  394. input.wekan-form-control#custom-help-link-url(type="text", placeholder="" value="{{currentSetting.customHelpLinkUrl}}")
  395. li.layout-form
  396. .title {{_ 'text-below-custom-login-logo'}}
  397. .form-group
  398. textarea#text-below-custom-login-logo.wekan-form-control= currentSetting.textBelowCustomLoginLogo
  399. li.layout-form
  400. .title {{_ 'custom-top-left-corner-logo-image-url'}}
  401. .form-group
  402. input.wekan-form-control#custom-top-left-corner-logo-image-url(type="text", placeholder="" value="{{currentSetting.customTopLeftCornerLogoImageUrl}}")
  403. li.layout-form
  404. .title {{_ 'custom-top-left-corner-logo-link-url'}}
  405. .form-group
  406. input.wekan-form-control#custom-top-left-corner-logo-link-url(type="text", placeholder="" value="{{currentSetting.customTopLeftCornerLogoLinkUrl}}")
  407. li.layout-form
  408. .title {{_ 'custom-top-left-corner-logo-height'}}
  409. .form-group
  410. input.wekan-form-control#custom-top-left-corner-logo-height(type="text", placeholder="" value="{{currentSetting.customTopLeftCornerLogoHeight}}")
  411. li.layout-form
  412. .title {{_ 'automatic-linked-url-schemes'}}
  413. .form-group
  414. textarea#automatic-linked-url-schemes.wekan-form-control= currentSetting.automaticLinkedUrlSchemes
  415. li.layout-form
  416. .title {{_ 'hide-card-counter-list'}}
  417. .form-group.flex
  418. input.wekan-form-control#hide-card-counter-list(type="radio" name="hideCardCounterList" value="true" checked="{{#if currentSetting.hideCardCounterList}}checked{{/if}}")
  419. label {{_ 'yes'}}
  420. input.wekan-form-control#hide-card-counter-list(type="radio" name="hideCardCounterList" value="false" checked="{{#unless currentSetting.hideCardCounterList}}checked{{/unless}}")
  421. label {{_ 'no'}}
  422. li.layout-form
  423. .title {{_ 'hide-board-member-list'}}
  424. .form-group.flex
  425. input.wekan-form-control#hide-board-member-list(type="radio" name="hideBoardMemberList" value="true" checked="{{#if currentSetting.hideBoardMemberList}}checked{{/if}}")
  426. label {{_ 'yes'}}
  427. input.wekan-form-control#hide-board-member-list(type="radio" name="hideBoardMemberList" value="false" checked="{{#unless currentSetting.hideBoardMemberList}}checked{{/unless}}")
  428. label {{_ 'no'}}
  429. li
  430. button.js-save-layout.primary {{_ 'save'}}
  431. template(name='selectAuthenticationMethod')
  432. select#defaultAuthenticationMethod
  433. each authentications
  434. if isSelected value
  435. option(value="{{value}}" selected) {{_ value}}
  436. else
  437. option(value="{{value}}") {{_ value}}
  438. template(name='selectSpinnerName')
  439. select#spinnerName
  440. each spinner in spinners
  441. if isSelected spinner
  442. option(value="{{spinner}}" selected) {{_ spinner}}
  443. else
  444. option(value="{{spinner}}") {{_ spinner}}