Skip to content

Commit

Permalink
Merge branch 'dev' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
francesco-filicetti committed Dec 2, 2021
2 parents ff99471 + a0ce785 commit 861957a
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 115 deletions.
7 changes: 5 additions & 2 deletions example/unicms/settingslocal.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,9 +258,13 @@
'cms.publications.handlers.PublicationListHandler' : CMS_PUBLICATION_URL_LIST_REGEXP,
}

# UNICMS ITALIA TEMPLATE
if "unicms_template_italia" in INSTALLED_APPS:
from unicms_template_italia.settings import *
# END UNICMS ITALIA TEMPLATE

# UNICMS CALENDAR HANDLER
if "unicms_calendar" in INSTALLED_APPS:

from unicms_calendar.settings import *

CMS_HANDLERS_PATHS.extend(CMS_CALENDAR_HANDLERS_PATHS)
Expand All @@ -269,7 +273,6 @@

# UNICAL STORAGE HANDLER
if "unicms_unical_storage_handler" in INSTALLED_APPS:

from unicms_unical_storage_handler.settings import *

CMS_HANDLERS_PATHS.extend(CMS_STORAGE_HANDLERS_PATHS)
Expand Down
2 changes: 1 addition & 1 deletion publiccode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ platforms:
releaseDate: '2021-12-02'
roadmap: 'https://github.com/UniversitaDellaCalabria/uniCMS/issues'
softwareType: standalone/web
softwareVersion: v0.30.0
softwareVersion: v0.30.1
url: 'https://github.com/UniversitaDellaCalabria/uniCMS'
usedBy:
- Università della Calabria - https://www.unical.it
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def get_requirements(fname='requirements.txt'):

setup(
name="unicms",
version='0.30.0',
version='0.30.1',
description="uniCMS is a Django Web Content Management System",
long_description=README,
long_description_content_type='text/markdown',
Expand Down
4 changes: 2 additions & 2 deletions src/cms/templates/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,13 @@
app_settings.CMS_BLOCK_TYPES)
CMS_BLOCK_TEMPLATES = getattr(settings, 'CMS_BLOCK_TEMPLATES',
app_settings.CMS_BLOCK_TEMPLATES)
CMS_TEMPLATE_BLOCK_SECTIONS = getattr(settings, 'CMS_TEMPLATE_BLOCK_SECTIONS',
app_settings.CMS_TEMPLATE_BLOCK_SECTIONS)
CMS_PAGE_TEMPLATES = getattr(settings, 'CMS_PAGE_TEMPLATES',
app_settings.CMS_PAGE_TEMPLATES)
CMS_LINKS_LABELS = getattr(settings, 'CMS_LINKS_LABELS',
app_settings.CMS_LINKS_LABELS)

CMS_TEMPLATE_BLOCK_SECTIONS = getattr(settings, 'CMS_TEMPLATE_BLOCK_SECTIONS')


