[vhffs-dev] [2042] Reworked objects statuses, removed CREATED ( ACTIVATED is the same thing), renamed CREATING_ERROR to CREATION_ERROR, renamed TO_DELETE to WAITING_FOR_DELETION, added DELETION_ERROR |
[ Thread Index |
Date Index
| More vhffs.org/vhffs-dev Archives
]
- To: vhffs-dev@xxxxxxxxx
- Subject: [vhffs-dev] [2042] Reworked objects statuses, removed CREATED ( ACTIVATED is the same thing), renamed CREATING_ERROR to CREATION_ERROR, renamed TO_DELETE to WAITING_FOR_DELETION, added DELETION_ERROR
- From: subversion@xxxxxxxxxxxxx
- Date: Thu, 23 Feb 2012 22:31:58 +0100
Revision: 2042
Author: gradator
Date: 2012-02-23 22:31:57 +0100 (Thu, 23 Feb 2012)
Log Message:
-----------
Reworked objects statuses, removed CREATED (ACTIVATED is the same thing), renamed CREATING_ERROR to CREATION_ERROR, renamed TO_DELETE to WAITING_FOR_DELETION, added DELETION_ERROR
Modified Paths:
--------------
trunk/vhffs-api/src/Vhffs/Constants.pm
trunk/vhffs-api/src/Vhffs/Group.pm
trunk/vhffs-api/src/Vhffs/Object.pm
trunk/vhffs-api/src/Vhffs/Panel/Mail.pm
trunk/vhffs-api/src/Vhffs/Panel/Main.pm
trunk/vhffs-api/src/Vhffs/Panel/Object.pm
trunk/vhffs-api/src/Vhffs/Panel/User.pm
trunk/vhffs-api/src/Vhffs/Robots/Bazaar.pm
trunk/vhffs-api/src/Vhffs/Robots/Cron.pm
trunk/vhffs-api/src/Vhffs/Robots/Cvs.pm
trunk/vhffs-api/src/Vhffs/Robots/Git.pm
trunk/vhffs-api/src/Vhffs/Robots/Group.pm
trunk/vhffs-api/src/Vhffs/Robots/Mercurial.pm
trunk/vhffs-api/src/Vhffs/Robots/Pgsql.pm
trunk/vhffs-api/src/Vhffs/Robots/Svn.pm
trunk/vhffs-api/src/Vhffs/Robots/User.pm
trunk/vhffs-api/src/Vhffs/Robots/Web.pm
trunk/vhffs-api/src/Vhffs/Services/Mail.pm
trunk/vhffs-api/src/Vhffs/Services/MailGroup.pm
trunk/vhffs-api/src/Vhffs/Services/MailUser.pm
trunk/vhffs-api/src/Vhffs/User.pm
trunk/vhffs-intl/extra_strings.pl
trunk/vhffs-panel/templates/admin/object/edit.tt
trunk/vhffs-robots/src/bazaar_delete.pl
trunk/vhffs-robots/src/cron_delete.pl
trunk/vhffs-robots/src/cvs_delete.pl
trunk/vhffs-robots/src/dns_delete.pl
trunk/vhffs-robots/src/git_delete.pl
trunk/vhffs-robots/src/group_delete.pl
trunk/vhffs-robots/src/mail_createboxes.pl
trunk/vhffs-robots/src/mail_delete.pl
trunk/vhffs-robots/src/mail_deleteboxes.pl
trunk/vhffs-robots/src/mailinglist_delete.pl
trunk/vhffs-robots/src/mercurial_delete.pl
trunk/vhffs-robots/src/mysql_delete.pl
trunk/vhffs-robots/src/pgsql_delete.pl
trunk/vhffs-robots/src/repository_delete.pl
trunk/vhffs-robots/src/svn_delete.pl
trunk/vhffs-robots/src/user_delete.pl
trunk/vhffs-robots/src/web_delete.pl
trunk/vhffs-tools/src/vhffs-groupdel
trunk/vhffs-tools/src/vhffs-userdel
Modified: trunk/vhffs-api/src/Vhffs/Constants.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Constants.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Constants.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -26,15 +26,14 @@
WAITING_FOR_VALIDATION => 1,
VALIDATION_REFUSED => 2,
WAITING_FOR_CREATION => 3,
- CREATING_ERROR => 4,
- CREATED => 5,
+ CREATION_ERROR => 4,
ACTIVATED => 6,
SUSPEND_PENDING => 7,
SUSPENDED => 8,
WAITING_FOR_MODIFICATION => 9,
MODIFICATION_ERROR => 10,
- MODIFICATION_APPLIED => 11,
- TO_DELETE => 12,
+ WAITING_FOR_DELETION => 12,
+ DELETION_ERROR => 13,
ACL_UNDEFINED => -1,
ACL_DENIED => 0,
@@ -94,15 +93,14 @@
Vhffs::Constants::WAITING_FOR_VALIDATION => 'Waiting for validation',
Vhffs::Constants::VALIDATION_REFUSED => 'Validation refused',
Vhffs::Constants::WAITING_FOR_CREATION => 'Waiting for creation',
- Vhffs::Constants::CREATING_ERROR => 'Creation error',
- Vhffs::Constants::CREATED => 'Created',
+ Vhffs::Constants::CREATION_ERROR => 'Creation error',
Vhffs::Constants::ACTIVATED => 'Activated',
Vhffs::Constants::SUSPEND_PENDING => 'Waiting for suspension',
Vhffs::Constants::SUSPENDED => 'Suspended',
Vhffs::Constants::WAITING_FOR_MODIFICATION => 'Waiting for modification',
Vhffs::Constants::MODIFICATION_ERROR => 'Modification error',
- Vhffs::Constants::MODIFICATION_APPLIED => 'Modification applied',
- Vhffs::Constants::TO_DELETE => 'Will be deleted',
+ Vhffs::Constants::WAITING_FOR_DELETION => 'Will be deleted',
+ Vhffs::Constants::DELETION_ERROR => 'Deletion error',
},
# Types strings
TYPES => {
@@ -197,15 +195,14 @@
=head2 WAITING_FOR_VALIDATION
=head2 VALIDATION_REFUSED
=head2 WAITING_FOR_CREATION
-=head2 CREATING_ERROR
-=head2 CREATED
+=head2 CREATION_ERROR
=head2 ACTIVATED
=head2 SUSPEND_PENDING
=head2 SUSPENDED
=head2 WAITING_FOR_MODIFICATION
=head2 MODIFICATION_ERROR
-=head2 MODIFICATION_APPLIED
-=head2 TO_DELETE
+=head2 WAITING_FOR_DELETION
+=head2 DELETION_ERROR
=head1 ACL CONSTANTS
=head2 ACL_UNDEFINED
Modified: trunk/vhffs-api/src/Vhffs/Group.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Group.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Group.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -390,7 +390,7 @@
my $uid = shift;
my $sql = 'UPDATE vhffs_user_group SET state=? WHERE gid=? AND uid=?';
- return $self->{db}->do( $sql, {}, Vhffs::Constants::TO_DELETE, $self->{gid}, $uid ) > 0;
+ return $self->{db}->do( $sql, {}, Vhffs::Constants::WAITING_FOR_DELETION, $self->{gid}, $uid ) > 0;
}
=pod
Modified: trunk/vhffs-api/src/Vhffs/Object.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Object.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Object.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -126,7 +126,7 @@
my $oid = $vhffs->get_db_object->last_insert_id(undef, undef, 'vhffs_object', undef);
my $object = get_by_oid($vhffs, $oid);
- $object->add_history('Object created');
+ $object->get_status == Vhffs::Constants::WAITING_FOR_VALIDATION ? $object->add_history('Object created, waiting for validation') : $object->add_history('Object created');
return $object;
}
@@ -311,10 +311,13 @@
=head2 delete
-Delete the object. This method is called from inherited class.
+Delete the object. This method is called from inherited class or directly if
+the sub class does not need a delete method.
+
Note that it destroy the object-part (history, ...), but not the inherited class.
-Returns negative value if fails, positive if success.
+Returns undef value if fails, true if success.
+
=cut
sub delete {
my $self = shift;
@@ -323,7 +326,7 @@
# we don't have to bother with foreign tables deletion.
my $query = 'DELETE FROM vhffs_object WHERE object_id=?';
my $request = $self->{'db'}->prepare($query);
- $request->execute( $self->{'object_id'} ) or return -1;
+ $request->execute( $self->{'object_id'} ) or return undef;
return 1;
}
@@ -456,34 +459,27 @@
=cut
sub set_status {
- my ($self , $value);
- $self = shift;
- $value = shift;
+ my ($self, $value) = @_;
$self->{'state'} = $value;
- if( $value == Vhffs::Constants::TO_DELETE ) {
- $self->add_history( "Will be deleted" );
+ if( $value == Vhffs::Constants::WAITING_FOR_VALIDATION ) {
+ $self->add_history( 'Waiting for validation' );
}
+ elsif( $value == Vhffs::Constants::VALIDATION_REFUSED ) {
+ $self->add_history( 'Validation refused' );
+ }
elsif( $value == Vhffs::Constants::WAITING_FOR_CREATION ) {
- $self->add_history( "Moderated. Will be created" );
+ $self->add_history( 'Validation accepted. Will be created' );
}
- elsif( $value == Vhffs::Constants::CREATING_ERROR ) {
- $self->add_history( "Creating error ! Robots can't create it" );
+ elsif( $value == Vhffs::Constants::ACTIVATED ) {
+ $self->add_history( 'Is now active for production' );
}
- elsif( $value == Vhffs::Constants::CREATED ) {
- $self->add_history( "Object is created" );
+ elsif( $value == Vhffs::Constants::CREATION_ERROR ) {
+ $self->add_history( 'An error occured while creating the object' );
}
- elsif( $value == Vhffs::Constants::WAITING_FOR_VALIDATION ) {
- $self->add_history( "Object is under moderation");
+ if( $value == Vhffs::Constants::WAITING_FOR_DELETION ) {
+ $self->add_history( 'Will be deleted' );
}
- elsif( $value == Vhffs::Constants::VALIDATION_REFUSED ) {
- $self->add_history( "Validation refused");
- }
- elsif( $value == Vhffs::Constants::ACTIVATED ) {
- $self->add_history( "Is now active for production");
- }
-
-
}
=pod
Modified: trunk/vhffs-api/src/Vhffs/Panel/Mail.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Panel/Mail.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Panel/Mail.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -379,7 +379,7 @@
return;
}
- if($mail->set_box_status($box, Vhffs::Constants::TO_DELETE) < 0) {
+ if($mail->set_box_status($box, Vhffs::Constants::WAITING_FOR_DELETION) < 0) {
$panel->add_error( sprintf(gettext('Unable to delete box %s'), $box) );
return;
}
Modified: trunk/vhffs-api/src/Vhffs/Panel/Main.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Panel/Main.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Panel/Main.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -382,15 +382,14 @@
WAITING_FOR_VALIDATION => Vhffs::Constants::WAITING_FOR_VALIDATION,
VALIDATION_REFUSED => Vhffs::Constants::VALIDATION_REFUSED,
WAITING_FOR_CREATION => Vhffs::Constants::WAITING_FOR_CREATION,
- CREATING_ERROR => Vhffs::Constants::CREATING_ERROR,
+ CREATION_ERROR => Vhffs::Constants::CREATION_ERROR,
ACTIVATED => Vhffs::Constants::ACTIVATED,
- CREATED => Vhffs::Constants::CREATED,
SUSPEND_PENDING => Vhffs::Constants::SUSPEND_PENDING,
SUSPENDED => Vhffs::Constants::SUSPENDED,
WAITING_FOR_MODIFICATION => Vhffs::Constants::WAITING_FOR_MODIFICATION,
MODIFICATION_ERROR => Vhffs::Constants::MODIFICATION_ERROR,
- MODIFICATION_APPLIED => Vhffs::Constants::MODIFICATION_APPLIED,
- TO_DELETE => Vhffs::Constants::TO_DELETE
+ WAITING_FOR_DELETION => Vhffs::Constants::WAITING_FOR_DELETION,
+ DELETION_ERROR => Vhffs::Constants::DELETION_ERROR
},
user_permissions => {
NORMAL => Vhffs::Constants::USER_NORMAL,
Modified: trunk/vhffs-api/src/Vhffs/Panel/Object.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Panel/Object.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Panel/Object.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -217,7 +217,7 @@
} elsif( $sure == 0 ) {
$message = gettext( 'This object will NOT be deleted' );
} else {
- $object->set_status( Vhffs::Constants::TO_DELETE );
+ $object->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
# Commit all the changes for the current user
if( $object->commit < 0 ) {
Modified: trunk/vhffs-api/src/Vhffs/Panel/User.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Panel/User.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Panel/User.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -588,7 +588,7 @@
if( $userp->have_activegroups ) {
$message = gettext('This user is still in a group');
} else {
- $userp->set_status( Vhffs::Constants::TO_DELETE );
+ $userp->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
if( $userp->commit < 0 ) {
$message = gettext('An error occured while applying changes. This user will NOT be deleted');
} else {
Modified: trunk/vhffs-api/src/Vhffs/Robots/Bazaar.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Bazaar.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Bazaar.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -50,7 +50,7 @@
my $dir = $bazaar->get_dir;
if( -e $dir ) {
- $bazaar->set_status( Vhffs::Constants::CREATING_ERROR );
+ $bazaar->set_status( Vhffs::Constants::CREATION_ERROR );
$bazaar->commit();
$bazaar->add_history('Error, directory of this bazaar repository already exists! Administrators must fix the problem.');
return -1;
@@ -78,7 +78,7 @@
chdir($oldcwd);
unless( -d $dir.'/.bzr' ) {
- $bazaar->set_status( Vhffs::Constants::CREATING_ERROR );
+ $bazaar->set_status( Vhffs::Constants::CREATION_ERROR );
$bazaar->commit();
$bazaar->add_history('Error, nothing was created after calling the bazaar binary, something is wrong.');
return -1;
Modified: trunk/vhffs-api/src/Vhffs/Robots/Cron.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Cron.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Cron.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -40,8 +40,7 @@
use Vhffs::Robots;
-sub get_runnable_jobs
-{
+sub get_runnable_jobs {
my $main = shift;
my $sql = 'SELECT c.cron_id, c.cronpath, c.interval, c.reportmail, c.lastrundate, c.lastrunreturncode, c.nextrundate, c.running, o.owner_uid, o.owner_gid, o.object_id, o.date_creation, o.description, o.state FROM vhffs_cron c INNER JOIN vhffs_object o ON c.object_id=o.object_id WHERE o.state=? AND c.running=0 AND ( c.nextrundate IS NULL OR c.nextrundate<? )';
@@ -56,9 +55,7 @@
return $repos;
}
-
-sub get_stalled_jobs
-{
+sub get_stalled_jobs {
my $main = shift;
my $maxexectime = shift;
@@ -74,5 +71,4 @@
return $repos;
}
-
1;
Modified: trunk/vhffs-api/src/Vhffs/Robots/Cvs.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Cvs.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Cvs.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -49,7 +49,7 @@
my $dir = $cvs->get_dir;
if( -e $dir ) {
- $cvs->set_status( Vhffs::Constants::CREATING_ERROR );
+ $cvs->set_status( Vhffs::Constants::CREATION_ERROR );
$cvs->commit();
$cvs->add_history('Error, directory of this cvs repository already exists! Administrators must fix the problem.');
return -1;
@@ -73,7 +73,7 @@
}
unless( -d $dir.'/CVSROOT' ) {
- $cvs->set_status( Vhffs::Constants::CREATING_ERROR );
+ $cvs->set_status( Vhffs::Constants::CREATION_ERROR );
$cvs->commit();
$cvs->add_history('Error, nothing was created after calling the cvs binary, something is wrong.');
return -1;
Modified: trunk/vhffs-api/src/Vhffs/Robots/Git.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Git.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Git.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -52,7 +52,7 @@
my $dir = $git->get_dir;
if( -e $dir ) {
- $git->set_status( Vhffs::Constants::CREATING_ERROR );
+ $git->set_status( Vhffs::Constants::CREATION_ERROR );
$git->commit();
$git->add_history('Error, directory of this git repository already exists! Administrators must fix the problem.');
return -1;
@@ -80,7 +80,7 @@
chdir($oldcwd);
unless( -f $dir.'/config' ) {
- $git->set_status( Vhffs::Constants::CREATING_ERROR );
+ $git->set_status( Vhffs::Constants::CREATION_ERROR );
$git->commit();
$git->add_history('Error, nothing was created after calling the git binary, something is wrong.');
return -1;
Modified: trunk/vhffs-api/src/Vhffs/Robots/Group.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Group.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Group.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -63,7 +63,7 @@
}
else {
$group->add_history( 'cannot create the group directory' );
-# $group->set_status( Vhffs::Constants::CREATING_ERROR );
+# $group->set_status( Vhffs::Constants::CREATION_ERROR );
# $group->commit;
return undef;
}
@@ -114,7 +114,7 @@
sub getall_user_group_to_delete
{
my $main = shift;
- my $query = 'SELECT gid, uid FROM vhffs_user_group WHERE state = '.Vhffs::Constants::TO_DELETE;
+ my $query = 'SELECT gid, uid FROM vhffs_user_group WHERE state = '.Vhffs::Constants::WAITING_FOR_DELETION;
my $request = $main->get_db_object()->prepare( $query ) or return -1;
return -1 unless( $request->execute() );
Modified: trunk/vhffs-api/src/Vhffs/Robots/Mercurial.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Mercurial.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Mercurial.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -50,7 +50,7 @@
my $dir = $mercurial->get_dir;
if( -e $dir ) {
- $mercurial->set_status( Vhffs::Constants::CREATING_ERROR );
+ $mercurial->set_status( Vhffs::Constants::CREATION_ERROR );
$mercurial->commit();
$mercurial->add_history('Error, directory of this mercurial repository already exists! Administrators must fix the problem.');
return -1;
@@ -78,7 +78,7 @@
chdir($oldcwd);
unless( -d $dir.'/.hg' ) {
- $mercurial->set_status( Vhffs::Constants::CREATING_ERROR );
+ $mercurial->set_status( Vhffs::Constants::CREATION_ERROR );
$mercurial->commit();
$mercurial->add_history('Error, nothing was created after calling the mercurial binary, something is wrong.');
return -1;
Modified: trunk/vhffs-api/src/Vhffs/Robots/Pgsql.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Pgsql.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Pgsql.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -84,7 +84,7 @@
my $db = pgsql_admin_db_connect( $main );
return unless $db;
- if( ( defined $pg ) && ( $pg->get_status == Vhffs::Constants::TO_DELETE ) )
+ if( ( defined $pg ) && ( $pg->get_status == Vhffs::Constants::WAITING_FOR_DELETION ) )
{
$pg->add_history("Ok, robots will erase all data");
Modified: trunk/vhffs-api/src/Vhffs/Robots/Svn.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Svn.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Svn.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -125,7 +125,7 @@
my $dir = $svn->get_dir;
if( -e $dir ) {
- $svn->set_status( Vhffs::Constants::CREATING_ERROR );
+ $svn->set_status( Vhffs::Constants::CREATION_ERROR );
$svn->commit();
$svn->add_history('Error, directory of this svn repository already exists! Administrators must fix the problem.');
return -1;
@@ -149,7 +149,7 @@
}
unless( -f $dir.'/format' ) {
- $svn->set_status( Vhffs::Constants::CREATING_ERROR );
+ $svn->set_status( Vhffs::Constants::CREATION_ERROR );
$svn->commit();
$svn->add_history('Error, nothing was created after calling the svnadmin binary, something is wrong.');
return -1;
Modified: trunk/vhffs-api/src/Vhffs/Robots/User.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/User.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/User.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -114,7 +114,7 @@
}
else {
$user->add_history( 'cannot create the homedir directory' );
-# $user->set_status( Vhffs::Constants::CREATING_ERROR );
+# $user->set_status( Vhffs::Constants::CREATION_ERROR );
# $user->commit;
return -1;
}
Modified: trunk/vhffs-api/src/Vhffs/Robots/Web.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Robots/Web.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Robots/Web.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -67,10 +67,10 @@
my $group = Vhffs::Group::get_by_gid( $main , $web->get_owner_gid );
if(Vhffs::Robots::link_to_group( $group, $web->get_servername.'-web', $webdir ) < 0) {
- $web->add_history( "Can't link the webdirectory to the specified group");
+# $web->add_history( "Can't link the webdirectory to the specified group");
}
else {
- $web->add_history( "Ok, robots finished to create webdir. Webdir is now linked to the group directory");
+# $web->add_history( "Ok, robots finished to create webdir. Webdir is now linked to the group directory");
}
$web->set_status( Vhffs::Constants::ACTIVATED );
$web->commit;
Modified: trunk/vhffs-api/src/Vhffs/Services/Mail.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Services/Mail.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Services/Mail.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -491,7 +491,7 @@
return -1 unless(defined($name) && defined($remote) && $name =~ /^[a-z0-9\_\-\.]+$/ && Vhffs::Functions::valid_mail( $remote ) );
return -2 if( defined $self->{'forward'}{$name}
- || ( defined $self->{'boxes'}{$name} && $self->{'boxes'}{$name}{'state'} != Vhffs::Constants::TO_DELETE )
+ || ( defined $self->{'boxes'}{$name} && $self->{'boxes'}{$name}{'state'} != Vhffs::Constants::WAITING_FOR_DELETION )
|| Vhffs::Services::MailingList::address_exists($self->get_main, $name, $self->{domain}) );
my $sql = 'INSERT INTO vhffs_forward(domain, local_part, remote_name, password) VALUES(?, ?, ?, \'x\')';
Modified: trunk/vhffs-api/src/Vhffs/Services/MailGroup.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Services/MailGroup.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Services/MailGroup.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -114,7 +114,7 @@
my $remote = shift;
$self->{mail_service}->delforward( $self->{localpart} ) if $self->exists_forward;
- $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::TO_DELETE ) if $self->exists_box;
+ $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::WAITING_FOR_DELETION ) if $self->exists_box;
return $self->{mail_service}->addforward( $self->{localpart}, $remote );
}
@@ -131,7 +131,7 @@
sub delbox {
my $self = shift;
- $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::TO_DELETE );
+ $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::WAITING_FOR_DELETION );
}
sub addbox {
Modified: trunk/vhffs-api/src/Vhffs/Services/MailUser.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/Services/MailUser.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/Services/MailUser.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -122,7 +122,7 @@
my $remote = shift;
$self->{mail_service}->delforward( $self->{localpart} ) if $self->exists_forward;
- $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::TO_DELETE ) if $self->exists_box;
+ $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::WAITING_FOR_DELETION ) if $self->exists_box;
return $self->{mail_service}->addforward( $self->{localpart}, $remote );
}
@@ -139,7 +139,7 @@
sub delbox {
my $self = shift;
- $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::TO_DELETE );
+ $self->{mail_service}->set_box_status( $self->{localpart}, Vhffs::Constants::WAITING_FOR_DELETION );
}
sub addbox {
Modified: trunk/vhffs-api/src/Vhffs/User.pm
===================================================================
--- trunk/vhffs-api/src/Vhffs/User.pm 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-api/src/Vhffs/User.pm 2012-02-23 21:31:57 UTC (rev 2042)
@@ -449,7 +449,7 @@
setlocale( LC_ALL , $prevlocale );
- $self->set_status( Vhffs::Constants::TO_DELETE );
+ $self->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
$self->commit;
}
Modified: trunk/vhffs-intl/extra_strings.pl
===================================================================
--- trunk/vhffs-intl/extra_strings.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-intl/extra_strings.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -12,7 +12,6 @@
gettext_noop('Validation refused');
gettext_noop('Waiting for creation');
gettext_noop('Creation error');
-gettext_noop('Created');
gettext_noop('Activated');
gettext_noop('Waiting for suspension');
gettext_noop('Suspended');
@@ -20,6 +19,7 @@
gettext_noop('Modification error');
gettext_noop('Modification applied');
gettext_noop('Will be deleted');
+gettext_noop('Deletion error');
# Object types
gettext_noop('User');
Modified: trunk/vhffs-panel/templates/admin/object/edit.tt
===================================================================
--- trunk/vhffs-panel/templates/admin/object/edit.tt 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-panel/templates/admin/object/edit.tt 2012-02-23 21:31:57 UTC (rev 2042)
@@ -17,30 +17,17 @@
<p>
<label for="status">[% 'Status:' | i18n | html %]</label>
<select name="status" id="status">
- <option value="[% constants.object_statuses.WAITING_FOR_VALIDATION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_VALIDATION %]>
- [% 'Waiting for validation' | i18n | html %]</option>
- <option value="[% constants.object_statuses.VALIDATION_REFUSED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.VALIDATION_REFUSED %]>
- [% 'Validation refused' | i18n | html %]</option>
- <option value="[% constants.object_statuses.WAITING_FOR_CREATION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_CREATION %]>
- [% 'Waiting for creation' | i18n | html %]</option>
- <option value="[% constants.object_statuses.CREATING_ERROR %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.CREATING_ERROR %]>
- [% 'Error while creating object' | i18n | html %]</option>
- <option value="[% constants.object_statuses.CREATED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.CREATED %]>
- [% 'Created' | i18n | html %]</option>
- <option value="[% constants.object_statuses.ACTIVATED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.ACTIVATED %]>
- [% 'Activated' | i18n | html %]</option>
- <option value="[% constants.object_statuses.SUSPEND_PENDING %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.SUSPEND_PENDING %]>
- [% 'Waiting for suspension' | i18n | html %]</option>
- <option value="[% constants.object_statuses.SUSPENDED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.SUSPENDED %]>
- [% 'Suspended' | i18n | html %]</option>
- <option value="[% constants.object_statuses.WAITING_FOR_MODIFICATION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_MODIFICATION %]>
- [% 'Waiting for modification' | i18n | html %]</option>
- <option value="[% constants.object_statuses.MODIFICATION_ERROR %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.MODIFICATION_ERROR %]>
- [% 'Error while modifying object' | i18n | html %]</option>
- <option value="[% constants.object_statuses.MODIFICATION_APPLIED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.MODIFICATION_APPLIED %]>
- [% 'Modification applied' | i18n | html %]</option>
- <option value="[% constants.object_statuses.TO_DELETE %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.TO_DELETE %]>
- [% 'Will be deleted' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.WAITING_FOR_VALIDATION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_VALIDATION %]>[% 'Waiting for validation' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.VALIDATION_REFUSED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.VALIDATION_REFUSED %]>[% 'Validation refused' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.WAITING_FOR_CREATION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_CREATION %]>[% 'Waiting for creation' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.CREATION_ERROR %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.CREATION_ERROR %]>[% 'Error while creating object' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.ACTIVATED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.ACTIVATED %]>[% 'Activated' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.SUSPEND_PENDING %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.SUSPEND_PENDING %]>[% 'Waiting for suspension' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.SUSPENDED %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.SUSPENDED %]>[% 'Suspended' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.WAITING_FOR_MODIFICATION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_MODIFICATION %]>[% 'Waiting for modification' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.MODIFICATION_ERROR %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.MODIFICATION_ERROR %]>[% 'Error while modifying object' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.WAITING_FOR_DELETION %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.WAITING_FOR_DELETION %]>[% 'Will be deleted' | i18n | html %]</option>
+ <option value="[% constants.object_statuses.DELETION_ERROR %]"[% ' selected="selected"' IF object.get_status == constants.object_statuses.DELETION_ERROR %]>[% 'Deletion error' | i18n | html %]</option>
</select>
</p>
<p>
Modified: trunk/vhffs-robots/src/bazaar_delete.pl
===================================================================
--- trunk/vhffs-robots/src/bazaar_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/bazaar_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , 'bazaar' );
-my $repos = Vhffs::Services::Bazaar::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $repos = Vhffs::Services::Bazaar::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $bazaar ( @{$repos} )
{
if( Vhffs::Robots::Bazaar::delete_repo( $bazaar ) != 0 ) {
Modified: trunk/vhffs-robots/src/cron_delete.pl
===================================================================
--- trunk/vhffs-robots/src/cron_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/cron_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -43,7 +43,7 @@
Vhffs::Robots::lock( $vhffs , 'cron' );
-my $crons = Vhffs::Services::Cron::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $crons = Vhffs::Services::Cron::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $c ( @{$crons} )
{
Modified: trunk/vhffs-robots/src/cvs_delete.pl
===================================================================
--- trunk/vhffs-robots/src/cvs_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/cvs_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , 'cvs' );
-my $repos = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $repos = Vhffs::Services::Cvs::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $cvs ( @{$repos} )
{
if( Vhffs::Robots::Cvs::delete_cvs( $cvs ) != 0 ) {
Modified: trunk/vhffs-robots/src/dns_delete.pl
===================================================================
--- trunk/vhffs-robots/src/dns_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/dns_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -43,7 +43,7 @@
Vhffs::Robots::lock( $vhffs , "dns" );
my $dns;
-my $todelete = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $todelete = Vhffs::Services::DNS::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
if( defined $todelete )
{
Modified: trunk/vhffs-robots/src/git_delete.pl
===================================================================
--- trunk/vhffs-robots/src/git_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/git_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -45,7 +45,7 @@
Vhffs::Robots::lock( $vhffs , 'git' );
-my $repos = Vhffs::Services::Git::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $repos = Vhffs::Services::Git::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $git ( @{$repos} )
{
if( Vhffs::Robots::Git::delete_repo( $git ) != 0 ) {
Modified: trunk/vhffs-robots/src/group_delete.pl
===================================================================
--- trunk/vhffs-robots/src/group_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/group_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , 'usergroup' );
-my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $groups = Vhffs::Group::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $group ( @{$groups} )
{
if( $group->is_empty ) {
@@ -54,8 +54,8 @@
else {
foreach my $object ( @{$group->getall_objects} )
{
- if( $group->get_oid != $object->get_oid && $object->get_status != Vhffs::Constants::TO_DELETE) {
- $object->set_status( Vhffs::Constants::TO_DELETE );
+ if( $group->get_oid != $object->get_oid && $object->get_status != Vhffs::Constants::WAITING_FOR_DELETION) {
+ $object->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
$object->commit;
}
}
Modified: trunk/vhffs-robots/src/mail_createboxes.pl
===================================================================
--- trunk/vhffs-robots/src/mail_createboxes.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/mail_createboxes.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -65,7 +65,7 @@
unless( @$errors ) {
$mail->set_box_status( $b->{local_part} , Vhffs::Constants::ACTIVATED );
} else {
- $mail->set_box_status( $b->{local_part} , Vhffs::Constants::CREATING_ERROR );
+ $mail->set_box_status( $b->{local_part} , Vhffs::Constants::CREATION_ERROR );
}
}
}
Modified: trunk/vhffs-robots/src/mail_delete.pl
===================================================================
--- trunk/vhffs-robots/src/mail_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/mail_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -46,7 +46,7 @@
Vhffs::Robots::lock( $vhffs , "mail" );
-my $mails = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $mails = Vhffs::Services::Mail::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
my $mail;
my $lists;
my $list;
@@ -55,7 +55,7 @@
my $lists = Vhffs::Services::MailingList::getall( $vhffs , undef , undef , undef , $mail->get_domain );
if( @$lists != 0) {
foreach $list ( @{$lists} ) {
- $list->set_status( Vhffs::Constants::TO_DELETE );
+ $list->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
$list->commit;
}
Vhffs::Robots::vhffs_log( $vhffs, sprintf( 'Cannot delete mail domain %s, remains lists, requests have been sent to delete them' , $mail->get_domain ) );
@@ -64,7 +64,7 @@
if( $mail->nb_boxes() > 0 ) {
foreach my $bo ( values( %{$mail->get_boxes()} ) ) {
- $mail->set_box_status( $bo->{'local_part'} , Vhffs::Constants::TO_DELETE );
+ $mail->set_box_status( $bo->{'local_part'} , Vhffs::Constants::WAITING_FOR_DELETION );
}
Vhffs::Robots::vhffs_log( $vhffs, sprintf( 'Cannot delete mail domain %s, remains %d boxes, requests have been sent to delete them' , $mail->get_domain , $mail->nb_boxes() ) );
next;
Modified: trunk/vhffs-robots/src/mail_deleteboxes.pl
===================================================================
--- trunk/vhffs-robots/src/mail_deleteboxes.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/mail_deleteboxes.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -48,7 +48,7 @@
Vhffs::Robots::lock( $vhffs , 'mail' );
-my $boxes = Vhffs::Robots::Mail::getall_boxes( $vhffs , Vhffs::Constants::TO_DELETE );
+my $boxes = Vhffs::Robots::Mail::getall_boxes( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $b ( @{$boxes} )
{
my $mail = Vhffs::Services::Mail::get_by_mxdomain( $vhffs, $b->{domain} );
Modified: trunk/vhffs-robots/src/mailinglist_delete.pl
===================================================================
--- trunk/vhffs-robots/src/mailinglist_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/mailinglist_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -41,7 +41,7 @@
my $vhffs = init Vhffs::Main;
Vhffs::Robots::lock( $vhffs , "ml" );
-my $mls = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $mls = Vhffs::Services::MailingList::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
my $ml;
foreach $ml ( @{$mls} )
Modified: trunk/vhffs-robots/src/mercurial_delete.pl
===================================================================
--- trunk/vhffs-robots/src/mercurial_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/mercurial_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , 'mercurial' );
-my $repos = Vhffs::Services::Mercurial::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $repos = Vhffs::Services::Mercurial::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
foreach my $mercurial ( @{$repos} )
{
if( Vhffs::Robots::Mercurial::delete_repo( $mercurial ) != 0 ) {
Modified: trunk/vhffs-robots/src/mysql_delete.pl
===================================================================
--- trunk/vhffs-robots/src/mysql_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/mysql_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -43,7 +43,7 @@
Vhffs::Robots::lock( $vhffs , "mysql" );
-my $dbs = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::TO_DELETE , undef , undef );
+my $dbs = Vhffs::Services::Mysql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION , undef , undef );
my $db;
Modified: trunk/vhffs-robots/src/pgsql_delete.pl
===================================================================
--- trunk/vhffs-robots/src/pgsql_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/pgsql_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -42,7 +42,7 @@
Vhffs::Robots::lock( $vhffs , "pgsql" );
-my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::TO_DELETE , undef , undef );
+my $dbs = Vhffs::Services::Pgsql::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION , undef , undef );
my $db;
Modified: trunk/vhffs-robots/src/repository_delete.pl
===================================================================
--- trunk/vhffs-robots/src/repository_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/repository_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , "repository" );
-my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $repos = Vhffs::Services::Repository::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
my $repo;
foreach $repo ( @{$repos} )
Modified: trunk/vhffs-robots/src/svn_delete.pl
===================================================================
--- trunk/vhffs-robots/src/svn_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/svn_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , 'svn' );
-my $repos = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::TO_DELETE);
+my $repos = Vhffs::Services::Svn::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION);
foreach my $svn ( @{$repos} )
{
if( Vhffs::Robots::Svn::delete_repo( $svn ) != 0 ) {
Modified: trunk/vhffs-robots/src/user_delete.pl
===================================================================
--- trunk/vhffs-robots/src/user_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/user_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , "usergroup" );
-my $lol = Vhffs::User::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $lol = Vhffs::User::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
my $user;
my $groups;
my $group;
@@ -63,7 +63,7 @@
if( $group->get_owner_uid == $user->get_uid )
{
$ok = 0;
- $group->set_status( Vhffs::Constants::TO_DELETE );
+ $group->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
$group->commit;
}
}
Modified: trunk/vhffs-robots/src/web_delete.pl
===================================================================
--- trunk/vhffs-robots/src/web_delete.pl 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-robots/src/web_delete.pl 2012-02-23 21:31:57 UTC (rev 2042)
@@ -44,7 +44,7 @@
Vhffs::Robots::lock( $vhffs , "web" );
-my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::TO_DELETE );
+my $webs = Vhffs::Services::Web::getall( $vhffs , Vhffs::Constants::WAITING_FOR_DELETION );
my $web;
Modified: trunk/vhffs-tools/src/vhffs-groupdel
===================================================================
--- trunk/vhffs-tools/src/vhffs-groupdel 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-tools/src/vhffs-groupdel 2012-02-23 21:31:57 UTC (rev 2042)
@@ -17,7 +17,7 @@
if( defined $group )
{
- $group->set_status( Vhffs::Constants::TO_DELETE );
+ $group->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
if( $group->commit <= 0 )
{
Modified: trunk/vhffs-tools/src/vhffs-userdel
===================================================================
--- trunk/vhffs-tools/src/vhffs-userdel 2012-02-23 00:36:01 UTC (rev 2041)
+++ trunk/vhffs-tools/src/vhffs-userdel 2012-02-23 21:31:57 UTC (rev 2042)
@@ -17,7 +17,7 @@
if( defined $user )
{
- $user->set_status( Vhffs::Constants::TO_DELETE );
+ $user->set_status( Vhffs::Constants::WAITING_FOR_DELETION );
if( $user->commit <= 0 )
{