forked from rc/aircox
nc
This commit is contained in:
parent
3a44c2d479
commit
bb185a02d4
|
@ -484,6 +484,7 @@ class ProgramPage(Publication):
|
|||
def save(self, *args, **kwargs):
|
||||
# set publish_as
|
||||
if self.program and not self.pk:
|
||||
super().save()
|
||||
self.publish_as = self
|
||||
super().save(*args, **kwargs)
|
||||
|
||||
|
|
|
@ -67,6 +67,10 @@ ul {
|
|||
padding: 0.4em;
|
||||
}
|
||||
|
||||
.menu:empty {
|
||||
display: none;
|
||||
}
|
||||
|
||||
body > .top *,
|
||||
body > .header * {
|
||||
vertical-align: middle;
|
||||
|
@ -123,6 +127,9 @@ body > .header {
|
|||
}
|
||||
|
||||
|
||||
.page_left { margin-right: 2em; }
|
||||
.page_right { margin-right: 2em; }
|
||||
|
||||
.page_left, .page_right {
|
||||
max-width: 16em;
|
||||
}
|
||||
|
|
|
@ -82,7 +82,7 @@ a:hover > .small_icon {
|
|||
|
||||
main {
|
||||
background-color: rgba(255,255,255,0.9);
|
||||
margin: 0em 2em;
|
||||
margin: 0em 0em;
|
||||
box-shadow: 0em 0em 0.2em black;
|
||||
width: 60%;
|
||||
}
|
||||
|
@ -110,6 +110,7 @@ main .post_content section {
|
|||
/** detail view **/
|
||||
main.detail {
|
||||
padding: 0em;
|
||||
margin: 0em;
|
||||
}
|
||||
|
||||
main > .content {
|
||||
|
|
|
@ -12,13 +12,17 @@ class TemplateMixin(models.Model):
|
|||
Template to use for the mixin. If not given, use
|
||||
"app_label/sections/section_class.html"
|
||||
"""
|
||||
snake_name = None
|
||||
"""
|
||||
Used in template as class
|
||||
"""
|
||||
|
||||
@classmethod
|
||||
def get_template_name(cl):
|
||||
if not cl.template_name:
|
||||
snake_name = camelcase_to_underscore(cl.__name__)
|
||||
cl.snake_name = camelcase_to_underscore(cl.__name__)
|
||||
cl.template_name = '{}/sections/{}.html'.format(
|
||||
cl._meta.app_label, snake_name
|
||||
cl._meta.app_label, cl.snake_name
|
||||
)
|
||||
|
||||
if snake_name != 'section_item':
|
||||
|
|
Loading…
Reference in New Issue
Block a user