Skip to content

Instantly share code, notes, and snippets.

@skipjac
Last active December 21, 2015 08:18
Show Gist options
  • Save skipjac/6276819 to your computer and use it in GitHub Desktop.
Save skipjac/6276819 to your computer and use it in GitHub Desktop.
defers in zendesk apps http://underscorejs.org/#defer
events: {
'app.activated': 'appActivated',
'ticket.form.id.changed': 'hideCustomField'
},
appActivated: function() {
this.hideCustomField();
},
hideCustomField: function() {
var self = this;
_.defer(function() {
self.ticketFields("custom_field_x").hide();
});
},
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment