Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-platform
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
edx
edx-platform
Commits
d0f72060
Commit
d0f72060
authored
Sep 06, 2013
by
Julian Arni
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Review fixes
parent
07014e8e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
cms/djangoapps/contentstore/features/upload.py
+1
-1
cms/static/js/views/assets.js
+4
-3
No files found.
cms/djangoapps/contentstore/features/upload.py
View file @
d0f72060
...
...
@@ -35,7 +35,7 @@ def upload_file(_step, file_name):
def
upload_file
(
_step
,
files_string
):
# Turn files_string to a list of file names
files
=
files_string
.
split
(
","
)
files
=
map
(
lambda
x
:
string
.
strip
(
x
,
' "'
),
files
)
files
=
map
(
lambda
x
:
string
.
strip
(
x
,
' "
\'
'
),
files
)
upload_css
=
'a.upload-button'
world
.
css_click
(
upload_css
)
...
...
cms/static/js/views/assets.js
View file @
d0f72060
...
...
@@ -53,7 +53,6 @@ function removeAsset(e){
function
showUploadModal
(
e
)
{
e
.
preventDefault
();
resetUploadModal
();
resetUploadBar
();
$modal
=
$
(
'.upload-modal'
).
show
();
$
(
'.upload-modal .file-chooser'
).
fileupload
({
dataType
:
'json'
,
...
...
@@ -61,10 +60,10 @@ function showUploadModal(e) {
maxChunkSize
:
100
*
1000
*
1000
,
// 100 MB
autoUpload
:
true
,
progressall
:
function
(
e
,
data
)
{
var
percentComplete
=
parseInt
(
data
.
loaded
/
data
.
total
*
100
,
10
);
var
percentComplete
=
parseInt
(
(
100
*
data
.
loaded
)
/
data
.
total
,
10
);
showUploadFeedback
(
e
,
percentComplete
);
},
maxFileSize
:
10
*
1000
*
1000
,
// 100 MB
maxFileSize
:
10
0
*
1000
*
1000
,
// 100 MB
maxNumberofFiles
:
100
,
add
:
function
(
e
,
data
)
{
data
.
process
().
done
(
function
()
{
...
...
@@ -103,6 +102,8 @@ function resetUploadBar() {
}
function
resetUploadModal
()
{
// Reset modal so it no longer displays information about previously
// completed uploads.
resetUploadBar
();
$
(
'.upload-modal .file-name'
).
html
(
''
);
$
(
'.upload-modal h1'
).
html
(
gettext
(
'Upload New File'
));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment