Last change
on this file since 2255 was
2255,
checked in by nanardon, 5 years ago
|
Really fix update task
|
-
Property svn:executable set to
*
|
File size:
1.1 KB
|
Line | |
---|
1 | package LATMOS::Accounts::Task::Update; |
---|
2 | |
---|
3 | use strict; |
---|
4 | use warnings; |
---|
5 | use base qw(LATMOS::Accounts::Task); |
---|
6 | use LATMOS::Accounts; |
---|
7 | use LATMOS::Accounts::Log; |
---|
8 | use LATMOS::Accounts::Utils; |
---|
9 | |
---|
10 | =head1 NAME |
---|
11 | |
---|
12 | LATMOS::Accounts::Task::Refreshexpired - Task to disable expired users |
---|
13 | |
---|
14 | =head1 DESCRIPTION |
---|
15 | |
---|
16 | This module update in the background objects that need some value to be recompute |
---|
17 | |
---|
18 | =cut |
---|
19 | |
---|
20 | sub order { -1 } |
---|
21 | |
---|
22 | sub init { |
---|
23 | my ($self) = @_; |
---|
24 | my $LA = LATMOS::Accounts->new($self->{config}); |
---|
25 | my $basename = $LA->default_base_name; |
---|
26 | my $labase = $LA->_load_base($basename) or die "Cannot load base"; |
---|
27 | |
---|
28 | $self->{_la} = $LA; |
---|
29 | $self->{_base} = $labase; |
---|
30 | |
---|
31 | 1; |
---|
32 | } |
---|
33 | |
---|
34 | sub run { |
---|
35 | my ($self) = @_; |
---|
36 | |
---|
37 | $self->{_base}->SchemaUpgrade(); |
---|
38 | |
---|
39 | 1; |
---|
40 | } |
---|
41 | |
---|
42 | 1; |
---|
43 | |
---|
44 | __END__ |
---|
45 | |
---|
46 | =head1 SEE ALSO |
---|
47 | |
---|
48 | L<LATMOS::Accounts>, L<LATMOS::Accounts::Task> |
---|
49 | |
---|
50 | =head1 AUTHOR |
---|
51 | |
---|
52 | Olivier Thauvin, E<lt>olivier.thauvin@latmos.ipsl.frE<gt> |
---|
53 | |
---|
54 | =head1 COPYRIGHT AND LICENSE |
---|
55 | |
---|
56 | Copyright (C) 2012 CNRS SA/CETP/LATMOS |
---|
57 | |
---|
58 | This library is free software; you can redistribute it and/or modify |
---|
59 | it under the same terms as Perl itself, either Perl version 5.10.0 or, |
---|
60 | at your option, any later version of Perl 5 you may have available. |
---|
61 | |
---|
62 | =cut |
---|
63 | |
---|
Note: See
TracBrowser
for help on using the repository browser.