Skip to content

Commit

Permalink
Implement tag replication for #33
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremystretch committed Dec 6, 2019
1 parent 446acbd commit b05566e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion netbox/utilities/templatetags/buttons.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,9 @@ def clone_button(url, instance):
if field_value not in (None, ''):
params[field_name] = field_value

# TODO: Tag replication
# Copy tags
if hasattr(instance, 'tags'):
params['tags'] = ','.join([t.name for t in instance.tags.all()])

# Append parameters to URL
param_string = '&'.join(['{}={}'.format(k, v) for k, v in params.items()])
Expand Down

0 comments on commit b05566e

Please sign in to comment.