Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Generated by Django 5.2.9 on 2026-03-25 06:45

from django.db import migrations, models


class Migration(migrations.Migration):

dependencies = [
('resources', '0002_casestudy_link'),
]

operations = [
migrations.AlterField(
model_name='casestudy',
name='content',
field=models.TextField(max_length=320),
),
migrations.AlterField(
model_name='casestudy',
name='link',
field=models.URLField(default='', verbose_name='External case study URL'),
preserve_default=False,
),
]
8 changes: 2 additions & 6 deletions apps/resources/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class CaseStudy(UserResource):
"""Model representing case study of national society for specific tool."""

title = models.CharField[str, str](max_length=200)
content = models.TextField[str, str]()
content = models.TextField[str, str](max_length=320)
cover_image = models.ImageField(
upload_to="case_studies/",
verbose_name="Case Study Cover Image",
Expand All @@ -40,11 +40,7 @@ class CaseStudy(UserResource):
on_delete=models.CASCADE,
related_name="case_studies",
)
link = models.URLField(
blank=True,
null=True,
verbose_name="External case study URL",
)
link = models.URLField(verbose_name="External case study URL")

class Meta(UserResource.Meta):
ordering = ["title"]
Expand Down
2 changes: 1 addition & 1 deletion schema.graphql
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ type CaseStudyType {
toolId: ID!
content: String!
coverImage: DjangoFileType
link: String
link: String!
}

type CaseStudyTypeOffsetPaginated {
Expand Down
Loading