Last active
August 29, 2015 14:20
-
-
Save mmarum-sugarcrm/c2981f4d5e7d25dfbbed to your computer and use it in GitHub Desktop.
MyAppAction footer extension (tested on Sugar 7.5, 7.6)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
({ | |
events: { | |
//On click of our "button" element | |
'click [data-action=chat]': 'chat' | |
}, | |
// tagName attribute is inherited from Backbone.js. | |
// We set it to "span" instead of default "div" so that our "button" element is displayed inline. | |
tagName: "span", | |
chat: function(){ | |
// Use Sugar 7 API to pop one of our standard alert message boxes. | |
app.alert.show('myapp-chat-alert', { | |
level: 'info', | |
messages: 'Send a chat message!', | |
autoClose: true | |
}); | |
} | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment