Small cleanup.

This commit is contained in:
Martin Edenhofer 2016-01-28 11:20:36 +01:00
parent 44e379a3d0
commit f09a4f1064
2 changed files with 2 additions and 4 deletions

View file

@ -131,7 +131,6 @@ class App.TicketZoomArticleActions extends App.Controller
e.preventDefault() e.preventDefault()
type = App.TicketArticleType.findByAttribute('name', 'facebook feed comment') type = App.TicketArticleType.findByAttribute('name', 'facebook feed comment')
console.log('tt', type)
@scrollToCompose() @scrollToCompose()
# empty form # empty form

View file

@ -52,7 +52,7 @@ class App.WidgetTag extends App.Controller
onAddTag: (e) => onAddTag: (e) =>
e.preventDefault() e.preventDefault()
item = @$('[name="new_tag"]').val() item = @$('[name="new_tag"]').val().trim()
return if !item return if !item
@add(item) @add(item)
@ -85,12 +85,11 @@ class App.WidgetTag extends App.Controller
e.preventDefault() e.preventDefault()
item = $(e.target).parents('li').find('.js-tag').text() item = $(e.target).parents('li').find('.js-tag').text()
return if !item return if !item
@remove(item) @remove(item)
remove: (item) => remove: (item) =>
@tags = _.filter(@tags, (tagItem) -> return tagItem if tagItem isnt item ) @tags = _.filter(@tags, (tagItem) -> return tagItem if tagItem isnt item)
@render() @render()
@ajax( @ajax(