00af109e2f
* add flake8 to pre-commit config, and fixup many things to make flake8 happy * add isort and sort all imports, add to pre-commit and requirements
61 lines
2 KiB
Python
61 lines
2 KiB
Python
# -*- coding: utf-8 -*-
|
|
# Generated by Django 1.9.2 on 2016-06-18 19:02
|
|
|
|
|
|
import django.db.models.deletion
|
|
from django.conf import settings
|
|
from django.db import migrations, models
|
|
|
|
|
|
class Migration(migrations.Migration):
|
|
|
|
dependencies = [
|
|
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
|
|
("shop", "0024_auto_20160605_2126"),
|
|
]
|
|
|
|
operations = [
|
|
migrations.CreateModel(
|
|
name="CreditNote",
|
|
fields=[
|
|
(
|
|
"id",
|
|
models.AutoField(
|
|
auto_created=True,
|
|
primary_key=True,
|
|
serialize=False,
|
|
verbose_name="ID",
|
|
),
|
|
),
|
|
("created", models.DateTimeField(auto_now_add=True)),
|
|
("updated", models.DateTimeField(auto_now=True)),
|
|
("amount", models.DecimalField(decimal_places=2, max_digits=10)),
|
|
("text", models.TextField()),
|
|
(
|
|
"pdf",
|
|
models.FileField(blank=True, null=True, upload_to=b"creditnotes/"),
|
|
),
|
|
(
|
|
"paid",
|
|
models.BooleanField(
|
|
default=False,
|
|
help_text="Whether this creditnote has been paid.",
|
|
verbose_name="Paid?",
|
|
),
|
|
),
|
|
("sent_to_customer", models.BooleanField(default=False)),
|
|
(
|
|
"user",
|
|
models.ForeignKey(
|
|
help_text="The user this credit note belongs to.",
|
|
on_delete=django.db.models.deletion.CASCADE,
|
|
related_name="creditnotes",
|
|
to=settings.AUTH_USER_MODEL,
|
|
verbose_name="User",
|
|
),
|
|
),
|
|
],
|
|
options={"abstract": False},
|
|
)
|
|
]
|