/[smeserver]/rpms/smeserver-manager/sme10/smeserver-manager-0.1.0-start_service.patch
ViewVC logotype

Annotation of /rpms/smeserver-manager/sme10/smeserver-manager-0.1.0-start_service.patch

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Wed Jul 1 15:16:09 2020 UTC (4 years, 4 months ago) by michel
Branch: MAIN
CVS Tags: smeserver-manager-0_1_0-28_el7_sme, smeserver-manager-0_1_0-29_el7_sme, smeserver-manager-0_1_0-26_el7_sme, smeserver-manager-0_1_0-30_el7_sme, smeserver-manager-0_1_0-27_el7_sme, smeserver-manager-0_1_0-31_el7_sme, smeserver-manager-0_1_2-1_el7_sme
* Wed Jul 01 2020 Michel Begue <mab974@gmail.com> 0.1.0-26.sme
- Fix first start error
- Fix incorrect messages and various typos in modules
- Add possibility to hide menu(s) (requires jquery)

1 michel 1.1 diff -urN smeserver-manager-0.1.0.old/createlinks smeserver-manager-0.1.0/createlinks
2     --- smeserver-manager-0.1.0.old/createlinks 2020-06-14 20:32:54.490778984 +0400
3     +++ smeserver-manager-0.1.0/createlinks 2020-06-14 20:22:02.000000000 +0400
4     @@ -7,8 +7,6 @@
5     #--------------------------------------------------
6     my $mngrdir = '/usr/share/smanager';
7    
8     -# links to add
9     -
10     # templates to expand
11     for ( qw( sme_core.css sme_main.css sme_menu.css styles.css ) )
12     {
13     @@ -18,14 +16,19 @@
14     }
15    
16     templates2events("$mngrdir/conf/srvmngr.conf",
17     - qw( smanager-modify bootstrap-console-save console-save));
18     + qw( smanager-modify bootstrap-console-save console-save ));
19     templates2events("/etc/systemd/system/smanager.service",
20     - qw( smanager-modify bootstrap-console-save console-save));
21     + qw( smanager-modify bootstrap-console-save console-save ));
22    
23     # services to launch on event
24     +for my $event ( qw( smanager-modify smanager-refresh bootstrap-console-save console-save ) )
25     +{
26     + safe_symlink("restart",
27     + "root/etc/e-smith/events/$event/services2adjust/smanager");
28     +}
29    
30     # actions to perform
31     -for my $event (qw( yum-install yum-update yum-remove smanager-refresh bootstrap-console-save console-save))
32     +for my $event ( qw( yum-install yum-update yum-remove smanager-refresh bootstrap-console-save console-save ) )
33     {
34     event_link('navigation2-conf', "$event", '80');
35     event_link('routes2-conf', "$event", '80');
36     diff -urN smeserver-manager-0.1.0.old/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/VirtualHosts/27SManagerProxyPass smeserver-manager-0.1.0/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/VirtualHosts/27SManagerProxyPass
37     --- smeserver-manager-0.1.0.old/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/VirtualHosts/27SManagerProxyPass 2020-05-20 16:50:11.000000000 +0400
38     +++ smeserver-manager-0.1.0/root/etc/e-smith/templates/etc/httpd/conf/httpd.conf/VirtualHosts/27SManagerProxyPass 2020-06-25 18:21:34.550012316 +0400
39     @@ -4,13 +4,11 @@
40     $haveSSL = (exists ${modSSL}{status} and ${modSSL}{status} eq "enabled") ? 'yes' : 'no';
41     $plainTextAccess = ${'httpd-admin'}{PermitPlainTextAccess} || 'no';
42     $plainPort = ${'httpd-e-smith'}{TCPPort} || '80';
43     - $adminPort2 = ${'httpd-admin'}{TCPPort2} || '982';
44     + $adminPort2 = ${'smanager'}{TCPPort} || '982';
45     $sslPort = ${modSSL}{TCPPort} || '443';
46    
47     $OUT = '';
48    
49     - $OUT .= "# LogLevel alert rewrite:trace8 \n";
50     -
51     foreach $place ('smanager')
52     {
53     if (($port eq $plainPort) && ($haveSSL eq 'yes') && ($plainTextAccess ne 'yes'))
54     diff -urN smeserver-manager-0.1.0.old/root/etc/e-smith/templates/etc/systemd/system/smanager.service/10All smeserver-manager-0.1.0/root/etc/e-smith/templates/etc/systemd/system/smanager.service/10All
55     --- smeserver-manager-0.1.0.old/root/etc/e-smith/templates/etc/systemd/system/smanager.service/10All 2020-05-28 23:45:55.000000000 +0400
56     +++ smeserver-manager-0.1.0/root/etc/e-smith/templates/etc/systemd/system/smanager.service/10All 2020-06-30 21:41:30.756998402 +0400
57     @@ -1,13 +1,11 @@
58     [Unit]
59     Description=Server Manager 2 Mojo
60     Requires=network.target
61     -After=network.target
62     -#Requires=apache.target
63     -#After=ldap.target
64     +##Requires= httpd.target slapd.target
65     +##After=network.target slapd.target
66    
67     [Service]
68     Type=simple
69     -# Type=forking
70     SyslogIdentifier=smanager
71     WorkingDirectory=/usr/share/smanager/script
72     PIDFile=/var/run/smanager.pid
73     diff -urN smeserver-manager-0.1.0.old/root/etc/e-smith/templates/usr/share/smanager/conf/srvmngr.conf/25hypnotoad smeserver-manager-0.1.0/root/etc/e-smith/templates/usr/share/smanager/conf/srvmngr.conf/25hypnotoad
74     --- smeserver-manager-0.1.0.old/root/etc/e-smith/templates/usr/share/smanager/conf/srvmngr.conf/25hypnotoad 2020-06-06 13:51:10.000000000 +0400
75     +++ smeserver-manager-0.1.0/root/etc/e-smith/templates/usr/share/smanager/conf/srvmngr.conf/25hypnotoad 2020-06-25 18:05:01.529568344 +0400
76     @@ -1,6 +1,6 @@
77     hypnotoad => \{
78     ## adresses and ports listened
79     - listen => ['http://127.0.0.1:{$smanager{'Port'} || 982 }'],
80     + listen => ['http://127.0.0.1:{$smanager{'TCPPort'} || 982 }'],
81     proxy => 1,
82     pid_file => '/var/run/smanager.pid',
83    
84     diff -urN smeserver-manager-0.1.0.old/root/etc/e-smith/templates/usr/share/smanager/themes/default/public/css/styles.css/50body smeserver-manager-0.1.0/root/etc/e-smith/templates/usr/share/smanager/themes/default/public/css/styles.css/50body
85     --- smeserver-manager-0.1.0.old/root/etc/e-smith/templates/usr/share/smanager/themes/default/public/css/styles.css/50body 2020-06-12 22:40:03.000000000 +0400
86     +++ smeserver-manager-0.1.0/root/etc/e-smith/templates/usr/share/smanager/themes/default/public/css/styles.css/50body 2020-06-30 19:51:14.759304053 +0400
87     @@ -1,7 +1,7 @@
88     {
89     $OUT = <<'EOF';
90    
91     -/* smanager (smeserver_manager2) */
92     +/* smeserver_manager2 */
93    
94     /*----------------------------------------------------------------------
95     * copyright (C) 1999-2003 Mitel Networks Corporation
96     @@ -147,24 +147,26 @@
97     font-weight: bold;
98     }
99    
100     +.section {
101     +}
102     .a, .item {
103     line-height: 12px;
104     }
105    
106     .section-title {
107     display: inline-block;
108     - line-height: 19px;
109     - color: #888;
110     + color: #6CA345; /*#888;*/
111     padding-left: 5px;
112     padding-right: 5px;
113     + line-height: 18px;
114     font-weight: bold;
115     }
116    
117     -p.menu-title {
118     +.menu-title {
119     display: inline-block;
120     - color: #666;
121     - padding-left: 0px;
122     - padding-right: 0px;
123     + color: #1A6D1A; /*#666;*/
124     + padding-left: 1px;
125     + padding-right: 1px;
126     font-weight: bold;
127     }
128    
129     @@ -209,7 +211,6 @@
130     text-align: center;
131     }
132    
133     -
134     /*end*/
135    
136     EOF
137     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Datetime.pm smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Datetime.pm
138     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Datetime.pm 2020-05-30 20:46:54.000000000 +0400
139     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Datetime.pm 2020-07-01 18:03:45.268785684 +0400
140     @@ -19,7 +19,7 @@
141     use esmith::FormMagick;
142     #use esmith::FormMagick::Panel::datetime;
143    
144     -our $db = esmith::ConfigDB->open() || die "Couldn't open config db";
145     +our $cdb = esmith::ConfigDB->open() || die "Couldn't open config db";
146    
147     sub main {
148     my $c = shift;
149     @@ -30,12 +30,12 @@
150     my $modul = $c->l('dat_INITIAL_DESC');
151    
152     # more complicated for ntpstatus
153     - $dat_datas{'ntpstatus'} = ($db->get_prop('ntpd','status')) || '';
154     - $dat_datas{'ntpserver'} = ($db->get_prop('ntpd','NTPServer')) || '';
155     + $dat_datas{'ntpstatus'} = ($cdb->get_prop('ntpd','status')) || '';
156     + $dat_datas{'ntpserver'} = ($cdb->get_prop('ntpd','NTPServer')) || '';
157     $dat_datas{'now_string'} = esmith::FormMagick->gen_locale_date_string();
158    
159     $c->stash( title => $title, modul => $modul, dat_datas => \%dat_datas );
160     - $c->render(template => 'datetime');
161     + $c->render('datetime');
162     };
163    
164    
165     @@ -45,22 +45,22 @@
166    
167     my %dat_datas = ();
168     my $title = $c->l('dat_FORM_TITLE');
169     - my $result = "";
170     + my $result = '';
171    
172     my $old_ntpstatus = $c->param('old_ntpstatus');
173     - $dat_datas{'ntpstatus'} = $c->param('ntpstatus');
174     - if ($dat_datas{'ntpstatus'} ne $old_ntpstatus) {
175     - my $modul = $c->l('dat_INITIAL_DESC');
176     - $dat_datas{'ntpserver'} = ($db->get_prop('ntpd','NTPServer')) || '';
177     - $dat_datas{'now_string'} = esmith::FormMagick->gen_locale_date_string();
178     + $dat_datas{ntpstatus} = $c->param('ntpstatus');
179    
180     + if ($dat_datas{ntpstatus} ne $old_ntpstatus) {
181     + my $modul = $c->l('dat_INITIAL_DESC');
182     + $dat_datas{ntpserver} = ($cdb->get_prop('ntpd','NTPServer')) || '';
183     + $dat_datas{now_string} = esmith::FormMagick->gen_locale_date_string();
184     $c->stash( title => $title, modul => $modul, dat_datas => \%dat_datas );
185     - $c->render(template => 'datetime');
186     + return $c->render('datetime');
187     }
188    
189     - if ($dat_datas{'ntpstatus'} eq 'enabled') {
190     - $dat_datas{'ntpserver'} = $c->param('ntpserver');
191     - $db->get('ntpd')->set_prop('NTPServer', $dat_datas{'ntpserver'});
192     + if ($dat_datas{ntpstatus} eq 'enabled') {
193     + $dat_datas{ntpserver} = $c->param('ntpserver');
194     + $cdb->get('ntpd')->set_prop('NTPServer', $dat_datas{'ntpserver'});
195     } else {
196     #my $servername = ($c->param('ServerName') || 'WS');
197     }
198     @@ -69,15 +69,23 @@
199     #
200     # Update the system
201     #
202     - system ("/sbin/e-smith/signal-event datetime-update") == 0
203     - or $result = $c->l('ERROR_UPDATING');
204     + system ("/sbin/e-smith/signal-event", "datetime-update") == 0
205     + or $result = $c->l('ERROR_UPDATING_CONFIGURATION');
206    
207     + if ( $result ) {
208     + $c->stash( error => $result );
209     + $c->stash( title => $title, dat_datas => \%dat_datas );
210     + return $c->render('datetime');
211     + #$c->flash( error => $result . '- f l a s h' );
212     + #$c->redirect_to('/datetime');
213     + }
214     + $result = $c->l('dat_SUCCESS');
215    
216     - if ( $result eq '' ) { $result = $c->l('dat_SUCCESS'); }
217     -
218     - $c->stash( title => $title, modul => $result );
219     - $c->render(template => 'module');
220     + my $message = "'Datetime' update DONE";
221     + $c->app->log->info($message);
222     + $c->flash( success => $result );
223    
224     + $c->redirect_to('/datetime');
225     };
226    
227    
228     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Domains.pm smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Domains.pm
229     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Domains.pm 2020-05-30 20:48:16.000000000 +0400
230     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Domains.pm 2020-06-28 18:55:52.827074656 +0400
231     @@ -166,7 +166,7 @@
232     }
233    
234     if ( ! $result ) {
235     - $result = $c->l('dom_CREATE_SUCCEEDED') . " $domain";
236     + $result = $c->l('dom_SUCCESSFULLY_CREATED') . " $domain";
237     }
238     }
239    
240     @@ -189,7 +189,7 @@
241     }
242    
243     if ( ! $result ) {
244     - $result = $c->l('dom_MODIFY_SUCCEEDED') . " $domain";
245     + $result = $c->l('dom_SUCCESSFULLY_MODIFIED') . " $domain";
246     }
247     }
248    
249     @@ -234,7 +234,7 @@
250     $result .= $res unless $res eq 'OK';
251     }
252     if ( ! $result ) {
253     - $result = $c->l('dom_REMOVE_SUCCEEDED') . " $domain";
254     + $result = $c->l('dom_SUCCESSFULLY_DELETED') . " $domain";
255     }
256     }
257    
258     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Groups.pm smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Groups.pm
259     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Groups.pm 2020-05-30 20:47:26.000000000 +0400
260     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Groups.pm 2020-06-30 23:01:13.000000000 +0400
261     @@ -279,8 +279,9 @@
262    
263     my ( $c, $group ) = @_;
264    
265     + my @members = ();
266     my $rec = $adb->get($group);
267     - my @members = split ( /,/, $rec->prop('Members') );
268     + @members = split ( /,/, $rec->prop('Members') ) if ( $rec );
269    
270     my %names;
271     foreach my $m (@members) {
272     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Ibays.pm smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Ibays.pm
273     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Ibays.pm 2020-06-04 21:12:20.000000000 +0400
274     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Ibays.pm 2020-06-30 22:04:23.000000000 +0400
275     @@ -32,7 +32,6 @@
276    
277     my %iba_datas = ();
278     my $title = $c->l('iba_FORM_TITLE');
279     - my $modul = '';
280    
281     $iba_datas{'trt'} = 'LIST';
282    
283     @@ -42,7 +41,7 @@
284     @ibays = $adb->ibays();
285     }
286    
287     - $c->stash( title => $title, modul => $modul, iba_datas => \%iba_datas, ibays => \@ibays );
288     + $c->stash( title => $title, iba_datas => \%iba_datas, ibays => \@ibays );
289     $c->render(template => 'ibays');
290    
291     };
292     @@ -143,13 +142,14 @@
293     $iba_datas{'trt'} = $trt;
294    
295     my $result = '';
296     + my $res;
297    
298     if ( $trt eq 'ADD' ) {
299    
300     my $name = ($c->param('ibay') || '');
301    
302     # controls
303     - my $res = validate_ibay( $c, $name );
304     + $res = validate_ibay( $c, $name );
305     $result .= $res unless $res eq 'OK';
306    
307     if ( ! $result ) {
308     @@ -167,7 +167,7 @@
309     my $name = ($c->param('ibay') || '');
310    
311     # controls
312     - my $res = '';
313     + $res = '';
314    
315     if ( ! $result ) {
316     $res = modify_ibay( $c, $name );
317     @@ -190,11 +190,11 @@
318     $result .= $c->l('iba_IBAY_PASSWD_VERIFY_ERROR') . ' - ';
319     }
320    
321     - my $res = check_password( $c, $pass1 );
322     + $res = check_password( $c, $pass1 );
323     $result .= $res unless $res eq 'OK';
324    
325     if ( ! $result ) {
326     - my $res = reset_password( $c, $ibay, $pass1 );
327     + $res = reset_password( $c, $ibay, $pass1 );
328     $result .= $res unless $res eq 'OK';
329     if ( ! $result ) {
330     $result = $c->l('iba_SUCCESSFULLY_RESET_PASSWORD') . ' ' . $ibay;
331     @@ -214,7 +214,7 @@
332     }
333    
334     if ( ! $result ) {
335     - my $res = remove_ibay( $c, $ibay );
336     + $res = remove_ibay( $c, $ibay );
337     $result .= $res unless $res eq 'OK';
338     if ( ! $result ) {
339     $result = $c->l('iba_SUCCESSFULLY_DELETED_IBAY') . ' ' . $ibay;
340     @@ -223,9 +223,19 @@
341     }
342     }
343    
344     - $c->stash( title => $title, modul => $result, iba_datas => \%iba_datas );
345     - $c->render(template => 'module');
346     + # common parts
347     +
348     + if ($res ne 'OK') {
349     + $c->stash( error => $result );
350     + $c->stash( title => $title, iba_datas => \%iba_datas );
351     + return $c->render('ibays');
352     + }
353     +
354     + my $message = "'Ibays' updates ($trt) DONE";
355     + $c->app->log->info($message);
356     + $c->flash( success => $result );
357    
358     + $c->redirect_to('/ibays');
359     };
360    
361    
362     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Quota.pm smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Quota.pm
363     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Quota.pm 2020-05-30 20:47:10.000000000 +0400
364     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Quota.pm 2020-06-28 18:50:36.433935049 +0400
365     @@ -106,7 +106,7 @@
366     $result .= $res unless $res eq 'OK';
367    
368     if ( ! $result ) {
369     - $result = $c->l('quo_SUCCESSFULLY_MODIFY') . ' ' . $acct;
370     + $result = $c->l('quo_SUCCESSFULLY_MODIFIED') . ' ' . $acct;
371     }
372     }
373    
374     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Reboot.pm smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Reboot.pm
375     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/Controller/Reboot.pm 2020-05-30 20:47:43.000000000 +0400
376     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/Controller/Reboot.pm 2020-07-01 00:51:07.000000000 +0400
377     @@ -74,9 +74,9 @@
378     sub rebootFunction_list {
379    
380     my $c = shift;
381     - return [[ $c->l('SHUTDOWN') => 'shutdown' ],
382     - [ $c->l('rbo_REBOOT') => 'reboot' ],
383     - [ $c->l('RECONFIGURE') => 'reconfigure' ]];
384     + return [[ $c->l('rbo_REBOOT') => 'reboot' ],
385     + [ $c->l('RECONFIGURE') => 'reconfigure' ],
386     + [ $c->l('SHUTDOWN') => 'shutdown' ]];
387     }
388    
389    
390     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/I18N/Modules/Manual/manual_fr.lex smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/I18N/Modules/Manual/manual_fr.lex
391     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/lib/SrvMngr/I18N/Modules/Manual/manual_fr.lex 2020-04-18 15:59:25.000000000 +0400
392     +++ smeserver-manager-0.1.0/root/usr/share/smanager/lib/SrvMngr/I18N/Modules/Manual/manual_fr.lex 2020-07-01 12:01:35.020031190 +0400
393     @@ -1,4 +1,4 @@
394     -manual_FORM_TITLE => 'Documentation et manuel en ligne (séparé)',
395     +manual_FORM_TITLE => 'Documentation et manuel en ligne',
396     manual_DESCRIPTION => '
397     <ul> <li><a target="new" href="https://wiki.koozali.org/documentation/manual/">Manuel en ligne</a>
398     <li><a target="new" href="https://wiki.koozali.org/documentation/FAQ/">Questions fréquemment posées (FAQs)</a>
399     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/script/srvmngr smeserver-manager-0.1.0/root/usr/share/smanager/script/srvmngr
400     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/script/srvmngr 2020-06-04 23:03:32.000000000 +0400
401     +++ smeserver-manager-0.1.0/root/usr/share/smanager/script/srvmngr 2020-06-22 01:03:32.724205365 +0400
402     @@ -11,7 +11,7 @@
403     $0 =~ /^(.+)$/ms; $0 = $1; # Untaint script name
404     $ENV{'PATH'} = '/bin:/usr/bin:/usr/local/bin';
405     $ENV{'SHELL'} = '/bin/bash';
406     - $ENV{'HOME'} = '/opt/smanager';
407     + $ENV{'HOME'} = '/usr/share/smanager';
408     delete $ENV{'ENV'};
409     esmith::util::setRealToEffective();
410     }
411     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/datetime.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/datetime.html.ep
412     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/datetime.html.ep 2020-04-26 12:59:58.000000000 +0400
413     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/datetime.html.ep 2020-07-01 00:47:43.000000000 +0400
414     @@ -1,34 +1,30 @@
415     % layout 'default', title => "Sme server 2 - datetime";
416    
417     -% content_for 'end' => begin
418     - <div id="end" class="sme-copyrightbar">
419     - content_end
420     - </div>
421     -% end
422     -
423     % content_for 'module' => begin
424     <div id="module">
425    
426     - %if ($config->{debug} == 1) {
427     + % if ($config->{debug} == 1) {
428     <p>
429     - (DBG)route: <%= $c->current_route %><br>
430     - (DBG)ntp: <%= $dat_datas->{ntpstatus}%><br>
431     - (DBG)svr: <%= $dat_datas->{ntpserver}%><br>
432     + %= dumper $c->current_route
433     + %= dumper $dat_datas
434     </p>
435     + % }
436     +
437     + % if ( stash 'error' ) {
438     + <br><div class=sme-error>
439     + %= $c->render_to_string(inline => stash 'error')
440     + </div>
441     %}
442    
443     - <!--h1>< % = l('dat_FORM_TITLE') % ></h1>
444     - < %= l('dat_INITIAL_DESC') % -->
445     - <h1><%= $title %></h1>
446     - <br>
447     - <%= $modul %>
448     + <h1><%= $title %></h1><br>
449     + %= $modul
450     <% my $btn = l('SAVE'); %>
451    
452     - %= form_for 'datetime' => (method => 'POST') => begin
453     + %= form_for '/datetime' => (method => 'POST') => begin
454     <p>
455     + %= hidden_field 'old_ntpstatus' => $dat_datas->{ntpstatus};
456     +
457     % param 'ntpstatus' => $dat_datas->{ntpstatus} unless param 'ntpstatus';
458     - % param 'old_ntpstatus' => $dat_datas->{ntpstatus} unless param 'ntpstatus';
459     - %= hidden_field 'old_ntpstatus'
460     %= radio_button ntpstatus => 'enabled'
461     <span class=label>
462     %=l 'dat_NTP_CONFIGURE_TITLE'
463     @@ -77,21 +73,21 @@
464     <span class=label>
465     %=l 'dat_NEW_M/D/Y'
466     </span><span class=data2>
467     - %= text_field 'month' => $dat_datas->{month}, class => 'input'
468     + %= text_field 'month' => $dat_datas->{month}, size => '2', class => 'input'
469     </span><span class=data2>
470     - %= text_field 'day' => $dat_datas->{day}, class => 'input'
471     + %= text_field 'day' => $dat_datas->{day}, size => '2', class => 'input'
472     </span><span class=data2>
473     - %= text_field 'year' => $dat_datas->{year}, class => 'input'
474     + %= text_field 'year' => $dat_datas->{year}, size => '2', class => 'input'
475     </span>
476     <br>
477     <span class=label>
478     %=l 'dat_NEW_H/M/S'
479     </span><span class=data2>
480     - %= text_field 'hour' => $dat_datas->{hour}, class => 'input'
481     + %= text_field 'hour' => $dat_datas->{hour}, size => '2', class => 'input'
482     </span><span class=data2>
483     - %= text_field 'minute' => $dat_datas->{minute}, class => 'input'
484     + %= text_field 'minute' => $dat_datas->{minute}, size => '2', class => 'input'
485     </span><span class=data2>
486     - %= text_field 'second' => $dat_datas->{second}, class => 'input'
487     + %= text_field 'second' => $dat_datas->{second}, size => '2', class => 'input'
488     </span>
489     <br>
490     <span class=label>
491     @@ -107,6 +103,8 @@
492     <br>
493     %= submit_button "$btn", class => 'action'
494     </p>
495     +
496     % end
497     +
498     </div>
499     %end
500     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/directory.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/directory.html.ep
501     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/directory.html.ep 2020-04-26 12:59:18.000000000 +0400
502     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/directory.html.ep 2020-06-28 19:11:30.406526546 +0400
503     @@ -10,7 +10,7 @@
504     </p>
505     %}
506    
507     - <h3><%= $title %></h3>
508     + <h1><%= $title %></h1>
509     <br>
510     <%= $modul %>
511     <% my $btn = l('SAVE');
512     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/ibays.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/ibays.html.ep
513     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/ibays.html.ep 2020-04-26 21:26:44.000000000 +0400
514     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/ibays.html.ep 2020-06-30 22:13:01.000000000 +0400
515     @@ -9,10 +9,18 @@
516     %= dumper $iba_datas
517     </p>
518     % }
519     -
520     +
521     + % if ( stash 'error' ) {
522     + <br><div class=sme-error>
523     + %= $c->render_to_string(inline => stash 'error')
524     + </div>
525     + %}
526     +
527     <h1><%= $title%></h1>
528    
529     - %= $c->render_to_string(inline => $modul );
530     + % if ( stash 'modul' ) {
531     + %= $c->render_to_string(inline => stash 'modul' );
532     + % }
533    
534     % if ($iba_datas->{trt} eq 'ADD') {
535     %= include 'partials/_iba_upd'
536     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/layouts/default.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/layouts/default.html.ep
537     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/layouts/default.html.ep 2020-05-31 01:32:17.000000000 +0400
538     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/layouts/default.html.ep 2020-06-29 21:22:51.000000000 +0400
539     @@ -11,7 +11,8 @@
540     %= stylesheet '/css/sme_main.css'
541     %= stylesheet '/css/sme_menu.css'
542     %= stylesheet '/css/styles.css'
543     - %= include '/partials/_js_imports'
544     + %= include 'partials/_js_imports'
545     + %= include 'common_js'
546     </head>
547    
548     <body>
549     @@ -28,6 +29,9 @@
550     %= include 'partials/_info'
551    
552     <div id="container">
553     +
554     + %= content 'js_toggleMenu'
555     +
556     <div id="navigation" class="col-md-3">
557     %= include 'partials/_nav_menu'
558     % if ( $c->is_logged_in ) {
559     @@ -55,7 +59,6 @@
560     </div>
561     </div>
562    
563     - %= include 'common_js'
564     %= content 'js_swapClass'
565    
566     </body>
567     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/manual.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/manual.html.ep
568     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/manual.html.ep 2020-04-26 21:25:20.000000000 +0400
569     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/manual.html.ep 2020-06-28 18:37:57.612477533 +0400
570     @@ -2,7 +2,7 @@
571    
572     % content_for 'module' => begin
573     <div id="central">
574     - <p><h3> <%= $title %> </h3></p>
575     + <p><h1> <%= $title %> </h1></p>
576     <%= $modul %><br>
577     </div>
578    
579     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_grp_upd.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_grp_upd.html.ep
580     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_grp_upd.html.ep 2020-04-26 21:20:38.000000000 +0400
581     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_grp_upd.html.ep 2020-06-30 21:45:02.547260949 +0400
582     @@ -5,7 +5,7 @@
583     %= form_for '/groups2' => (method => 'POST') => begin
584    
585     <p><h2>
586     - %=l 'MODIFY_GROUP'
587     + %=l 'MODIFY_USER_GROUP'
588     </h2><br></p>
589    
590     <p>
591     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_iba_upd.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_iba_upd.html.ep
592     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_iba_upd.html.ep 2020-04-15 21:43:35.000000000 +0400
593     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_iba_upd.html.ep 2020-06-30 21:42:47.205009045 +0400
594     @@ -71,7 +71,7 @@
595     %=l 'iba_ALLOW_DYNAMIC_CONTENT'
596     </span><span class=data>
597     % param 'CgiBin' => $iba_datas->{CgiBin} unless param 'CgiBin';
598     - %= select_field 'CgiBin' => [[ (l 'ENABLED') => 'enabled'], [ (l 'DISABLED') => 'disabled']], class => 'input'
599     + %= select_field 'CgiBin' => [[ (l 'DISABLED') => 'disabled'], [ (l 'ENABLED') => 'enabled']], class => 'input'
600     <br>
601     </span>
602     </p>
603     @@ -81,7 +81,7 @@
604     %=l 'iba_HTTPS_Only'
605     </span><span class=data>
606     % param 'SSL' => $iba_datas->{SSL} unless param 'SSL';
607     - %= select_field 'SSL' => [[ (l 'ENABLED') => 'enabled'], [ (l 'DISABLED') => 'disabled']], class => 'input'
608     + %= select_field 'SSL' => [[ (l 'DISABLED') => 'disabled'], [ (l 'ENABLED') => 'enabled']], class => 'input'
609     <br>
610     </span>
611     </p>
612     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_js_imports.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_js_imports.html.ep
613     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_js_imports.html.ep 2020-04-15 21:43:42.000000000 +0400
614     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_js_imports.html.ep 2020-06-28 23:31:41.000000000 +0400
615     @@ -1,4 +1,22 @@
616    
617     +% content_for 'js_toggleMenu' => begin
618     + %= javascript begin
619     +
620     + $(document).ready(function() {
621     + $('#tognav').click(function() {
622     + $('#menunav').toggle({ duration: 300 });
623     + });
624     + $('#toguser').click(function() {
625     + $('#menuuser').toggle({ duration: 600 });
626     + });
627     + $('#togadm').click(function() {
628     + $('#menuadm').toggle({ duration: 900 });
629     + });
630     + });
631     +
632     + % end
633     +% end
634     +
635     % content_for 'js_swapClass' => begin
636     %= javascript begin
637     (function($) {
638     @@ -29,6 +47,7 @@
639     // alert('menu found! ' + $(this).attr('href') + ' ' + $(this).attr('class'));
640     }
641     })
642     +
643     });
644     % end
645     % end
646     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_navig2.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_navig2.html.ep
647     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_navig2.html.ep 2020-06-06 19:17:01.000000000 +0400
648     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_navig2.html.ep 2020-06-28 23:05:33.000000000 +0400
649     @@ -2,7 +2,9 @@
650     % my %nav = %{SrvMngr->getNavigation( $c->languages(), 'A' )};
651    
652     <div id='navigat2'>
653     - <p class='menu-title'>ADMINISTRATION</p>
654     + <a href='#' id='togadm' class='menu-title'>ADMINISTRATION</a>
655     + <div id='menuadm'>
656     +
657     % my $cc = 1;
658     % foreach my $h (sort { ($nav{$a}{'WEIGHT'}/$nav{$a}{'COUNT'})
659     % <=> ($nav{$b}{'WEIGHT'}/$nav{$b}{'COUNT'}) } keys %nav) {
660     @@ -29,3 +31,4 @@
661     % }
662    
663     </div>
664     + </div>
665     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_nav_menu.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_nav_menu.html.ep
666     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_nav_menu.html.ep 2020-06-06 19:17:52.000000000 +0400
667     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_nav_menu.html.ep 2020-06-28 22:55:15.000000000 +0400
668     @@ -2,7 +2,8 @@
669     % my %nav = %{SrvMngr->getNavigation( $c->languages(), 'N' )};
670    
671     <div id='navmenu'>
672     - <p class='menu-title'>NAVIGATION</p>
673     + <a href='#' id='tognav' class='menu-title'>NAVIGATION</a>
674     + <div id='menunav'>
675     % my $cc = 1;
676     % foreach my $h (sort { ($nav{$a}{'WEIGHT'}/$nav{$a}{'COUNT'})
677     % <=> ($nav{$b}{'WEIGHT'}/$nav{$b}{'COUNT'}) } keys %nav) {
678     @@ -28,3 +29,4 @@
679    
680     % }
681     </div>
682     + </div>
683     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_pf_list.html.ep.svg smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_pf_list.html.ep.svg
684     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_pf_list.html.ep.svg 2020-04-18 15:58:09.000000000 +0400
685     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_pf_list.html.ep.svg 1970-01-01 04:00:00.000000000 +0400
686     @@ -1,109 +0,0 @@
687     -<div id='pf_list'>
688     - % my $btn = l('pf_CREATE_RULE');
689     - %= form_for '/portforwardingadd' => (method => 'POST') => begin
690     -
691     - % my $retref= $c->stash("ret");
692     - % my %ret;
693     - % unless (length($retref)) {%ret = (ret=>"");}
694     - % else {%ret = %$retref;}
695     -
696     - % my $numtcpforwards = @$tcpforwards;
697     - % my $numudpforwards = @$udpforwards;
698     -
699     - % my @vars = split(",",$ret{vars});
700     - % my $var1 = @vars[0];
701     - % my $var2 = @vars[1];
702     - % my $var3 = @vars[2];
703     - % my $var4 = @vars[3];
704     - % my $var5 = @vars[4];
705     - % my $var6 = @vars[5];
706     -
707     -
708     -
709     - %if ($ret{ret} eq "") {
710     - %= $c->render_to_string(inline => l('pf_FIRST_PAGE_DESCRIPTION'));
711     - %} elsif (index($ret{ret},"SUCCESS") != -1) {
712     - <div class='success'>
713     - <h2> Operation Status Report</h2>
714     - %= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6);
715     - </div>
716     - %} else {
717     - <div class='sme-error'>
718     - <h2> Operation Status Report - Error</h2>
719     - %= $c->l($ret{ret},$var1,$var2,$var3,$var4,$var5,$var6);
720     - </div>
721     - %}
722     - <br><br>
723     - %= submit_button "$btn", class => 'action2'
724     - <br>
725     -
726     - % if ($empty){
727     - <br>
728     - %=l 'pf_NO_FORWARDS'
729     - % } else {
730     - <br>
731     - %=l 'pf_SHOW_FORWARDS'
732     - <br>
733     - <table class="sme-border"><tbody>
734     - <tr>
735     - <th class='sme-border'>
736     - %=l 'pf_LABEL_PROTOCOL'
737     - </th>
738     - <th class='sme-border'>
739     - %=l 'pf_LABEL_SOURCE_PORT'
740     - </th>
741     -
742     - <th class='sme-border'>
743     - %=l 'pf_LABEL_DESTINATION_HOST'
744     - </th>
745     -
746     - <th class='sme-border'>
747     - %=l 'pf_LABEL_DESTINATION_PORT'
748     - </th>
749     -
750     - <th class='sme-border'>
751     - %=l 'pf_ALLOW_HOSTS'
752     - </th>
753     -
754     -
755     - <th class='sme-border'>
756     - %=l 'pf_RULE_COMMENT'
757     - </th>
758     -
759     - <th class='sme-border' '>
760     - %=l 'ACTION'
761     - </th>
762     - </tr>
763     -
764     - % my %forwards = ();
765     - % $forwards{TCP} = $tcpforwards;
766     - % $forwards{UDP} = $udpforwards;
767     -
768     - % foreach my $proto (sort keys %forwards) {
769     -
770     - % if (@{ $forwards{$proto} }) {
771     - % foreach my $entry (@{ $forwards{$proto} }) {
772     - <tr>
773     - % my $sport = $entry->key;
774     - % my $dhost = $entry->prop('DestHost');
775     - % my $dport = $entry->prop('DestPort') || '';
776     - % my $cmmnt = $entry->prop('Comment') || '';
777     - % my $allow = $entry->prop('AllowHosts') || '';
778     - %= t td => (class => 'sme-border') => $proto
779     - %= t td => (class => 'sme-border') => $sport
780     - %= t td => (class => 'sme-border') => $dhost
781     - %= t td => (class => 'sme-border') => $dport
782     - %= t td => (class => 'sme-border') => $allow
783     - %= t td => (class => 'sme-border') => $cmmnt
784     - <td class='sme-border'>
785     - <a href="/smanager/portforwardingdel?trt=DEL&sport=<%= $sport%>&proto=<%= $proto%>"><%=l 'REMOVE'%></a></td>
786     - </tr>
787     - % }
788     - % }
789     - %}
790     - %= hidden_field 'trt' => $pf_datas->{trt}
791     - %}
792     - </tbody>
793     - </table>
794     - % end
795     -</div>
796     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_user_menu.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_user_menu.html.ep
797     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/partials/_user_menu.html.ep 2020-06-06 19:18:20.000000000 +0400
798     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/partials/_user_menu.html.ep 2020-06-28 23:07:32.000000000 +0400
799     @@ -2,11 +2,13 @@
800     % my %nav = %{SrvMngr->getNavigation( $c->languages(), 'U' )};
801    
802     <div id='usermenu'>
803     - <p class='menu-title'>Hello <%= session 'username' %></p>
804     + <a href='#' id='toguser' class='menu-title'>
805     + Hello <%= session 'username' %></a>
806     + <div id='menuuser'>
807     % my $cc = 1;
808     % foreach my $h (sort { ($nav{$a}{'WEIGHT'}/$nav{$a}{'COUNT'})
809     % <=> ($nav{$b}{'WEIGHT'}/$nav{$b}{'COUNT'}) } keys %nav) {
810     - <!-- div class='section section-title'><%= $h %></div -->
811     + <!-- div class='section'><%= $h %></div -->
812     % my ($classNew, $target, $href) = '';
813     % foreach (sort { $a->{'WEIGHT'} <=> $b->{'WEIGHT'} } @{$nav{$h}{'DESCRIPTIONS'}}) {
814    
815     @@ -28,3 +30,4 @@
816     % }
817    
818     </div>
819     + </div>
820     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/proxy.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/proxy.html.ep
821     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/proxy.html.ep 2020-04-26 12:59:28.000000000 +0400
822     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/proxy.html.ep 2020-06-28 19:11:49.035298384 +0400
823     @@ -8,7 +8,7 @@
824     (DBG)sm stat: <%=$prx_datas->{smtp_proxy_status} %>
825     </p>
826     %}
827     - <h3><%= $title %></h3>
828     + <h1><%= $title %></h1>
829     <br>
830     <%= $modul %>
831     <% my $btn = l('SAVE'); %>
832     diff -urN smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/review.html.ep smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/review.html.ep
833     --- smeserver-manager-0.1.0.old/root/usr/share/smanager/themes/default/templates/review.html.ep 2020-04-26 12:59:10.000000000 +0400
834     +++ smeserver-manager-0.1.0/root/usr/share/smanager/themes/default/templates/review.html.ep 2020-06-28 19:54:17.417844436 +0400
835     @@ -2,7 +2,7 @@
836    
837     % content_for 'module' => begin
838     <div id="central">
839     - <p><h3> <%= $title %> </h3></p>
840     + <h1> <%= $title %> </h1>
841     <%= $modul %><br><br>
842    
843     %= form_for 'review' => begin

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed