Skip to content

Instantly share code, notes, and snippets.

@juanghurtado
Created December 11, 2013 10:50
Show Gist options
  • Save juanghurtado/7908439 to your computer and use it in GitHub Desktop.
Save juanghurtado/7908439 to your computer and use it in GitHub Desktop.
define [
'modules/main/views/general-view'
'app.framework'
'communication-bus'
], (GeneralView, Framework, Bus) ->
# ----------------------------------------------------------------------------
# Class definition
# ----------------------------------------------------------------------------
class ShowController extends Framework.Controller
initialize: ->
generalView = new GeneralView
generalView.on "sign-document:click", API.initSignDocument
generalView.on "my-certs:click", API.initMyCerts
@show generalView
# ----------------------------------------------------------------------------
# Controller API
# ----------------------------------------------------------------------------
API =
initSignDocument: ->
alert "Not implemented"
initMyCerts: ->
console.log "'Mis certificados' clicked"
# ----------------------------------------------------------------------------
# Return class definition for AMD behaviour
# ----------------------------------------------------------------------------
return ShowController
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment