Skip to content

Commit

Permalink
feat: DidatticaSsd model
Browse files Browse the repository at this point in the history
  • Loading branch information
francesco-filicetti committed Nov 21, 2023
1 parent b2a5b1c commit e8005b1
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Generated by Django 4.2.6 on 2023-11-21 10:24

from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

dependencies = [
('ricerca_app', '0153_didatticacdsperiodi'),
]

operations = [
migrations.CreateModel(
name='DidatticaSsd',
fields=[
('ssd_id', models.CharField(db_column='SSD_ID', max_length=100, primary_key=True, serialize=False)),
('ssd_des', models.CharField(db_column='SSD_DES', max_length=2000)),
],
options={
'db_table': 'DIDATTICA_SSD',
'managed': True,
},
),
]
12 changes: 12 additions & 0 deletions ricerca_app/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
def patents_media_path(instance, filename): # pragma: no cover
return f'portale/brevetti/loghi/{filename}'

def laboratories_media_path(instance, filename): # pragma: no cover
return f'portale/laboratori/loghi/{filename}'

def companies_media_path(instance, filename): # pragma: no cover
return f'portale/spinoff-startup/loghi/{filename}'

Expand Down Expand Up @@ -104,6 +107,15 @@ class Meta:
db_table = 'COMUNI_ALL'


class DidatticaSsd(models.Model):
ssd_id = models.CharField(db_column='SSD_ID', primary_key=True, max_length=100) # Field name made lowercase.
ssd_des = models.CharField(db_column='SSD_DES', max_length=2000) # Field name made lowercase.

class Meta:
managed = True
db_table = 'DIDATTICA_SSD'


class DidatticaAttivitaFormativa(models.Model):
af_id = models.IntegerField(db_column='AF_ID', primary_key=True) # Field name made lowercase.
cds = models.ForeignKey('DidatticaCds', models.DO_NOTHING, db_column='CDS_ID', blank=True, null=True) # Field name made lowercase.
Expand Down

0 comments on commit e8005b1

Please sign in to comment.