summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2019-03-03 15:42:30 -0600
committerluxagraf <sng@luxagraf.net>2019-03-03 15:42:30 -0600
commitc24e6043db413f5722e7d378805da069698d64e7 (patch)
tree918a82522b1f2775bbdceb8abc3d0772c0c50f4a
parent16e406acfe5ae26b7f80fa6b7cb1a1c1194d4697 (diff)
got rid of old sketches model
-rw-r--r--app/jrnl/models.py1
-rw-r--r--app/unused_apps/sketches/__init__.py (renamed from app/sketches/__init__.py)0
-rw-r--r--app/unused_apps/sketches/admin.py (renamed from app/sketches/admin.py)6
-rw-r--r--app/unused_apps/sketches/build.py (renamed from app/sketches/build.py)0
-rw-r--r--app/unused_apps/sketches/migrations/0001_initial.py (renamed from app/sketches/migrations/0001_initial.py)0
-rw-r--r--app/unused_apps/sketches/migrations/0002_auto_20180208_0743.py (renamed from app/sketches/migrations/0002_auto_20180208_0743.py)0
-rw-r--r--app/unused_apps/sketches/migrations/__init__.py (renamed from app/sketches/migrations/__init__.py)0
-rw-r--r--app/unused_apps/sketches/models.py (renamed from app/sketches/models.py)3
-rw-r--r--app/unused_apps/sketches/urls.py (renamed from app/sketches/urls.py)0
-rw-r--r--app/unused_apps/sketches/views.py (renamed from app/sketches/views.py)0
-rw-r--r--design/templates/archives/notes.html2
-rw-r--r--design/templates/archives/sketches.html72
12 files changed, 30 insertions, 54 deletions
diff --git a/app/jrnl/models.py b/app/jrnl/models.py
index c3aace3..88fd84b 100644
--- a/app/jrnl/models.py
+++ b/app/jrnl/models.py
@@ -20,7 +20,6 @@ from django_comments.moderation import CommentModerator, moderator
from photos.models import PhotoGallery, LuxImage, LuxImageSize
from locations.models import Location
-from sketches.models import Sketch
from books.models import Book
from fieldnotes.models import FieldNote
diff --git a/app/sketches/__init__.py b/app/unused_apps/sketches/__init__.py
index e69de29..e69de29 100644
--- a/app/sketches/__init__.py
+++ b/app/unused_apps/sketches/__init__.py
diff --git a/app/sketches/admin.py b/app/unused_apps/sketches/admin.py
index 07a2e6a..0c59867 100644
--- a/app/sketches/admin.py
+++ b/app/unused_apps/sketches/admin.py
@@ -6,17 +6,19 @@ from .models import Sketch
from utils.widgets import LGEntryForm, OLAdminBase
from utils.util import get_latlon
+
@admin.register(Sketch)
class SketchAdmin(OLAdminBase):
form = LGEntryForm
-
prepopulated_fields = {"slug": ('title',)}
list_display = ('title', 'slug', 'pub_date', 'location')
fieldsets = (
('Note', {
'fields': (
- ('title', 'slug'),
+ 'title',
+ 'subtitle',
'body_markdown',
+ 'slug',
('pub_date', 'status'),
'point'
),
diff --git a/app/sketches/build.py b/app/unused_apps/sketches/build.py
index e75b6fd..e75b6fd 100644
--- a/app/sketches/build.py
+++ b/app/unused_apps/sketches/build.py
diff --git a/app/sketches/migrations/0001_initial.py b/app/unused_apps/sketches/migrations/0001_initial.py
index 1e034b4..1e034b4 100644
--- a/app/sketches/migrations/0001_initial.py
+++ b/app/unused_apps/sketches/migrations/0001_initial.py
diff --git a/app/sketches/migrations/0002_auto_20180208_0743.py b/app/unused_apps/sketches/migrations/0002_auto_20180208_0743.py
index 664fcbc..664fcbc 100644
--- a/app/sketches/migrations/0002_auto_20180208_0743.py
+++ b/app/unused_apps/sketches/migrations/0002_auto_20180208_0743.py
diff --git a/app/sketches/migrations/__init__.py b/app/unused_apps/sketches/migrations/__init__.py
index e69de29..e69de29 100644
--- a/app/sketches/migrations/__init__.py
+++ b/app/unused_apps/sketches/migrations/__init__.py
diff --git a/app/sketches/models.py b/app/unused_apps/sketches/models.py
index aa21678..f6df269 100644
--- a/app/sketches/models.py
+++ b/app/unused_apps/sketches/models.py
@@ -14,7 +14,8 @@ def render_images(s):
return s
class Sketch(models.Model):
- title = models.CharField(max_length=250, null=True, blank=True)
+ title = models.CharField(max_length=250, blank=True)
+ subtitle = models.CharField(max_length=250,blank=True)
slug = models.SlugField(unique_for_date='pub_date', blank=True)
pub_date = models.DateTimeField(default=timezone.now)
body_html = models.TextField(blank=True)
diff --git a/app/sketches/urls.py b/app/unused_apps/sketches/urls.py
index 465a0d2..465a0d2 100644
--- a/app/sketches/urls.py
+++ b/app/unused_apps/sketches/urls.py
diff --git a/app/sketches/views.py b/app/unused_apps/sketches/views.py
index b696932..b696932 100644
--- a/app/sketches/views.py
+++ b/app/unused_apps/sketches/views.py
diff --git a/design/templates/archives/notes.html b/design/templates/archives/notes.html
index 8dc168e..9960fc8 100644
--- a/design/templates/archives/notes.html
+++ b/design/templates/archives/notes.html
@@ -14,7 +14,7 @@
<main role="main">
<h1>Field Notes</h1>
<h4 class="subhead divide-after">Quick notes and images from the road</h4>
- {% autopaginate object_list 2 %}{% for object in object_list %}
+ {% autopaginate object_list 16 %}{% for object in object_list %}
<article class="h-entry">
<h2 class="p-name note--title hide">{{object.title|safe|amp|smartypants}}</h2>
<h5 class="note--date-hed"><a class="u-url" href="{{object.get_absolute_url}}" rel="bookmark"><time class="dt-published" datetime="{{object.pub_date|html5_datetime}}">{{object.pub_date|date:"F j, Y"}}</time></a></h5>
diff --git a/design/templates/archives/sketches.html b/design/templates/archives/sketches.html
index cf53ac1..06fe311 100644
--- a/design/templates/archives/sketches.html
+++ b/design/templates/archives/sketches.html
@@ -4,61 +4,35 @@
{% load pagination_tags %}
{% block pagetitle %} Field Notes | luxagraf {% endblock %}
{% block metadescription %} Rough notes and sketches from the field {% endblock %}
-{%block bodyid%}class="notes" id="notes-archive"{%endblock%}
+{%block bodyid%}id="field-notes"{%endblock%}
{% block primary %}
<ul class="bl" id="breadcrumbs" itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
<li><a href="/" title="luxagraf homepage" itemprop="url"><span itemprop="title">Home</span></a> &rarr; </li>
<li>Field Notes</li>
</ul>
- <main role="main">
- <h1>Field Notes</h1>
- <h4 class="subhead divide-after">Quick notes, sketches and images from the road (often literally)</h4>
- {% autopaginate object_list 8 %}{% for object in object_list %}
- <article class="h-entry post--article">
- {% if object.title %}<h1 class="p-name note--title"><a href="{{object.get_absolute_url}}" class="permalink">{{object.title|safe|amp|smartypants}}</a></h1>{%endif%}
- <div class="e-content">
- {{object.body_html|safe|smartypants}}
- </div>
- <span class="p-author h-card">
- <data class="p-name" value="Scott Gilbertson"></data>
- <data class="u-url" value="https://luxagraf.net/"></data>
- </span>
- <footer>
- {%comment%}<p class="note--date">
- <a class="u-url" href="{{object.get_absolute_url}}" rel="bookmark"><time class="dt-published" datetime="{{object.pub_date|html5_datetime}}">{{object.pub_date|date:"F j, Y"}}</time></a>
- </p>{%endcomment%}{% if object.location %}
- <p class="p-location h-adr note--location bl" itemprop="geo" itemscope itemtype="http://data-vocabulary.org/Geo">
- <span class="p-locality">{{object.location.name|smartypants|safe}}</span>,
- <span class="p-region">{{object.location.state.name}}</span>,
- <span class="p-country-name">{{object.location.state.country.name}}</span>
- <data class="p-latitude" value="{{object.latitude}}"></data>
- <data class="p-longitude" value="{{object.longitude}}"></data>
- </p>{% endif %}
-
- <p class="note--date">
- <a class="u-url" href="{{object.get_absolute_url}}" rel="bookmark"><time class="dt-published" datetime="{{object.pub_date|html5_datetime}}">{{object.pub_date|date:"F j, Y"}}</time></a>
- </p>
- {% comment %} {% if object.twitter_id %}
- <ul class="note--actions">
- <li><a rel="syndication" class="u-syndication" href="https://twitter.com/luxagraf/status/{{object.twitter_id}}">View on Twitter</a></li>
- <li>
- <indie-action do="reply" with="{{SITE_URL}}{{object.get_absolute_url}}"><a href="https://twitter.com/intent/tweet?in_reply_to={{object.twitter_id}}">Reply</a></indie-action>
- </li>
- <li>
- <indie-action do="post" with="{{SITE_URL}}{{object.get_absolute_url}}">
- <a href="https://twitter.com/intent/retweet?tweet_id={{object.twitter_id}}">Retweet</a>
- </indie-action>
- </li>
- <li>
- <indie-action do="bookmark" with="{{SITE_URL}}{{object.get_absolute_url}}">
- <a href="https://twitter.com/intent/favorite?tweet_id={{object.twitter_id}}">Favourite</a>
- </indie-action>
- </li>
- </ul>{% endif %}{% endcomment %}
- </footer>
- </article>
-{% endfor %}
+ <main role="main" id="essay-archive" class="essay-archive archive-list">
+ <div class="essay-intro">
+ <h2>Field Notes</h2>
+ <p>Quick notes, sketches and images from the road. This is the semi-orgnized brain dump that comes before the more organized <a href="/jrnl/" title="read the journal">journal entries</a> and <a href="/essays/" title="read essays">essays</a>. If I used social media this is the stuff I'd probably put there, but I prefer to put it here, even if it means a lot few people read it.</p>
+ </div>
+ {% autopaginate object_list 30 %}
+ <ul class="fancy-archive-list">{% for object in object_list %}{% if object.slug != 'about' %}
+ <li class="h-entry hentry" itemscope itemType="http://schema.org/Article">
+ <span class="date dt-published">{{object.pub_date|date:"F d, Y"}}</span>
+ <a href="{{object.get_absolute_url}}">
+ <h2>{{object.title|safe|smartypants|widont}}</h2>
+ {% if object.subtitle %}<h3 class="p-summary">{{object.subtitle|safe|smartypants|widont}}</h3>{%endif%}
+ </a>
+ {% if object.location %}<h4 class="p-location h-adr post-location" itemprop="geo" itemscope itemtype="http://data-vocabulary.org/Geo">
+ <span class="p-locality">{{object.location.name|smartypants|safe}}</span>,
+ <span class="p-region">{{object.location.state_name}}</span>,
+ <span class="p-country-name">{{object.location.country_name}}</span>
+ <data class="p-latitude" value="{{object.latitude}}"></data>
+ <data class="p-longitude" value="{{object.longitude}}"></data>
+ </h4>{% endif %}
+ </li>
+ {%endif%}{%endfor%}</ul>
</main>
<nav class="pagination">