Messing with millenialcaves.html or similar

This commit is contained in:
Rad 2019-02-26 00:17:11 +00:00
parent 83e489c425
commit a61ad6e7b8
3 changed files with 8 additions and 1 deletions

View File

@ -397,6 +397,8 @@ class Cave(TroggleModel):
url = models.CharField(max_length=200,blank=True,null=True) url = models.CharField(max_length=200,blank=True,null=True)
filename = models.CharField(max_length=200) filename = models.CharField(max_length=200)
fixedfield = "napis"
#class Meta: #class Meta:
# unique_together = (("area", "kataster_number"), ("area", "unofficial_number")) # unique_together = (("area", "kataster_number"), ("area", "unofficial_number"))
# FIXME Kataster Areas and CUCC defined sub areas need seperating # FIXME Kataster Areas and CUCC defined sub areas need seperating

View File

@ -13,7 +13,7 @@
<h3>Notable caves</h3> <h3>Notable caves</h3>
<ul> <ul>
{% for cave in notablecaves %} {% for cave in notablecaves %}
<li> <a href="{{ cave.url }}">{% if cave.kataster_number %}{{ cave.kataster_number }}{% else %}{{cave.unofficial_number }}{%endif %} {{cave.official_name|safe}}</a> </li> <li> <a href="{{ cave.fixedfield }}">{% if cave.kataster_number %}{{ cave.kataster_number }}{% else %}{{cave.unofficial_number }}{%endif %} {{cave.official_name|safe}}</a> </li>
{% endfor %} {% endfor %}
</ul> </ul>

View File

@ -15,6 +15,11 @@ admin.autodiscover()
# type url probably means it's used. # type url probably means it's used.
# HOW DOES THIS WORK:
# url( <regular expression that matches the thing in the web browser>,
# <reference to python function in 'core' folder>,
# <name? not sure what does this actually do>)
actualurlpatterns = patterns('', actualurlpatterns = patterns('',
url(r'^millenialcaves/?$', views_caves.millenialcaves, name="someothershit"), url(r'^millenialcaves/?$', views_caves.millenialcaves, name="someothershit"),