@@ -106,7 +106,7 @@ class Meta:
106
106
model = Project
107
107
fields = ('id' , 'name' , 'description' , 'guideline' , 'users' , 'current_users_role' , 'project_type' , 'image' ,
108
108
'updated_at' , 'randomize_document_order' , 'collaborative_annotation' )
109
- read_only_fields = ('image' , 'updated_at' , 'current_users_role' )
109
+ read_only_fields = ('image' , 'updated_at' , 'users' , ' current_users_role' )
110
110
111
111
112
112
class TextClassificationProjectSerializer (ProjectSerializer ):
@@ -115,7 +115,7 @@ class Meta:
115
115
model = TextClassificationProject
116
116
fields = ('id' , 'name' , 'description' , 'guideline' , 'users' , 'current_users_role' , 'project_type' , 'image' ,
117
117
'updated_at' , 'randomize_document_order' )
118
- read_only_fields = ( 'image' , 'updated_at' , 'users' , 'current_users_role' )
118
+ read_only_fields = ProjectSerializer . Meta . read_only_fields
119
119
120
120
121
121
class SequenceLabelingProjectSerializer (ProjectSerializer ):
@@ -124,7 +124,7 @@ class Meta:
124
124
model = SequenceLabelingProject
125
125
fields = ('id' , 'name' , 'description' , 'guideline' , 'users' , 'current_users_role' , 'project_type' , 'image' ,
126
126
'updated_at' , 'randomize_document_order' )
127
- read_only_fields = ( 'image' , 'updated_at' , 'users' , 'current_users_role' )
127
+ read_only_fields = ProjectSerializer . Meta . read_only_fields
128
128
129
129
130
130
class Seq2seqProjectSerializer (ProjectSerializer ):
@@ -133,7 +133,7 @@ class Meta:
133
133
model = Seq2seqProject
134
134
fields = ('id' , 'name' , 'description' , 'guideline' , 'users' , 'current_users_role' , 'project_type' , 'image' ,
135
135
'updated_at' , 'randomize_document_order' )
136
- read_only_fields = ( 'image' , 'updated_at' , 'users' , 'current_users_role' )
136
+ read_only_fields = ProjectSerializer . Meta . read_only_fields
137
137
138
138
139
139
class ProjectPolymorphicSerializer (PolymorphicSerializer ):
0 commit comments