From: Radek Czajka {% trans "Append to other book" %} {% trans "Last published" %}:
- {% if book.last_published %}
- {{ book.last_published }}
- {% else %}
- —
- {% endif %}
-
- {% trans "Full XML" %} {% trans "This book can't be published yet, because:" %} {% trans "No books found." %}
-{% trans "Please submit a ZIP with UTF-8 encoded XML files. Files not ending with {% trans "There have been some errors. No files have been added to the repository." %}
- {% trans "Files have been successfully uploaded to the repository." %} {% trans "Files skipped due to no {% trans "Last published" %}:
- {% if object.last_published %}
- {{ object.last_published }}
- {% else %}
- —
- {% endif %}
- {% trans "This book can't be published yet, because:" %} {% trans "No images found." %} KsiÄ
żki zostaÅy oznaczone. {% trans "None" %}.xml
will be ignored."
-msgstr ""
-"ProszÄ wskazaÄ archiwum ZIP z plikami XML w kodowaniu UTF-8. Pliki nie "
-"koÅczÄ
ce siÄ na .xml
zostanÄ
zignorowane."
-
-#: templates/catalogue/document_upload.html:20
-#: templates/catalogue/upload_pdf.html:16 templatetags/catalogue.py:36
-msgid "Upload"
-msgstr "ZaÅaduj"
-
-#: templates/catalogue/document_upload.html:27
-msgid ""
-"There have been some errors. No files have been added to the repository."
-msgstr "WystÄ
piÅy bÅÄdy. Å»adne pliki nie zostaÅy dodane do repozytorium."
-
-#: templates/catalogue/document_upload.html:28
-msgid "Offending files"
-msgstr "BÅÄdne pliki"
-
-#: templates/catalogue/document_upload.html:36
-msgid "Correct files"
-msgstr "Poprawne pliki"
-
-#: templates/catalogue/document_upload.html:47
-msgid "Files have been successfully uploaded to the repository."
-msgstr "Pliki zostaÅy dodane do repozytorium."
-
-#: templates/catalogue/document_upload.html:48
-msgid "Uploaded files"
-msgstr "Dodane pliki"
-
-#: templates/catalogue/document_upload.html:58
-msgid "Skipped files"
-msgstr "PominiÄte pliki"
-
-#: templates/catalogue/document_upload.html:59
-msgid "Files skipped due to no .xml
extension"
-msgstr "Pliki pominiÄte z powodu braku rozszerzenia .xml
."
-
-#: templates/catalogue/image_detail.html:26
-msgid "Editor"
-msgstr "Edytor"
-
-#: templates/catalogue/image_detail.html:28
-msgid "Proceed to the editor."
-msgstr "Przejdź do edytora."
-
-#: templates/catalogue/image_list.html:8
-msgid "Image list"
-msgstr "Lista obrazów"
-
-#: templates/catalogue/image_short.html:6
-msgid "Image settings"
-msgstr "Ustawienia obrazu"
-
-#: templates/catalogue/image_table.html:23
-#: templates/catalogue/book_list/book_list.html:28
-msgid "Search in book titles"
-msgstr "Szukaj w tytuÅach ksiÄ
żek"
-
-#: templates/catalogue/image_table.html:28
-#: templates/catalogue/book_list/book_list.html:33
-msgid "stage"
-msgstr "etap"
-
-#: templates/catalogue/image_table.html:30
-#: templates/catalogue/image_table.html:41
-#: templates/catalogue/image_table.html:60
-#: templates/catalogue/book_list/book_list.html:35
-#: templates/catalogue/book_list/book_list.html:46
-#: templates/catalogue/book_list/book_list.html:67
-msgid "none"
-msgstr "brak"
-
-#: templates/catalogue/image_table.html:39
-#: templates/catalogue/book_list/book_list.html:44
-msgid "editor"
-msgstr "redaktor"
-
-#: templates/catalogue/image_table.html:50
-#: templates/catalogue/book_list/book_list.html:57
-msgid "status"
-msgstr "status"
-
-#: templates/catalogue/image_table.html:77
-#, python-format
-msgid "%(c)s image"
-msgid_plural "%(c)s images"
-msgstr[0] "%(c)s obraz"
-msgstr[1] "%(c)s obrazy"
-msgstr[2] "%(c)s obrazów"
-
-#: templates/catalogue/image_table.html:82
-msgid "No images found."
-msgstr "Nie znaleziono obrazów."
-
-#: templates/catalogue/image_table.html:88
-#: templates/catalogue/book_list/book_list.html:102
-msgid "Set stage"
-msgstr "Ustaw etap"
-
-#: templates/catalogue/image_table.html:89
-#: templates/catalogue/book_list/book_list.html:103
-msgid "Set user"
-msgstr "Przypisz redaktora"
-
-#: templates/catalogue/image_table.html:91
-#: templates/catalogue/book_list/book_list.html:105
-msgid "Project"
-msgstr "Projekt"
-
-#: templates/catalogue/image_table.html:92
-#: templates/catalogue/book_list/book_list.html:106
-msgid "More users"
-msgstr "WiÄcej użytkowników"
-
-#: templates/catalogue/my_page.html:15 templatetags/catalogue.py:27
-msgid "My page"
-msgstr "Moja strona"
-
-#: templates/catalogue/my_page.html:24
-msgid "Your last edited documents"
-msgstr "Twoje ostatnie edycje"
-
-#: templates/catalogue/my_page.html:39 templates/catalogue/user_page.html:16
-msgid "Recent activity for"
-msgstr "Ostatnia aktywnoÅÄ dla:"
-
-#: templates/catalogue/upload_pdf.html:5 templates/catalogue/upload_pdf.html:11
-msgid "PDF file upload"
-msgstr "Åadowanie pliku PDF"
-
-#: templates/catalogue/user_list.html:7 templates/catalogue/user_list.html:12
-#: templatetags/catalogue.py:32
-msgid "Users"
-msgstr "Użytkownicy"
-
-#: templates/catalogue/wall.html:30
-msgid "not logged in"
-msgstr "nie zalogowany"
-
-#: templates/catalogue/wall.html:35
-msgid "No activity recorded."
-msgstr "Nie zanotowano aktywnoÅci."
-
-#: templates/catalogue/book_list/book.html:8
-#: templates/catalogue/book_list/book.html:29
-msgid "Book settings"
-msgstr "Ustawienia ksiÄ
żki"
-
-#: templates/catalogue/book_list/book_list.html:23
-msgid "Show hidden books"
-msgstr "Pokaż ukryte ksiÄ
żki"
-
-#: templates/catalogue/book_list/book_list.html:91
-#, python-format
-msgid "%(c)s book"
-msgid_plural "%(c)s books"
-msgstr[0] "%(c)s ksiÄ
żka"
-msgstr[1] "%(c)s ksiÄ
żki"
-msgstr[2] "%(c)s ksiÄ
żek"
-
-#: templates/catalogue/book_list/book_list.html:96
-msgid "No books found."
-msgstr "Nie znaleziono ksiÄ
żek."
-
-#: templatetags/book_list.py:84 templatetags/book_list.py:152
-msgid "publishable"
-msgstr "do publikacji"
-
-#: templatetags/book_list.py:85 templatetags/book_list.py:153
-msgid "changed"
-msgstr "zmienione"
-
-#: templatetags/book_list.py:86 templatetags/book_list.py:154
-msgid "published"
-msgstr "opublikowane"
-
-#: templatetags/book_list.py:87 templatetags/book_list.py:155
-msgid "unpublished"
-msgstr "nie opublikowane"
-
-#: templatetags/book_list.py:88 templatetags/book_list.py:156
-msgid "empty"
-msgstr "puste"
-
-#: templatetags/catalogue.py:30
-msgid "All"
-msgstr "Wszystkie"
-
-#: templatetags/catalogue.py:31
-msgid "Images"
-msgstr "Obrazy"
-
-#: templatetags/catalogue.py:35
-msgid "Add"
-msgstr "Dodaj"
-
-#: templatetags/catalogue.py:38
-msgid "Covers"
-msgstr "OkÅadki"
-
-#: templatetags/wall.py:49 templatetags/wall.py:78
-msgid "Related edit"
-msgstr "PowiÄ
zana zmiana"
-
-#: templatetags/wall.py:51 templatetags/wall.py:80
-msgid "Edit"
-msgstr "Zmiana"
-
-#: templatetags/wall.py:150
-msgid "Comment"
-msgstr "Komentarz"
-
-#~ msgid "Comments"
-#~ msgstr "Komentarze"
-
-#~ msgid "Mark publishable"
-#~ msgstr "Oznacz do publikacji"
-
-#~ msgid "Mark not publishable"
-#~ msgstr "Odznacz do publikacji"
-
-#~ msgid "Other user"
-#~ msgstr "Inny użytkownik"
-
-#~ msgid "Admin"
-#~ msgstr "Administracja"
-
-#~ msgid "edit"
-#~ msgstr "edytuj"
-
-#~ msgid "add basic document structure"
-#~ msgstr "dodaj podstawowÄ
strukturÄ dokumentu"
-
-#~ msgid "change master tag to"
-#~ msgstr "zmieÅ tak master na"
-
-#~ msgid "add begin trimming tag"
-#~ msgstr "dodaj poczÄ
tkowy ogranicznik"
-
-#~ msgid "add end trimming tag"
-#~ msgstr "dodaj koÅcowy ogranicznik"
-
-#~ msgid "unstructured text"
-#~ msgstr "tekst bez struktury"
-
-#~ msgid "unknown XML"
-#~ msgstr "nieznany XML"
-
-#~ msgid "broken document"
-#~ msgstr "uszkodzony dokument"
-
-#~ msgid "Apply fixes"
-#~ msgstr "Wykonaj zmiany"
-
-#~ msgid "Can mark for publishing"
-#~ msgstr "Oznacza do publikacji"
-
-#~ msgid "Author"
-#~ msgstr "Autor"
-
-#~ msgid "Your name"
-#~ msgstr "ImiÄ i nazwisko"
-
-#~ msgid "Author's email"
-#~ msgstr "E-mail autora"
-
-#~ msgid "Your email address, so we can show a gravatar :)"
-#~ msgstr "Adres e-mail, żebyÅmy mogli pokazaÄ gravatar :)"
-
-#~ msgid "Describe changes you made."
-#~ msgstr "Opisz swoje zmiany"
-
-#~ msgid "Completed"
-#~ msgstr "UkoÅczono"
-
-#~ msgid "If you completed a life cycle stage, select it."
-#~ msgstr "JeÅli zostaÅ ukoÅczony etap prac, wskaż go."
-
-#~ msgid "Describe the reason for reverting."
-#~ msgstr "Opisz powód przywrócenia."
-
-#~ msgid "theme"
-#~ msgstr "motyw"
-
-#~ msgid "themes"
-#~ msgstr "motywy"
-
-#~ msgid "Tag added"
-#~ msgstr "Dodano tag"
-
-#~ msgid "Revision marked"
-#~ msgstr "Wersja oznaczona"
-
-#~ msgid "New version"
-#~ msgstr "Nowa wersja"
-
-#~ msgid "Click to open/close gallery"
-#~ msgstr "Kliknij, aby (ro)zwinÄ
Ä galeriÄ"
-
-#~ msgid "Help"
-#~ msgstr "Pomoc"
-
-#~ msgid "Version"
-#~ msgstr "Wersja"
-
-#~ msgid "Unknown"
-#~ msgstr "nieznana"
-
-#~ msgid "Save attempt in progress"
-#~ msgstr "Trwa zapisywanie"
-
-#~ msgid "There is a newer version of this document!"
-#~ msgstr "Istnieje nowsza wersja tego dokumentu!"
-
-#~ msgid "Clear filter"
-#~ msgstr "WyczyÅÄ filtr"
-
-#~ msgid "Cancel"
-#~ msgstr "Anuluj"
-
-#~ msgid "Revert"
-#~ msgstr "PrzywróÄ"
-
-#~ msgid "all"
-#~ msgstr "wszystkie"
-
-#~ msgid "Annotations"
-#~ msgstr "Przypisy"
-
-#~ msgid "Previous"
-#~ msgstr "Poprzednie"
-
-#~ msgid "Next"
-#~ msgstr "NastÄpne"
-
-#~ msgid "Zoom in"
-#~ msgstr "PowiÄksz"
-
-#~ msgid "Zoom out"
-#~ msgstr "Zmniejsz"
-
-#~ msgid "Gallery"
-#~ msgstr "Galeria"
-
-#~ msgid "Compare versions"
-#~ msgstr "Porównaj wersje"
-
-#~ msgid "Revert document"
-#~ msgstr "PrzywrÃ³Ä wersjÄ"
-
-#~ msgid "View version"
-#~ msgstr "Zobacz wersjÄ"
-
-#~ msgid "History"
-#~ msgstr "Historia"
-
-#~ msgid "Search"
-#~ msgstr "Szukaj"
-
-#~ msgid "Replace with"
-#~ msgstr "ZamieÅ na"
-
-#~ msgid "Replace"
-#~ msgstr "ZamieÅ"
-
-#~ msgid "Options"
-#~ msgstr "Opcje"
-
-#~ msgid "Case sensitive"
-#~ msgstr "Rozróżniaj wielkoÅÄ liter"
-
-#~ msgid "From cursor"
-#~ msgstr "Zacznij od kursora"
-
-#~ msgid "Search and replace"
-#~ msgstr "Znajdź i zamieÅ"
-
-#~ msgid "Source code"
-#~ msgstr "Kod źródÅowy"
-
-#~ msgid "Title"
-#~ msgstr "TytuÅ"
-
-#~ msgid "Document ID"
-#~ msgstr "ID dokumentu"
-
-#~ msgid "Current version"
-#~ msgstr "Aktualna wersja"
-
-#~ msgid "Last edited by"
-#~ msgstr "Ostatnio edytowane przez"
-
-#~ msgid "Summary"
-#~ msgstr "Podsumowanie"
-
-#~ msgid "Insert theme"
-#~ msgstr "Wstaw motyw"
-
-#~ msgid "Insert annotation"
-#~ msgstr "Wstaw przypis"
-
-#~ msgid "Visual editor"
-#~ msgstr "Edytor wizualny"
-
-#~ msgid "Unassigned"
-#~ msgstr "Nie przypisane"
-
-#~ msgid "First correction"
-#~ msgstr "Autokorekta"
-
-#~ msgid "Tagging"
-#~ msgstr "Tagowanie"
-
-#~ msgid "Initial Proofreading"
-#~ msgstr "Korekta"
-
-#~ msgid "Annotation Proofreading"
-#~ msgstr "Sprawdzenie przypisów źródÅa"
-
-#~ msgid "Modernisation"
-#~ msgstr "UwspóÅczeÅnienie"
-
-#~ msgid "Themes"
-#~ msgstr "Motywy"
-
-#~ msgid "Editor's Proofreading"
-#~ msgstr "Ostateczna redakcja literacka"
-
-#~ msgid "Technical Editor's Proofreading"
-#~ msgstr "Ostateczna redakcja techniczna"
-
-#~ msgid "Finished stage: %s"
-#~ msgstr "UkoÅczony etap: %s"
-
-#~ msgid "Refresh"
-#~ msgstr "OdÅwież"
diff --git a/apps/catalogue/management/__init__.py b/apps/catalogue/management/__init__.py
deleted file mode 100644
index bc3d6c02..00000000
--- a/apps/catalogue/management/__init__.py
+++ /dev/null
@@ -1,120 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-from collections import defaultdict
-from django.db import transaction
-from lxml import etree
-
-
-class XmlUpdater(object):
- """A base class for massive XML updates.
-
- In a subclass, override `fix_tree` and/or use `fixes_field` decorator.
- Attributes:
- * commit_desc: commits description
- * retain_publishable: set publishable if head is (default: True)
- * only_first_chunk: process only first chunks of books (default: False)
- """
- commit_desc = "auto-update"
- retain_publishable = True
- only_first_chunk = False
-
- _element_fixers = defaultdict(list)
-
- def __init__(self):
- self.counters = defaultdict(lambda: 0)
-
- @classmethod
- def fixes_elements(cls, xpath):
- """Decorator, registering a function as a fixer for given field type.
-
- Any decorated function will be called like
- f(element, change=..., verbose=...)
- providing changeset as context.
-
- :param xpath: element lookup, e.g. ".//{namespace-uri}tag-name"
- :returns: True if anything changed
- """
- def wrapper(fixer):
- cls._element_fixers[xpath].append(fixer)
- return fixer
- return wrapper
-
- def fix_tree(self, tree, verbose):
- """Override to provide general tree-fixing mechanism.
-
- :param tree: the parsed XML tree
- :param verbose: verbosity level
- :returns: True if anythig changed
- """
- return False
-
- def fix_chunk(self, chunk, user, verbose=0, dry_run=False):
- """Runs the update for a single chunk."""
- if verbose >= 2:
- print chunk.get_absolute_url()
- old_head = chunk.head
- src = old_head.materialize()
- try:
- tree = etree.fromstring(src)
- except:
- if verbose:
- print "%s: invalid XML" % chunk.get_absolute_url()
- self.counters['Bad XML'] += 1
- return
-
- dirty = False
- # Call the general fixing function.
- if self.fix_tree(tree, verbose=verbose):
- dirty = True
- # Call the registered fixers.
- for xpath, fixers in self._element_fixers.items():
- for elem in tree.findall(xpath):
- for fixer in fixers:
- if fixer(elem, change=old_head, verbose=verbose):
- dirty = True
-
- if not dirty:
- self.counters['Clean'] += 1
- return
-
- if not dry_run:
- new_head = chunk.commit(
- etree.tostring(tree, encoding=unicode),
- author=user,
- description=self.commit_desc
- )
- if self.retain_publishable:
- if old_head.publishable:
- new_head.set_publishable(True)
- if verbose >= 2:
- print "done"
- self.counters['Updated chunks'] += 1
-
- def run(self, user, verbose=0, dry_run=False, books=None):
- """Runs the actual update."""
- if books is None:
- from catalogue.models import Book
- books = Book.objects.all()
-
- # Start transaction management.
- transaction.enter_transaction_management()
-
- for book in books:
- self.counters['All books'] += 1
- chunks = book.chunk_set.all()
- if self.only_first_chunk:
- chunks = chunks[:1]
- for chunk in chunks:
- self.counters['All chunks'] += 1
- self.fix_chunk(chunk, user, verbose, dry_run)
-
- transaction.commit()
- transaction.leave_transaction_management()
-
- def print_results(self):
- """Prints the counters."""
- for item in sorted(self.counters.items()):
- print "%s: %d" % item
diff --git a/apps/catalogue/management/commands/__init__.py b/apps/catalogue/management/commands/__init__.py
deleted file mode 100644
index e6f146f8..00000000
--- a/apps/catalogue/management/commands/__init__.py
+++ /dev/null
@@ -1,43 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-import sys
-from optparse import make_option
-from django.contrib.auth.models import User
-from django.core.management.base import BaseCommand
-from catalogue.models import Book
-
-
-class XmlUpdaterCommand(BaseCommand):
- """Base class for creating massive XML-updating commands.
-
- In a subclass, provide an XmlUpdater class in the `updater' attribute.
- """
- option_list = BaseCommand.option_list + (
- make_option('-q', '--quiet', action='store_false', dest='verbose',
- default=True, help='Less output'),
- make_option('-d', '--dry-run', action='store_true', dest='dry_run',
- default=False, help="Don't actually touch anything"),
- make_option('-u', '--username', dest='username', metavar='USER',
- help='Assign commits to this user (required, preferably yourself).'),
- )
- args = "[slug]..."
-
- def handle(self, *args, **options):
- verbose = options.get('verbose')
- dry_run = options.get('dry_run')
- username = options.get('username')
-
- if username:
- user = User.objects.get(username=username)
- else:
- print 'Please provide a username.'
- sys.exit(1)
-
- books = Book.objects.filter(slug__in=args) if args else None
-
- updater = self.updater()
- updater.run(user, verbose=verbose, dry_run=dry_run, books=books)
- updater.print_results()
diff --git a/apps/catalogue/management/commands/add_parent.py b/apps/catalogue/management/commands/add_parent.py
deleted file mode 100644
index 2ab0510c..00000000
--- a/apps/catalogue/management/commands/add_parent.py
+++ /dev/null
@@ -1,101 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-import sys
-
-from datetime import date
-from lxml import etree
-
-from django.core.management import BaseCommand
-
-from catalogue.models import Book
-from librarian import RDFNS, DCNS
-
-TEMPLATE = '''
- {% trans "Active users since" %} {{ since }}
-
-
-
-{% for email, names, count in users %}
-
-
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/activity.html b/apps/catalogue/templates/catalogue/activity.html
deleted file mode 100755
index 3bb8afb2..00000000
--- a/apps/catalogue/templates/catalogue/activity.html
+++ /dev/null
@@ -1,19 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load i18n %}
-{% load wall %}
-
-
-{% block titleextra %}{% trans "Activity" %}{% endblock %}
-
-
-{% block content %}
-
-<
- {% trans "Activity" %}: {{ day }}
- {% if next_day %}
- >
- {% endif %}
-
-
- {% day_wall day %}
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/base.html b/apps/catalogue/templates/catalogue/base.html
deleted file mode 100644
index 8577f104..00000000
--- a/apps/catalogue/templates/catalogue/base.html
+++ /dev/null
@@ -1,54 +0,0 @@
-{% load pipeline i18n %}
-{% load catalogue %}
-
-
-
-
-
- {% stylesheet 'catalogue' %}
- {{ book.title }}
-
-
-{% if editable %}{% endif %}
-
-{% if editable %}
- {% if book.gallery %}
-
- {% endif %}
-
- {% trans "Chunks" %}
-
-
- {% for chunk in book %}
- {{ chunk.short_html|safe }}
- {% endfor %}
-
-
-{% trans "Publication" %}
-
-
- {% trans "HTML version" %}
- {% trans "TXT version" %}
- {% trans "PDF version" %}
- {% trans "PDF version for mobiles" %}
- {% trans "EPUB version" %}
- {% trans "MOBI version" %}
-
-{% endif %}
-
-
-
-
- {% endwith %}
-{% else %}
-
- [B]
- [c]
-
- {{ book.title }}
- {% if chunk.stage %}
- {{ chunk.stage }}
- {% else %}â
- {% endif %}
- {% if chunk.user %}{{ chunk.user|username }}{% endif %}
-
- {% if chunk.published %}P{% endif %}
- {% if book.new_publishable %}p{% endif %}
- {% if chunk.changed %}+{% endif %}
-
- {{ book.project.name }}
-
-
-{% endif %}
diff --git a/apps/catalogue/templates/catalogue/book_list/book_list.html b/apps/catalogue/templates/catalogue/book_list/book_list.html
deleted file mode 100755
index e238827b..00000000
--- a/apps/catalogue/templates/catalogue/book_list/book_list.html
+++ /dev/null
@@ -1,114 +0,0 @@
-{% load i18n %}
-{% load pagination_tags %}
-{% load username from common_tags %}
-
-
-
-
-
-
- [B]
-
- {{ book.title }}
-
-
-
- {% if book.published %}P{% endif %}
- {% if book.new_publishable %}p{% endif %}
-
- {{ book.project.name }}
-
-
-{% if not books %}
-
-
-
- {% with cnt=books|length %}
- {% autopaginate books 100 %}
-
- {% for item in books %}
- {% with item.book as book %}
- {{ book.short_html|safe }}
- {% if not book.single %}
- {% for chunk in item.chunks %}
- {{ chunk.short_html|safe }}
- {% endfor %}
- {% endif %}
- {% endwith %}
- {% endfor %}
-
-
-
-
-
-
-
-
-
-
- {% if not viewed_user %}
-
- {% else %}
-
- {% endif %}
-
-
-
-
-
-
-
- {% endwith %}
-
- {% paginate %}
- {% blocktrans count c=cnt %}{{c}} book{% plural %}{{c}} books{% endblocktrans %}
-
diff --git a/apps/catalogue/templates/catalogue/book_text.html b/apps/catalogue/templates/catalogue/book_text.html
deleted file mode 100644
index 2e484483..00000000
--- a/apps/catalogue/templates/catalogue/book_text.html
+++ /dev/null
@@ -1,28 +0,0 @@
-{% load i18n pipeline %}
-
-
-
-
-
-
- [c]
-
- {{ chunk.number }}.
- {{ chunk.title }}
- {% if chunk.stage %}
- {{ chunk.stage }}
- {% else %}
- â
- {% endif %}
- {% if chunk.user %}
-
- {{ chunk.user|username }}
- {% else %}
-
- {% endif %}
-
-
- {% if chunk.new_publishable %}p{% endif %}
- {% if chunk.changed %}+{% endif %}
-
-{% trans "Split chunk" %}
-
-
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/chunk_edit.html b/apps/catalogue/templates/catalogue/chunk_edit.html
deleted file mode 100755
index 20062265..00000000
--- a/apps/catalogue/templates/catalogue/chunk_edit.html
+++ /dev/null
@@ -1,24 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load i18n %}
-
-
-{% block titleextra %}{% trans "Chunk settings" %}{% endblock %}
-
-
-{% block content %}
- {% trans "Chunk settings" %}
-
-
-
-
-
-
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/document_create_missing.html b/apps/catalogue/templates/catalogue/document_create_missing.html
deleted file mode 100644
index aa2ce06c..00000000
--- a/apps/catalogue/templates/catalogue/document_create_missing.html
+++ /dev/null
@@ -1,18 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load i18n %}
-
-
-{% block titleextra %}{% trans "Create a new book" %}{% endblock %}
-
-
-{% block content %}
- {% trans "Create a new book" %}
-
-
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/document_list.html b/apps/catalogue/templates/catalogue/document_list.html
deleted file mode 100644
index fe3598e1..00000000
--- a/apps/catalogue/templates/catalogue/document_list.html
+++ /dev/null
@@ -1,20 +0,0 @@
-{% extends "catalogue/base.html" %}
-
-{% load i18n %}
-{% load catalogue book_list %}
-{% load pipeline %}
-
-{% block titleextra %}{% trans "Book list" %}{% endblock %}
-
-
-{% block add_js %}
-{% javascript 'book_list' %}
-{% endblock %}
-
-{% block add_css %}
-{% stylesheet 'book_list' %}
-{% endblock %}
-
-{% block content %}
- {% book_list %}
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/document_upload.html b/apps/catalogue/templates/catalogue/document_upload.html
deleted file mode 100644
index 009d1540..00000000
--- a/apps/catalogue/templates/catalogue/document_upload.html
+++ /dev/null
@@ -1,72 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load i18n %}
-
-
-{% block titleextra %}{% trans "Bulk document upload" %}{% endblock %}
-
-
-{% block leftcolumn %}
-
-
-{% trans "Bulk documents upload" %}
-
-.xml
will be ignored." %}
-
-
-{% if error_list %}
-
- {% trans "Offending files" %}
-
- {% for filename, title, error in error_list %}
-
-
- {% if ok_list %}
- {{ filename }}
): {{ error }}{% trans "Correct files" %}
-
- {% for filename, slug, title in ok_list %}
-
- {% endif %}
-
-{% else %}
-
- {% if ok_list %}
- {{ filename }}
){% trans "Uploaded files" %}
-
- {% for filename, slug, title in ok_list %}
-
- {% endif %}
-{% endif %}
-
-{% if skipped_list %}
- {{ filename }})
{% trans "Skipped files" %}
- .xml
extension" %}
- {% for filename in skipped_list %}
-
-{% endif %}
-
-
-{% endblock leftcolumn %}
-
-
-{% block rightcolumn %}
-{% endblock rightcolumn %}
diff --git a/apps/catalogue/templates/catalogue/image_detail.html b/apps/catalogue/templates/catalogue/image_detail.html
deleted file mode 100755
index 8ad2a63f..00000000
--- a/apps/catalogue/templates/catalogue/image_detail.html
+++ /dev/null
@@ -1,71 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load book_list i18n %}
-
-
-{% block titleextra %}{{ object.title }}{% endblock %}
-
-
-{% block content %}
-
-
-{{ object.title }}
-
-
-{% if editable %}{% endif %}
-
-
-
-{% trans "Editor" %}
-
-
-{% trans "Publication" %}
-
-
-{% endif %}
-
-
-
diff --git a/apps/catalogue/templates/catalogue/image_table.html b/apps/catalogue/templates/catalogue/image_table.html
deleted file mode 100755
index e6caedda..00000000
--- a/apps/catalogue/templates/catalogue/image_table.html
+++ /dev/null
@@ -1,100 +0,0 @@
-{% load i18n %}
-{% load pagination_tags %}
-{% load username from common_tags %}
-
-
-
-
-
-
- [B]
-
- {{ image.title }}
- {% if image.stage %}
- {{ image.stage }}
- {% else %}â
- {% endif %}
- {% if image.user %}{{ image.user|username }}{% endif %}
-
- {% if image.published %}P{% endif %}
- {% if image.new_publishable %}p{% endif %}
- {% if image.changed %}+{% endif %}
-
- {{ image.project.name }}
-
-
-{% if not objects %}
-
-
-
- {% with cnt=objects|length %}
- {% autopaginate objects 100 %}
-
- {% for item in objects %}
- {{ item.short_html|safe }}
- {% endfor %}
-
-
-
-
-
-
-
- {% if not viewed_user %}
-
- {% endif %}
-
-
-
-
-
-
-
- {% endwith %}
-
- {% paginate %}
- {% blocktrans count c=cnt %}{{c}} image{% plural %}{{c}} images{% endblocktrans %} Oznacz ksiÄ
żki
-
-
-
-{% endblock leftcolumn %}
\ No newline at end of file
diff --git a/apps/catalogue/templates/catalogue/mark_final_completed.html b/apps/catalogue/templates/catalogue/mark_final_completed.html
deleted file mode 100644
index 1b37c836..00000000
--- a/apps/catalogue/templates/catalogue/mark_final_completed.html
+++ /dev/null
@@ -1,12 +0,0 @@
-{% extends "catalogue/base.html" %}
-
-{% block titleextra %}Oznaczono ksiÄ
żki{% endblock %}
-
-
-{% block leftcolumn %}
-
-Oznaczono ksiÄ
żki
-
-{% trans "Your last edited documents" %}
-
- {% for edit_url, item in last_books %}
-
-
({{ item.time|date:"H:i:s, d/m/Y" }}){% trans "Recent activity for" %} {{ request.user|nice_name }}
- {% wall request.user 10 %}
-{% endblock rightcolumn %}
diff --git a/apps/catalogue/templates/catalogue/upload_pdf.html b/apps/catalogue/templates/catalogue/upload_pdf.html
deleted file mode 100755
index 265b84ad..00000000
--- a/apps/catalogue/templates/catalogue/upload_pdf.html
+++ /dev/null
@@ -1,20 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load i18n %}
-
-
-{% block titleextra %}{% trans "PDF file upload" %}{% endblock %}
-
-
-{% block content %}
-
-
-{% trans "PDF file upload" %}
-
-
-
-
-{% endblock content %}
diff --git a/apps/catalogue/templates/catalogue/user_list.html b/apps/catalogue/templates/catalogue/user_list.html
deleted file mode 100755
index 460a38b9..00000000
--- a/apps/catalogue/templates/catalogue/user_list.html
+++ /dev/null
@@ -1,23 +0,0 @@
-{% extends "catalogue/base.html" %}
-
-{% load i18n %}
-{% load username from common_tags %}
-
-
-{% block titleextra %}{% trans "Users" %}{% endblock %}
-
-
-{% block leftcolumn %}
-
-{% trans "Users" %}
-
-
-{% for user in users %}
-
-
-{% endblock leftcolumn %}
diff --git a/apps/catalogue/templates/catalogue/user_page.html b/apps/catalogue/templates/catalogue/user_page.html
deleted file mode 100755
index 4be4ca3e..00000000
--- a/apps/catalogue/templates/catalogue/user_page.html
+++ /dev/null
@@ -1,18 +0,0 @@
-{% extends "catalogue/base.html" %}
-
-{% load i18n %}
-{% load catalogue book_list wall %}
-
-
-{% block titleextra %}{{ viewed_user|nice_name }}{% endblock %}
-
-
-{% block leftcolumn %}
- {{ viewed_user|nice_name }}
- {% book_list viewed_user %}
-{% endblock leftcolumn %}
-
-{% block rightcolumn %}
- {% trans "Recent activity for" %} {{ viewed_user|nice_name }}
- {% wall viewed_user 10 %}
-{% endblock rightcolumn %}
diff --git a/apps/catalogue/templates/catalogue/wall.html b/apps/catalogue/templates/catalogue/wall.html
deleted file mode 100755
index a107dfa8..00000000
--- a/apps/catalogue/templates/catalogue/wall.html
+++ /dev/null
@@ -1,37 +0,0 @@
-{% load i18n %}
-{% load gravatar %}
-{% load email %}
-{% load username from common_tags %}
-
-
-{% for item in wall %}
-
diff --git a/apps/catalogue/templatetags/__init__.py b/apps/catalogue/templatetags/__init__.py
deleted file mode 100644
index e69de29b..00000000
diff --git a/apps/catalogue/templatetags/book_list.py b/apps/catalogue/templatetags/book_list.py
deleted file mode 100755
index 9ac996b8..00000000
--- a/apps/catalogue/templatetags/book_list.py
+++ /dev/null
@@ -1,209 +0,0 @@
-from __future__ import absolute_import
-
-from re import split
-from django.db.models import Q, Count
-from django import template
-from django.utils.translation import ugettext_lazy as _
-from django.contrib.auth.models import User
-from catalogue.models import Chunk, Image, Project
-
-register = template.Library()
-
-
-class ChunksList(object):
- def __init__(self, chunk_qs):
- #self.chunk_qs = chunk_qs#.annotate(
- #book_length=Count('book__chunk')).select_related(
- #'book')#, 'stage__name',
- #'user')
- self.chunk_qs = chunk_qs.select_related('book__hidden')
-
- self.book_qs = chunk_qs.values('book_id')
-
- def __getitem__(self, key):
- if isinstance(key, slice):
- return self.get_slice(key)
- elif isinstance(key, int):
- return self.get_slice(slice(key, key+1))[0]
- else:
- raise TypeError('Unsupported list index. Must be a slice or an int.')
-
- def __len__(self):
- return self.book_qs.count()
-
- def get_slice(self, slice_):
- book_ids = [x['book_id'] for x in self.book_qs[slice_]]
- chunk_qs = self.chunk_qs.filter(book__in=book_ids)
-
- chunks_list = []
- book = None
- for chunk in chunk_qs:
- if chunk.book != book:
- book = chunk.book
- chunks_list.append(ChoiceChunks(book, [chunk]))
- else:
- chunks_list[-1].chunks.append(chunk)
- return chunks_list
-
-
-class ChoiceChunks(object):
- """
- Associates the given chunks iterable for a book.
- """
-
- chunks = None
-
- def __init__(self, book, chunks):
- self.book = book
- self.chunks = chunks
-
-
-def foreign_filter(qs, value, filter_field, model, model_field='slug', unset='-'):
- if value == unset:
- return qs.filter(**{filter_field: None})
- if not value:
- return qs
- try:
- obj = model._default_manager.get(**{model_field: value})
- except model.DoesNotExist:
- return qs.none()
- else:
- return qs.filter(**{filter_field: obj})
-
-
-def search_filter(qs, value, filter_fields):
- if not value:
- return qs
- q = Q(**{"%s__icontains" % filter_fields[0]: value})
- for field in filter_fields[1:]:
- q |= Q(**{"%s__icontains" % field: value})
- return qs.filter(q)
-
-
-_states = [
- ('publishable', _('publishable'), Q(book___new_publishable=True)),
- ('changed', _('changed'), Q(_changed=True)),
- ('published', _('published'), Q(book___published=True)),
- ('unpublished', _('unpublished'), Q(book___published=False)),
- ('empty', _('empty'), Q(head=None)),
- ]
-_states_options = [s[:2] for s in _states]
-_states_dict = dict([(s[0], s[2]) for s in _states])
-
-
-def document_list_filter(request, **kwargs):
-
- def arg_or_GET(field):
- return kwargs.get(field, request.GET.get(field))
-
- if arg_or_GET('all'):
- chunks = Chunk.objects.all()
- else:
- chunks = Chunk.visible_objects.all()
-
- chunks = chunks.order_by('book__title', 'book', 'number')
-
- if not request.user.is_authenticated():
- chunks = chunks.filter(book__public=True)
-
- state = arg_or_GET('status')
- if state in _states_dict:
- chunks = chunks.filter(_states_dict[state])
-
- chunks = foreign_filter(chunks, arg_or_GET('user'), 'user', User, 'username')
- chunks = foreign_filter(chunks, arg_or_GET('stage'), 'stage', Chunk.tag_model, 'slug')
- chunks = search_filter(chunks, arg_or_GET('title'), ['book__title', 'title'])
- chunks = foreign_filter(chunks, arg_or_GET('project'), 'book__project', Project, 'pk')
- return chunks
-
-
-@register.inclusion_tag('catalogue/book_list/book_list.html', takes_context=True)
-def book_list(context, user=None):
- request = context['request']
-
- if user:
- filters = {"user": user}
- new_context = {"viewed_user": user}
- else:
- filters = {}
- new_context = {
- "users": User.objects.annotate(
- count=Count('chunk')).filter(count__gt=0).order_by(
- '-count', 'last_name', 'first_name'),
- "other_users": User.objects.annotate(
- count=Count('chunk')).filter(count=0).order_by(
- 'last_name', 'first_name'),
- }
-
- new_context.update({
- "filters": True,
- "request": request,
- "books": ChunksList(document_list_filter(request, **filters)),
- "stages": Chunk.tag_model.objects.all(),
- "states": _states_options,
- "projects": Project.objects.all(),
- })
-
- return new_context
-
-
-
-_image_states = [
- ('publishable', _('publishable'), Q(_new_publishable=True)),
- ('changed', _('changed'), Q(_changed=True)),
- ('published', _('published'), Q(_published=True)),
- ('unpublished', _('unpublished'), Q(_published=False)),
- ('empty', _('empty'), Q(head=None)),
- ]
-_image_states_options = [s[:2] for s in _image_states]
-_image_states_dict = dict([(s[0], s[2]) for s in _image_states])
-
-def image_list_filter(request, **kwargs):
-
- def arg_or_GET(field):
- return kwargs.get(field, request.GET.get(field))
-
- images = Image.objects.all()
-
- if not request.user.is_authenticated():
- images = images.filter(public=True)
-
- state = arg_or_GET('status')
- if state in _image_states_dict:
- images = images.filter(_image_states_dict[state])
-
- images = foreign_filter(images, arg_or_GET('user'), 'user', User, 'username')
- images = foreign_filter(images, arg_or_GET('stage'), 'stage', Image.tag_model, 'slug')
- images = search_filter(images, arg_or_GET('title'), ['title', 'title'])
- images = foreign_filter(images, arg_or_GET('project'), 'project', Project, 'pk')
- return images
-
-
-@register.inclusion_tag('catalogue/image_table.html', takes_context=True)
-def image_list(context, user=None):
- request = context['request']
-
- if user:
- filters = {"user": user}
- new_context = {"viewed_user": user}
- else:
- filters = {}
- new_context = {
- "users": User.objects.annotate(
- count=Count('image')).filter(count__gt=0).order_by(
- '-count', 'last_name', 'first_name'),
- "other_users": User.objects.annotate(
- count=Count('image')).filter(count=0).order_by(
- 'last_name', 'first_name'),
- }
-
- new_context.update({
- "filters": True,
- "request": request,
- "objects": image_list_filter(request, **filters),
- "stages": Image.tag_model.objects.all(),
- "states": _image_states_options,
- "projects": Project.objects.all(),
- })
-
- return new_context
diff --git a/apps/catalogue/templatetags/catalogue.py b/apps/catalogue/templatetags/catalogue.py
deleted file mode 100644
index 07c5cf9d..00000000
--- a/apps/catalogue/templatetags/catalogue.py
+++ /dev/null
@@ -1,46 +0,0 @@
-from __future__ import absolute_import
-
-from django.core.urlresolvers import reverse
-from django import template
-from django.utils.translation import ugettext as _
-
-register = template.Library()
-
-
-class Tab(object):
- slug = None
- caption = None
- url = None
-
- def __init__(self, slug, caption, url):
- self.slug = slug
- self.caption = caption
- self.url = url
-
-
-@register.inclusion_tag("catalogue/main_tabs.html", takes_context=True)
-def main_tabs(context):
- active = getattr(context['request'], 'catalogue_active_tab', None)
-
- tabs = []
- user = context['user']
- tabs.append(Tab('my', _('My page'), reverse("catalogue_user")))
-
- tabs.append(Tab('activity', _('Activity'), reverse("catalogue_activity")))
- tabs.append(Tab('all', _('All'), reverse("catalogue_document_list")))
- tabs.append(Tab('images', _('Images'), reverse("catalogue_image_list")))
- tabs.append(Tab('users', _('Users'), reverse("catalogue_users")))
-
- if user.has_perm('catalogue.add_book'):
- tabs.append(Tab('create', _('Add'), reverse("catalogue_create_missing")))
- tabs.append(Tab('upload', _('Upload'), reverse("catalogue_upload")))
-
- tabs.append(Tab('cover', _('Covers'), reverse("cover_image_list")))
-
- return {"tabs": tabs, "active_tab": active}
-
-
-@register.filter
-def nice_name(user):
- return user.get_full_name() or user.username
-
diff --git a/apps/catalogue/templatetags/common_tags.py b/apps/catalogue/templatetags/common_tags.py
deleted file mode 100755
index 7f5d0e9f..00000000
--- a/apps/catalogue/templatetags/common_tags.py
+++ /dev/null
@@ -1,6 +0,0 @@
-from django import template
-register = template.Library()
-
-@register.filter
-def username(user):
- return ("%s %s" % (user.first_name, user.last_name)).lstrip() or user.username
diff --git a/apps/catalogue/templatetags/set_get_parameter.py b/apps/catalogue/templatetags/set_get_parameter.py
deleted file mode 100755
index b3d44d73..00000000
--- a/apps/catalogue/templatetags/set_get_parameter.py
+++ /dev/null
@@ -1,46 +0,0 @@
-from re import split
-
-from django import template
-
-register = template.Library()
-
-
-"""
-In template:
- {% set_get_paramater param1='const_value',param2=,param3=variable %}
-results with changes to query string:
- param1 is set to `const_value' string
- param2 is unset, if exists,
- param3 is set to the value of variable in context
-
-Using 'django.core.context_processors.request' is required.
-
-"""
-
-
-class SetGetParameter(template.Node):
- def __init__(self, values):
- self.values = values
-
- def render(self, context):
- request = template.Variable('request').resolve(context)
- params = request.GET.copy()
- for key, value in self.values.items():
- if value == '':
- if key in params:
- del(params[key])
- else:
- params[key] = template.Variable(value).resolve(context)
- return '?%s' % params.urlencode()
-
-
-@register.tag
-def set_get_parameter(parser, token):
- parts = split(r'\s+', token.contents, 2)
-
- values = {}
- for pair in parts[1].split(','):
- s = pair.split('=')
- values[s[0]] = s[1]
-
- return SetGetParameter(values)
diff --git a/apps/catalogue/templatetags/wall.py b/apps/catalogue/templatetags/wall.py
deleted file mode 100755
index d000421a..00000000
--- a/apps/catalogue/templatetags/wall.py
+++ /dev/null
@@ -1,210 +0,0 @@
-from __future__ import absolute_import
-
-from datetime import timedelta
-from django.db.models import Q
-from django.core.urlresolvers import reverse
-from django.contrib.comments.models import Comment
-from django import template
-from django.utils.translation import ugettext as _
-
-from catalogue.models import Chunk, BookPublishRecord, Image, ImagePublishRecord
-
-register = template.Library()
-
-
-class WallItem(object):
- title = ''
- summary = ''
- url = ''
- timestamp = ''
- user = None
- user_name = ''
- email = ''
-
- def __init__(self, tag):
- self.tag = tag
-
- def get_email(self):
- if self.user:
- return self.user.email
- else:
- return self.email
-
-
-def changes_wall(user=None, max_len=None, day=None):
- qs = Chunk.change_model.objects.order_by('-created_at')
- qs = qs.select_related('author', 'tree', 'tree__book__title')
- if user is not None:
- qs = qs.filter(Q(author=user) | Q(tree__user=user))
- if max_len is not None:
- qs = qs[:max_len]
- if day is not None:
- next_day = day + timedelta(1)
- qs = qs.filter(created_at__gte=day, created_at__lt=next_day)
- for item in qs:
- tag = 'stage' if item.tags.count() else 'change'
- chunk = item.tree
- w = WallItem(tag)
- if user and item.author != user:
- w.header = _('Related edit')
- else:
- w.header = _('Edit')
- w.title = chunk.pretty_name()
- w.summary = item.description
- w.url = reverse('wiki_editor',
- args=[chunk.book.slug, chunk.slug]) + '?diff=%d' % item.revision
- w.timestamp = item.created_at
- w.user = item.author
- w.user_name = item.author_name
- w.email = item.author_email
- yield w
-
-
-def image_changes_wall(user=None, max_len=None, day=None):
- qs = Image.change_model.objects.order_by('-created_at')
- qs = qs.select_related('author', 'tree', 'tree__title')
- if user is not None:
- qs = qs.filter(Q(author=user) | Q(tree__user=user))
- if max_len is not None:
- qs = qs[:max_len]
- if day is not None:
- next_day = day + timedelta(1)
- qs = qs.filter(created_at__gte=day, created_at__lt=next_day)
- for item in qs:
- tag = 'stage' if item.tags.count() else 'change'
- image = item.tree
- w = WallItem(tag)
- if user and item.author != user:
- w.header = _('Related edit')
- else:
- w.header = _('Edit')
- w.title = image.title
- w.summary = item.description
- w.url = reverse('wiki_img_editor',
- args=[image.slug]) + '?diff=%d' % item.revision
- w.timestamp = item.created_at
- w.user = item.author
- w.user_name = item.author_name
- w.email = item.author_email
- yield w
-
-
-
-# TODO: marked for publishing
-
-
-def published_wall(user=None, max_len=None, day=None):
- qs = BookPublishRecord.objects.select_related('book__title')
- if user:
- # TODO: published my book
- qs = qs.filter(Q(user=user))
- if max_len is not None:
- qs = qs[:max_len]
- if day is not None:
- next_day = day + timedelta(1)
- qs = qs.filter(timestamp__gte=day, timestamp__lt=next_day)
- for item in qs:
- w = WallItem('publish')
- w.header = _('Publication')
- w.title = item.book.title
- w.timestamp = item.timestamp
- w.url = item.book.get_absolute_url()
- w.user = item.user
- w.email = item.user.email
- yield w
-
-
-def image_published_wall(user=None, max_len=None, day=None):
- qs = ImagePublishRecord.objects.select_related('image__title')
- if user:
- # TODO: published my book
- qs = qs.filter(Q(user=user))
- if max_len is not None:
- qs = qs[:max_len]
- if day is not None:
- next_day = day + timedelta(1)
- qs = qs.filter(timestamp__gte=day, timestamp__lt=next_day)
- for item in qs:
- w = WallItem('publish')
- w.header = _('Publication')
- w.title = item.image.title
- w.timestamp = item.timestamp
- w.url = item.image.get_absolute_url()
- w.user = item.user
- w.email = item.user.email
- yield w
-
-
-def comments_wall(user=None, max_len=None, day=None):
- qs = Comment.objects.filter(is_public=True).select_related().order_by('-submit_date')
- if user:
- # TODO: comments concerning my books
- qs = qs.filter(Q(user=user))
- if max_len is not None:
- qs = qs[:max_len]
- if day is not None:
- next_day = day + timedelta(1)
- qs = qs.filter(submit_date__gte=day, submit_date__lt=next_day)
- for item in qs:
- w = WallItem('comment')
- w.header = _('Comment')
- w.title = item.content_object
- w.summary = item.comment
- w.url = item.content_object.get_absolute_url()
- w.timestamp = item.submit_date
- w.user = item.user
- ui = item.userinfo
- w.email = item.email
- w.user_name = item.name
- yield w
-
-
-def big_wall(walls, max_len=None):
- """
- Takes some WallItem iterators and zips them into one big wall.
- Input iterators must already be sorted by timestamp.
- """
- subwalls = []
- for w in walls:
- try:
- subwalls.append([next(w), w])
- except StopIteration:
- pass
-
- if max_len is None:
- max_len = -1
- while max_len and subwalls:
- i, next_item = max(enumerate(subwalls), key=lambda x: x[1][0].timestamp)
- yield next_item[0]
- max_len -= 1
- try:
- next_item[0] = next(next_item[1])
- except StopIteration:
- del subwalls[i]
-
-
-@register.inclusion_tag("catalogue/wall.html", takes_context=True)
-def wall(context, user=None, max_len=100):
- return {
- "request": context['request'],
- "STATIC_URL": context['STATIC_URL'],
- "wall": big_wall([
- changes_wall(user, max_len),
- published_wall(user, max_len),
- image_changes_wall(user, max_len),
- image_published_wall(user, max_len),
- comments_wall(user, max_len),
- ], max_len)}
-
-@register.inclusion_tag("catalogue/wall.html", takes_context=True)
-def day_wall(context, day):
- return {
- "request": context['request'],
- "STATIC_URL": context['STATIC_URL'],
- "wall": big_wall([
- changes_wall(day=day),
- published_wall(day=day),
- image_changes_wall(day=day),
- image_published_wall(day=day),
- comments_wall(day=day),
- ])}
diff --git a/apps/catalogue/test_utils.py b/apps/catalogue/test_utils.py
deleted file mode 100644
index 2b085450..00000000
--- a/apps/catalogue/test_utils.py
+++ /dev/null
@@ -1,14 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-"""Testing utilities."""
-
-from os.path import abspath, dirname, join
-
-
-def get_fixture(path):
- f_path = join(dirname(abspath(__file__)), 'tests/files', path)
- with open(f_path) as f:
- return unicode(f.read(), 'utf-8')
diff --git a/apps/catalogue/tests/__init__.py b/apps/catalogue/tests/__init__.py
deleted file mode 100644
index 533a6c53..00000000
--- a/apps/catalogue/tests/__init__.py
+++ /dev/null
@@ -1,9 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-from catalogue.tests.book import *
-from catalogue.tests.gallery import *
-from catalogue.tests.publish import *
-from catalogue.tests.xml_updater import *
diff --git a/apps/catalogue/tests/book.py b/apps/catalogue/tests/book.py
deleted file mode 100644
index df6f3b4f..00000000
--- a/apps/catalogue/tests/book.py
+++ /dev/null
@@ -1,54 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-"""Tests for manipulating books in the catalogue."""
-
-from django.test import TestCase
-from django.contrib.auth.models import User
-from catalogue.models import Book
-
-
-class ManipulationTests(TestCase):
-
- def setUp(self):
- self.user = User.objects.create(username='tester')
- self.book1 = Book.create(self.user, 'book 1', slug='book1')
- self.book2 = Book.create(self.user, 'book 2', slug='book2')
-
- def test_append(self):
- self.book1.append(self.book2)
- self.assertEqual(Book.objects.all().count(), 1)
- self.assertEqual(len(self.book1), 2)
-
- def test_append_to_self(self):
- with self.assertRaises(AssertionError):
- self.book1.append(Book.objects.get(pk=self.book1.pk))
- self.assertEqual(Book.objects.all().count(), 2)
- self.assertEqual(len(self.book1), 1)
-
- def test_prepend_history(self):
- self.book1.prepend_history(self.book2)
- self.assertEqual(Book.objects.all().count(), 1)
- self.assertEqual(len(self.book1), 1)
- self.assertEqual(self.book1.materialize(), 'book 1')
-
- def test_prepend_history_to_self(self):
- with self.assertRaises(AssertionError):
- self.book1.prepend_history(self.book1)
- self.assertEqual(Book.objects.all().count(), 2)
- self.assertEqual(self.book1.materialize(), 'book 1')
- self.assertEqual(self.book2.materialize(), 'book 2')
-
- def test_split_book(self):
- self.book1.chunk_set.create(number=2, title='Second chunk',
- slug='book3')
- self.book1[1].commit('I survived!')
- self.assertEqual(len(self.book1), 2)
- self.book1.split()
- self.assertEqual(set([b.slug for b in Book.objects.all()]),
- set(['book2', '1', 'book3']))
- self.assertEqual(
- Book.objects.get(slug='book3').materialize(),
- 'I survived!')
diff --git a/apps/catalogue/tests/files/chunk1.xml b/apps/catalogue/tests/files/chunk1.xml
deleted file mode 100755
index 6a75580a..00000000
--- a/apps/catalogue/tests/files/chunk1.xml
+++ /dev/null
@@ -1,42 +0,0 @@
-
- {% endif %}
- {{ item.header }}
- {{ item.title }}
-
{% trans "user" %}:
- {% if item.user %}
-
- {{ item.user|username }}
- <{{ item.user.email|email_link }}>
- {% else %}
- {{ item.user_name }}
- {% if item.email %}
- <{{ item.email|email_link }}>
- {% endif %}
- ({% trans "not logged in" %})
- {% endif %}
-
{{ item.summary|linebreaksbr }}
- {% trans "Add image" %}
-
-
-
-
-
-
-
-{% endblock %}
diff --git a/apps/cover/templates/cover/image_detail.html b/apps/cover/templates/cover/image_detail.html
deleted file mode 100755
index db9b176f..00000000
--- a/apps/cover/templates/cover/image_detail.html
+++ /dev/null
@@ -1,59 +0,0 @@
-{% extends "catalogue/base.html" %}
-{% load i18n %}
-{% load thumbnail %}
-{% load build_absolute_uri from fnp_common %}
-
-{% block titleextra %}{% trans "Cover image" %}{% endblock %}
-
-{% block content %}
-{% trans "Cover image" %}
-
-
{{ object.title }} by {{ object.author }},
- {% if object.license_url %}{% endif %}
- {{ object.license_name }}
- {% if object.license_url %}{% endif %}
-
-
{% trans "source" %}: {{ object.download_url }}
-{% trans "Used in:" %}
-{% if object.book_set %}
-
- {% for book in object.book_set.all %}
-
-{% else %}
- {% trans "Cover images" %}
-
-{% if can_add %}
- {% trans "Add new" %}
-{% endif %}
-
-
-{% autopaginate object_list 100 %}
-{% for image in object_list %}
-
-
-
-
-
-{% endblock %}
diff --git a/apps/cover/tests.py b/apps/cover/tests.py
deleted file mode 100644
index be8d0033..00000000
--- a/apps/cover/tests.py
+++ /dev/null
@@ -1,20 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-from nose.tools import *
-from django.test import TestCase
-from cover.forms import FlickrForm
-
-
-class FlickrTests(TestCase):
- def test_flickr(self):
- form = FlickrForm({"source_url": "https://www.flickr.com/photos/rczajka/6941928577/in/photostream"})
- self.assertTrue(form.is_valid())
- self.assertEqual(form.cleaned_data['source_url'], "https://www.flickr.com/photos/rczajka/6941928577/")
- self.assertEqual(form.cleaned_data['author'], "Radek Czajka@Flickr")
- self.assertEqual(form.cleaned_data['title'], u"Pirate StaÅczyk")
- self.assertEqual(form.cleaned_data['license_name'], "CC BY 2.0")
- self.assertEqual(form.cleaned_data['license_url'], "https://creativecommons.org/licenses/by/2.0/")
- self.assertTrue('.staticflickr.com' in form.cleaned_data['download_url'])
diff --git a/apps/cover/urls.py b/apps/cover/urls.py
deleted file mode 100644
index 1146f62d..00000000
--- a/apps/cover/urls.py
+++ /dev/null
@@ -1,21 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-from django.conf.urls import patterns, url
-
-
-urlpatterns = patterns('cover.views',
- url(r'^preview/$', 'preview_from_xml', name='cover_preview'),
- url(r'^preview/(?P
- {{ image }}
-{% endfor %}
-{% paginate %}
-]*>(.*?)
', html, re.S)
- if not m:
- raise FlickrError('Error reading image title.')
- title = m.group(1).strip()
- m = re.search(r'modelExport: (\{.*\})', html)
- try:
- assert m
- download_url = 'https:' + json.loads(m.group(1))['main']['photo-models'][0]['sizes']['o']['url']
- except (AssertionError, ValueError, IndexError, KeyError):
- raise FlickrError('Error reading image URL.')
- return {
- 'source_url': base_url,
- 'license_url': license_url,
- 'license_name': license_name,
- 'author': author,
- 'title': title,
- 'download_url': download_url,
- }
diff --git a/apps/cover/views.py b/apps/cover/views.py
deleted file mode 100644
index 3f2c46fa..00000000
--- a/apps/cover/views.py
+++ /dev/null
@@ -1,141 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-import os.path
-from django.conf import settings
-from django.contrib.auth.decorators import permission_required
-from django.http import HttpResponse, HttpResponseRedirect, Http404
-from django.shortcuts import get_object_or_404, render
-from django.views.decorators.csrf import csrf_exempt
-from django.views.decorators.http import require_POST
-from catalogue.helpers import active_tab
-from catalogue.models import Chunk
-from cover.models import Image
-from cover import forms
-
-PREVIEW_SIZE = (216, 300)
-
-
-def preview(request, book, chunk=None, rev=None):
- """Creates a cover image.
-
- If chunk and rev number are given, use version from given revision.
- If rev is not given, use publishable version.
- """
- from PIL import Image
- from librarian.cover import make_cover
- from librarian.dcparser import BookInfo
-
- chunk = Chunk.get(book, chunk)
- if rev is not None:
- try:
- revision = chunk.at_revision(rev)
- except Chunk.change_model.DoesNotExist:
- raise Http404
- else:
- revision = chunk.publishable()
- if revision is None:
- raise Http404
- xml = revision.materialize().encode('utf-8')
-
- try:
- info = BookInfo.from_bytes(xml)
- except:
- return HttpResponseRedirect(os.path.join(settings.STATIC_URL, "img/sample_cover.png"))
- cover = make_cover(info)
- response = HttpResponse(content_type=cover.mime_type())
- img = cover.image().resize(PREVIEW_SIZE, Image.ANTIALIAS)
- img.save(response, cover.format)
- return response
-
-
-@csrf_exempt
-@require_POST
-def preview_from_xml(request):
- from hashlib import sha1
- from PIL import Image
- from os import makedirs
- from lxml import etree
- from librarian.cover import make_cover
- from librarian.dcparser import BookInfo
-
- xml = request.POST['xml']
- try:
- info = BookInfo.from_bytes(xml.encode('utf-8'))
- except:
- return HttpResponse(os.path.join(settings.STATIC_URL, "img/sample_cover.png"))
- coverid = sha1(etree.tostring(info.to_etree())).hexdigest()
- cover = make_cover(info)
-
- cover_dir = 'cover/preview'
- try:
- makedirs(os.path.join(settings.MEDIA_ROOT, cover_dir))
- except OSError:
- pass
- fname = os.path.join(cover_dir, "%s.%s" % (coverid, cover.ext()))
- img = cover.image().resize(PREVIEW_SIZE, Image.ANTIALIAS)
- img.save(os.path.join(settings.MEDIA_ROOT, fname))
- return HttpResponse(os.path.join(settings.MEDIA_URL, fname))
-
-
-@active_tab('cover')
-def image(request, pk):
- img = get_object_or_404(Image, pk=pk)
-
- if request.user.has_perm('cover.change_image'):
- if request.method == "POST":
- form = forms.ImageEditForm(request.POST, request.FILES, instance=img)
- if form.is_valid():
- form.save()
- return HttpResponseRedirect(img.get_absolute_url())
- else:
- form = forms.ImageEditForm(instance=img)
- editable = True
- else:
- form = forms.ReadonlyImageEditForm(instance=img)
- editable = False
-
- return render(request, "cover/image_detail.html", {
- "object": Image.objects.get(id=img.id),
- "form": form,
- "editable": editable,
- })
-
-
-def image_file(request, pk):
- img = get_object_or_404(Image, pk=pk)
- return HttpResponseRedirect(img.file.url)
-
-
-@active_tab('cover')
-def image_list(request):
- return render(request, "cover/image_list.html", {
- 'object_list': Image.objects.all(),
- 'can_add': request.user.has_perm('cover.add_image'),
- })
-
-
-@permission_required('cover.add_image')
-@active_tab('cover')
-def add_image(request):
- form = ff = None
- if request.method == 'POST':
- if request.POST.get('form_id') == 'flickr':
- ff = forms.FlickrForm(request.POST)
- if ff.is_valid():
- form = forms.ImageAddForm(ff.cleaned_data)
- else:
- form = forms.ImageAddForm(request.POST, request.FILES)
- if form.is_valid():
- obj = form.save()
- return HttpResponseRedirect(obj.get_absolute_url())
- if form is None:
- form = forms.ImageAddForm()
- if ff is None:
- ff = forms.FlickrForm()
- return render(request, 'cover/add_image.html', {
- 'form': form,
- 'ff': ff,
- })
diff --git a/apps/dvcs/__init__.py b/apps/dvcs/__init__.py
deleted file mode 100644
index e69de29b..00000000
diff --git a/apps/dvcs/locale/pl/LC_MESSAGES/django.mo b/apps/dvcs/locale/pl/LC_MESSAGES/django.mo
deleted file mode 100644
index dfd85c25..00000000
Binary files a/apps/dvcs/locale/pl/LC_MESSAGES/django.mo and /dev/null differ
diff --git a/apps/dvcs/locale/pl/LC_MESSAGES/django.po b/apps/dvcs/locale/pl/LC_MESSAGES/django.po
deleted file mode 100644
index c0365d56..00000000
--- a/apps/dvcs/locale/pl/LC_MESSAGES/django.po
+++ /dev/null
@@ -1,124 +0,0 @@
-# SOME DESCRIPTIVE TITLE.
-# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
-# This file is distributed under the same license as the PACKAGE package.
-# FIRST AUTHOR
-{% trans "Browse:" %}
-{% for crumb in view.breadcrumbs %}
- {% if crumb.1 %}
- {{ crumb.0 }}
- {% else %}
- {{ crumb.0 }}
- {% endif %}
- {% if not forloop.last %}/{% endif %}
-{% endfor %}
-
-
-
-
-
-
-
.xml
will be ignored."
-#~ msgstr ""
-#~ "ProszÄ wskazaÄ archiwum ZIP z plikami XML w kodowaniu UTF-8. Pliki nie "
-#~ "koÅczÄ
ce siÄ na .xml
zostanÄ
zignorowane."
-
-#~ msgid "Upload"
-#~ msgstr "ZaÅaduj"
-
-#~ msgid ""
-#~ "There have been some errors. No files have been added to the repository."
-#~ msgstr "WystÄ
piÅy bÅÄdy. Å»adne pliki nie zostaÅy dodane do repozytorium."
-
-#~ msgid "Offending files"
-#~ msgstr "BÅÄdne pliki"
-
-#~ msgid "Correct files"
-#~ msgstr "Poprawne pliki"
-
-#~ msgid "Files have been successfully uploaded to the repository."
-#~ msgstr "Pliki zostaÅy dodane do repozytorium."
-
-#~ msgid "Uploaded files"
-#~ msgstr "Dodane pliki"
-
-#~ msgid "Skipped files"
-#~ msgstr "PominiÄte pliki"
-
-#~ msgid "Files skipped due to no .xml
extension"
-#~ msgstr "Pliki pominiÄte z powodu braku rozszerzenia .xml
."
-
-#~ msgid "Users"
-#~ msgstr "Użytkownicy"
-
-#~ msgid "Assigned to me"
-#~ msgstr "Przypisane do mnie"
-
-#~ msgid "Unassigned"
-#~ msgstr "Nie przypisane"
-
-#~ msgid "All"
-#~ msgstr "Wszystkie"
-
-#~ msgid "Add"
-#~ msgstr "Dodaj"
-
-#~ msgid "Admin"
-#~ msgstr "Administracja"
-
-#~ msgid "First correction"
-#~ msgstr "Autokorekta"
-
-#~ msgid "Tagging"
-#~ msgstr "Tagowanie"
-
-#~ msgid "Initial Proofreading"
-#~ msgstr "Korekta"
-
-#~ msgid "Annotation Proofreading"
-#~ msgstr "Sprawdzenie przypisów źródÅa"
-
-#~ msgid "Modernisation"
-#~ msgstr "UwspóÅczeÅnienie"
-
-#~ msgid "Themes"
-#~ msgstr "Motywy"
-
-#~ msgid "Editor's Proofreading"
-#~ msgstr "Ostateczna redakcja literacka"
-
-#~ msgid "Technical Editor's Proofreading"
-#~ msgstr "Ostateczna redakcja techniczna"
-
-#~ msgid "Finished stage: %s"
-#~ msgstr "UkoÅczony etap: %s"
-
-#~ msgid "Refresh"
-#~ msgstr "OdÅwież"
-
-#~ msgid "Insert special character"
-#~ msgstr "Wstaw znak specjalny"
diff --git a/apps/wiki/migrations/0001_initial.py b/apps/wiki/migrations/0001_initial.py
deleted file mode 100644
index 4acf5ba5..00000000
--- a/apps/wiki/migrations/0001_initial.py
+++ /dev/null
@@ -1,21 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
- pass
-
-
- def backwards(self, orm):
- pass
-
-
- models = {
-
- }
-
- complete_apps = ['wiki']
diff --git a/apps/wiki/migrations/0002_auto__add_theme.py b/apps/wiki/migrations/0002_auto__add_theme.py
deleted file mode 100644
index 6688139d..00000000
--- a/apps/wiki/migrations/0002_auto__add_theme.py
+++ /dev/null
@@ -1,38 +0,0 @@
-# encoding: utf-8
-import datetime
-from south.db import db
-from south.v2 import SchemaMigration
-from django.db import models
-
-class Migration(SchemaMigration):
-
- def forwards(self, orm):
-
- # Adding model 'Theme'
- db.create_table('wiki_theme', (
- ('id', self.gf('django.db.models.fields.AutoField')(primary_key=True)),
- ('name', self.gf('django.db.models.fields.CharField')(unique=True, max_length=50)),
- ))
- db.send_create_signal('wiki', ['Theme'])
-
- if not db.dry_run:
- from django.core.management import call_command
- call_command("loaddata", "initial_themes.yaml")
-
-
-
- def backwards(self, orm):
-
- # Deleting model 'Theme'
- db.delete_table('wiki_theme')
-
-
- models = {
- 'wiki.theme': {
- 'Meta': {'object_name': 'Theme'},
- 'id': ('django.db.models.fields.AutoField', [], {'primary_key': 'True'}),
- 'name': ('django.db.models.fields.CharField', [], {'unique': 'True', 'max_length': '50'})
- }
- }
-
- complete_apps = ['wiki']
diff --git a/apps/wiki/migrations/__init__.py b/apps/wiki/migrations/__init__.py
deleted file mode 100644
index e69de29b..00000000
diff --git a/apps/wiki/models.py b/apps/wiki/models.py
deleted file mode 100644
index c539908d..00000000
--- a/apps/wiki/models.py
+++ /dev/null
@@ -1,26 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-from django.db import models
-from django.utils.translation import ugettext_lazy as _
-
-import logging
-logger = logging.getLogger("fnp.wiki")
-
-
-class Theme(models.Model):
- name = models.CharField(_('name'), max_length=50, unique=True)
-
- class Meta:
- ordering = ('name',)
- verbose_name = _('theme')
- verbose_name_plural = _('themes')
-
- def __unicode__(self):
- return self.name
-
- def __repr__(self):
- return "Theme(name=%r)" % self.name
-
diff --git a/apps/wiki/nice_diff.py b/apps/wiki/nice_diff.py
deleted file mode 100644
index b228fad9..00000000
--- a/apps/wiki/nice_diff.py
+++ /dev/null
@@ -1,61 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
-import difflib
-import re
-from collections import deque
-
-from django.template.loader import render_to_string
-from django.utils.html import escape as html_escape
-
-DIFF_RE = re.compile(r"""\x00([+^-])""", re.UNICODE)
-NAMES = {'+': 'added', '-': 'removed', '^': 'changed'}
-
-
-def diff_replace(match):
- return """""" % NAMES[match.group(1)]
-
-
-def filter_line(line):
- return DIFF_RE.sub(diff_replace, html_escape(line)).replace('\x01', '')
-
-
-def format_changeset(a, b, change):
- return (a[0], filter_line(a[1]), b[0], filter_line(b[1]), change)
-
-
-def html_diff_table(la, lb, context=None):
- all_changes = difflib._mdiff(la, lb)
-
- if context is None:
- changes = (format_changeset(*c) for c in all_changes)
- else:
- changes = []
- q = deque()
- after_change = False
-
- for changeset in all_changes:
- q.append(changeset)
-
- if changeset[2]:
- after_change = True
- if not after_change:
- changes.append((0, '-----', 0, '-----', False))
- changes.extend(format_changeset(*c) for c in q)
- q.clear()
- else:
- if len(q) == context and after_change:
- changes.extend(format_changeset(*c) for c in q)
- q.clear()
- after_change = False
- elif len(q) > context:
- q.popleft()
-
- return render_to_string("wiki/diff_table.html", {
- "changes": changes,
- })
-
-
-__all__ = ['html_diff_table']
diff --git a/apps/wiki/settings.py b/apps/wiki/settings.py
deleted file mode 100644
index 50f49d8b..00000000
--- a/apps/wiki/settings.py
+++ /dev/null
@@ -1,3 +0,0 @@
-from django.conf import settings
-
-GALLERY_URL = settings.MEDIA_URL + 'images/'
diff --git a/apps/wiki/templates/admin/wiki/theme/change_list.html b/apps/wiki/templates/admin/wiki/theme/change_list.html
deleted file mode 100755
index 3e5d2ea4..00000000
--- a/apps/wiki/templates/admin/wiki/theme/change_list.html
+++ /dev/null
@@ -1,29 +0,0 @@
-{% extends "admin/change_list.html" %}
-{% load i18n %}
-
-{% block extrahead %}
-{{ block.super }}
-
-{% endblock %}
-
-
-
-{% block pretitle %}
-
-
-â {% trans "Table for Redmine wiki" %} â
-
-
-{{ block.super }}
-{% endblock %}
diff --git a/apps/wiki/templates/wiki/diff_table.html b/apps/wiki/templates/wiki/diff_table.html
deleted file mode 100644
index 818c38cc..00000000
--- a/apps/wiki/templates/wiki/diff_table.html
+++ /dev/null
@@ -1,21 +0,0 @@
-{% load i18n %}
-{% trans "Old version" %} | -{% trans "New version" %} | -||
---|---|---|---|
{{an}} | -{{ a|safe }} | -{{bn}} | -{{ b|safe }} | -
{% trans "Search" %}:
-
-
-
{% trans "Replace with" %}:
-
-
-
-
-
{% trans "Options" %}
-
-
-
-
-
- Potrzebne materialy k1asa -
diff --git a/apps/wiki/tests/xslt/auto/data/big.xml b/apps/wiki/tests/xslt/auto/data/big.xml deleted file mode 100644 index de73d5f0..00000000 --- a/apps/wiki/tests/xslt/auto/data/big.xml +++ /dev/null @@ -1,1049 +0,0 @@ -.xml
will be ignored."
-#~ msgstr ""
-#~ "ProszÄ wskazaÄ archiwum ZIP z plikami XML w kodowaniu UTF-8. Pliki nie "
-#~ "koÅczÄ
ce siÄ na .xml
zostanÄ
zignorowane."
-
-#~ msgid "Upload"
-#~ msgstr "Dodaj"
-
-#~ msgid ""
-#~ "There have been some errors. No files have been added to the repository."
-#~ msgstr "WystÄ
piÅy bÅÄdy. Å»adne pliki nie zostaÅy dodane do repozytorium."
-
-#~ msgid "Offending files"
-#~ msgstr "BÅÄdne pliki"
-
-#~ msgid "Correct files"
-#~ msgstr "Poprawne pliki"
-
-#~ msgid "Files have been successfully uploaded to the repository."
-#~ msgstr "Pliki zostaÅy dodane do repozytorium."
-
-#~ msgid "Uploaded files"
-#~ msgstr "Dodane pliki"
-
-#~ msgid "Skipped files"
-#~ msgstr "PominiÄte pliki"
-
-#~ msgid "Files skipped due to no .xml
extension"
-#~ msgstr "Pliki pominiÄte z powodu braku rozszerzenia .xml
."
-
-#~ msgid "Refresh"
-#~ msgstr "OdÅwież"
-
-#~ msgid "Previous"
-#~ msgstr "Poprzednie"
-
-#~ msgid "Next"
-#~ msgstr "NastÄpne"
-
-#~ msgid "Zoom in"
-#~ msgstr "PowiÄksz"
-
-#~ msgid "Zoom out"
-#~ msgstr "Zmniejsz"
-
-#~ msgid "Gallery"
-#~ msgstr "Galeria"
-
-#~ msgid "Mark version"
-#~ msgstr "Oznacz wersjÄ"
-
-#~ msgid "History"
-#~ msgstr "Historia"
-
-#~ msgid "Search"
-#~ msgstr "Szukaj"
-
-#~ msgid "Replace with"
-#~ msgstr "ZamieÅ na"
-
-#~ msgid "Replace"
-#~ msgstr "ZamieÅ"
-
-#~ msgid "Options"
-#~ msgstr "Opcje"
-
-#~ msgid "Case sensitive"
-#~ msgstr "Rozróżniaj wielkoÅÄ liter"
-
-#~ msgid "From cursor"
-#~ msgstr "Zacznij od kursora"
-
-#~ msgid "Search and replace"
-#~ msgstr "Znajdź i zamieÅ"
-
-#~ msgid "Link to gallery"
-#~ msgstr "Link do galerii"
-
-#~ msgid "Insert theme"
-#~ msgstr "Wstaw motyw"
-
-#~ msgid "Insert annotation"
-#~ msgstr "Wstaw przypis"
-
-#~ msgid "Insert special character"
-#~ msgstr "Wstaw znak specjalny"
-
-#~ msgid "Visual editor"
-#~ msgstr "Edytor wizualny"
diff --git a/apps/wiki_img/models.py b/apps/wiki_img/models.py
deleted file mode 100644
index b685324b..00000000
--- a/apps/wiki_img/models.py
+++ /dev/null
@@ -1,5 +0,0 @@
-# -*- coding: utf-8 -*-
-#
-# This file is part of FNP-Redakcja, licensed under GNU Affero GPLv3 or later.
-# Copyright © Fundacja Nowoczesna Polska. See NOTICE for more information.
-#
diff --git a/apps/wiki_img/templates/wiki_img/diff_table.html b/apps/wiki_img/templates/wiki_img/diff_table.html
deleted file mode 100644
index 818c38cc..00000000
--- a/apps/wiki_img/templates/wiki_img/diff_table.html
+++ /dev/null
@@ -1,21 +0,0 @@
-{% load i18n %}
-{% trans "Old version" %} | -{% trans "New version" %} | -||
---|---|---|---|
{{an}} | -{{ a|safe }} | -{{bn}} | -{{ b|safe }} | -
- This plugin lets you add context menu functionality to your web applications. -
- -- Tip: Try using your keyboard to make a selection. -
- - - -- - -
- -- - -
-