Coverage for crateweb/consent/migrations/0002_auto_20160621_1511.py: 100%

8 statements  

« prev     ^ index     » next       coverage.py v7.8.0, created at 2025-08-27 10:34 -0500

1""" 

2crate_anon/crateweb/consent/migrations/0002_auto_20160621_1511.py 

3 

4=============================================================================== 

5 

6 Copyright (C) 2015, University of Cambridge, Department of Psychiatry. 

7 Created by Rudolf Cardinal (rnc1001@cam.ac.uk). 

8 

9 This file is part of CRATE. 

10 

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. 

15 

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. 

20 

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/>. 

23 

24=============================================================================== 

25 

26**Consent app, migration 0002.** 

27 

28""" 

29 

30# Generated by Django 1.9.7 on 2016-06-21 15:11 

31from __future__ import unicode_literals 

32 

33from cardinal_pythonlib.django.fields.restrictedcontentfile import ( 

34 ContentTypeRestrictedFileField, 

35) 

36from django.db import migrations, models 

37 

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 

44 

45# edited: FileField "location" defaults removed 

46 

47 

48class Migration(migrations.Migration): 

49 

50 dependencies = [ 

51 ("consent", "0001_initial"), 

52 ] 

53 

54 operations = [ 

55 migrations.AlterField( 

56 model_name="emailattachment", 

57 name="file", 

58 field=models.FileField( 

59 storage=CustomFileSystemStorage( 

60 base_url="download_privatestorage" 

61 ), 

62 upload_to="", 

63 ), 

64 ), 

65 migrations.AlterField( 

66 model_name="leaflet", 

67 name="pdf", 

68 field=ContentTypeRestrictedFileField( 

69 blank=True, 

70 storage=CustomFileSystemStorage( 

71 base_url="download_privatestorage" 

72 ), 

73 upload_to=leaflet_upload_to, 

74 ), 

75 ), 

76 migrations.AlterField( 

77 model_name="letter", 

78 name="pdf", 

79 field=models.FileField( 

80 storage=CustomFileSystemStorage( 

81 base_url="download_privatestorage" 

82 ), 

83 upload_to="", 

84 ), 

85 ), 

86 migrations.AlterField( 

87 model_name="study", 

88 name="study_details_pdf", 

89 field=ContentTypeRestrictedFileField( 

90 blank=True, 

91 storage=CustomFileSystemStorage( 

92 base_url="download_privatestorage" 

93 ), 

94 upload_to=study_details_upload_to, 

95 ), 

96 ), 

97 migrations.AlterField( 

98 model_name="study", 

99 name="subject_form_template_pdf", 

100 field=ContentTypeRestrictedFileField( 

101 blank=True, 

102 storage=CustomFileSystemStorage( 

103 base_url="download_privatestorage" 

104 ), 

105 upload_to=study_form_upload_to, 

106 ), 

107 ), 

108 ]