combine some template includes

merge-requests/208/head
fatchan 5 years ago
parent ac6a6f8c05
commit 74e6fb5b93
  1. 18
      views/includes/banform.pug
  2. 18
      views/pages/globalmanagebans.pug
  3. 2
      views/pages/globalmanagereports.pug
  4. 19
      views/pages/managebans.pug
  5. 2
      views/pages/managereports.pug

@ -0,0 +1,18 @@
if bans.length === 0
p No bans.
else
input(type='hidden' name='_csrf' value=csrf)
include ../includes/bantable.pug
for ban in bans
+ban(ban)
.action-wrapper.mv-10
.row
label
input(type='radio' name='option' value='unban' checked='checked')
| Unban
.row
label
input(type='radio' name='option' value='deny_appeal')
| Deny Appeal
input(type='submit' value='submit')

@ -13,20 +13,4 @@ block content
hr(size=1)
h4.no-m-p Global Bans & Appeals:
form(action=`/forms/global/editbans` method='POST' enctype='application/x-www-form-urlencoded')
input(type='hidden' name='_csrf' value=csrf)
if bans.length === 0
p No bans.
else
include ../includes/bantable.pug
for ban in bans
+ban(ban)
.action-wrapper.mv-10
.row
label
input(type='radio' name='option' value='unban' checked='checked')
| Unban
.row
label
input(type='radio' name='option' value='deny_appeal')
| Deny Appeal
input(type='submit' value='submit')
include ../includes/banform.pug

@ -11,11 +11,11 @@ block content
br
+globalmanagenav('reports')
form(action=`/forms/global/actions` method='POST' enctype='application/x-www-form-urlencoded')
input(type='hidden' name='_csrf' value=csrf)
if reports.length === 0
hr(size=1)
p No reports.
else
input(type='hidden' name='_csrf' value=csrf)
hr(size=1)
if ip
h4.no-m-p Reports against or by ...#{ip}

@ -14,21 +14,4 @@ block content
hr(size=1)
h4.no-m-p Bans & Appeals:
form(action=`/forms/board/${board._id}/editbans` method='POST' enctype='application/x-www-form-urlencoded')
input(type='hidden' name='_csrf' value=csrf)
if bans.length === 0
p No bans.
else
include ../includes/bantable.pug
for ban in bans
+ban(ban)
.action-wrapper.mv-10
.row
label
input(type='radio' name='option' value='unban' checked='checked')
| Unban
.row
label
input(type='radio' name='option' value='deny_appeal')
| Deny Appeal
input(type='submit' value='submit')
include ../includes/banform.pug

@ -15,10 +15,10 @@ block content
hr(size=1)
h4.no-m-p Reports:
form(action=`/forms/board/${board._id}/modactions` method='POST' enctype='application/x-www-form-urlencoded')
input(type='hidden' name='_csrf' value=csrf)
if reports.length === 0
p No reports.
else
input(type='hidden' name='_csrf' value=csrf)
for report in reports
.thread
+post(report, false, true)

Loading…
Cancel
Save