class CreatedModifiedBy(models.Model):
created_by = models.ForeignKey(get_user_model(),
Expand Down
107 changes: 0 additions & 107 deletions src/cms/templates/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,113 +11,6 @@
# BASE_DIR = Path(__file__).resolve().parent.parent
BASE_DIR = os.getcwd()


CMS_TEMPLATE_BLOCK_SECTIONS = (
('pre-head', _('Pre-Head')),
('head', _('Head')),

('menu-1', _('Menu-1')),
('menu-2', _('Menu-2')),
('menu-3', _('Menu-3')),
('menu-4', _('Menu-4')),

('banner', _('Banner')),
('slider-2', _('Slider-2')),

('pre-footer', _('Pre-Footer')),
('footer', _('Footer')),
('post-footer', _('Post-Footer')),

# breadcrumbs
('breadcrumbs', _('Breadcrumbs')),

# section 1
('section-1',
(
('1-top-a', _('Section 1 - Top A')),
('1-top-b', _('Section 1 - Top B')),
('1-top-c', _('Section 1 - Top C')),
('1-mid-top-a', _('Section 1 - Middle Top A')),
('1-mid-top-b', _('Section 1 - Middle Top B')),
('1-mid-top-c', _('Section 1 - Middle Top C')),
('1-left-a', _('Section 1 - Left A')),
('1-left-b', _('Section 1 - Left B')),
('1-center-top-a', _('Section 1 - Center Top A')),
('1-center-top-b', _('Section 1 - Center Top B')),
('1-center-top-c', _('Section 1 - Center Top C')),
('1-center-content', _('Section 1 - Center Content')),
('1-center-bottom-a', _('Section 1 - Center Bottom A')),
('1-center-bottom-b', _('Section 1 - Center Bottom B')),
('1-center-bottom-c', _('Section 1 - Center Bottom C')),
('1-right-a', _('Section 1 - Right A')),
('1-right-b', _('Section 1 - Right B')),
('1-mid-bottom-a', _('Section 1 - Middle Bottom A')),
('1-mid-bottom-b', _('Section 1 - Middle Bottom B')),
('1-mid-bottom-c', _('Section 1 - Middle Bottom C')),
('1-bottom-a', _('Section 1 - Bottom A')),
('1-bottom-b', _('Section 1 - Bottom B')),
('1-bottom-c', _('Section 1 - Bottom C')),
)
),

# section 2
('section-2',
(
('2-top-a', _('Section 2 - Top A')),
('2-top-b', _('Section 2 - Top B')),
('2-top-c', _('Section 2 - Top C')),
('2-mid-top-a', _('Section 2 - Middle Top A')),
('2-mid-top-b', _('Section 2 - Middle Top B')),
('2-mid-top-c', _('Section 2 - Middle Top C')),
('2-left-a', _('Section 2 - Left A')),
('2-left-b', _('Section 2 - Left B')),
('2-center-top-a', _('Section 2 - Center Top A')),
('2-center-top-b', _('Section 2 - Center Top B')),
('2-center-top-c', _('Section 2 - Center Top C')),
('2-center-content', _('Section 2 - Center Content')),
('2-center-bottom-a', _('Section 2 - Center Bottom A')),
('2-center-bottom-b', _('Section 2 - Center Bottom B')),
('2-center-bottom-c', _('Section 2 - Center Bottom C')),
('2-right-a', _('Section 2 - Right A')),
('2-right-b', _('Section 2 - Right B')),
('2-mid-bottom-a', _('Section 2 - Middle Bottom A')),
('2-mid-bottom-b', _('Section 2 - Middle Bottom B')),
('2-mid-bottom-c', _('Section 2 - Middle Bottom C')),
('2-bottom-a', _('Section 2 - Bottom A')),
('2-bottom-b', _('Section 2 - Bottom B')),
('2-bottom-c', _('Section 2 - Bottom C')),
)
),

('section-3',
(
('3-top-a', _('Section 3 - Top A')),
('3-top-b', _('Section 3 - Top B')),
('3-top-c', _('Section 3 - Top C')),
('3-mid-top-a', _('Section 3 - Middle Top A')),
('3-mid-top-b', _('Section 3 - Middle Top B')),
('3-mid-top-c', _('Section 3 - Middle Top C')),
('3-left-a', _('Section 3 - Left A')),
('3-left-b', _('Section 3 - Left B')),
('3-center-top-a', _('Section 3 - Center Top A')),
('3-center-top-b', _('Section 3 - Center Top B')),
('3-center-top-c', _('Section 3 - Center Top C')),
('3-center-content', _('Section 3 - Center Content')),
('3-center-bottom-a', _('Section 3 - Center Bottom A')),
('3-center-bottom-b', _('Section 3 - Center Bottom B')),
('3-center-bottom-c', _('Section 3 - Center Bottom C')),
('3-right-a', _('Section 3 - Right A')),
('3-right-b', _('Section 3 - Right B')),
('3-mid-bottom-a', _('Section 3 - Middle Bottom A')),
('3-mid-bottom-b', _('Section 3 - Middle Bottom B')),
('3-mid-bottom-c', _('Section 3 - Middle Bottom C')),
('3-bottom-a', _('Section 3 - Bottom A')),
('3-bottom-b', _('Section 3 - Bottom B')),
('3-bottom-c', _('Section 3 - Bottom C')),
)
),
)

CMS_BLOCK_TYPES = (
('cms.templates.blocks.HtmlBlock', 'HTML Block'),
('cms.templates.blocks.JSONBlock', 'JSON Block'),
Expand Down
3 changes: 1 addition & 2 deletions src/cms/templates/templatetags/unicms_templates.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@
logger = logging.getLogger(__name__)
register = template.Library()

CMS_TEMPLATE_BLOCK_SECTIONS = getattr(settings, "CMS_TEMPLATE_BLOCK_SECTIONS",
app_settings.CMS_TEMPLATE_BLOCK_SECTIONS)
CMS_TEMPLATE_BLOCK_SECTIONS = getattr(settings, "CMS_TEMPLATE_BLOCK_SECTIONS")


@register.simple_tag
Expand Down

0 comments on commit 861957a

Please sign in to comment.