     return rights
 
 getSelfRights = (tr) ->
-#    rights = []
-#    tr.find(SELF_RIGHT_COL).find(".customLabel").each ->
-#      rights.push($(@).text())
-#    return rights
-  return null
+    rights = []
+    tr.find(SELF_RIGHT_COL).find(".customLabel").each ->
+      rights.push($(@).text())
+    return rights
 
 getRoles = (tr) ->
     roles = []

    $("#addRightUi").parent().append(" ")
    populateRightComboBox($(@).parents("tr"))
    enableSaveButtonIfPossible($(@).parents("tr"))

  #Wire up Add Role button
  $("#addGroupButton").click ->

    if ($(@).val() != "none")
      $(@).remove()

  $("#addSelfRightUi option").each ->
    if ($(@).val() != "none")
      $(@).remove()

  for right in defaultRights
    if (curRights.indexOf(right) < 0)
      $("#addRightUi select").append($("<option></option>").val(right).text(right))

  for right in selfRights
    if (curSelfRights.indexOf(right) < 0)
      $("#addSelfRightUi select").append($("<option></option>").val(right).text(right))

wrapInputWithDeleteButton = (input, type, name) ->
  div = $('<span>').addClass("input-append")
