Added set to current user for macros.
This commit is contained in:
parent
4299f3ea4c
commit
df1420d5db
2 changed files with 11 additions and 0 deletions
|
@ -548,6 +548,13 @@ class App.TicketZoom extends App.Controller
|
||||||
else
|
else
|
||||||
@sidebar.tagWidget.add(tag)
|
@sidebar.tagWidget.add(tag)
|
||||||
|
|
||||||
|
# apply user changes
|
||||||
|
else if attributes[1] is 'owner_id'
|
||||||
|
if content.pre_condition is 'current_user.id'
|
||||||
|
ticket[attributes[1]] = App.Session.get('id')
|
||||||
|
else
|
||||||
|
ticket[attributes[1]] = content.value
|
||||||
|
|
||||||
# apply direct value changes
|
# apply direct value changes
|
||||||
else
|
else
|
||||||
ticket[attributes[1]] = content.value
|
ticket[attributes[1]] = content.value
|
||||||
|
|
|
@ -1661,6 +1661,10 @@ Macro.create_if_not_exists(
|
||||||
operator: 'add',
|
operator: 'add',
|
||||||
value: 'spam',
|
value: 'spam',
|
||||||
},
|
},
|
||||||
|
'ticket.owner_id' => {
|
||||||
|
pre_condition: 'current_user.id',
|
||||||
|
value: '',
|
||||||
|
},
|
||||||
},
|
},
|
||||||
note: 'example macro',
|
note: 'example macro',
|
||||||
active: true,
|
active: true,
|
||||||
|
|
Loading…
Reference in a new issue