Compare commits
6 Commits
91105c83c9
...
76cbe17b34
Author | SHA1 | Date | |
---|---|---|---|
![]() |
76cbe17b34 | ||
![]() |
ffe62c9951 | ||
![]() |
2ccc3b18cc | ||
![]() |
b356e9fabe | ||
![]() |
03eacd8e36 | ||
![]() |
9963a8836f |
@@ -104,9 +104,12 @@ html {
|
||||
border-left-width: 0px;
|
||||
}
|
||||
|
||||
.user-valign-center {
|
||||
/* .user-valign-center {
|
||||
text-align: center;
|
||||
}
|
||||
-- Use align-middle --
|
||||
} */
|
||||
|
||||
|
||||
|
||||
.user-table-max-wdith {
|
||||
max-width: 50%;
|
||||
|
@@ -1,6 +1,6 @@
|
||||
<%
|
||||
|
||||
my $backups = esmith::BackupHistoryDB->open;
|
||||
my $backups = esmith::BackupHistoryDB->open; # no UTF8
|
||||
my $now = time();
|
||||
my $backup_rec = $backups->new_record($now, {
|
||||
type => 'backup_record', BackupType => 'desktop',
|
||||
@@ -22,7 +22,7 @@
|
||||
my $success = open my $fh, '-|', $cmd;
|
||||
#unless ($success) { return "Error download command."; };
|
||||
if ($success) {
|
||||
# Try with download plugin - seems to fail to complete download and also
|
||||
# Try with download plugin - seems to fail to complete download and also
|
||||
# name of file deposited is not as required.
|
||||
#my $output = do { local $/; <$fh> };
|
||||
#close $fh;
|
||||
|
@@ -28,7 +28,7 @@
|
||||
<th class="col-sm"><%=l 'DESCRIPTION_BRIEF' %></th>
|
||||
<th class="col-sm"><%=l 'dom_CONTENT' %></th>
|
||||
<th class="col-sm"><%=l 'dom_LABEL_NAMESERVERS'%></th>
|
||||
<th class="col-sm user-valign-center" colspan="2"><%=l 'ACTION' %></th>
|
||||
<th class="col-sm text-center" colspan="2"><%=l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@@ -65,10 +65,10 @@
|
||||
% </button>
|
||||
% </a>
|
||||
%};
|
||||
%# $actionRemove = "<a href='domains2?CsrfDef=TOKEN&trt=DEL&Domain=" . $domain->{Domain} . "'>" . "<button class="" title=".l('REMOVE').">".l('REMOVE')."</button>" . "</a>";
|
||||
%# $actionRemove = "<a href='domains2?CsrfDef=TOKEN&trt=DEL&Domain=" . $domain->{Domain} . "'>" . "<button class="" title=".l('REMOVE').">".l('REMOVE')."</button>" . "</a>";
|
||||
%};
|
||||
<td class="col-auto user-valign-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="col-auto user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="col-auto text-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="col-auto text-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
</tr>
|
||||
% }
|
||||
|
||||
|
@@ -24,7 +24,7 @@
|
||||
<tr>
|
||||
<th class="col-sm"><%= l 'GROUP' %></th>
|
||||
<th class="col-sm"><%= l 'DESCRIPTION' %></th>
|
||||
<th class="col-sm user-valign-center" colspan="2"><%= l 'ACTION' %></th>
|
||||
<th class="col-sm align-middle" colspan="2"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -54,8 +54,8 @@
|
||||
% </a>
|
||||
%};
|
||||
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
</tr>
|
||||
% }
|
||||
</tbody>
|
||||
|
@@ -26,7 +26,7 @@
|
||||
<th class="col-auto"><%= l 'IP_ADDRESS_OR_FQDN' %></th>
|
||||
<th class="col-auto"><%= l 'hos_ETHERNET_ADDRESS' %></th>
|
||||
<th class="col-auto"><%= l 'COMMENT' %></th>
|
||||
<th class="user-valign-center" colspan="2"><%= l 'ACTION' %></th>
|
||||
<th class="align-middle" colspan="2"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@@ -63,8 +63,8 @@
|
||||
% </a>
|
||||
%};
|
||||
% }
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
|
||||
</tr>
|
||||
% }
|
||||
|
@@ -36,7 +36,7 @@
|
||||
<tr>
|
||||
<th class="col-sm"><%= l 'NAME' %></th>
|
||||
<th class="col-sm"><%= l 'DESCRIPTION' %></th>
|
||||
<th class="col-sm user-valign-center" colspan="3"><%= l 'ACTION' %></th>
|
||||
<th class="col-sm align-middle" colspan="3"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@@ -103,9 +103,9 @@
|
||||
% </a>
|
||||
%};
|
||||
% }
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionResetPw)%></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionResetPw)%></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
</td>
|
||||
</tr>
|
||||
% }
|
||||
|
@@ -1,32 +1,35 @@
|
||||
<div>
|
||||
|
||||
% my $retref= $c->stash("ret");
|
||||
% my %ret;
|
||||
% unless (length($retref)) {%ret = (ret=>"");}
|
||||
% else {%ret = %$retref;}
|
||||
% my $retref = $c->stash("ret");
|
||||
% my %ret = $retref ? %$retref : (ret => "");
|
||||
% my @vars = split(/,/, $ret{vars} // '');
|
||||
% my ($var1, $var2, $var3, $var4, $var5, $var6, $var7) = @vars;
|
||||
|
||||
% my @vars = split(",",$ret{vars});
|
||||
% my $var1 = @vars[0];
|
||||
% my $var2 = @vars[1];
|
||||
% my $var3 = @vars[2];
|
||||
% my $var4 = @vars[3];
|
||||
% my $var5 = @vars[4];
|
||||
% my $var6 = @vars[5];
|
||||
% if ($c->app->config->{debug}) {
|
||||
<br>
|
||||
<pre>
|
||||
<%= dumper { ret_data => \%ret } %>
|
||||
</pre>
|
||||
% }
|
||||
|
||||
%if ($ret{'ret'} eq "") {
|
||||
% if ($ret{ret} eq "") {
|
||||
<br>
|
||||
<%= l "ln_FIRSTPAGE_DESC" %>
|
||||
<BR>
|
||||
% } elsif (index($ret{ret},"SUCCESS") != -1) {
|
||||
<div class="">
|
||||
<h2> Operation Status Report</h2>
|
||||
<%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6); %>
|
||||
</div>
|
||||
% } else {
|
||||
<div class="">
|
||||
<h2> Operation Status Report - Error</h2>
|
||||
<%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6); %>
|
||||
</div>
|
||||
% }
|
||||
|
||||
<br>
|
||||
|
||||
%} elsif (index($ret{ret},"SUCCESS") != -1) {
|
||||
<div class="">
|
||||
<h2> Operation Status Report</h2>
|
||||
<%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6); %>
|
||||
</div>
|
||||
%} else {
|
||||
<div class="">
|
||||
<h2> Operation Status Report - Error</h2>
|
||||
<%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6); %>
|
||||
</div>
|
||||
%}
|
||||
<br />
|
||||
% my $btn = l('ADD');
|
||||
% my $network_db = esmith::NetworksDB::UTF8->open() || die "Couldn't open NetworksDB db";
|
||||
|
||||
@@ -37,7 +40,6 @@
|
||||
</div>
|
||||
% }
|
||||
|
||||
|
||||
<form action="/smanager/localnetworksb" method="POST">
|
||||
<div>
|
||||
<h2><%=l "ln_ADD_TITLE" %></h2>
|
||||
@@ -54,7 +56,7 @@
|
||||
<label for="inputNetwork" class="col-form-label"><%= l "NETWORK" %></label>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" name="networkAddress" id="inputNetwork" class="form-control" aria-describedby="inputNetwork" >
|
||||
<input type="text" name="networkAddress" id="inputNetwork" class="form-control" aria-describedby="Network" >
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -65,7 +67,7 @@
|
||||
<label for="inputNetworkMask" class="col-form-label"><%= l "ln_SUBNET_MASK" %></label>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" name="networkMask" id="inputNetworkMask" class="form-control" aria-describedby="inputNetworkMask" >
|
||||
<input type="text" name="networkMask" id="inputNetworkMask" class="form-control" aria-describedby="Network Subnet Mask" >
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -76,7 +78,7 @@
|
||||
<label for="inputNetworkRouter" class="col-form-label"><%= l "ROUTER" %></label>
|
||||
</div>
|
||||
<div class="col-auto">
|
||||
<input type="text" name="networkRouter" id="inputNetworkRouter" class="form-control" aria-describedby="inputNetworkRouter" >
|
||||
<input type="text" name="networkRouter" id="inputNetworkRouter" class="form-control" aria-describedby="Network Router" >
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@@ -17,11 +17,11 @@
|
||||
<form action="/smanager/localnetworkse" method="POST">
|
||||
|
||||
<div>
|
||||
<h2><%=l "ln_REMOVE_TITLE" %></h2>
|
||||
<h2><%= l "ln_REMOVE_TITLE" %></h2>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<%=l "ln_REMOVE_DESC" %>
|
||||
<%= l "ln_REMOVE_DESC" %>
|
||||
</div>
|
||||
|
||||
<br><br>
|
||||
@@ -60,19 +60,20 @@
|
||||
<br>
|
||||
|
||||
% if ($deletehosts) {
|
||||
<br>
|
||||
<br>
|
||||
|
||||
<b>tell me if you find this!</b>
|
||||
<b>tell me if you find this!</b>
|
||||
<b>Please opoen a bug and tell me</b>
|
||||
|
||||
<%= $c->l("ln_REMOVE_HOSTS_DESC") %>
|
||||
<br>
|
||||
<span class="">
|
||||
<%= $c->l("ln_REMOVE_HOSTS_LABEL") %>
|
||||
</span>
|
||||
<span class="">
|
||||
<%= check_box deletehost=>1, checked=>1 %>
|
||||
</span>
|
||||
<br><br>
|
||||
<%= $c->l("ln_REMOVE_HOSTS_DESC") %>
|
||||
<br>
|
||||
<span class="">
|
||||
<%= $c->l("ln_REMOVE_HOSTS_LABEL") %>
|
||||
</span>
|
||||
<span class="">
|
||||
<%= check_box deletehost=>1, checked=>1 %>
|
||||
</span>
|
||||
<br><br>
|
||||
% }
|
||||
|
||||
<div class="row g-3 align-items-center">
|
||||
|
@@ -5,37 +5,31 @@
|
||||
<br>
|
||||
|
||||
% my $retref = $c->stash("ret");
|
||||
% my %ret;
|
||||
% unless (length($retref)) {%ret = (ret=>"");}
|
||||
% else {%ret = %$retref;}
|
||||
% my %ret = $retref ? %$retref : (ret => "");
|
||||
% my @vars = split(/,/, $ret{vars} // '');
|
||||
% my ($var1, $var2, $var3, $var4, $var5, $var6, $var7) = @vars;
|
||||
|
||||
<!-- So at this point the next section is only relevant it ret is not defined -->
|
||||
% if ($c->app->config->{debug}) {
|
||||
<br>
|
||||
<pre>
|
||||
<%= dumper { ret_data => \%ret } %>
|
||||
</pre>
|
||||
% }
|
||||
|
||||
%# my $element_count = scalar(@ret);
|
||||
|
||||
%# if (length $element_count == 0) {
|
||||
% my @vars = split(",",$ret{vars});
|
||||
% my $var1 = $vars[0];
|
||||
% my $var2 = $vars[1];
|
||||
% my $var3 = $vars[2];
|
||||
% my $var4 = $vars[3];
|
||||
% my $var5 = $vars[4];
|
||||
% my $var6 = $vars[5];
|
||||
% my $var7 = $vars[6];
|
||||
%# }
|
||||
|
||||
%if ($ret{ret} eq "") {
|
||||
% if ($ret{ret} eq "") {
|
||||
<%= l "ln_FIRSTPAGE_DESC" %>
|
||||
% } elsif (index($ret{ret},"SUCCESS") != -1) {
|
||||
<h2> Operation Status Report</h2>
|
||||
<br>
|
||||
<div>
|
||||
<h2> Operation Status Report</h2>
|
||||
<%= $c->render_to_string(inline => l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6,$var7)); %>
|
||||
<%= $c->render_to_string(inline => l($ret{ret}, @vars[0..6])) %>
|
||||
</div>
|
||||
% } else {
|
||||
<div>
|
||||
<h2> Operation Status Report - Error</h2>
|
||||
<br>
|
||||
<div class="text-danger">
|
||||
<h2> Operation Status Report - Error</h2>
|
||||
<%= $c->render_to_string(inline => l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6,$var7)); %>
|
||||
<%= $c->render_to_string(inline => l($ret{ret}, @vars[0..6])) %>
|
||||
</div>
|
||||
% }
|
||||
|
||||
@@ -63,7 +57,7 @@
|
||||
<th><%= l 'ln_SUBNET_MASK' %></th>
|
||||
<th><%= l 'ln_NUMBER_OF_HOSTS' %></th>
|
||||
<th><%= l 'ROUTER' %></th>
|
||||
<th><%= l 'ACTION' %></th>
|
||||
<th class="text-center"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -90,7 +84,7 @@
|
||||
% </a>
|
||||
%};
|
||||
% }
|
||||
<td><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
</tr>
|
||||
% }
|
||||
</tbody>
|
||||
|
@@ -7,67 +7,83 @@
|
||||
% my $dhost = $pf_datas->{dhost};
|
||||
% my $cmmnt = $pf_datas->{cmmnt};
|
||||
% my $allow = $pf_datas->{allow};
|
||||
|
||||
% if (config->{debug} == 1) {
|
||||
<p>
|
||||
%= dumper $c->current_route
|
||||
%= dumper $c->stash("ret")
|
||||
%= dumper %$pf_datas
|
||||
</p>
|
||||
% }
|
||||
|
||||
%= form_for '/portforwardinge' => (method => 'POST') => begin
|
||||
<br>
|
||||
%= l "pf_SUMMARY_REMOVE_DESC"
|
||||
</p><br>
|
||||
<span class="">
|
||||
%=l "pf_LABEL_PROTOCOL"
|
||||
</span>
|
||||
<span class="">
|
||||
%=$proto
|
||||
</span><br><br>
|
||||
<span class="">
|
||||
%=l "pf_LABEL_SOURCE_PORT"
|
||||
</span>
|
||||
<span class="">
|
||||
%=$sport
|
||||
</span>
|
||||
<br><br>
|
||||
<span class="">
|
||||
%=l "pf_LABEL_DESTINATION_HOST"
|
||||
</span>
|
||||
<span class="">
|
||||
%=$dport
|
||||
</span>
|
||||
<br><br>
|
||||
<span class="">
|
||||
%=l "pf_LABEL_DESTINATION_PORT"
|
||||
</span>
|
||||
<span class="">
|
||||
%=$dhost
|
||||
</span>
|
||||
<br><br>
|
||||
<span class="">
|
||||
%=l "pf_RULE_COMMENT"
|
||||
</span>
|
||||
<span class="">
|
||||
%=$cmmnt
|
||||
</span>
|
||||
<br><br>
|
||||
<span class="">
|
||||
%=l "pf_ALLOW_HOSTS"
|
||||
</span>
|
||||
<span class="">
|
||||
%=$allow
|
||||
</span>
|
||||
<br><br>
|
||||
%#}
|
||||
%= hidden_field sport=>$sport
|
||||
%= hidden_field proto=>$proto
|
||||
<br>
|
||||
%= submit_button "$btn", class => ""
|
||||
</p>
|
||||
|
||||
%end
|
||||
% if (config->{debug} == 0) {
|
||||
<pre>
|
||||
<%= dumper $c->current_route %>
|
||||
<%= dumper $c->stash("ret") %>
|
||||
<%= dumper %$pf_datas %>
|
||||
</pre>
|
||||
% }
|
||||
|
||||
<form action="/smanager/portforwardinge" method="POST">
|
||||
|
||||
<br>
|
||||
<div>
|
||||
<%= l 'pf_SUMMARY_REMOVE_DESC' %>
|
||||
</div>
|
||||
|
||||
<table>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
<% l 'pf_LABEL_PROTOCOL' %>
|
||||
</td>
|
||||
<td>
|
||||
<%= $proto %>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<% l 'pf_LABEL_SOURCE_PORT' %>
|
||||
</td>
|
||||
<td>
|
||||
<%= $sport %>
|
||||
</td>
|
||||
<tr>
|
||||
<tr>
|
||||
<td>
|
||||
<% l 'pf_LABEL_DESTINATION_HOST' %>
|
||||
</td>
|
||||
<td>
|
||||
<%= $dport %>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<% l 'pf_LABEL_DESTINATION_PORT' %>
|
||||
</td>
|
||||
<td>
|
||||
<%= $dhost %>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<% l 'pf_RULE_COMMENT' %>
|
||||
</td>
|
||||
<td>
|
||||
<%= $cmmnt %>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
<% l 'pf_ALLOW_HOSTS' %>
|
||||
</td>
|
||||
<td>
|
||||
<%= $allow %>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<%= hidden_field sport=>$sport %>
|
||||
<%= hidden_field proto=>$proto %>
|
||||
|
||||
<div class="row g-3 align-items-center">
|
||||
<div class="col-md-1">
|
||||
<button type="submit" class="btn btn-primary"><%= $btn %></button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
</div>
|
||||
|
@@ -1,12 +1,16 @@
|
||||
<div>
|
||||
% my $btn = l('pf_CREATE_RULE');
|
||||
%= form_for '/portforwardinga' => (method => 'POST') => begin
|
||||
|
||||
|
||||
|
||||
<form action="/smanager/portforwardinga" method="POST">
|
||||
|
||||
<br>
|
||||
|
||||
% my $retref= $c->stash("ret");
|
||||
% my %ret;
|
||||
% unless (length($retref)) {%ret = (ret=>"");}
|
||||
% else {%ret = %$retref;}
|
||||
|
||||
|
||||
% my $numtcpforwards = @$tcpforwards;
|
||||
% my $numudpforwards = @$udpforwards;
|
||||
|
||||
@@ -18,103 +22,94 @@
|
||||
% my $var5 = @vars[4];
|
||||
% my $var6 = @vars[5];
|
||||
|
||||
%if ($ret{ret} eq "") {
|
||||
%= $c->render_to_string(inline => l('pf_FIRST_PAGE_DESCRIPTION'));
|
||||
%} elsif (index($ret{ret},"SUCCESS") != -1) {
|
||||
% if ($ret{ret} eq "") {
|
||||
<%= $c->render_to_string(inline => l('pf_FIRST_PAGE_DESCRIPTION')); %>
|
||||
% } elsif (index($ret{ret},"SUCCESS") != -1) {
|
||||
<br>
|
||||
<div class="">
|
||||
<!--<h2> Operation Status Report</h2>-->
|
||||
%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6);
|
||||
<div>
|
||||
<h2> Operation Status Report</h2>
|
||||
<%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6); %>
|
||||
</div>
|
||||
%} else {
|
||||
% } else {
|
||||
<br>
|
||||
<div class="">
|
||||
<!--<h2> Operation Status Report - Error</h2>-->
|
||||
%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6);
|
||||
<div class="text-danger">
|
||||
<h2> Operation Status Report - Error</h2>
|
||||
<%= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6); %>
|
||||
</div>
|
||||
%}
|
||||
% }
|
||||
|
||||
<p>
|
||||
<br>
|
||||
%= submit_button "$btn", class => ""
|
||||
</p>
|
||||
|
||||
% my $btn = l('pf_CREATE_RULE');
|
||||
|
||||
<div class="row g-3 align-items-center">
|
||||
<div class="col-md-2">
|
||||
<button type="submit" class="btn btn-primary"><%= $btn %></button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
% end
|
||||
|
||||
% if ($empty){
|
||||
|
||||
% if ($empty){
|
||||
<br>
|
||||
%=l 'pf_NO_FORWARDS'
|
||||
% } else {
|
||||
<br>
|
||||
%=l 'pf_SHOW_FORWARDS'
|
||||
<br><br />
|
||||
<table class="table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="">
|
||||
%=l 'pf_LABEL_PROTOCOL'
|
||||
</th>
|
||||
<th class="">
|
||||
%=l 'pf_LABEL_SOURCE_PORT'
|
||||
</th>
|
||||
<th class="">
|
||||
%=l 'pf_LABEL_DESTINATION_HOST'
|
||||
</th>
|
||||
<th class="">
|
||||
%=l 'pf_LABEL_DESTINATION_PORT'
|
||||
</th>
|
||||
<th class="">
|
||||
%=l 'pf_ALLOW_HOSTS'
|
||||
</th>
|
||||
<th class="">
|
||||
%=l 'pf_RULE_COMMENT'
|
||||
</th>
|
||||
<th class="" '>
|
||||
%=l 'ACTION'
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
% my %forwards = ();
|
||||
% $forwards{TCP} = $tcpforwards;
|
||||
% $forwards{UDP} = $udpforwards;
|
||||
|
||||
% foreach my $proto (sort keys %forwards) {
|
||||
|
||||
% if (@{ $forwards{$proto} }) {
|
||||
% foreach my $entry (@{ $forwards{$proto} }) {
|
||||
<%= l 'pf_NO_FORWARDS' %>
|
||||
% } else {
|
||||
<br>
|
||||
<%= l 'pf_SHOW_FORWARDS' %>
|
||||
<br><br>
|
||||
<table class="table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
% my $sport = $entry->key;
|
||||
% my $dhost = $entry->prop('DestHost');
|
||||
% my $dport = $entry->prop('DestPort') || '';
|
||||
% my $cmmnt = $entry->prop('Comment') || '';
|
||||
% my $allow = $entry->prop('AllowHosts') || '';
|
||||
%= t td => (class => "") => $proto
|
||||
%= t td => (class => "") => $sport
|
||||
%= t td => (class => "") => $dhost
|
||||
%= t td => (class => "") => $dport
|
||||
%= t td => (class => "") => $allow
|
||||
%= t td => (class => "") => $cmmnt
|
||||
<td class="">
|
||||
%my $remove_text = l('REMOVE'); # Localized text
|
||||
%my $csrf_token = "TOKEN"; # CSRF token for security
|
||||
%my $actionRemove = qq{
|
||||
% <a href="portforwardingd?CsrfDef=$csrf_token&trt=DEL&sport=$sport&proto=$proto">
|
||||
% <button type='button' class="" title='$remove_text' >
|
||||
% $remove_text
|
||||
% </button>
|
||||
% </a>
|
||||
%};
|
||||
<%= $c->render_to_string(inline => $actionRemove) %>
|
||||
</td>
|
||||
<th><%= l 'pf_LABEL_PROTOCOL' %></th>
|
||||
<th><%= l 'pf_LABEL_SOURCE_PORT' %></th>
|
||||
<th><%= l 'pf_LABEL_DESTINATION_HOST' %></th>
|
||||
<th><%= l 'pf_LABEL_DESTINATION_PORT' %></th>
|
||||
<th><%= l 'pf_ALLOW_HOSTS' %></th>
|
||||
<th><%= l 'pf_RULE_COMMENT' %></th>
|
||||
<th class="text-center"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
% }
|
||||
% }
|
||||
%}
|
||||
%}
|
||||
</tbody>
|
||||
</thead>
|
||||
<tbody>
|
||||
% my %forwards = ();
|
||||
% $forwards{TCP} = $tcpforwards;
|
||||
% $forwards{UDP} = $udpforwards;
|
||||
|
||||
% foreach my $proto (sort keys %forwards) {
|
||||
|
||||
% if (@{ $forwards{$proto} }) {
|
||||
% foreach my $entry (@{ $forwards{$proto} }) {
|
||||
<tr class="align-middle">
|
||||
% my $sport = $entry->key;
|
||||
% my $dhost = $entry->prop('DestHost');
|
||||
% my $dport = $entry->prop('DestPort') || '';
|
||||
% my $cmmnt = $entry->prop('Comment') || '';
|
||||
% my $allow = $entry->prop('AllowHosts') || '';
|
||||
<td><%= $proto %></td>
|
||||
<td><%= $sport %></td>
|
||||
<td><%= $dhost %></td>
|
||||
<td><%= $dport %></td>
|
||||
<td><%= $allow %></td>
|
||||
<td><%= $cmmnt %></td>
|
||||
% my $remove_text = l('REMOVE'); # Localized text
|
||||
% my $csrf_token = "TOKEN"; # CSRF token for security
|
||||
% my $actionRemove = qq{
|
||||
% <a href="portforwardingd?CsrfDef=$csrf_token&trt=DEL&sport=$sport&proto=$proto">
|
||||
% <button type='button' class="btn btn-primary" title='$remove_text' >
|
||||
% $remove_text
|
||||
% </button>
|
||||
% </a>
|
||||
% };
|
||||
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
</tr>
|
||||
% }
|
||||
% }
|
||||
% }
|
||||
% }
|
||||
</tbody>
|
||||
</table>
|
||||
%= hidden_field 'trt' => $pf_datas->{trt}
|
||||
|
||||
<%= hidden_field 'trt' => $pf_datas->{trt} %>
|
||||
|
||||
</div>
|
||||
|
@@ -17,7 +17,7 @@
|
||||
</div>
|
||||
|
||||
<div class="col-auto">
|
||||
<input type="text" name="pseudonymDesc" id="inputPseudonymDesc" class="form-control" aria-describedby="PseudonymDesc" >
|
||||
<input type="text" name="pseudonymDesc" id="inputPseudonymDesc" class="form-control" aria-describedby="Pseudonym Description" >
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
@@ -22,9 +22,9 @@
|
||||
<table class="table table-bordered user-table-max-width">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="col-sm"><%= l 'pse_PSEUDONYM' %></th>
|
||||
<th class="col-sm"><%= l 'pse_USER_OR_GROUP' %></th>
|
||||
<th class="col-sm user-valign-center" colspan="2"><%= l 'ACTION' %></th>
|
||||
<th class="col-sm"><%= l 'pse_PSEUDONYM' %></th>
|
||||
<th class="col-sm"><%= l 'pse_USER_OR_GROUP' %></th>
|
||||
<th class="col-sm align-middle" colspan="2"><%= l 'ACTION' %></th>
|
||||
<!-- <th class="" style="display: normal;"></th> -->
|
||||
</tr>
|
||||
</thead>
|
||||
@@ -57,7 +57,7 @@
|
||||
% $modify_text
|
||||
% </button>
|
||||
% </a>
|
||||
%};
|
||||
% };
|
||||
% }
|
||||
|
||||
% if ($removable eq 'yes') {
|
||||
@@ -70,11 +70,11 @@
|
||||
% $remove_text
|
||||
% </button>
|
||||
% </a>
|
||||
%};
|
||||
% };
|
||||
% }
|
||||
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
|
||||
</tr>
|
||||
% }
|
||||
|
@@ -36,7 +36,7 @@
|
||||
<th class="col-sm"><%= $limit %></th>
|
||||
<th class="col-sm"><%= $absolute %></th>
|
||||
<th class="col-sm"><%= $current %></th>
|
||||
<th class="col-sm user-valign-center"><%= l 'ACTION' %></th>
|
||||
<th class="col-sm align-middle"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
% </a>
|
||||
%};
|
||||
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="align-middle"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
</tr>
|
||||
% }
|
||||
</tbody>
|
||||
|
@@ -23,11 +23,11 @@
|
||||
<table class="table table-bordered">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><%=l 'ACCOUNT' %></th>
|
||||
<th><%=l 'USER_NAME' %></th>
|
||||
<th><%=l 'usr_VPN_CLIENT_ACCESS' %></th>
|
||||
<th><%=l 'usr_FORWARDING_ADDRESS' %></th>
|
||||
<th class="user-valign-center" colspan="5"><%= l 'ACTION' %></th>
|
||||
<th><%= l 'ACCOUNT' %></th>
|
||||
<th><%= l 'USER_NAME' %></th>
|
||||
<th><%= l 'usr_VPN_CLIENT_ACCESS' %></th>
|
||||
<th><%= l 'usr_FORWARDING_ADDRESS' %></th>
|
||||
<th class="text-center text-center" colspan="5"><%= l 'ACTION' %></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -136,17 +136,17 @@
|
||||
<!-- If webmail disabled??? -->
|
||||
% $actionroundcube = qq{
|
||||
%<a href="roundcubepanel?CsrfDef=$csrf_token&url=https://$thisdomain/roundcube?_user=$useraccounts_user_name&height=600px">
|
||||
% <button type='button' class="btn btn-primary" title='$roundcube_text' >
|
||||
% <button type='button' class="btn btn-primary" title='$roundcube_text' >
|
||||
% $roundcube_text
|
||||
% </button>
|
||||
%</a>
|
||||
%};
|
||||
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionResetPw) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionLock) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="user-valign-center"><%= $c->render_to_string(inline => $actionroundcube) %></td>
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionModify) %></td>
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionResetPw) %></td>
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionLock) %></td>
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionRemove) %></td>
|
||||
<td class="text-center"><%= $c->render_to_string(inline => $actionroundcube) %></td>
|
||||
</tr>
|
||||
% }
|
||||
</tbody>
|
||||
|
@@ -5,28 +5,29 @@
|
||||
<div class="card-body">
|
||||
|
||||
% if (config->{debug} == 1) {
|
||||
<p>
|
||||
%= dumper "<pf>".$c->current_route
|
||||
%= dumper $c->stash("ret")
|
||||
%= dumper $c->stash("portforwarding")
|
||||
% my $ref = $pf_datas->{portforwarding};
|
||||
%= dumper $ref->{TCP}->[0]."</pf>"
|
||||
</p>
|
||||
<pre>
|
||||
<%= dumper "<pf>".$c->current_route %>
|
||||
<%= dumper $c->stash("ret") %>
|
||||
<%= dumper $c->stash("portforwarding") %>
|
||||
% my $ref = $pf_datas->{portforwarding}; %>
|
||||
<%= dumper $ref->{TCP}->[0]."</pf>" %>
|
||||
</pre>
|
||||
% }
|
||||
|
||||
|
||||
<h1><%= $title%></h1>
|
||||
%= $modul
|
||||
|
||||
%= $modul
|
||||
|
||||
% if ($pf_datas->{trt} eq 'ADD') {
|
||||
%= include 'partials/_pf_add'
|
||||
%} elsif ($pf_datas->{trt} eq 'ADD1') {
|
||||
%= include 'partials/_pf_add'
|
||||
%} elsif ($pf_datas->{trt} eq 'DEL') {
|
||||
%= include 'partials/_pf_del'
|
||||
%} elsif ($pf_datas->{trt} eq 'DEL1'){
|
||||
%= include 'partials/_pf_list'
|
||||
%} else {
|
||||
%= include 'partials/_pf_list'
|
||||
<%= include 'partials/_pf_add' %>
|
||||
% } elsif ($pf_datas->{trt} eq 'ADD1') {
|
||||
<%= include 'partials/_pf_add' %>
|
||||
% } elsif ($pf_datas->{trt} eq 'DEL') {
|
||||
<%= include 'partials/_pf_del' %>
|
||||
% } elsif ($pf_datas->{trt} eq 'DEL1'){
|
||||
<%= include 'partials/_pf_list' %>
|
||||
% } else {
|
||||
<%= include 'partials/_pf_list' %>
|
||||
%}
|
||||
|
||||
</div>
|
||||
|
@@ -85,10 +85,10 @@
|
||||
<tbody>
|
||||
|
||||
% foreach my $val ( @vals ) {
|
||||
% my ($net, $mask) = split '/', $val;
|
||||
% $mask = '255.255.255.255' unless ($mask);
|
||||
% my ($numhosts,$a,$b) = esmith::util::computeHostRange($net,$mask);
|
||||
<tr class="align-middle">
|
||||
% my ($net, $mask) = split '/', $val;
|
||||
% $mask = '255.255.255.255' unless ($mask);
|
||||
% my ($numhosts,$a,$b) = esmith::util::computeHostRange($net,$mask);
|
||||
<tr class="align-middle">
|
||||
<td><%= $net %></td>
|
||||
<td><%= $mask %></td>
|
||||
<td><%= $numhosts %></td>
|
||||
@@ -96,7 +96,7 @@
|
||||
<input type='checkbox' name='Remove_nets' value='<%= $net.'/'.$mask %>'>
|
||||
</td>
|
||||
</tr>
|
||||
% }
|
||||
% }
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
|
@@ -1,6 +1,6 @@
|
||||
%define name smeserver-manager-AdminLTE
|
||||
%define version 11.0.0
|
||||
%define release 35
|
||||
%define release 36
|
||||
Summary: AdminLTE is an html framework for admin consoles - this rpm adds it to smeserver manager2
|
||||
Name: %{name}
|
||||
Version: %{version}
|
||||
@@ -11,7 +11,6 @@ URL: https://adminlte.io/
|
||||
Group: SMEserver/addon
|
||||
source: %{name}-%{version}.tar.gz
|
||||
|
||||
|
||||
Packager: Brian Read <brianr@koozali.org>
|
||||
BuildArchitectures: noarch
|
||||
BuildRoot: /var/tmp/%{name}-%{version}-%{release}-buildroot
|
||||
@@ -29,6 +28,11 @@ AdminLTE is an html framework for admin consoles
|
||||
wget https://github.com/ColorlibHQ/AdminLTE/archive/master.zip
|
||||
|
||||
%changelog
|
||||
* Fri Jun 13 2025 John Crisp <jcrisp@safeandsoundit.co.uk> 11.0.0-36.sme
|
||||
- Cosmetic tweaks
|
||||
- Localnetworking fix via [SME: 13041]
|
||||
- Portforwarding panels done but require fix to module similar to 13041 above.
|
||||
|
||||
* Thu Jun 12 2025 John Crisp <jcrisp@safeandsoundit.co.uk> 11.0.0-35.sme
|
||||
- Finish backup panels
|
||||
- Finish printer panels
|
||||
|
Reference in New Issue
Block a user