You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: catalyst_voices/packages/internal/catalyst_voices_models/lib/src/document/data/document_data_metadata.dart
+16-1Lines changed: 16 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -27,10 +27,16 @@ final class DocumentDataMetadata extends Equatable {
27
27
/// A reference to a section of a document.
28
28
finalString? section;
29
29
30
+
/// A list of allowed Collaborators on the next subsequent version of a document.
31
+
finalList<CatalystId>? collaborators;
32
+
30
33
/// A list of referenced parameters like brand, category or campaign.
31
34
finalDocumentParameters parameters;
32
35
33
-
/// List of authors represented by CatalystId
36
+
/// List of authors represented by CatalystId.
37
+
///
38
+
/// Note. This list just represents who signed this version
39
+
/// Note. Can change from version to version when [collaborators] are non empty.
34
40
finalList<CatalystId>? authors;
35
41
36
42
/// The default constructor for the [DocumentDataMetadata].
@@ -42,6 +48,7 @@ final class DocumentDataMetadata extends Equatable {
42
48
this.template,
43
49
this.reply,
44
50
this.section,
51
+
this.collaborators,
45
52
this.parameters =constDocumentParameters(),
46
53
this.authors,
47
54
}) :assert(
@@ -80,6 +87,7 @@ final class DocumentDataMetadata extends Equatable {
80
87
requiredSignedDocumentRef template,
81
88
requiredDocumentParameters parameters,
82
89
requiredList<CatalystId> authors,
90
+
List<CatalystId>? collaborators,
83
91
}) {
84
92
returnDocumentDataMetadata(
85
93
type:DocumentType.proposalDocument,
@@ -88,6 +96,7 @@ final class DocumentDataMetadata extends Equatable {
88
96
template: template,
89
97
parameters: parameters,
90
98
authors: authors,
99
+
collaborators: collaborators,
91
100
);
92
101
}
93
102
@@ -134,10 +143,14 @@ final class DocumentDataMetadata extends Equatable {
134
143
template,
135
144
reply,
136
145
section,
146
+
collaborators,
137
147
parameters,
138
148
authors,
139
149
];
140
150
151
+
/// Who signed this document version. Can change from version to version.
152
+
List<CatalystId>?get signers => authors;
153
+
141
154
Stringget version => selfRef.version!;
142
155
143
156
DocumentDataMetadatacopyWith({
@@ -148,6 +161,7 @@ final class DocumentDataMetadata extends Equatable {
148
161
Optional<SignedDocumentRef>? template,
149
162
Optional<SignedDocumentRef>? reply,
150
163
Optional<String>? section,
164
+
Optional<List<CatalystId>>? collaborators,
151
165
DocumentParameters? parameters,
152
166
Optional<List<CatalystId>>? authors,
153
167
}) {
@@ -159,6 +173,7 @@ final class DocumentDataMetadata extends Equatable {
Copy file name to clipboardExpand all lines: catalyst_voices/packages/internal/catalyst_voices_repositories/lib/src/dto/document/document_data_dto.dart
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -92,6 +92,7 @@ final class DocumentDataMetadataDto {
92
92
finalDocumentRefDto? template;
93
93
finalDocumentRefDto? reply;
94
94
finalString? section;
95
+
finalList<String>? collaborators;
95
96
finalList<DocumentRefDto> parameters;
96
97
finalList<String>? authors;
97
98
@@ -103,6 +104,7 @@ final class DocumentDataMetadataDto {
103
104
this.template,
104
105
this.reply,
105
106
this.section,
107
+
this.collaborators,
106
108
this.parameters =const [],
107
109
this.authors,
108
110
});
@@ -125,6 +127,7 @@ final class DocumentDataMetadataDto {
0 commit comments