Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
synnefo
Commits
004cc109
Commit
004cc109
authored
Feb 21, 2012
by
Giorgos Verigakis
Browse files
Send an email to user when activating
parent
ca96a346
Changes
1
Hide whitespace changes
Inline
Side-by-side
astakos/im/management/commands/activateuser.py
View file @
004cc109
...
...
@@ -35,11 +35,12 @@ from optparse import make_option
from
django.core.management.base
import
BaseCommand
,
CommandError
from
astakos.im.admin.functions
import
activate
from
astakos.im.models
import
AstakosUser
class
Command
(
BaseCommand
):
args
=
"<user
_
id or email> [user
_
id or email] ..."
args
=
"<user
id or email> [user
id or email] ..."
help
=
"Activates one or more users"
def
handle
(
self
,
*
args
,
**
options
):
...
...
@@ -63,7 +64,6 @@ class Command(BaseCommand):
self
.
stderr
.
write
(
msg
)
continue
user
.
is_active
=
True
user
.
save
()
activate
(
user
)
self
.
stdout
.
write
(
"Activated '%s'
\n
"
%
(
user
.
email
,))
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment