mirror of
https://github.com/bszczuka/steel-training.git
synced 2025-12-24 22:39:13 +01:00
Name change
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
# Paper Challenge
|
# Steel Training
|
||||||
- Projekt powstał na potrzeby treningu Steel Challenge w domowym zaciszu
|
- Projekt powstał na potrzeby treningu Steel Challenge w domowym zaciszu
|
||||||
- Ostrzeżenie: Od ponad 11 lat pracuję z PHP, więc mogą być widoczne naleciałości! Ten projekt to moje pierwsze... no może drugie kroki w Pythonie.
|
- Ostrzeżenie: Od ponad 11 lat pracuję z PHP, więc mogą być widoczne naleciałości! Ten projekt to moje pierwsze... no może drugie kroki w Pythonie.
|
||||||
### Kopiowanie, rozpowszechnianie, modyfikowanie i udostępnianie na potrzeby własne, klubowe lub dla kolegi, stanowczo zalecane
|
### Kopiowanie, rozpowszechnianie, modyfikowanie i udostępnianie na potrzeby własne, klubowe lub dla kolegi, stanowczo zalecane
|
||||||
|
|||||||
6
app.py
6
app.py
@@ -178,7 +178,7 @@ def generate_pdf():
|
|||||||
pdf_file = io.BytesIO()
|
pdf_file = io.BytesIO()
|
||||||
HTML(string=rendered_html).write_pdf(pdf_file)
|
HTML(string=rendered_html).write_pdf(pdf_file)
|
||||||
pdf_file.seek(0)
|
pdf_file.seek(0)
|
||||||
filename = 'Paper Challenge - ' + stage.replace('_', ' ') + ' - ' + str(distance) + 'cm-' + size + '.pdf'
|
filename = 'Steel Training - ' + stage.replace('_', ' ') + ' - ' + str(distance) + 'cm-' + size + '.pdf'
|
||||||
|
|
||||||
return send_file(pdf_file, download_name=filename, as_attachment=False)
|
return send_file(pdf_file, download_name=filename, as_attachment=False)
|
||||||
|
|
||||||
@@ -218,7 +218,7 @@ def generate_pdf_shootoff():
|
|||||||
pdf_file = io.BytesIO()
|
pdf_file = io.BytesIO()
|
||||||
HTML(string=rendered_html).write_pdf(pdf_file)
|
HTML(string=rendered_html).write_pdf(pdf_file)
|
||||||
pdf_file.seek(0)
|
pdf_file.seek(0)
|
||||||
filename = 'Paper Challenge - Shootoff - ' + str(distance) + 'cm-' + size + '.pdf'
|
filename = 'Steel Training - Shootoff - ' + str(distance) + 'cm-' + size + '.pdf'
|
||||||
|
|
||||||
return send_file(pdf_file, download_name=filename, as_attachment=False)
|
return send_file(pdf_file, download_name=filename, as_attachment=False)
|
||||||
|
|
||||||
@@ -260,7 +260,7 @@ def generate_pdf_ipsc():
|
|||||||
pdf_file = io.BytesIO()
|
pdf_file = io.BytesIO()
|
||||||
HTML(string=rendered_html).write_pdf(pdf_file)
|
HTML(string=rendered_html).write_pdf(pdf_file)
|
||||||
pdf_file.seek(0)
|
pdf_file.seek(0)
|
||||||
filename = 'Paper Challenge - IPSC - EL Presidente - ' + str(distance) + 'cm-' + size + '.pdf'
|
filename = 'Steel Training - IPSC - EL Presidente - ' + str(distance) + 'cm-' + size + '.pdf'
|
||||||
|
|
||||||
return send_file(pdf_file, download_name=filename, as_attachment=False)
|
return send_file(pdf_file, download_name=filename, as_attachment=False)
|
||||||
|
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>Paper Challenge</title>
|
<title>Steel Training</title>
|
||||||
<script src="https://cdn.tailwindcss.com?plugins=forms,typography,aspect-ratio,line-clamp,container-queries"></script>
|
<script src="https://cdn.tailwindcss.com?plugins=forms,typography,aspect-ratio,line-clamp,container-queries"></script>
|
||||||
<style>
|
<style>
|
||||||
/* Style the labels to act like buttons */
|
/* Style the labels to act like buttons */
|
||||||
@@ -27,7 +27,7 @@
|
|||||||
</head>
|
</head>
|
||||||
<body class="bg-gray-100 font-sans">
|
<body class="bg-gray-100 font-sans">
|
||||||
<div class="max-w-4xl mx-auto p-6 bg-white shadow-md rounded-lg mt-10">
|
<div class="max-w-4xl mx-auto p-6 bg-white shadow-md rounded-lg mt-10">
|
||||||
<h1 class="text-2xl font-bold mb-6 text-center text-gray-700">Paper Challenge</h1>
|
<h1 class="text-2xl font-bold mb-6 text-center text-gray-700">Steel Training</h1>
|
||||||
<h2 class="my-10 mx-auto text-center font-bold text-xl">{% trans %}Generate stage for{% endtrans %} {% block title %}{% endblock %}</h2>
|
<h2 class="my-10 mx-auto text-center font-bold text-xl">{% trans %}Generate stage for{% endtrans %} {% block title %}{% endblock %}</h2>
|
||||||
<div class="flex justify-center gap-6">
|
<div class="flex justify-center gap-6">
|
||||||
<a href="{{ url_for('index') }}"
|
<a href="{{ url_for('index') }}"
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>Paper Challenge - {{ stage.split('_') | map('capitalize') | join(' ') }} - {{ distance }} cm
|
<title>Steel Training - {{ stage.split('_') | map('capitalize') | join(' ') }} - {{ distance }} cm
|
||||||
- {{ size|capitalize }}</title>
|
- {{ size|capitalize }}</title>
|
||||||
<style>
|
<style>
|
||||||
@page {
|
@page {
|
||||||
@@ -67,7 +67,7 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="page-break">
|
<div class="page-break">
|
||||||
<h1>Paper Challenge</h1>
|
<h1>Steel Training</h1>
|
||||||
<h2>{{ stage.split('_') | map('capitalize') | join(' ') }}</h2>
|
<h2>{{ stage.split('_') | map('capitalize') | join(' ') }}</h2>
|
||||||
|
|
||||||
<div class="preview">
|
<div class="preview">
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>Paper Challenge - IPSC - El Presidente - {{ distance }} cm
|
<title>Steel Training - IPSC - El Presidente - {{ distance }} cm
|
||||||
- {{ size|capitalize }}</title>
|
- {{ size|capitalize }}</title>
|
||||||
<style>
|
<style>
|
||||||
@page {
|
@page {
|
||||||
@@ -62,7 +62,7 @@
|
|||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div class="page-break">
|
<div class="page-break">
|
||||||
<h1>Paper Challenge</h1>
|
<h1>Steel Training</h1>
|
||||||
<h2>IPSC - El Presidente</h2>
|
<h2>IPSC - El Presidente</h2>
|
||||||
<div class="preview">
|
<div class="preview">
|
||||||
{% for i in range(3) %}
|
{% for i in range(3) %}
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="UTF-8">
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
<title>Paper Challenge - Shootoff - {{ distance }} cm
|
<title>Steel Training - Shootoff - {{ distance }} cm
|
||||||
- {{ size|capitalize }}</title>
|
- {{ size|capitalize }}</title>
|
||||||
<style>
|
<style>
|
||||||
@page {
|
@page {
|
||||||
@@ -77,7 +77,7 @@
|
|||||||
|
|
||||||
<body>
|
<body>
|
||||||
<div class="page-break">
|
<div class="page-break">
|
||||||
<h1>Paper Challenge</h1>
|
<h1>Steel Training</h1>
|
||||||
<h2>Shootoff</h2>
|
<h2>Shootoff</h2>
|
||||||
|
|
||||||
<div class="preview">
|
<div class="preview">
|
||||||
|
|||||||
Reference in New Issue
Block a user