2
0
mirror of https://expo.survex.com/repositories/troggle/.git synced 2025-12-15 13:37:05 +00:00

ruf cleanup imports, bigly.

This commit is contained in:
2023-01-30 23:04:11 +00:00
parent e35fccea5d
commit 3aca0d0c76
29 changed files with 165 additions and 325 deletions

View File

@@ -1,19 +1,14 @@
import datetime
import os
import re
import stat
from pathlib import Path
from urllib.parse import unquote as urlunquote
from urllib.parse import urljoin
from urllib.request import urlopen
from django.conf import settings
from django.db import transaction
from django.http import HttpResponse
from django.shortcuts import render
from troggle.core.models.caves import GetCaveLookup
from troggle.core.models.survex import SingleScan, SurvexBlock, Wallet
from troggle.core.models.survex import SingleScan, SurvexBlock
from troggle.core.models.wallets import Wallet
from troggle.core.models.troggle import DataIssue, Expedition, Person
from troggle.core.views.expo import getmimetype
@@ -158,7 +153,7 @@ def walletslistperson(request, first_name, last_name):
fixsurvextick(w, w.ticks)
return manywallets
print(f"-walletslistperson")
print("-walletslistperson")
try:
if last_name:
@@ -176,7 +171,7 @@ def walletslistperson(request, first_name, last_name):
manywallets = tickspersonwallet(p)
expeditions = Expedition.objects.all()
print(f"--")
print("--")
return render(
request,
"personwallets.html",
@@ -209,7 +204,7 @@ def walletslistyear(request, year):
return manywallets
print(f"-walletslistyear")
print("-walletslistyear")
if year < 1976 or year > 2050:
return render(request, "errors/generic.html", {"message": "Year out of range. Must be between 1976 and 2050"})
@@ -219,7 +214,7 @@ def walletslistyear(request, year):
manywallets = ticksyearwallet(year)
expeditions = Expedition.objects.all()
expedition = expeditions.filter(year=year)
print(f"--")
print("--")
return render(
request,
"yearwallets.html",
@@ -235,7 +230,7 @@ def walletslistyear(request, year):
def cavewallets(request, caveid):
"""Returns all the wallets for just one cave"""
print(f"-cavewalletsl")
print("-cavewalletsl")
Gcavelookup = GetCaveLookup()
if caveid in Gcavelookup:
@@ -270,7 +265,7 @@ def cavewallets(request, caveid):
w.ticks = w.get_ticks() # the complaints in colour form, from the json file on disc
fixsurvextick(w, w.ticks)
expeditions = Expedition.objects.all()
print(f"--")
print("--")
return render(
request,
"cavewallets.html",