"Fossies" - the Fresh Open Source Software Archive

Member "taiga-back-5.0.6/taiga/webhooks/migrations/0001_initial.py" (15 Jan 2020, 1520 Bytes) of package /linux/www/taiga-back-5.0.6.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Python source code syntax highlighting (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file. For more information about "0001_initial.py" see the Fossies "Dox" file reference documentation.

    1 # -*- coding: utf-8 -*-
    2 from __future__ import unicode_literals
    3 
    4 from django.db import models, migrations
    5 import taiga.base.db.models.fields
    6 
    7 
    8 class Migration(migrations.Migration):
    9 
   10     dependencies = [
   11         ('projects', '0015_auto_20141230_1212'),
   12     ]
   13 
   14     operations = [
   15         migrations.CreateModel(
   16             name='Webhook',
   17             fields=[
   18                 ('id', models.AutoField(serialize=False, verbose_name='ID', auto_created=True, primary_key=True)),
   19                 ('url', models.URLField(verbose_name='URL')),
   20                 ('key', models.TextField(verbose_name='secret key')),
   21                 ('project', models.ForeignKey(related_name='webhooks', to='projects.Project')),
   22             ],
   23             options={
   24             },
   25             bases=(models.Model,),
   26         ),
   27         migrations.CreateModel(
   28             name='WebhookLog',
   29             fields=[
   30                 ('id', models.AutoField(serialize=False, verbose_name='ID', auto_created=True, primary_key=True)),
   31                 ('url', models.URLField(verbose_name='URL')),
   32                 ('status', models.IntegerField(verbose_name='Status code')),
   33                 ('request_data', taiga.base.db.models.fields.JSONField(verbose_name='Request data')),
   34                 ('response_data', models.TextField(verbose_name='Response data')),
   35                 ('webhook', models.ForeignKey(related_name='logs', to='webhooks.Webhook')),
   36             ],
   37             options={
   38             },
   39             bases=(models.Model,),
   40         ),
   41     ]