-{% load staticfiles %}
+{% load static %}
{% load i18n %}
<!DOCTYPE html>
{% endif %}
</script>
{% endif %}
- <script src="{% url 'django.views.i18n.javascript_catalog' %}"></script>
- <script src="http://cdnjs.cloudflare.com/ajax/libs/ace/1.1.01/ace.js" type="text/javascript" charset="utf-8"></script>
+ <script src="{% url 'javascript_catalog' %}"></script>
{% if DEBUG %}
<link rel="stylesheet/less" type="text/css" href="{% static 'wiki/editor/src/editor/styles/main.less' %}"/>
<script type="text/javascript">less = {relativeUrls: true};</script>
<script src="{% static 'wiki/editor/libs/less-1.3.3.min.js' %}"></script>
<script src="{% static 'wiki/editor/libs/require.js' %}" data-main="{% static 'wiki/editor/src/editor/entrypoint.js' %}" ></script>
+ <script src="{% static 'wiki/editor/libs/jquery-1.9.1.min.js' %}"></script>
+ <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.2/js/bootstrap.min.js"></script>
{% else %}
<link href="{% static 'wiki/build/rng.css' %}" rel="stylesheet">
<script src="{% static 'wiki/build/rng.js' %}"></script>
{% endif %}
+ <script src="{% static 'js/catalogue/catalogue.js' %}"></script> {# for tutorial #}
</head>
<body>
<script type="text/javascript">
},
'console': {
level: 'debug',
- handler: 'console'
+ handler: 'console',
+ formatter: 'simple'
}
},
loggers: {
'': {
level: 'debug',
- handlers: ['sentry', 'console']
+ handlers: ['console', 'sentry']
}
}
},
- metadata: [
- {key: 'audience', values: [
- 'Wych. przedszkolne',
- 'Szkoła podstawowa 1-3',
- 'Szkoła podstawowa 4-6',
- 'Gimnazjum',
- 'Szkoła ponadgimnazjalna',
- 'Szkolnictwo wyższe',
- 'Poziom minimum',
- 'Poziom optimum',
- 'Poziom mistrzowski'
- ]},
- {key: 'creator.scenario'},
- {key: 'creator.methodologist'},
- {key: 'description'},
- {key: 'type', values: ['cource', 'synthetic', 'project']},
- {key: 'subject.curriculum', values: [
- '2012/III/ETYKA/c4',
- '2012/III/ETYKA/t5',
- '2012/III/ETYKA/t9',
- '2012/III/ETYKA/t11',
- '2012/IV/WOS/c4',
- '2012/IV/WOS/c6',
- '2012/IV/WOS/t1',
- '2012/IV/WOS/t2',
- '2012/IV/WOS/t5',
- '2012/IV/INFORMATYKA/c5',
- '2012/II/POLSKI/C3',
- '2012/II/POLSKI/C2',
- '2012/II/POLSKI/C1',
- '2012/II/PLASTYKA/C1',
- '2012/II/PLASTYKA/C2',
- '2012/II/PLASTYKA/C3',
- '2012/II/ETYKA/C4',
- '2012/IV/WOS/c6/roz',
- '2012/II/WYCHOWANIE_DO_ZYCIA_W_RODZINIE/T11',
- '2012/II/POLSKI/T3',
- '2012/II/POLSKI/T5',
- '2012/II/POLSKI/T4',
- '2012/II/POLSKI/T7',
- '2012/II/POLSKI/T9',
- '2012/II/POLSKI/T10',
- '2012/II/POLSKI/T11',
- '2012/II/POLSKI/T12',
- '2012/II/POLSKI/T13',
- '2012/II/POLSKI/T14',
- '2012/II/POLSKI/T15',
- '2012/II/POLSKI/T16',
- '2012/II/POLSKI/T17',
- '2012/II/POLSKI/T18',
- '2012/II/PLASTYKA/T1',
- '2012/II/PLASTYKA/T2',
- '2012/II/PLASTYKA/T3',
- '2012/II/POLSKI/T6',
- '2012/II/ZAJECIA_KOMPUTEROWE/T6',
- '2012/II/ZAJECIA_KOMPUTEROWE/T7',
- '2012/II/POLSKI/t1',
- '2012/II/ZAJECIA_KOMPUTEROWE/T4',
- '2012/II/WYCHOWANIE_DO_ZYCIA_W_RODZINIE/T13',
- '2012/II/WYCHOWANIE_DO_ZYCIA_W_RODZINIE/T10',
- '2012/IV/WOS/t3',
- '2012/IV/WOS/t2/roz',
- '2012/IV/INFORMATYKA/t1',
- '2012/IV/INFORMATYKA/t7',
- '2012/IV/ETYKA/c2',
- '2012/IV/ETYKA/t4',
- '2012/IV/WOS/t8/roz',
- '2012/IV/WOS/c3',
- '2012/IV/ETYKA/c1',
- '2012/III/POLSKI/c1',
- '2012/III/POLSKI/c2',
- '2012/III/POLSKI/c3',
- '2012/III/PLASTYKA/c1',
- '2012/III/PLASTYKA/c2',
- '2012/III/PLASTYKA/c3',
- '2012/III/WOS/c1',
- '2012/III/WOS/c2',
- '2012/III/WOS/c3',
- '2012/III/WOS/c4',
- '2012/III/WOS/c5',
- '2012/III/WOS/t1',
- '2012/III/WOS/t2',
- '2012/III/WOS/t3',
- '2012/III/WOS/t4',
- '2012/III/WOS/t5',
- '2012/III/WOS/t6',
- '2012/III/WOS/t9',
- '2012/III/WOS/t10',
- '2012/III/WOS/t11',
- '2012/III/WOS/t24',
- '2012/III/WOS/t25',
- '2012/III/WOS/t26',
- '2012/III/INFORMATYKA/c1',
- '2012/III/INFORMATYKA/c2',
- '2012/III/INFORMATYKA/c5',
- '2012/III/ETYKA/c1',
- '2012/III/ETYKA/t1',
- '2012/IV/INFORMATYKA/c2',
- '2012/IV/INFORMATYKA/c4',
- '2012/IV/INFORMATYKA/t2',
- '2012/IV/INFORMATYKA/t3',
- '2012/IV/INFORMATYKA/t4',
- '2012/IV/POLSKI/c1',
- '2012/IV/POLSKI/c2',
- '2012/IV/POLSKI/c3',
- '2012/IV/INFORMATYKA/c2',
- '2012/IV/INFORMATYKA/c4',
- '2012/IV/INFORMATYKA/t2',
- '2012/IV/INFORMATYKA/t3',
- '2012/IV/INFORMATYKA/t4',
- '2012/IV/POLSKI/c1',
- '2012/IV/POLSKI/c2',
- '2012/IV/POLSKI/c3',
- '2012/IV/WOK/c1',
- '2012/IV/WOK/c2',
- '2012/IV/WOK/c3',
- '2012/IV/ETYKA/t11',
- '2012/IV/WOS/c1',
- '2012/IV/WOS/t13/roz',
- '2012/IV/WOS/c2',
- '2012/IV/ETYKA/t6',
- '2012/IV/ETYKA/t8',
- '2012/II/ZAJECIA_KOMPUTEROWE/c1',
- '2012/II/ZAJECIA_KOMPUTEROWE/c2',
- '2012/II/ZAJECIA_KOMPUTEROWE/c3',
- '2012/II/ZAJECIA_KOMPUTEROWE/c5',
- '2012/II/HISTORIA_I_SPOLECZENSTWO/c4',
- '2012/II/HISTORIA_I_SPOLECZENSTWO/t1',
- '2012/II/HISTORIA_I_SPOLECZENSTWO/t4',
- '2012/II/HISTORIA_I_SPOLECZENSTWO/t5',
- '2012/II/ETYKA/c1',
- '2012/II/ETYKA/c3',
- '2012/II/ETYKA/c5',
- '2012/II/ETYKA/t2',
- '2012/II/ETYKA/t3',
- '2012/II/ETYKA/t4',
- '2012/II/ETYKA/t5',
- '2012/II/ETYKA/t6',
- '2012/II/ETYKA/t7',
- '2012/IV/WOS/t6',
- '2012/IV/WOS/t10/roz',
- '2012/IV/WOS/t14/roz',
- '2012/IV/WOS/t15/roz',
- '2012/IV/WOS/t27/roz',
- '2012/IV/WOS/t32/roz',
- '2012/IV/WOS/t36/roz',
- '2012/IV/INFORMATYKA/c1',
- '2012/II/HISTORIA_I_SPOLECZENSTWO/t7'
- ]},
- {key: 'subject.competence', values: [
- 'Źródła informacji',
- 'Wyszukiwanie informacji',
- 'Podejście krytyczne do informacji',
- 'Wykorzystanie informacji',
- 'Komunikacja',
- 'Otoczenie',
- 'Wizerunek',
- 'Kultura komunikacji medialnej',
- 'Funkcje komunikatów medialnych',
- 'Językowa natura mediów',
- 'Tworzenie',
- 'Przetwarzanie',
- 'Prezentowanie',
- 'Wyzwania etyczne a normy prawa w mediach i komunikacji',
- 'Wyzwania etyczne a treści mediów i komunikacji',
- 'Komunikacja i media jako przedmiot refleksji etycznej',
- 'Wyzwania etyczne w relacjach przez media',
- 'Bezpieczeństwo komunikacji, pracy i transakcji',
- 'Uzależnienia i higiena korzystania z mediów',
- 'Anonimowość',
- 'Ochrona prywatności i wizerunku',
- 'Nadzór nad siecią',
- 'Rodzaje, źródła i praktyka stosowania prawa w kontekście mediów',
- 'Prawa osób niepełnosprawnych',
- 'Prawo mediów i media publiczne',
- 'Ochrona danych osobowych',
- 'Prawa wyłączne i monopole intelektualne',
- 'Prawo telekomunikacyjne',
- 'Media a prawa człowieka, obywatela i dziecka',
- 'Rynek mediów',
- 'Informacja jako dobro ekonomiczne',
- 'Finansowanie mediów i wybrane sposoby zarabiania w nowych mediach'
- ]}
- ],
-
documentSummaryView: {
title: '{% trans 'Informations about lesson' %}',
properties: [
- {name: 'stage', label: '{% trans 'Stage' %}'},
+ {name: 'version', label: '{% trans 'Version' %}'},
+ {name: 'stage_name', label: '{% trans 'Stage' %}'},
{name: 'assignment', label: '{% trans 'Assignment' %}'}
]
},
+
+ plugins: {
+ core: {
+ templates: {{serialized_templates|safe}},
+ metadata: [
+ {key: 'audience', values: [
+ '3-6', '6-9', '9-12', '12-18', '18+', 'Adults'
+ ]},
+ {key: 'creator'},
+ {key: 'description'},
+ {key: 'publisher'},
+ {key: 'language'},
+ {key: 'rights'},
+ {key: 'relation.coverimage.url', isFile: true}
+ ]
+ }
+ },
+
+ toolbar: [
+ ['core.undo', 'core.redo'],
+
+ [
+ {actionName: 'core.switchToHeader'},
+ {actionName: 'core.switchToParagraph'},
+ {actionName: 'core.switchToImage'},
+ {actionName: 'core.switchToVideo'},
+ 'core.toggleBulletList', 'core.toggleEnumList'
+ ],
+
+ [
+ {actionName: 'core.emphasis', actionConfig: {label: '{% trans "emphasis" %}'}},
+ {actionName: 'core.cite', actionConfig: {label: '{% trans "cite" %}'}},
+ {actionName: 'core.link', actionConfig: {label: '{% trans "link" %}'}}
+ ],
+
+ //['core.template'],
+
+ ['core.showMetadataEditor']
+ /*[
+ 'core.insertOrderExercise',
+ 'core.insertChoiceSingleExercise',
+ 'core.insertChoiceMultiExercise',
+ 'core.insertChoiceTrueOrFalseExercise',
+ 'core.insertGapsExercise',
+ 'core.insertReplaceExercise'
+ ]*/
+ ],
documentSaveUrl: function(id) { return '/editor/text/' + id + '/'; },
documentHistoryUrl: function(id) { return '/editor/history/' + id + '/'},
documentDiffUrl: function(id) { return '/editor/diff/' + id + '/'; },
documentRestoreUrl: function(id) { return '/editor/revert/' + id + '/'},
+ documentPublishUrl: '{% url "catalogue_publish" pk %}',
+
+ documentScheduleUrl: '{% url "catalogue_book_schedule" pk %}',
+ documentForkUrl: '{% url "catalogue_fork" pk %}',
+ documentGalleryUrl: '{% url "catalogue_book_gallery" pk %}',
+
+ documentAttachmentUrl: function(attachmentName) {
+ return '{{MEDIA_URL}}uploads/{{ pk }}/' + attachmentName;
+ },
+ documentUrl: function(id, version) {
+ var url = '{% url 'wiki_editor' pk %}';
+ if(version) {
+ url = url + '?version=' + version;
+ }
+ return url;
+ },
+ documentPreviewUrl: function(id) { return '/documents/{{ pk }}/rev' + id + '/preview/' },
+ documentPreviewMainUrl: function() { return '/documents/{{ pk }}/preview/' },
documentSaveForm: {
fields: [
{label: '{{forms.text_save.comment.label}}', name: '{{forms.text_save.comment.html_name}}', type: 'textarea'},
- {label: '{{forms.text_save.stage_completed.label}}', name: '{{forms.text_save.stage_completed.html_name}}', type: 'select', options: [
- {% for value,text in tags %}
+ {label: '{{forms.text_save.stage.label}}', name: '{{forms.text_save.stage.html_name}}', type: 'select', options: [
+ {% for value, text in forms.text_save.stage.field.choices %}
{value:'{{value|default:''}}', text:'{{text}}'} {% if not forloop.last %}, {% endif %}
{% endfor %}
- ], description: '{{forms.text_save.stage_completed.help_text}}'},
+ ], description: '{{forms.text_save.stage.help_text}}'}
],
content_field_name: '{{forms.text_save.text.html_name}}',
version_field_name: '{{forms.text_save.parent_revision.html_name}}'
{label: '{{forms.text_revert.comment.label}}', name: '{{forms.text_revert.comment.html_name}}', type: 'textarea'}
],
version_field_name: '{{forms.text_revert.revision.html_name}}'
- }
+ },
+
+ documentPublishForm: {
+ fields: [
+ ],
+ revision_field_name: '{{forms.text_publish.revision.html_name}}'
+ },
+
+ tutorial: [
+ {name: 'editor', text: '{% trans "Edit your document text." %}'},
+ {name: 'sourceEditor', text: '{% trans "View the xml code of your document." %}'},
+ {name: 'history', text: '{% trans "Here you can view the change history." %}'},
+ {name: 'switchToHeader', text: '{% trans "Place the mouse cursor at the end of the line after which you want to add a new header, and press Enter. Click “header” to switch the new paragraph into a header." %}'},
+ {name: 'switchToParagraph', text: '{% trans "Use this option to switch a header to a paragraph." %}'},
+ {name: 'switchToImage', text: '{% trans "Add graphics to your document. Click “image” to make a frame, then click this frame to insert an image file (JPG, PNG, GIF, SVG)." %}'},
+ {name: 'switchToVideo', text: '{% trans "Add a video material to your document to make it more attractive. Paste the http link from a YouTube channel." %}'},
+ {name: 'toggleBulletList', text: '{% trans "Select this option to create a bullet list. Press Enter to add another item. To end the list, place the cursor at the end of the last item, and press Enter twice." %}'},
+ {name: 'toggleEnumList', text: '{% trans "Create numbered lists. To end the list, set the cursor at the end of the last item, and press Enter twice." %}'},
+ {name: 'emphasis', text: '{% trans "Emphasize some text by using boldface. To turn it off, click the specific word and then click “emphasis”." %}'},
+ {name: 'cite', text: '{% trans "Select some text and click “cite” to make it italic. To turn it off, set the cursor on the specific word then click “cite” again." %}'},
+ {name: 'link', text: '{% trans "Paste the link and select it, or select text and click “link” to add a hyperlink or to link additional materials (ODT, DOC, PDF)." %}'},
+ {name: 'showMetadataEditor', text: '{% trans "Here you can review and edit metadata. In “Attachments” you can add or change the cover of your document." %}'},
+ {name: 'preview', text: '{% trans "Review your document before publication." %}'},
+ {name: 'attachments', text: '{% trans "Here you can add other important materials to this document (audio files, JPG, PNG, ODT, PDF etc.)" %}'},
+ {name: 'draft', text: '{% trans "Select this option if you do not like your unsaved changes. Warning! Dropped changes will be lost and they cannot be restored." %}'},
+ {name: 'comment', text: '{% trans "If you work on a document with a group, you can leave comments on each line of the document. Your comment will appear as a “bubble” on the left." %}'},
+ {name: 'save', text: '{% trans "Click “Save” to save all the changes in your document. Remember to select the appropriate stage of the work on the document (Draft, Comments, Comments review, Proofreading, Publication)." %}'},
+ {name: 'mainpage', text: '{% trans "Click on the MIL/PEER logo to open the home page in a new window." %}'},
+ {name: 'exit', text: '{% trans "“Exit” will take you to the main page." %}'}
+ ]
};
{% if can_pubmark %}
{% endif %}
{% autoescape off%}
- var data = {{serialized_document_data}},
- templates = {{serialized_templates}}
+ var data = {{serialized_document_data}};
{%endautoescape%}
var editor_init = function(Editor) {
Editor.setBootstrappedData('data', data);
- Editor.setBootstrappedData('documentToolbar', templates);
Editor.start(config);
};
+
</script>
+ <div id="tuton"></div>
<div id="editor_root"></div>
</body>
</html>