Esempio n. 1
0
def package_last_modified(request, *args, **kwargs):
    return retrieve_latest(Package)
Esempio n. 2
0
def news_last_modified(request, *args, **kwargs):
    return retrieve_latest(News, 'last_modified')
Esempio n. 3
0
def package_etag(request, *args, **kwargs):
    latest = retrieve_latest(Package)
    if latest:
        return hashlib.md5(str(kwargs) + str(latest)).hexdigest()
    return None
Esempio n. 4
0
def news_etag(request, *args, **kwargs):
    latest = retrieve_latest(News, 'last_modified')
    if latest:
        return hashlib.md5(str(latest)).hexdigest()
    return None
Esempio n. 5
0
def package_last_modified(request, *args, **kwargs):
    return retrieve_latest(Package)
Esempio n. 6
0
def package_etag(request, *args, **kwargs):
    latest = retrieve_latest(Package)
    if latest:
        return hashlib.md5(str(kwargs) + str(latest)).hexdigest()
    return None
Esempio n. 7
0
def news_last_modified(request, *args, **kwargs):
    return retrieve_latest(News, 'last_modified')
Esempio n. 8
0
def news_etag(request, *args, **kwargs):
    latest = retrieve_latest(News, 'last_modified')
    if latest:
        return hashlib.md5(str(latest)).hexdigest()
    return None