Skip to content

Commit

Permalink
fix: theme links
Browse files Browse the repository at this point in the history
  • Loading branch information
Abdur-rahmaanJ committed Apr 16, 2024
1 parent 387b3bb commit 39dc881
Show file tree
Hide file tree
Showing 2 changed files with 142 additions and 119 deletions.
255 changes: 136 additions & 119 deletions pythoncms/modules/box__default/theme/templates/theme/index.html
Original file line number Diff line number Diff line change
@@ -1,129 +1,146 @@
{%extends get_active_back_theme()+'/base.html'%}


{%block content%}
<br>
{%extends get_active_back_theme()+'/base.html'%} {%block content%}
<br />
<i>Note: change theme in .env file also </i>
<br>
<br />
<div class="container">
<br />
<div class="card" style="color: black">
<div class="card-header">Front Theme</div>
<div class="card-body">
<table class="table">
<thead>
<tr>
<th>Choose</th>

<br>
<div class="card" style="color: black">
<div class="card-header">
Front Theme
</div>
<div class="card-body">
<table class="table">
<thead>
<tr>
<th>Name</th>
<th>Author</th>
<th></th>
</tr>
</thead>
<tbody>
{%for key in all_front_info%}
<tr>
<td>{{key}}</td>
<td>{{all_front_info[key]['author']}}</td>
<td>
{%if active_front_theme != key%}
<a class="" href="{{url_for('theme.activate_front_theme', theme_name=key)}}">
<div class="form-check">
<input class="form-check-input" type="radio" value="" disabled="">
</div>
</a>
{%else%}
<div class="form-check">
<input name="" class="form-check-input" type="radio" value="" id="defaultRadio2" checked="">
</div>
{%endif%}
</td>
</tr>
{%endfor%}
</tbody>
</table>
</div>
</div>
<br>
<div class="card" style="color: black">
<div class="card-header">
Back Theme
</div>
<div class="card-body">
<table class="table">
<thead>
<tr>
<th>Name</th>
<th>Author</th>
<th></th>
</tr>
</thead>
<tbody>
{%for key in all_back_info%}
<tr>
<td>{{key}}</td>
<td>{{all_back_info[key]['author']}}</td>
<td>
{%if active_back_theme != key%}
<a class="" href="{{url_for('theme.activate_back_theme', theme_name=key)}}">
<div class="form-check">
<input class="form-check-input" type="radio" value="" disabled="">
</div>
</a>
{%else%}
<div class="form-check">
<input name="" class="form-check-input" type="radio" value="" checked="">
</div>
{%endif%}
</td>
</tr>
{%endfor%}
</tbody>
</table>
</div>
</tr>
</thead>
<tbody>
{%for key in all_front_info%}
<tr>
<td>

{%if active_front_theme != key%}
<a
class=""
href="{{url_for('theme.activate_front_theme', theme_name=key)}}"
>

{{key}} by
{{all_front_info[key]['author']}}

<input
type="radio"
value=""
disabled=""
/>

</a>
{%else%}
<a
class=""
href="{{url_for('theme.activate_front_theme', theme_name=key)}}"
>

{{key}} by
{{all_front_info[key]['author']}}

<input
type="radio"
value=""
checked
/>

</a>
{%endif%}
</td>
</tr>
{%endfor%}
</tbody>
</table>
</div>
<br>
<div class="card" style="color: black">
<div class="card-header">
Iconset
</div>
<div class="card-body">
<table class="table">
<thead>
<tr>
<th>Name</th>
<th></th>
</tr>
</thead>
<tbody>
{%for icon in ['fa', 'boxicons']%}
<tr>
<td>{{icon}}</td>
<td>
{%if active_iconset != icon%}
<a class="" href="{{url_for('theme.activate_iconset', name=icon)}}">
<div class="form-check">
<input class="form-check-input" type="radio" value="" disabled="">
</div>
</a>
{%else%}
<div class="form-check">
<input name="" class="form-check-input" type="radio" value="" checked="">
</div>
{%endif%}
</td>
</tr>
{%endfor%}
</tbody>
</table>
</div>
</div>
<br />
<div class="card" style="color: black">
<div class="card-header">Back Theme</div>
<div class="card-body">
<table class="table">
<thead>
<tr>
<th>choose</th>
</tr>
</thead>
<tbody>
{%for key in all_back_info%}
<tr>
<td>
{%if active_back_theme
!= key%}
<a
class="theme-input"
class=""
href="{{url_for('theme.activate_back_theme', theme_name=key)}}"
>
{{key}} by {{all_back_info[key]['author']}}
<input type="radio" value="" disabled="" />
</a>
{%else%}
<a
class="theme-input"
class=""
href="{{url_for('theme.activate_back_theme', theme_name=key)}}"
>
{{key}} by {{all_back_info[key]['author']}}
<input name="" type="radio" value="" checked="" />
</a>
{%endif%}
</td>
</tr>
{%endfor%}
</tbody>
</table>
</div>
</div>
<br />
<div class="card" style="color: black">
<div class="card-header">Iconset</div>
<div class="card-body">
<table class="table">
<thead>
<tr>
<th>Name</th>
</tr>
</thead>
<tbody>
{%for icon in ['fa', 'boxicons']%}
<tr>
<td>
{%if active_iconset != icon%}
<a
class="theme-input"
href="{{url_for('theme.activate_iconset', name=icon)}}"
>
{{icon}}
<input type="radio" value="" disabled="" />
</a>
{%else%}
<a
class="theme-input"
href="{{url_for('theme.activate_iconset', name=icon)}}"
>
{{icon}}
<input type="radio" value="" checked="" />
</a>

<div>

</div>
{%endif%}
</td>
</tr>
{%endfor%}
</tbody>
</table>
</div>
</div>

<div></div>
</div>

{% endblock %}
6 changes: 6 additions & 0 deletions pythoncms/static/themes/back/sbadmin/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@

<!-- Custom styles for this template-->
<link href="{{url_for('static', filename='themes/back/sbadmin/css/sb-admin-2.min.css')}}" rel="stylesheet">

<style>
.theme-input:hover{
cursor: pointer !important;
}
</style>
{%block head%}
{%endblock%}
</head>
Expand Down

0 comments on commit 39dc881

Please sign in to comment.