Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
ConceptXBlock
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
ConceptXBlock
Commits
3073110c
Commit
3073110c
authored
Mar 20, 2014
by
Piotr Mitros
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rename xoncept to concept. More traditional name is nicer
parent
2602b476
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
15 additions
and
15 deletions
+15
-15
concept/__init__.py
+1
-0
concept/concept.py
+8
-8
concept/static/css/concept.css
+0
-0
concept/static/html/concept.html
+0
-0
concept/static/js/concept.js
+0
-0
setup.py
+6
-6
xoncept/__init__.py
+0
-1
No files found.
concept/__init__.py
0 → 100644
View file @
3073110c
from
.concept
import
ConceptXBlock
xoncept/x
oncept.py
→
concept/c
oncept.py
View file @
3073110c
...
@@ -9,9 +9,9 @@ from xblock.fields import Scope, Integer, String
...
@@ -9,9 +9,9 @@ from xblock.fields import Scope, Integer, String
from
xblock.fragment
import
Fragment
from
xblock.fragment
import
Fragment
class
X
onceptXBlock
(
XBlock
):
class
C
onceptXBlock
(
XBlock
):
"""
"""
This XBlock
will play an MP3 file as an HTML5 Xoncept element
.
This XBlock
allows concept tagging in a course
.
"""
"""
# Fields are defined on the class. You can access them in your code as
# Fields are defined on the class. You can access them in your code as
...
@@ -49,24 +49,24 @@ class XonceptXBlock(XBlock):
...
@@ -49,24 +49,24 @@ class XonceptXBlock(XBlock):
# TO-DO: change this view to display your data your own way.
# TO-DO: change this view to display your data your own way.
def
student_view
(
self
,
context
=
None
):
def
student_view
(
self
,
context
=
None
):
"""
"""
The primary view of the
X
onceptXBlock, shown to students
The primary view of the
C
onceptXBlock, shown to students
when viewing courses.
when viewing courses.
"""
"""
print
"HERE"
,
self
.
concept_map
print
"HERE"
,
self
.
concept_map
html
=
self
.
resource_string
(
"static/html/
x
oncept.html"
)
#.replace("PLACEHOLDER_FOR_CONCEPT_MAP",json.dumps(self.concept_map))
html
=
self
.
resource_string
(
"static/html/
c
oncept.html"
)
#.replace("PLACEHOLDER_FOR_CONCEPT_MAP",json.dumps(self.concept_map))
#print self.server
#print self.server
#print html.format
#print html.format
cm
=
self
.
concept_map
cm
=
self
.
concept_map
print
"Read"
,
cm
print
"Read"
,
cm
frag
=
Fragment
(
html
.
replace
(
"PLACEHOLDER_FOR_CONCEPT_MAP"
,
cm
)
.
replace
(
"SERVER"
,
self
.
server
))
#)#format(server = self.server, concept_map = cm))
frag
=
Fragment
(
html
.
replace
(
"PLACEHOLDER_FOR_CONCEPT_MAP"
,
cm
)
.
replace
(
"SERVER"
,
self
.
server
))
#)#format(server = self.server, concept_map = cm))
frag
.
add_css_url
(
"https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/themes/smoothness/jquery-ui.css"
)
frag
.
add_css_url
(
"https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/themes/smoothness/jquery-ui.css"
)
frag
.
add_css
(
self
.
resource_string
(
"static/css/
x
oncept.css"
))
frag
.
add_css
(
self
.
resource_string
(
"static/css/
c
oncept.css"
))
frag
.
add_javascript_url
(
"http://builds.handlebarsjs.com.s3.amazonaws.com/handlebars-v1.3.0.js"
)
frag
.
add_javascript_url
(
"http://builds.handlebarsjs.com.s3.amazonaws.com/handlebars-v1.3.0.js"
)
# frag.add_javascript_url("https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js")
# frag.add_javascript_url("https://ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js")
frag
.
add_javascript_url
(
"https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js"
)
frag
.
add_javascript_url
(
"https://ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js"
)
frag
.
add_javascript
(
self
.
resource_string
(
"static/js/
x
oncept.js"
))
frag
.
add_javascript
(
self
.
resource_string
(
"static/js/
c
oncept.js"
))
frag
.
initialize_js
(
'ConceptXBlock'
)
frag
.
initialize_js
(
'ConceptXBlock'
)
print
self
.
xml_text_content
()
print
self
.
xml_text_content
()
...
@@ -78,9 +78,9 @@ class XonceptXBlock(XBlock):
...
@@ -78,9 +78,9 @@ class XonceptXBlock(XBlock):
def
workbench_scenarios
():
def
workbench_scenarios
():
"""A canned scenario for display in the workbench."""
"""A canned scenario for display in the workbench."""
return
[
return
[
(
"
X
onceptXBlock"
,
(
"
C
onceptXBlock"
,
"""<vertical_demo>
"""<vertical_demo>
<
Xoncept server="http://pmitros.edx.org:8000/"> </X
oncept>
<
Concept server="http://pmitros.edx.org:8000/"> </C
oncept>
</vertical_demo>
</vertical_demo>
"""
),
"""
),
]
]
xoncept/static/css/x
oncept.css
→
concept/static/css/c
oncept.css
View file @
3073110c
File moved
xoncept/static/html/x
oncept.html
→
concept/static/html/c
oncept.html
View file @
3073110c
File moved
xoncept/static/js/x
oncept.js
→
concept/static/js/c
oncept.js
View file @
3073110c
File moved
setup.py
View file @
3073110c
"""Setup for
x
oncept XBlock."""
"""Setup for
c
oncept XBlock."""
import
os
import
os
from
setuptools
import
setup
from
setuptools
import
setup
...
@@ -15,19 +15,19 @@ def package_data(pkg, root):
...
@@ -15,19 +15,19 @@ def package_data(pkg, root):
setup
(
setup
(
name
=
'
x
oncept-xblock'
,
name
=
'
c
oncept-xblock'
,
version
=
'0.1'
,
version
=
'0.1'
,
description
=
'
x
oncept XBlock'
,
# TODO: write a better description.
description
=
'
c
oncept XBlock'
,
# TODO: write a better description.
packages
=
[
packages
=
[
'
x
oncept'
,
'
c
oncept'
,
],
],
install_requires
=
[
install_requires
=
[
'XBlock'
,
'XBlock'
,
],
],
entry_points
=
{
entry_points
=
{
'xblock.v1'
:
[
'xblock.v1'
:
[
'
xoncept = xoncept:X
onceptXBlock'
,
'
concept = concept:C
onceptXBlock'
,
]
]
},
},
package_data
=
package_data
(
"
x
oncept"
,
"static"
),
package_data
=
package_data
(
"
c
oncept"
,
"static"
),
)
)
xoncept/__init__.py
deleted
100644 → 0
View file @
2602b476
from
.xoncept
import
XonceptXBlock
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