Skip to content

Commit

Permalink
Merge pull request #45 from EmpowrOrg/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
dri94 authored Oct 9, 2022
2 parents 644003a + e2c2141 commit 961fa50
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ An XBlock for Empowr's course platform that allows for the input and checking of

## TODO
- Add support for all CodeMirror languages. This is an easy task, just tedious.
- Fix CSS. The Bootstrap css interferes with Open Edx CSS. This causes weird styling on pages that show the plugin.

## Installation

Expand Down
16 changes: 6 additions & 10 deletions swiftplugin/swiftplugin/swiftplugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,6 @@ class SwiftPluginXBlock(
TO-DO: document what your XBlock does.
"""

code = String(
default="",
scope=Scope.user_state,
help="User code",
)

starter_code = String(
default="",
scope=Scope.settings,
Expand All @@ -44,13 +38,13 @@ class SwiftPluginXBlock(

api_url_submit = String(
default="",
scope=Scope.settings,
scope=Scope.content,
help="URL api used to check the code (submit final response)"
)

api_url_run = String(
default="",
scope=Scope.settings,
scope=Scope.content,
help="URL api used to run the code (run code by api)"
)

Expand All @@ -62,7 +56,7 @@ class SwiftPluginXBlock(

api_key = String(
default="",
scope=Scope.preferences,
scope=Scope.content,
help="Key to send to API",
)

Expand All @@ -81,6 +75,7 @@ class SwiftPluginXBlock(

has_score = True
attempt = 1
code = ""

problem_solution = String(
default="",
Expand All @@ -102,7 +97,8 @@ class SwiftPluginXBlock(
'problem_solution',
'problem_language',
'api_url_run',
'api_url_submit'
'api_url_submit',
'api_key'
]

def resource_string(self, path):
Expand Down

0 comments on commit 961fa50

Please sign in to comment.