Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
website
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Container registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Vincent Wehrwein
website
Commits
ca71e995
Commit
ca71e995
authored
6 years ago
by
Julian Rother
Browse files
Options
Downloads
Patches
Plain Diff
Added stream_settings field
parent
cebdf37a
No related branches found
No related tags found
No related merge requests found
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
db_schema.sql
+2
-1
2 additions, 1 deletion
db_schema.sql
edit.py
+3
-1
3 additions, 1 deletion
edit.py
templates/course.html
+12
-8
12 additions, 8 deletions
templates/course.html
templates/macros.html
+1
-1
1 addition, 1 deletion
templates/macros.html
with
18 additions
and
11 deletions
db_schema.sql
+
2
−
1
View file @
ca71e995
...
@@ -107,7 +107,8 @@ CREATE TABLE IF NOT EXISTS `lectures_data` (
...
@@ -107,7 +107,8 @@ CREATE TABLE IF NOT EXISTS `lectures_data` (
`titlefile`
varchar
(
255
)
NOT
NULL
DEFAULT
''
,
`titlefile`
varchar
(
255
)
NOT
NULL
DEFAULT
''
,
`live`
INTEGER
NOT
NULL
DEFAULT
0
,
`live`
INTEGER
NOT
NULL
DEFAULT
0
,
`norecording`
INTEGER
NOT
NULL
DEFAULT
0
,
`norecording`
INTEGER
NOT
NULL
DEFAULT
0
,
`profile`
varchar
(
64
)
`profile`
varchar
(
64
),
`stream_settings`
text
NOT
NULL
DEFAULT
''
);
);
CREATE
TABLE
IF
NOT
EXISTS
`places`
(
CREATE
TABLE
IF
NOT
EXISTS
`places`
(
`place`
varchar
(
20
)
NOT
NULL
PRIMARY
KEY
,
`place`
varchar
(
20
)
NOT
NULL
PRIMARY
KEY
,
...
...
This diff is collapsed.
Click to expand it.
edit.py
+
3
−
1
View file @
ca71e995
...
@@ -45,7 +45,9 @@ editable_tables = {
...
@@ -45,7 +45,9 @@ editable_tables = {
'
jumplist
'
:
{
'
type
'
:
''
},
'
jumplist
'
:
{
'
type
'
:
''
},
'
deleted
'
:
{
'
type
'
:
'
boolean
'
},
'
deleted
'
:
{
'
type
'
:
'
boolean
'
},
'
live
'
:
{
'
type
'
:
'
boolean
'
,
'
description
'
:
'
Ist ein Livestream geplant? Muss gesetzt sein damit der RTMP Stream zugeordnet wird.
'
},
'
live
'
:
{
'
type
'
:
'
boolean
'
,
'
description
'
:
'
Ist ein Livestream geplant? Muss gesetzt sein damit der RTMP Stream zugeordnet wird.
'
},
'
norecording
'
:
{
'
type
'
:
'
boolean
'
,
'
description:
'
:
'
Führt dazu, dass der Termin ausgegraut wird.
'
}},
'
norecording
'
:
{
'
type
'
:
'
boolean
'
,
'
description:
'
:
'
Führt dazu, dass der Termin ausgegraut wird.
'
},
'
stream_settings
'
:
{
'
type
'
:
'
text
'
}
},
'
creationtime_fields
'
:
[
'
course_id
'
,
'
time_created
'
,
'
time_updated
'
]
},
'
creationtime_fields
'
:
[
'
course_id
'
,
'
time_created
'
,
'
time_updated
'
]
},
'
videos
'
:
{
'
videos
'
:
{
'
table
'
:
'
videos_data
'
,
'
table
'
:
'
videos_data
'
,
...
...
This diff is collapsed.
Click to expand it.
templates/course.html
+
12
−
8
View file @
ca71e995
...
@@ -223,10 +223,9 @@ function editstream_dump() {
...
@@ -223,10 +223,9 @@ function editstream_dump() {
$
(
"
#editstream select[name!='']
"
).
each
(
function
()
{
$
(
"
#editstream select[name!='']
"
).
each
(
function
()
{
res
[
$
(
this
).
attr
(
'
name
'
)]
=
$
(
this
).
val
();
res
[
$
(
this
).
attr
(
'
name
'
)]
=
$
(
this
).
val
();
});
});
return
JSON
.
stringify
(
res
)
;
return
res
;
};
};
function
editstream_load
(
data
)
{
function
editstream_load
(
obj
)
{
var
obj
=
JSON
.
parse
(
data
);
$
(
"
#editstream input:checkbox[name!='']
"
).
each
(
function
()
{
$
(
"
#editstream input:checkbox[name!='']
"
).
each
(
function
()
{
if
(
$
(
this
).
attr
(
'
name
'
)
in
obj
)
if
(
$
(
this
).
attr
(
'
name
'
)
in
obj
)
$
(
this
).
prop
(
'
checked
'
,
obj
[
$
(
this
).
attr
(
'
name
'
)]);
$
(
this
).
prop
(
'
checked
'
,
obj
[
$
(
this
).
attr
(
'
name
'
)]);
...
@@ -238,13 +237,18 @@ function editstream_load(data) {
...
@@ -238,13 +237,18 @@ function editstream_load(data) {
};
};
$
(
'
#editstream .source-select
'
).
on
(
'
change
'
,
editstream_update
);
$
(
'
#editstream .source-select
'
).
on
(
'
change
'
,
editstream_update
);
$
(
'
#editstream-submit
'
).
on
(
'
click
'
,
function
()
{
$
(
'
#editstream-submit
'
).
on
(
'
click
'
,
function
()
{
var
tmp
=
editstream_dump
();
moderator
.
api
.
set
(
$
(
'
#editstream
'
).
data
(
'
currentpath
'
),
JSON
.
stringify
(
editstream_dump
()),
true
);
console
.
log
(
tmp
);
$
(
'
#editstream
'
).
modal
(
'
hide
'
);
});
$
(
'
#editstream
'
).
on
(
'
show.bs.modal
'
,
function
(
event
)
{
var
button
=
$
(
event
.
relatedTarget
);
$
(
'
#editstream
'
).
data
(
'
currentpath
'
,
button
.
data
(
'
path
'
));
$
(
"
#editstream-form
"
)[
0
].
reset
();
$
(
"
#editstream-form
"
)[
0
].
reset
();
console
.
log
(
editstream_dump
(
))
;
if
(
button
.
data
(
'
value
'
))
editstream_load
(
tmp
);
editstream_load
(
button
.
data
(
'
value
'
)
);
console
.
log
(
editstream_
dump
()
);
editstream_
update
(
);
});
});
$
(
'
#responsible-select
'
).
multiselect
({
enableCaseInsensitiveFiltering
:
true
,
$
(
'
#responsible-select
'
).
multiselect
({
enableCaseInsensitiveFiltering
:
true
,
maxHeight
:
200
,
numberDisplayed
:
5
,
nonSelectedText
:
'
Niemand
'
,
maxHeight
:
200
,
numberDisplayed
:
5
,
nonSelectedText
:
'
Niemand
'
,
nSelectedText
:
'
ausgewählt
'
,
allSelectedText
:
false
,
nSelectedText
:
'
ausgewählt
'
,
allSelectedText
:
false
,
...
...
This diff is collapsed.
Click to expand it.
templates/macros.html
+
1
−
1
View file @
ca71e995
...
@@ -262,7 +262,7 @@ $('#embedcodebtn').popover(
...
@@ -262,7 +262,7 @@ $('#embedcodebtn').popover(
</li>
</li>
{% if ismod() %}
{% if ismod() %}
<li
class=
"pull-right"
>
<li
class=
"pull-right"
>
<button
class=
"btn btn-default"
data-toggle=
"modal"
data-target=
"#editstream"
>
<button
class=
"btn btn-default"
data-toggle=
"modal"
data-target=
"#editstream"
data-path=
"{{ 'lectures.%i.stream_settings'%lecture.id }}"
data-value=
'{{ lecture.stream_settings|e }}'
>
<span
class=
"glyphicon glyphicon-transfer"
></span>
<span
class=
"glyphicon glyphicon-transfer"
></span>
</button>
</button>
</li>
</li>
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment