From a9aa5d9ea0c62376622ab08066ad75133d484ac0 Mon Sep 17 00:00:00 2001 From: Prem Sichanugrist Date: Thu, 5 Jul 2012 14:44:01 -0400 Subject: [PATCH] Update code base on changes in master --- cms/static/coffee/src/views/week.coffee | 2 +- cms/templates/widgets/navigation.html | 4 ++-- cms/templates/widgets/sequence-edit.html | 2 +- common/lib/xmodule/xmodule/js/module/html.coffee | 6 +++--- common/lib/xmodule/xmodule/js/module/raw.coffee | 6 +++--- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/cms/static/coffee/src/views/week.coffee b/cms/static/coffee/src/views/week.coffee index e07b159a46..f81a76c369 100644 --- a/cms/static/coffee/src/views/week.coffee +++ b/cms/static/coffee/src/views/week.coffee @@ -1,6 +1,6 @@ class CMS.Views.Week extends Backbone.View events: - 'click .module-edit': 'edit' + 'click .week-edit': 'edit' initialize: -> @model = new CMS.Models.Week(id: @$el.data('id')) diff --git a/cms/templates/widgets/navigation.html b/cms/templates/widgets/navigation.html index dca9177860..e67894d3e5 100644 --- a/cms/templates/widgets/navigation.html +++ b/cms/templates/widgets/navigation.html @@ -38,7 +38,7 @@ % for week in weeks:
  • -

    ${week.name}

    +

    ${week.name}

      % if 'goals' in week.metadata: % for goal in week.metadata['goals']: @@ -52,7 +52,7 @@
        % for module in week.get_children(): -
      • +
      • ${module.name} handle
      • diff --git a/cms/templates/widgets/sequence-edit.html b/cms/templates/widgets/sequence-edit.html index bba45d8856..0b0bfa5f5c 100644 --- a/cms/templates/widgets/sequence-edit.html +++ b/cms/templates/widgets/sequence-edit.html @@ -37,7 +37,7 @@
          % for child in module.get_children():
        1. - ${child.name} + ${child.name} handle
        2. %endfor diff --git a/common/lib/xmodule/xmodule/js/module/html.coffee b/common/lib/xmodule/xmodule/js/module/html.coffee index 5e072c27a3..2d2ab744c7 100644 --- a/common/lib/xmodule/xmodule/js/module/html.coffee +++ b/common/lib/xmodule/xmodule/js/module/html.coffee @@ -1,7 +1,7 @@ class @HTML - constructor: (@id) -> - @edit_box = $("##{@id} .edit-box") - @preview = $("##{@id} .preview") + constructor: (@element) -> + @edit_box = $(".edit-box", @element) + @preview = $(".preview", @element) @edit_box.on('input', => @preview.empty().append(@edit_box.val()) ) diff --git a/common/lib/xmodule/xmodule/js/module/raw.coffee b/common/lib/xmodule/xmodule/js/module/raw.coffee index 1b9e05d6b6..920db47c92 100644 --- a/common/lib/xmodule/xmodule/js/module/raw.coffee +++ b/common/lib/xmodule/xmodule/js/module/raw.coffee @@ -1,7 +1,7 @@ class @Raw - constructor: (@id) -> - @edit_box = $("##{@id} .edit-box") - @preview = $("##{@id} .preview") + constructor: (@element) -> + @edit_box = $(".edit-box", @element) + @preview = $(".preview", @element) @edit_box.on('input', => @preview.empty().text(@edit_box.val()) )