Display table actions BatchActions buttons in the correct locale
The table actions' verbose names were getting initialised too early. The most noticeable effect was all the red buttons being displayed in English no matter the locale. Fixes bug #1126324 Change-Id: I8e21a1ec73f11129317249d103c081e90fa13a34
This commit is contained in:
parent
accc983d00
commit
e89f949151
@ -493,10 +493,11 @@ class BatchAction(Action):
|
||||
self.current_past_action = 0
|
||||
self.data_type_plural = getattr(self, 'data_type_plural',
|
||||
self.data_type_singular + 's')
|
||||
# If setting a default name, don't initialise it too early
|
||||
self.verbose_name = getattr(self, "verbose_name",
|
||||
self._conjugate())
|
||||
self._conjugate)
|
||||
self.verbose_name_plural = getattr(self, "verbose_name_plural",
|
||||
self._conjugate('plural'))
|
||||
lambda: self._conjugate('plural'))
|
||||
# Keep record of successfully handled objects
|
||||
self.success_ids = []
|
||||
super(BatchAction, self).__init__()
|
||||
|
Loading…
x
Reference in New Issue
Block a user