summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRob Crittenden <rcritten@redhat.com>2011-06-14 21:35:02 -0400
committerMartin Kosek <mkosek@redhat.com>2011-06-15 16:02:14 +0200
commitae775ec169374c9de47e91c0d350a1d3e2518623 (patch)
treed50f47caeefbf3daf2fce53475e6f1ab552f481f
parent23c5af218fe6262757d27de59840fa1bb1610ea8 (diff)
downloadfreeipa-ae775ec169374c9de47e91c0d350a1d3e2518623.tar.gz
freeipa-ae775ec169374c9de47e91c0d350a1d3e2518623.tar.xz
freeipa-ae775ec169374c9de47e91c0d350a1d3e2518623.zip
Add message output summary to sudorule del, mod and find.
https://fedorahosted.org/freeipa/ticket/1255
-rw-r--r--ipalib/plugins/sudorule.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/ipalib/plugins/sudorule.py b/ipalib/plugins/sudorule.py
index 01d871490..d38db3a6b 100644
--- a/ipalib/plugins/sudorule.py
+++ b/ipalib/plugins/sudorule.py
@@ -189,6 +189,7 @@ class sudorule_del(LDAPDelete):
"""
Delete Sudo Rule.
"""
+ msg_summary = _('Deleted sudo rule "%(value)s"')
api.register(sudorule_del)
@@ -197,6 +198,7 @@ class sudorule_mod(LDAPUpdate):
"""
Modify Sudo Rule.
"""
+ msg_summary = _('Modified sudo rule "%(value)s"')
api.register(sudorule_mod)
@@ -205,6 +207,9 @@ class sudorule_find(LDAPSearch):
"""
Search for Sudo Rule.
"""
+ msg_summary = ngettext(
+ '%(count)d sudo rule matched', '%(count)d sudo rules matched', 0
+ )
api.register(sudorule_find)