After this merge, the teacher will have access to the following features:
A list of all activities and a list of all scenarios in database
Teacher can, from the list page, add, delete or edit existing activities or scenarios in database
Scenarios are created/edited as Raphael graphs with the 'graphs/graph-editor.html' template, using the javascript functions contained in 'graphs/graphs/grapheditor'
List of additions/deletions by files:
graphs/graphs/...
templates/graph-editor.html: delete the template
urls.py: add new patterns: scenario-creator, scenario-editor, activity-creator, activity-editor, activity-delete, activity-list
views.py: add new views: ScenarioCreateView, ScenarioUpdateView, ActivityCreateView and ActivityDeleteView
models.py: add raphaelJson text field to Scenario model
graphs/graphs/grapheditor/...
init.js: main script for graph-editor.html, global variables and functions
modeAdd.js: functions called when adding activity
modeMove.js: functions called when moving activity
modeConnect.js: functions called when adding connection
modeEdit.js: functions called when editing activity
modeErase.js: functions called when deleting activity/connections
modeLoad.js: functions called for loading a scenario
modeSave.js: functions called before saving a scenario in database
graphs/templates/...
teacher-base.html: add link to activity-list, delete link to scenario-creator
activity-list.html: template for activity-list (table)
activity-editor.html: template for activity-creator (form)
activity-delete.html: template for activity-delete (confirmation page)
scenario-list.html: links to scenario-creator and scenario-editor
graph-editor.html: html template for scenario-creator and scenario-editor
graphs/static/js/
graphs/static/js/raphael.json.js: script needed to serialize the graph in json
After this merge, the teacher will have access to the following features:
List of additions/deletions by files:
graphs/graphs/...
templates/graph-editor.html: delete the template urls.py: add new patterns: scenario-creator, scenario-editor, activity-creator, activity-editor, activity-delete, activity-list views.py: add new views: ScenarioCreateView, ScenarioUpdateView, ActivityCreateView and ActivityDeleteView models.py: add raphaelJson text field to Scenario model
graphs/graphs/grapheditor/...
init.js: main script for graph-editor.html, global variables and functions modeAdd.js: functions called when adding activity modeMove.js: functions called when moving activity modeConnect.js: functions called when adding connection modeEdit.js: functions called when editing activity modeErase.js: functions called when deleting activity/connections modeLoad.js: functions called for loading a scenario modeSave.js: functions called before saving a scenario in database
graphs/templates/...
teacher-base.html: add link to activity-list, delete link to scenario-creator activity-list.html: template for activity-list (table) activity-editor.html: template for activity-creator (form) activity-delete.html: template for activity-delete (confirmation page) scenario-list.html: links to scenario-creator and scenario-editor graph-editor.html: html template for scenario-creator and scenario-editor
graphs/static/js/
graphs/static/js/raphael.json.js: script needed to serialize the graph in json