|
|
@ -23,8 +23,16 @@ from mediagoblin.db.models import MediaEntry |
|
|
|
from mediagoblin.db.util import media_entries_for_tag_slug |
|
|
|
from mediagoblin.db.util import media_entries_for_tag_slug |
|
|
|
from mediagoblin.tools.pagination import Pagination |
|
|
|
from mediagoblin.tools.pagination import Pagination |
|
|
|
from mediagoblin.tools.response import render_to_response |
|
|
|
from mediagoblin.tools.response import render_to_response |
|
|
|
|
|
|
|
from mediagoblin.tools.licenses import SORTED_LICENSES, SUPPORTED_LICENSES, License |
|
|
|
from mediagoblin.decorators import uses_pagination, user_not_banned |
|
|
|
from mediagoblin.decorators import uses_pagination, user_not_banned |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Add CC BY-SA 4.0 to licenses |
|
|
|
|
|
|
|
cc_by_sa_4 = License("CC BY-SA 4.0", |
|
|
|
|
|
|
|
"Creative Commons Attribution-ShareAlike 4.0 International", |
|
|
|
|
|
|
|
"https://creativecommons.org/licenses/by-sa/4.0/") |
|
|
|
|
|
|
|
SORTED_LICENSES.insert(1, cc_by_sa_4) |
|
|
|
|
|
|
|
SUPPORTED_LICENSES[cc_by_sa_4.uri] = cc_by_sa_4 |
|
|
|
|
|
|
|
|
|
|
|
PLUGIN_DIR = os.path.dirname(__file__) |
|
|
|
PLUGIN_DIR = os.path.dirname(__file__) |
|
|
|
MAX_HOME_ITEMS = 20 |
|
|
|
MAX_HOME_ITEMS = 20 |
|
|
|
LP_TAG = 'lp2015' |
|
|
|
LP_TAG = 'lp2015' |
|
|
|