2018-03-02 12:01:51 +01:00
|
|
|
# Generated by Django 2.0.2 on 2018-03-02 11:00
|
|
|
|
|
|
|
|
from django.db import migrations, models
|
|
|
|
import django.db.models.deletion
|
|
|
|
|
|
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
|
|
|
|
initial = True
|
|
|
|
|
2019-06-23 15:39:13 +02:00
|
|
|
dependencies = []
|
2018-03-02 12:01:51 +01:00
|
|
|
|
|
|
|
operations = [
|
|
|
|
migrations.CreateModel(
|
2019-06-23 15:39:13 +02:00
|
|
|
name="Equipment",
|
2018-03-02 12:01:51 +01:00
|
|
|
fields=[
|
2019-06-23 15:39:13 +02:00
|
|
|
(
|
|
|
|
"id",
|
|
|
|
models.AutoField(
|
|
|
|
auto_created=True,
|
|
|
|
primary_key=True,
|
|
|
|
serialize=False,
|
|
|
|
verbose_name="ID",
|
|
|
|
),
|
|
|
|
),
|
|
|
|
("name", models.CharField(max_length=300, verbose_name="nom")),
|
2018-03-02 12:01:51 +01:00
|
|
|
],
|
2019-06-23 15:39:13 +02:00
|
|
|
options={"verbose_name": "machine", "verbose_name_plural": "machines"},
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
2019-06-23 15:39:13 +02:00
|
|
|
name="Room",
|
2018-03-02 12:01:51 +01:00
|
|
|
fields=[
|
2019-06-23 15:39:13 +02:00
|
|
|
(
|
|
|
|
"id",
|
|
|
|
models.AutoField(
|
|
|
|
auto_created=True,
|
|
|
|
primary_key=True,
|
|
|
|
serialize=False,
|
|
|
|
verbose_name="ID",
|
|
|
|
),
|
|
|
|
),
|
|
|
|
("name", models.CharField(max_length=300, verbose_name="nom")),
|
|
|
|
(
|
|
|
|
"latitude",
|
|
|
|
models.DecimalField(
|
|
|
|
decimal_places=8, max_digits=11, verbose_name="latitude"
|
|
|
|
),
|
|
|
|
),
|
|
|
|
(
|
|
|
|
"longitude",
|
|
|
|
models.DecimalField(
|
|
|
|
decimal_places=8, max_digits=11, verbose_name="longitude"
|
|
|
|
),
|
|
|
|
),
|
|
|
|
("notes", models.TextField(verbose_name="notes")),
|
2018-03-02 12:01:51 +01:00
|
|
|
],
|
2019-06-23 15:39:13 +02:00
|
|
|
options={"verbose_name": "salle", "verbose_name_plural": "salles"},
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
2019-06-23 15:39:13 +02:00
|
|
|
name="Round",
|
2018-03-02 12:01:51 +01:00
|
|
|
fields=[
|
2019-06-23 15:39:13 +02:00
|
|
|
(
|
|
|
|
"id",
|
|
|
|
models.AutoField(
|
|
|
|
auto_created=True,
|
|
|
|
primary_key=True,
|
|
|
|
serialize=False,
|
|
|
|
verbose_name="ID",
|
|
|
|
),
|
|
|
|
),
|
|
|
|
(
|
|
|
|
"repetition_number",
|
|
|
|
models.PositiveIntegerField(verbose_name="nombre de répétitions"),
|
|
|
|
),
|
|
|
|
(
|
|
|
|
"theoretical_max_percentage",
|
|
|
|
models.PositiveIntegerField(verbose_name="pourcentage"),
|
|
|
|
),
|
|
|
|
("chosen_weight", models.FloatField(verbose_name="charge choisie")),
|
|
|
|
("notes", models.TextField(verbose_name="notes")),
|
|
|
|
(
|
|
|
|
"equipment",
|
|
|
|
models.ForeignKey(
|
|
|
|
on_delete=django.db.models.deletion.CASCADE,
|
|
|
|
related_name="rounds",
|
|
|
|
to="gym.Equipment",
|
|
|
|
verbose_name="machine",
|
|
|
|
),
|
|
|
|
),
|
2018-03-02 12:01:51 +01:00
|
|
|
],
|
2019-06-23 15:39:13 +02:00
|
|
|
options={"verbose_name": "série", "verbose_name_plural": "séries"},
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
2019-06-23 15:39:13 +02:00
|
|
|
name="Session",
|
2018-03-02 12:01:51 +01:00
|
|
|
fields=[
|
2019-06-23 15:39:13 +02:00
|
|
|
(
|
|
|
|
"id",
|
|
|
|
models.AutoField(
|
|
|
|
auto_created=True,
|
|
|
|
primary_key=True,
|
|
|
|
serialize=False,
|
|
|
|
verbose_name="ID",
|
|
|
|
),
|
|
|
|
),
|
|
|
|
("date", models.DateField(verbose_name="date")),
|
|
|
|
("notes", models.TextField(verbose_name="notes")),
|
|
|
|
(
|
|
|
|
"room",
|
|
|
|
models.ForeignKey(
|
|
|
|
null=True,
|
|
|
|
on_delete=django.db.models.deletion.SET_NULL,
|
|
|
|
related_name="sessions",
|
|
|
|
to="gym.Room",
|
|
|
|
verbose_name="salle",
|
|
|
|
),
|
|
|
|
),
|
2018-03-02 12:01:51 +01:00
|
|
|
],
|
2019-06-23 15:39:13 +02:00
|
|
|
options={"verbose_name": "séance", "verbose_name_plural": "séances"},
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
2019-06-23 15:39:13 +02:00
|
|
|
name="Setting",
|
2018-03-02 12:01:51 +01:00
|
|
|
fields=[
|
2019-06-23 15:39:13 +02:00
|
|
|
(
|
|
|
|
"id",
|
|
|
|
models.AutoField(
|
|
|
|
auto_created=True,
|
|
|
|
primary_key=True,
|
|
|
|
serialize=False,
|
|
|
|
verbose_name="ID",
|
|
|
|
),
|
|
|
|
),
|
|
|
|
("name", models.CharField(max_length=200, verbose_name="nom")),
|
|
|
|
("value", models.CharField(max_length=200, verbose_name="valeur")),
|
|
|
|
(
|
|
|
|
"equipment",
|
|
|
|
models.ForeignKey(
|
|
|
|
on_delete=django.db.models.deletion.CASCADE,
|
|
|
|
related_name="settings",
|
|
|
|
to="gym.Equipment",
|
|
|
|
verbose_name="machine",
|
|
|
|
),
|
|
|
|
),
|
2018-03-02 12:01:51 +01:00
|
|
|
],
|
2019-06-23 15:39:13 +02:00
|
|
|
options={"verbose_name": "réglage", "verbose_name_plural": "réglages"},
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
migrations.CreateModel(
|
2019-06-23 15:39:13 +02:00
|
|
|
name="TheoreticalMax",
|
2018-03-02 12:01:51 +01:00
|
|
|
fields=[
|
2019-06-23 15:39:13 +02:00
|
|
|
(
|
|
|
|
"id",
|
|
|
|
models.AutoField(
|
|
|
|
auto_created=True,
|
|
|
|
primary_key=True,
|
|
|
|
serialize=False,
|
|
|
|
verbose_name="ID",
|
|
|
|
),
|
|
|
|
),
|
|
|
|
("date", models.DateField(verbose_name="date")),
|
|
|
|
("value", models.FloatField(verbose_name="valeur")),
|
|
|
|
(
|
|
|
|
"equipment",
|
|
|
|
models.ForeignKey(
|
|
|
|
on_delete=django.db.models.deletion.CASCADE,
|
|
|
|
related_name="theoretical_maxs",
|
|
|
|
to="gym.Equipment",
|
|
|
|
verbose_name="machine",
|
|
|
|
),
|
|
|
|
),
|
2018-03-02 12:01:51 +01:00
|
|
|
],
|
|
|
|
options={
|
2019-06-23 15:39:13 +02:00
|
|
|
"verbose_name": "maximum théorique",
|
|
|
|
"verbose_name_plural": "maximums théoriques",
|
2018-03-02 12:01:51 +01:00
|
|
|
},
|
|
|
|
),
|
|
|
|
migrations.AddField(
|
2019-06-23 15:39:13 +02:00
|
|
|
model_name="round",
|
|
|
|
name="session",
|
|
|
|
field=models.ForeignKey(
|
|
|
|
on_delete=django.db.models.deletion.CASCADE,
|
|
|
|
related_name="rounds",
|
|
|
|
to="gym.Session",
|
|
|
|
verbose_name="séance",
|
|
|
|
),
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
migrations.AddField(
|
2019-06-23 15:39:13 +02:00
|
|
|
model_name="equipment",
|
|
|
|
name="room",
|
|
|
|
field=models.ForeignKey(
|
|
|
|
null=True,
|
|
|
|
on_delete=django.db.models.deletion.SET_NULL,
|
|
|
|
related_name="equipments",
|
|
|
|
to="gym.Room",
|
|
|
|
verbose_name="salle",
|
|
|
|
),
|
2018-03-02 12:01:51 +01:00
|
|
|
),
|
|
|
|
]
|