[vhffs-dev] [1791] Use cleanup

[ Thread Index | Date Index | More vhffs.org/vhffs-dev Archives ]


Revision: 1791
Author:   beuss
Date:     2011-05-20 13:14:46 +0200 (Fri, 20 May 2011)
Log Message:
-----------
Use cleanup

And I forgot to delete unused code from web/create.

Modified Paths:
--------------
    trunk/vhffs-panel/bazaar/index.pl
    trunk/vhffs-panel/dns/index.pl
    trunk/vhffs-panel/git/create.pl
    trunk/vhffs-panel/group/index.pl
    trunk/vhffs-panel/mail/index.pl
    trunk/vhffs-panel/user/delete.pl
    trunk/vhffs-panel/web/create.pl

Modified: trunk/vhffs-panel/bazaar/index.pl
===================================================================
--- trunk/vhffs-panel/bazaar/index.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/bazaar/index.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -32,7 +32,6 @@
 
 use utf8;
 use POSIX qw(locale_h);
-use HTML::Template;
 use locale;
 use Locale::gettext;
 use strict;

Modified: trunk/vhffs-panel/dns/index.pl
===================================================================
--- trunk/vhffs-panel/dns/index.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/dns/index.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -32,7 +32,6 @@
 
 use utf8;
 use POSIX qw(locale_h);
-use HTML::Template;
 use locale;
 use Locale::gettext;
 use strict;
@@ -40,6 +39,7 @@
 use lib '%VHFFS_LIB_DIR%';
 use Vhffs::Panel::Main;
 use Vhffs::Panel::DNS;
+use Vhffs::Constants;
 
 my $panel = new Vhffs::Panel::Main();
 exit 0 unless $panel;

Modified: trunk/vhffs-panel/git/create.pl
===================================================================
--- trunk/vhffs-panel/git/create.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/git/create.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -33,7 +33,6 @@
 use strict;
 use utf8;
 use POSIX qw(locale_h);
-use HTML::Template;
 use locale;
 use Locale::gettext;
 use CGI;

Modified: trunk/vhffs-panel/group/index.pl
===================================================================
--- trunk/vhffs-panel/group/index.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/group/index.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -32,7 +32,6 @@
 
 use utf8;
 use POSIX qw(locale_h);
-use HTML::Template;
 use locale;
 use Locale::gettext;
 use strict;

Modified: trunk/vhffs-panel/mail/index.pl
===================================================================
--- trunk/vhffs-panel/mail/index.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/mail/index.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -32,7 +32,6 @@
 
 use utf8;
 use POSIX qw(locale_h);
-use HTML::Template;
 use locale;
 use Locale::gettext;
 use strict;

Modified: trunk/vhffs-panel/user/delete.pl
===================================================================
--- trunk/vhffs-panel/user/delete.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/user/delete.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -32,7 +32,6 @@
 
 use utf8;
 use POSIX qw(locale_h);
-use HTML::Template;
 use locale;
 use Locale::gettext;
 use CGI;

Modified: trunk/vhffs-panel/web/create.pl
===================================================================
--- trunk/vhffs-panel/web/create.pl	2011-05-20 11:14:39 UTC (rev 1790)
+++ trunk/vhffs-panel/web/create.pl	2011-05-20 11:14:46 UTC (rev 1791)
@@ -85,23 +85,7 @@
         $vars->{servername} = sprintf( gettext('<new site>.%s'), $webconfig->{default_domain} ) if( defined $webconfig->{default_domain} );
 	}
 
-	if( !$submitted || $panel->has_errors() ) {
-		$panel->set_title( gettext('Create a web space') );
-        $vars->{group} = $group;
-        $panel->render('web/create.tt', $vars);
-		my $template = new HTML::Template( filename => $templatedir.'/panel/web/create.tmpl' );
-		$template->param( SERVERNAME_TEXT => gettext('Address (ServerName directive)') );
-		$template->param( SERVERNAME_WARNING => gettext('Be careful, if you want create www.domain.tld, you should create a webspace with domain.tld as servername. VHFFS redirect all request from www.domain.tld to domain.tld') );
-		$template->param( SERVERNAME_VALUE => $servername );
-		$template->param( GROUP_NAME => gettext('Group owning this web space') );
-
-		$template->param( GROUP => $group->get_groupname );
-		$template->param( SEND => gettext('Send') );
-		$template->param( DESCRIPTION => gettext('Tell us what the use of this web space will be') );
-		$template->param( WARNING_PUBLIC => gettext('Please consider that this description is going to be displayed in the public area. So you have to write it in impersonal form. You should take care to write it with correct grammar and tenses. Take all the time you need to fill it with the best content you are able to do.') ) if $panel->is_public;
-		$template->param( DESCRIPTION_VALUE => $description );
-
-		$panel->build( $template );
-		$panel->display;
-	}
+    $panel->set_title( gettext('Create a web space') );
+    $vars->{group} = $group;
+    $panel->render('web/create.tt', $vars);
 }


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/