diff --git a/lms/envs/common.py b/lms/envs/common.py index 247a0774db..ef0528df20 100644 --- a/lms/envs/common.py +++ b/lms/envs/common.py @@ -1293,7 +1293,6 @@ discussion_vendor_js = [ 'js/split.js' ] -staff_grading_js = sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/staff_grading/**/*.js')) notes_js = sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/notes/**/*.js')) instructor_dash_js = ( sorted(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/instructor_dashboard/**/*.js')) + @@ -1478,8 +1477,8 @@ PIPELINE_CSS = { } -common_js = set(rooted_glob(COMMON_ROOT / 'static', 'coffee/src/**/*.js')) - set(courseware_js + discussion_js + staff_grading_js + notes_js + instructor_dash_js) # pylint: disable=line-too-long -project_js = set(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/**/*.js')) - set(courseware_js + discussion_js + staff_grading_js + notes_js + instructor_dash_js) # pylint: disable=line-too-long +common_js = set(rooted_glob(COMMON_ROOT / 'static', 'coffee/src/**/*.js')) - set(courseware_js + discussion_js + notes_js + instructor_dash_js) # pylint: disable=line-too-long +project_js = set(rooted_glob(PROJECT_ROOT / 'static', 'coffee/src/**/*.js')) - set(courseware_js + discussion_js + notes_js + instructor_dash_js) # pylint: disable=line-too-long PIPELINE_JS = { @@ -1530,10 +1529,6 @@ PIPELINE_JS = { 'source_filenames': discussion_vendor_js, 'output_filename': 'js/discussion_vendor.js', }, - 'staff_grading': { - 'source_filenames': staff_grading_js, - 'output_filename': 'js/staff_grading.js', - }, 'notes': { 'source_filenames': notes_js, 'output_filename': 'js/notes.js', diff --git a/lms/static/coffee/spec/staff_grading_spec.coffee b/lms/static/coffee/spec/staff_grading_spec.coffee deleted file mode 100644 index 595a9eb550..0000000000 --- a/lms/static/coffee/spec/staff_grading_spec.coffee +++ /dev/null @@ -1,11 +0,0 @@ -describe 'StaffGrading', -> - beforeEach -> - spyOn Logger, 'log' - @mockBackend = new StaffGradingBackend('url', true) - - describe 'constructor', -> - beforeEach -> - @staff_grading = new StaffGrading(@mockBackend) - - it 'we are originally in the list view', -> - expect(@staff_grading.list_view).toBe(true) diff --git a/lms/static/coffee/src/staff_grading/staff_grading.coffee b/lms/static/coffee/src/staff_grading/staff_grading.coffee deleted file mode 100644 index a06405aad0..0000000000 --- a/lms/static/coffee/src/staff_grading/staff_grading.coffee +++ /dev/null @@ -1,502 +0,0 @@ -# wrap everything in a class in case we want to use inside xmodules later - -get_random_int: (min, max) -> - return Math.floor(Math.random() * (max - min + 1)) + min - -# states -state_grading = "grading" -state_graded = "graded" -state_no_data = "no_data" -state_error = "error" - -class @StaffGradingBackend - constructor: (ajax_url, mock_backend) -> - @ajax_url = ajax_url - # prevent this from trying to make requests when we don't have - # a proper url - if !ajax_url - mock_backend = true - @mock_backend = mock_backend - if @mock_backend - @mock_cnt = 0 - - mock: (cmd, data) -> - # Return a mock response to cmd and data - # should take a location as an argument - if cmd == 'get_next' - @mock_cnt++ - switch data.location - when 'i4x://MITx/3.091x/problem/open_ended_demo1' - response = - success: true - problem_name: 'Problem 1' - num_graded: 3 - min_for_ml: 5 - num_pending: 4 - prompt: ''' -
Shown below are schematic band diagrams for two different metals. Both diagrams appear different, yet both of the elements are undisputably metallic in nature.
-
-* Why is it that both sodium and magnesium behave as metals, even though the s-band of magnesium is filled?
-This is a self-assessed open response question. Please use as much space as you need in the box below to answer the question.
- ''' - submission: ''' - Contrary to popular belief, Lorem Ipsum is not simply random text. It has roots in a piece of classical Latin literature from 45 BC, making it over 2000 years old. Richard McClintock, a Latin professor at Hampden-Sydney College in Virginia, looked up one of the more obscure Latin words, consectetur, from a Lorem Ipsum passage, and going through the cites of the word in classical literature, discovered the undoubtable source. Lorem Ipsum comes from sections 1.10.32 and 1.10.33 of "de Finibus Bonorum et Malorum" (The Extremes of Good and Evil) by Cicero, written in 45 BC. This book is a treatise on the theory of ethics, very popular during the Renaissance. The first line of Lorem Ipsum, "Lorem ipsum dolor sit amet..", comes from a line in section 1.10.32. - -The standard chunk of Lorem Ipsum used since the 1500s is reproduced below for those interested. Sections 1.10.32 and 1.10.33 from "de Finibus Bonorum et Malorum" by Cicero are also reproduced in their exact original form, accompanied by English versions from the 1914 translation by H. Rackham. - ''' - rubric: ''' -| Purpose | - -- - | - -- - | - -- - | - -- - | -
|---|---|---|---|---|
| Organization | - -- - | - -- - | - -- - | - -- - | -
" + msg + "
") - - error: (msg) -> - @error_msg = msg - @state = state_error - - data_loaded: (response) -> - @prompt = response.prompt - @submission = response.submission - @rubric = response.rubric - @submission_id = response.submission_id - @feedback_area.val('') - @grade = null - @max_score = response.max_score - @ml_error_info=response.ml_error_info - @prompt_name = response.problem_name - @num_graded = response.num_graded - @min_for_ml = response.min_for_ml - @num_pending = response.num_pending - @state = state_grading - if not @max_score? - @error("No max score specified for submission.") - - no_more: (message) -> - @prompt = null - @prompt_name = '' - @num_graded = 0 - @min_for_ml = 0 - @submission = null - @rubric = null - @ml_error_info = null - @submission_id = null - @message = message - @grade = null - @max_score = 0 - @state = state_no_data - - render_view: (before_ajax) -> - # clear the problem list and breadcrumbs - @problem_list.html(''' -NOTE: Mocking backend.
" - @message_container.html(@message) - @error_container.html(@error_msg) - @message_container.toggle(@message != "") - @error_container.toggle(@error_msg != "") - @flag_submission_checkbox.prop('checked', false) - - - # only show the grading elements when we are not in list view or the state - # is invalid - show_grading_elements = !(@list_view || @state == state_error || - @state == state_no_data) - @prompt_wrapper.toggle(show_grading_elements) - @submission_wrapper.toggle(show_grading_elements) - @grading_wrapper.toggle(show_grading_elements) - @meta_info_wrapper.toggle(show_grading_elements) - @action_button.hide() - - if before_ajax - @scroll_to_top() - else - if @list_view - @render_list() - else - @render_problem() - - problem_link:(problem) -> - link = $('').attr('href', "javascript:void(0)").append( - "#{problem.problem_name}") - .click => - @get_next_submission problem.location - - make_paragraphs: (text) -> - paragraph_split = text.split(/\n\s*\n/) - new_text = '' - for paragraph in paragraph_split - new_text += "#{paragraph}
" - return new_text - - render_list: () -> - for problem in @problems - problem_row = $('-
-${_("This is the list of problems that currently need to be graded in order to train AI grading and create calibration essays for peer grading. Each problem needs to be treated separately, and we have indicated the number of student submissions that need to be graded. You can grade more than the minimum required number of submissions--this will improve the accuracy of AI grading, though with diminishing returns. You can see the current accuracy of AI grading in the problem view.")}
--
--
-- ${_("Flag as inappropriate content for later review")} -
-