text: # Generated by Django 3.1.7 on 2021-03-18 12:42
  
  from django.db import migrations, models
  import django.db.models.deletion
  
  
  class Migration(migrations.Migration):
  
      initial = True
  
      dependencies = []
  
      operations = [
          migrations.CreateModel(
              name="MaasOperator",
              fields=[
                  (
                      "id",
                      models.AutoField(
                          auto_created=True,
                          primary_key=True,
                          serialize=False,
                          verbose_name="ID",
                      ),
                  ),
                  ("name", models.CharField(max_length=64, verbose_name="name")),
                  (
                      "api_token",
                      models.CharField(
                          blank=True,
                          db_index=True,
                          max_length=100,
                          verbose_name="api_token",
                      ),
                  ),
              ],
              options={
                  "verbose_name": "maas operator",
                  "verbose_name_plural": "maas operators",
              },
          ),
          migrations.CreateModel(
              name="TransportServiceProvider",
              fields=[
                  (
                      "id",
                      models.AutoField(
                          auto_created=True,
                          primary_key=True,
                          serialize=False,
                          verbose_name="ID",
                      ),
                  ),
                  ("name", models.CharField(max_length=64, verbose_name="name")),
              ],
              options={
                  "verbose_name": "transport service provider",
                  "verbose_name_plural": "transport service provider",
              },
          ),
          migrations.CreateModel(
              name="Permission",
              fields=[
                  (
                      "id",
                      models.AutoField(
                          auto_created=True,
                          primary_key=True,
                          serialize=False,
                          verbose_name="ID",
                      ),
                  ),
                  ("expires_at", models.DateField(blank=True, null=True)),
                  (
                      "maas_operator",
                      models.ForeignKey(
                          on_delete=django.db.models.deletion.CASCADE,
                          related_name="permissions",
                          to="maas.maasoperator",
                      ),
                  ),
                  (
                      "transport_service_provider",
                      models.ForeignKey(
                          on_delete=django.db.models.deletion.CASCADE,
                          related_name="permissions",
                          to="maas.transportserviceprovider",
                      ),
                  ),
              ],
              options={
                  "verbose_name": "permission",
                  "verbose_name_plural": "permissions",
                  "default_related_name": "permissions",
              },
          ),
          migrations.AddField(
              model_name="maasoperator",
              name="transport_service_providers",
              field=models.ManyToManyField(
                  related_name="maas_operators",
                  through="maas.Permission",
                  to="maas.TransportServiceProvider",
              ),
          ),
      ]
  