mirror of
https://github.com/mCaptcha/mCaptcha.git
synced 2026-02-11 10:05:41 +00:00
add sitekey helper in list sitekey page
This commit is contained in:
@@ -1,19 +1,19 @@
|
|||||||
/*
|
/*
|
||||||
* Copyright (C) 2021 Aravinth Manivannan <realaravinth@batsense.net>
|
* Copyright (C) 2021 Aravinth Manivannan <realaravinth@batsense.net>
|
||||||
*
|
*
|
||||||
* This program is free software: you can redistribute it and/or modify
|
* This program is free software: you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU Affero General Public License as
|
* it under the terms of the GNU Affero General Public License as
|
||||||
* published by the Free Software Foundation, either version 3 of the
|
* published by the Free Software Foundation, either version 3 of the
|
||||||
* License, or (at your option) any later version.
|
* License, or (at your option) any later version.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful,
|
* This program is distributed in the hope that it will be useful,
|
||||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
* GNU Affero General Public License for more details.
|
* GNU Affero General Public License for more details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU Affero General Public License
|
* You should have received a copy of the GNU Affero General Public License
|
||||||
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
use actix_identity::Identity;
|
use actix_identity::Identity;
|
||||||
use actix_web::{HttpResponse, Responder};
|
use actix_web::{HttpResponse, Responder};
|
||||||
|
|||||||
@@ -1,14 +1,7 @@
|
|||||||
<ul class="taskbar">
|
<ul class="taskbar">
|
||||||
<!--
|
|
||||||
<li class="taskbar__action">Brand Name</li>
|
|
||||||
-->
|
|
||||||
<li class="taskbar__spacer"></li>
|
<li class="taskbar__spacer"></li>
|
||||||
<li class="taskbar__action">
|
<li class="taskbar__action">
|
||||||
<a class="taskbar__link" href="<.= crate::PAGES.panel.sitekey.add .>">
|
<. include!("./new-sitekey-btn.html"); .>
|
||||||
<button class="taskbar__add-site">
|
|
||||||
+ New Site
|
|
||||||
</button>
|
|
||||||
</a>
|
|
||||||
</li>
|
</li>
|
||||||
<li class="taskbar__action">
|
<li class="taskbar__action">
|
||||||
<img class="taskbar__icon" src="<.=
|
<img class="taskbar__icon" src="<.=
|
||||||
@@ -23,7 +16,6 @@
|
|||||||
alt="Notifications" />
|
alt="Notifications" />
|
||||||
</a>
|
</a>
|
||||||
</li>
|
</li>
|
||||||
|
|
||||||
<li class="taskbar__action">
|
<li class="taskbar__action">
|
||||||
<a href="<.= crate::V1_API_ROUTES.auth.logout .>">
|
<a href="<.= crate::V1_API_ROUTES.auth.logout .>">
|
||||||
<img class="taskbar__icon" src="<.=
|
<img class="taskbar__icon" src="<.=
|
||||||
|
|||||||
5
templates/panel/header/taskbar/new-sitekey-btn.html
Normal file
5
templates/panel/header/taskbar/new-sitekey-btn.html
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
<a class="taskbar__link" href="<.= crate::PAGES.panel.sitekey.add .>">
|
||||||
|
<button class="taskbar__add-site">
|
||||||
|
+ New Site
|
||||||
|
</button>
|
||||||
|
</a>
|
||||||
@@ -11,16 +11,8 @@ include!("./navbar/index.html"); .>
|
|||||||
<. include!("./help-banner/index.html"); .>
|
<. include!("./help-banner/index.html"); .>
|
||||||
<div class="inner-container">
|
<div class="inner-container">
|
||||||
<. if sitekeys.is_empty() { .>
|
<. if sitekeys.is_empty() { .>
|
||||||
<ul class="sitekey-list__box">
|
<. include!("./sitekey/list/empty-sitekey.html"); .>
|
||||||
<p>
|
|
||||||
It looks like you don't have any sitekeys. Click
|
|
||||||
<a href="<.= crate::PAGES.panel.sitekey.add .>">here</a> to add new
|
|
||||||
sitekey.
|
|
||||||
</p>
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<.} else {.>
|
<.} else {.>
|
||||||
|
|
||||||
<table class="sitekey__table">
|
<table class="sitekey__table">
|
||||||
<thead class="sitekey__table-heading">
|
<thead class="sitekey__table-heading">
|
||||||
<tr>
|
<tr>
|
||||||
@@ -62,7 +54,6 @@ include!("./navbar/index.html"); .>
|
|||||||
<. } .>
|
<. } .>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
<.}.>
|
<.}.>
|
||||||
</div>
|
</div>
|
||||||
<. include!("../components/footers.html"); .>
|
<. include!("../components/footers.html"); .>
|
||||||
|
|||||||
6
templates/panel/sitekey/list/empty-sitekey.html
Normal file
6
templates/panel/sitekey/list/empty-sitekey.html
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<ul class="sitekey-list__box">
|
||||||
|
<p>
|
||||||
|
It looks like you don't have any sitekeys. Click <.
|
||||||
|
include!("../../header/taskbar/new-sitekey-btn.html"); .> to add new sitekey.
|
||||||
|
</p>
|
||||||
|
</ul>
|
||||||
@@ -12,6 +12,9 @@ include!("../../navbar/index.html"); .>
|
|||||||
<!-- Main content container -->
|
<!-- Main content container -->
|
||||||
<div class="inner-container">
|
<div class="inner-container">
|
||||||
<!-- Main menu/ important actions roaster -->
|
<!-- Main menu/ important actions roaster -->
|
||||||
|
<. if sitekeys.is_empty() { .>
|
||||||
|
<. include!("./empty-sitekey.html"); .>
|
||||||
|
<.} else {.>
|
||||||
<table class="sitekey__table">
|
<table class="sitekey__table">
|
||||||
<thead class="sitekey__table-heading">
|
<thead class="sitekey__table-heading">
|
||||||
<tr>
|
<tr>
|
||||||
@@ -53,6 +56,7 @@ include!("../../navbar/index.html"); .>
|
|||||||
<. } .>
|
<. } .>
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
<.}.>
|
||||||
</div>
|
</div>
|
||||||
<!-- end of container -->
|
<!-- end of container -->
|
||||||
<. include!("../../../components/footers.html"); .>
|
<. include!("../../../components/footers.html"); .>
|
||||||
|
|||||||
Reference in New Issue
Block a user