Coverage for crateweb/consent/migrations/0006_auto_20170206_1617.py: 100%
9 statements
« prev ^ index » next coverage.py v7.8.0, created at 2025-08-27 10:34 -0500
« prev ^ index » next coverage.py v7.8.0, created at 2025-08-27 10:34 -0500
1"""
2crate_anon/crateweb/consent/migrations/0006_auto_20170206_1617.py
4===============================================================================
6 Copyright (C) 2015, University of Cambridge, Department of Psychiatry.
7 Created by Rudolf Cardinal (rnc1001@cam.ac.uk).
9 This file is part of CRATE.
11 CRATE is free software: you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation, either version 3 of the License, or
14 (at your option) any later version.
16 CRATE is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with CRATE. If not, see <https://www.gnu.org/licenses/>.
24===============================================================================
26**Consent app, migration 0006.**
28"""
30# Generated by Django 1.9.8 on 2017-02-06 16:17
31from __future__ import unicode_literals
33from cardinal_pythonlib.django.fields.restrictedcontentfile import (
34 ContentTypeRestrictedFileField,
35)
36from django.db import migrations, models
38from crate_anon.crateweb.consent.models import (
39 leaflet_upload_to,
40 study_details_upload_to,
41 study_form_upload_to,
42)
43from crate_anon.crateweb.consent.storage import CustomFileSystemStorage
45_DEFAULT_STORAGE_DIR = (
46 "/home/rudolf/Documents/code/crate/working/crateweb/crate_filestorage"
47)
50class Migration(migrations.Migration):
52 dependencies = [
53 ("consent", "0005_auto_20170203_1348"),
54 ]
56 operations = [
57 migrations.AlterField(
58 model_name="emailattachment",
59 name="file",
60 field=models.FileField(
61 storage=CustomFileSystemStorage(
62 base_url="download_privatestorage",
63 location=_DEFAULT_STORAGE_DIR,
64 ),
65 upload_to="",
66 ),
67 ),
68 migrations.AlterField(
69 model_name="leaflet",
70 name="pdf",
71 field=ContentTypeRestrictedFileField(
72 blank=True,
73 storage=CustomFileSystemStorage(
74 base_url="download_privatestorage",
75 location=_DEFAULT_STORAGE_DIR,
76 ),
77 upload_to=leaflet_upload_to,
78 ),
79 ),
80 migrations.AlterField(
81 model_name="letter",
82 name="pdf",
83 field=models.FileField(
84 storage=CustomFileSystemStorage(
85 base_url="download_privatestorage",
86 location=_DEFAULT_STORAGE_DIR,
87 ),
88 upload_to="",
89 ),
90 ),
91 migrations.AlterField(
92 model_name="study",
93 name="study_details_pdf",
94 field=ContentTypeRestrictedFileField(
95 blank=True,
96 storage=CustomFileSystemStorage(
97 base_url="download_privatestorage",
98 location=_DEFAULT_STORAGE_DIR,
99 ),
100 upload_to=study_details_upload_to,
101 ),
102 ),
103 migrations.AlterField(
104 model_name="study",
105 name="subject_form_template_pdf",
106 field=ContentTypeRestrictedFileField(
107 blank=True,
108 storage=CustomFileSystemStorage(
109 base_url="download_privatestorage",
110 location=_DEFAULT_STORAGE_DIR,
111 ),
112 upload_to=study_form_upload_to,
113 ),
114 ),
115 ]