Specto fixes #9
5
.editorconfig
Normal file
5
.editorconfig
Normal file
@ -0,0 +1,5 @@
|
||||
root = true
|
||||
|
||||
[*.{js,css}]
|
||||
indent_style = space
|
||||
indent_size = 2
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,17 +1,20 @@
|
||||
.popup {
|
||||
width: 900px;
|
||||
margin: auto;
|
||||
text-align: center
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.popup img {
|
||||
width: 200px;
|
||||
height: 200px;
|
||||
cursor: pointer
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.show {
|
||||
z-index: 999;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.show .overlay {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
@ -20,6 +23,7 @@
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
|
||||
.show .img-show {
|
||||
width: 600px;
|
||||
height: 400px;
|
||||
@ -28,8 +32,9 @@
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
transform: translate(-50%,-50%);
|
||||
overflow: hidden
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.img-show span {
|
||||
position: absolute;
|
||||
top: 10px;
|
||||
@ -37,6 +42,7 @@
|
||||
z-index: 99;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.img-show img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
@ -108,27 +114,14 @@
|
||||
transition: background-color 0.3s ease;
|
||||
}
|
||||
|
||||
.img-box:hover img {
|
||||
transform: scale(1.1);
|
||||
}
|
||||
|
||||
.img-box:hover .transparent-box {
|
||||
background-color:rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
.img-box:hover img { transform: scale(1.1); }
|
||||
.img-box:hover .transparent-box { background-color: rgba(0, 0, 0, 0.5); }
|
||||
|
||||
.img-box:hover .caption {
|
||||
transform: translateY(-20px);
|
||||
opacity: 1.0;
|
||||
}
|
||||
|
||||
.img-box:hover {
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.caption > p:nth-child(2) {
|
||||
font-size: 0.8em;
|
||||
}
|
||||
|
||||
.opacity-low {
|
||||
opacity: 0.5;
|
||||
}
|
||||
.img-box:hover { cursor: pointer; }
|
||||
.caption > p:nth-child(2) { font-size: 0.8em; }
|
||||
.opacity-low { opacity: 0.5; }
|
||||
|
@ -138,17 +138,12 @@ header {
|
||||
.menu {
|
||||
display: initial;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
html{
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
p {
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
|
||||
|
@ -5,10 +5,12 @@ from django.conf import settings
|
||||
from users.models import User
|
||||
import operator
|
||||
from upload.models import Media
|
||||
from django.db.models import Sum
|
||||
|
||||
|
||||
def homePage(request):
|
||||
iter_var = 0
|
||||
all_balance = []
|
||||
all_balance = 0
|
||||
Cashier = False
|
||||
Processor = False
|
||||
|
||||
@ -29,19 +31,19 @@ def homePage(request):
|
||||
userQR = f"Name = {request.user.username}, Date Joined = {request.user.date_joined.date()}, ID = {request.user.id}, isCashier={Cashier}, isProcessor={Processor}, Balance = {userBalance}"
|
||||
else:
|
||||
userQR=None
|
||||
a = Balance.objects.all()
|
||||
|
||||
for user in a:
|
||||
all_balance.append(user.balanceValue)
|
||||
print(f"{all_balance}")
|
||||
limited_coins = settings.ALL_COINS - sum(all_balance)
|
||||
# Use aggregation that can be calculated in database (fast)
|
||||
all_balance = Balance.objects.all().aggregate(s=Sum("balanceValue"))['s']
|
||||
# print(f"{all_balance}")
|
||||
|
||||
limited_coins = settings.ALL_COINS - all_balance
|
||||
context = {
|
||||
"isCashier": Cashier,
|
||||
"isProcessor": Processor,
|
||||
"userQR":userQR,
|
||||
"fullbalance": limited_coins,
|
||||
"currencyTotal": sum(all_balance),
|
||||
"userBalance": userBalance
|
||||
"currencyTotal": all_balance,
|
||||
"userBalance": userBalance,
|
||||
}
|
||||
|
||||
|
||||
|
@ -1,9 +1,8 @@
|
||||
<!DOCTYPE html>
|
||||
|
||||
<head>
|
||||
|
||||
{% load static %}
|
||||
{% load qr_code %}
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge">
|
||||
<title>{% block title %}reValuate{% endblock %}</title>
|
||||
@ -11,9 +10,7 @@
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<link rel="stylesheet" href="{% static 'home/css/style.css' %}">
|
||||
<link rel="shortcut icon" type="image/png" href="{% static 'home/img/logo.png' %}"/>
|
||||
|
||||
{% block optionalParams %}{% endblock %}
|
||||
|
||||
</head>
|
||||
<body>
|
||||
{% block aboveNav %}{% endblock %}
|
||||
|
@ -1,7 +1,7 @@
|
||||
<!-- templates/home.html -->
|
||||
{% extends 'base.html' %}
|
||||
|
||||
{% block title %}Home{% endblock %}
|
||||
|
||||
{% block optionalParams%}
|
||||
<style>
|
||||
.checkmark__circle {
|
||||
@ -56,6 +56,7 @@
|
||||
</style>
|
||||
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="centered" style="text-align: center;">
|
||||
|
||||
|
@ -1,4 +1,8 @@
|
||||
{% extends 'base.html' %}
|
||||
|
||||
{% load qr_code %}
|
||||
{% load static %}
|
||||
|
||||
{% block optionalParams %}
|
||||
<style>
|
||||
html{
|
||||
@ -11,8 +15,7 @@
|
||||
}
|
||||
</style>
|
||||
{% endblock %}
|
||||
{% load qr_code %}
|
||||
{% load static %}
|
||||
|
||||
{% block content %}
|
||||
<div id="page-wrap">
|
||||
<h1 class="heading">reValuate</h1>
|
||||
|
@ -1,6 +1,7 @@
|
||||
{% extends 'base.html' %}
|
||||
|
||||
{% block title %}Класация{% endblock %}
|
||||
|
||||
{% block optionalParams %}
|
||||
<style>
|
||||
|
||||
|
@ -1,6 +1,8 @@
|
||||
{% extends 'base.html' %}
|
||||
{% load static %}
|
||||
|
||||
{% block title %} My Images {% endblock %}
|
||||
|
||||
{% block optionalParams %}
|
||||
<link rel="stylesheet" href="{% static 'home/css/gallery.css' %}">
|
||||
<style>
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user