|
19 | 19 | from opaque_keys.edx.keys import AssetKey, CourseKey |
20 | 20 | from pymongo import ASCENDING, DESCENDING |
21 | 21 |
|
22 | | -from common.djangoapps.edxmako.shortcuts import render_to_response |
23 | 22 | from common.djangoapps.student.auth import has_course_author_access |
24 | 23 | from common.djangoapps.util.date_utils import get_default_time_display |
25 | 24 | from common.djangoapps.util.json_request import JsonResponse |
|
34 | 33 | from xmodule.modulestore.exceptions import ItemNotFoundError # lint-amnesty, pylint: disable=wrong-import-order |
35 | 34 |
|
36 | 35 | from .exceptions import AssetNotFoundException, AssetSizeTooLargeException |
37 | | -from .utils import reverse_course_url, get_files_uploads_url, get_response_format, request_response_format_is_json |
38 | | -from .toggles import use_new_files_uploads_page |
| 36 | +from .utils import get_files_uploads_url, get_response_format, request_response_format_is_json |
39 | 37 |
|
40 | 38 |
|
41 | 39 | REQUEST_DEFAULTS = { |
@@ -169,22 +167,8 @@ def _get_asset_usage_path(course_key, assets): |
169 | 167 | def _asset_index(request, course_key): |
170 | 168 | ''' |
171 | 169 | Display an editable asset library. |
172 | | -
|
173 | | - Supports start (0-based index into the list of assets) and max query parameters. |
174 | 170 | ''' |
175 | | - course_block = modulestore().get_course(course_key) |
176 | | - |
177 | | - if use_new_files_uploads_page(course_key): |
178 | | - return redirect(get_files_uploads_url(course_key)) |
179 | | - |
180 | | - return render_to_response('asset_index.html', { |
181 | | - 'language_code': request.LANGUAGE_CODE, |
182 | | - 'context_course': course_block, |
183 | | - 'max_file_size_in_mbs': settings.MAX_ASSET_UPLOAD_FILE_SIZE_IN_MB, |
184 | | - 'chunk_size_in_mbs': settings.UPLOAD_CHUNK_SIZE_IN_MB, |
185 | | - 'max_file_size_redirect_url': settings.MAX_ASSET_UPLOAD_FILE_SIZE_URL, |
186 | | - 'asset_callback_url': reverse_course_url('assets_handler', course_key) |
187 | | - }) |
| 171 | + return redirect(get_files_uploads_url(course_key)) |
188 | 172 |
|
189 | 173 |
|
190 | 174 | def _assets_json(request, course_key): |
|
0 commit comments