Compare commits

..

No commits in common. "master" and "0.2.0-8.el8.sme" have entirely different histories.

5 changed files with 3 additions and 76 deletions

View File

@ -6,14 +6,7 @@ SMEServer Koozali developed git repo for smeserver-diskusage smecontribs
<br />https://wiki.koozali.org/Diskusage <br />https://wiki.koozali.org/Diskusage
## Bugzilla ## Bugzilla
Show list of outstanding bugs: Show list of outstanding bugs: [here](https://bugs.koozali.org/buglist.cgi?component=smeserver-diskusage&product=SME%20Contribs&query_format=advanced&limit=0&bug_status=UNCONFIRMED&bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&bug_status=CONFIRMED)
[All](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=UNCONFIRMED&bug_status=CONFIRMED&bug_status=NEEDINFO&bug_status=IN_PROGRESS&bug_status=RESOLVED&bug_status=VERIFIED&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
[Confirmed](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=CONFIRMED&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
[Unconfirmed](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=UNCONFIRMED&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
[Need Info](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=NEEDINFO&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
[In Progress](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=IN_PROGRESS&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
[Verified](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=VERIFIED&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
[Resolved](https://bugs.koozali.org/buglist.cgi?action=wrap&bug_status=RESOLVED&classification=Contribs&component=smeserver-diskusage&list_id=105781&order=changeddate+DESC%2Ccomponent%2Cpriority%2Cbug_severity&product=SME+Contribs&query_format=advanced)
## Description ## Description

View File

@ -1,34 +0,0 @@
package SrvMngr::Controller::Diskusage;
#----------------------------------------------------------------------
# heading : Investigation
# description : Disk Usage
# navigation : 4000 600
#----------------------------------------------------------------------
#----------------------------------------------------------------------
# name : diskusage, method : get, url : /diskusage, ctlact : Diskusage#main
#
# routes : end
#----------------------------------------------------------------------
use strict;
use warnings;
use Mojo::Base 'Mojolicious::Controller';
use Locale::gettext;
use SrvMngr::I18N;
use SrvMngr qw(theme_list init_session);
#use SrvMngr::Model::Main;
sub main {
my $c = shift;
$c->app->log->info($c->log_req);
my $title = $c->l('diskusage_panel');
my $diskusage_height = $c->param('height') || '600';
my $diskusage_full_html = qx(perl -T /etc/e-smith/web/functions/diskusage);
my ($diskusage_html) = $diskusage_full_html =~ m{<body[^>]*>(.*?)</body>}si;
# Remove lines starting with the specified phrases
$diskusage_html =~ s/^( SME Server|<BR>Copyright \(c\)).*\n//gmi;
$c->stash(title => $title, diskusage => $diskusage_html, height => $diskusage_height);
#die("$diskusage_html");
$c->render(template => 'diskusage');
} ## end sub main
1;

View File

@ -1,2 +0,0 @@
'du_FUll_description' => 'Full description',
'du_diskusage' => 'Disc Usage'

View File

@ -1,23 +0,0 @@
% layout 'default', title => "Sme server 2 - Disk usage";
% content_for 'module' => begin
<div id='Diskusage' class='module diskusage-panel'>
% if (config->{debug} == 1) {
<pre>
%= dumper $c->current_route
%= dumper $c->stash('diskusage')
</pre>
% }
% if ( stash 'error' ) {
<br><div class=sme-error>
%= $c->render_to_string(inline => stash 'error')
</div>
%}
<!--<h1>Legacy-<%#=l('du_diskusage') %></h1><br>-->
% my $height = $c->stash('height') | '600';
% if ($height !~ /px$/) { $height = $height.'px';}
%== $c->stash('diskusage');
</div>
%end

View File

@ -5,8 +5,8 @@
Summary: Disk usage panel for the SME Server Summary: Disk usage panel for the SME Server
%define name smeserver-diskusage %define name smeserver-diskusage
Name: %{name} Name: %{name}
%define version 11.0.0 %define version 0.2.0
%define release 2 %define release 8
Version: %{version} Version: %{version}
Release: %{release}%{?dist} Release: %{release}%{?dist}
License: GPL License: GPL
@ -24,13 +24,6 @@ AutoReqProv: no
Disk usage panel showing filesystem, i-bay and user statistics. Disk usage panel showing filesystem, i-bay and user statistics.
%changelog %changelog
* Sat Apr 19 2025 Brian Read <brianr@koozali.org> 11.0.0-2.sme
- Get the new SM2 code right - calling the old perl.
- Update version to 11
* Fri Apr 18 2025 Brian Read <brianr@koozali.org> 0.2.0-9.sme
- Add in legacy panel code into SM2
* Sun Sep 08 2024 fix-e-smith-pkg.sh by Trevor Batley <trevor@batley.id.au> 0.2.0-8.sme * Sun Sep 08 2024 fix-e-smith-pkg.sh by Trevor Batley <trevor@batley.id.au> 0.2.0-8.sme
- Fix e-smith references in smeserver-diskusage [SME: 12732] - Fix e-smith references in smeserver-diskusage [SME: 12732]