mirror of
https://github.com/netbox-community/netbox.git
synced 2024-05-10 07:54:54 +00:00
Tweaked bulk import message to reflect object type
This commit is contained in:
@ -222,7 +222,8 @@ class BulkImportView(View):
|
|||||||
new_objs.append(obj)
|
new_objs.append(obj)
|
||||||
|
|
||||||
obj_table = self.table(new_objs)
|
obj_table = self.table(new_objs)
|
||||||
msg = 'Imported {} objects'.format(len(new_objs))
|
if new_objs:
|
||||||
|
msg = 'Imported {} {}'.format(len(new_objs), new_objs[0]._meta.verbose_name_plural)
|
||||||
messages.success(request, msg)
|
messages.success(request, msg)
|
||||||
UserAction.objects.log_import(request.user, ContentType.objects.get_for_model(new_objs[0]), msg)
|
UserAction.objects.log_import(request.user, ContentType.objects.get_for_model(new_objs[0]), msg)
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user