Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
edx-val
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-val
Commits
d5ec9e5e
Commit
d5ec9e5e
authored
Sep 22, 2017
by
muhammad-ammar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add video_source_language field
parent
ba8dcb03
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
4 deletions
+15
-4
edxval/migrations/0007_transcriptpreference.py
+2
-1
edxval/models.py
+7
-0
edxval/serializers.py
+2
-1
edxval/tests/constants.py
+4
-2
No files found.
edxval/migrations/0007_transcriptpreference.py
View file @
d5ec9e5e
# -*- coding: utf-8 -*-
# Generated by Django 1.11.4 on 2017-0
8-24 07:21
# Generated by Django 1.11.4 on 2017-0
9-22 07:13
from
__future__
import
unicode_literals
from
django.db
import
migrations
,
models
...
...
@@ -27,6 +27,7 @@ class Migration(migrations.Migration):
(
'cielo24_turnaround'
,
models
.
CharField
(
blank
=
True
,
choices
=
[(
b
'STANDARD'
,
b
'Standard, 48h'
),
(
b
'PRIORITY'
,
b
'Priority, 24h'
)],
max_length
=
20
,
null
=
True
,
verbose_name
=
b
'Cielo24 Turnaround'
)),
(
'three_play_turnaround'
,
models
.
CharField
(
blank
=
True
,
choices
=
[(
b
'extended_service'
,
b
'10-Day/Extended'
),
(
b
'default'
,
b
'4-Day/Default'
),
(
b
'expedited_service'
,
b
'2-Day/Expedited'
),
(
b
'rush_service'
,
b
'24 hour/Rush'
),
(
b
'same_day_service'
,
b
'Same Day'
)],
max_length
=
20
,
null
=
True
,
verbose_name
=
b
'3PlayMedia Turnaround'
)),
(
'preferred_languages'
,
edxval
.
models
.
ListField
(
blank
=
True
,
default
=
[],
max_items
=
50
,
verbose_name
=
b
'Preferred Languages'
)),
(
'video_source_language'
,
models
.
CharField
(
blank
=
True
,
help_text
=
b
'This is the source language of a video.'
,
max_length
=
20
,
null
=
True
,
verbose_name
=
b
'Video Source Language'
)),
],
options
=
{
'abstract'
:
False
,
...
...
edxval/models.py
View file @
d5ec9e5e
...
...
@@ -600,6 +600,13 @@ class TranscriptPreference(TimeStampedModel):
blank
=
True
,
)
preferred_languages
=
ListField
(
verbose_name
=
'Preferred Languages'
,
max_items
=
50
,
default
=
[],
blank
=
True
)
video_source_language
=
models
.
CharField
(
verbose_name
=
'Video Source Language'
,
max_length
=
20
,
null
=
True
,
blank
=
True
,
help_text
=
'This is the source language of a video.'
)
def
__unicode__
(
self
):
return
u'{course_id} - {provider}'
.
format
(
course_id
=
self
.
course_id
,
provider
=
self
.
provider
)
...
...
edxval/serializers.py
View file @
d5ec9e5e
...
...
@@ -217,7 +217,8 @@ class TranscriptPreferenceSerializer(serializers.ModelSerializer):
'cielo24_turnaround'
,
'three_play_turnaround'
,
'preferred_languages'
,
'modified'
'video_source_language'
,
'modified'
,
)
preferred_languages
=
serializers
.
SerializerMethodField
()
...
...
edxval/tests/constants.py
View file @
d5ec9e5e
...
...
@@ -426,12 +426,14 @@ TRANSCRIPT_PREFERENCES_CIELO24 = dict(
provider
=
TranscriptProviderType
.
CIELO24
,
cielo24_fidelity
=
Cielo24Fidelity
.
PROFESSIONAL
,
cielo24_turnaround
=
Cielo24Turnaround
.
PRIORITY
,
preferred_languages
=
[
'ar'
]
preferred_languages
=
[
'ar'
],
video_source_language
=
'en'
,
)
TRANSCRIPT_PREFERENCES_3PLAY
=
dict
(
course_id
=
'edX/DemoX/Demo_Course'
,
provider
=
TranscriptProviderType
.
THREE_PLAY_MEDIA
,
three_play_turnaround
=
ThreePlayTurnaround
.
SAME_DAY_SERVICE
,
preferred_languages
=
[
'ar'
,
'en'
]
preferred_languages
=
[
'ar'
,
'en'
],
video_source_language
=
'en'
,
)
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