Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
class Assignment
constructor: (o) ->
$.map o, (v,k) =>
@name = k
@app = v
class System
constructor: (o) ->
@users = $.map o.users, (v,k) =>
new User(k,v)
class User
constructor: (name, roles) ->
@name = ko.observable(name)
@r = roles
@roles = $.map roles(), (v,k) ->
new Assignment(v)
window.System = System
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment