Extend ReportRequestBody to Include "mock" Boolean Field
This commit adds a new boolean field, "mock", to the `ReportRequestBody` class. This additional field is in line with the new requirements to specify whether the report is a mock or not. The `toJson()` method is also updated to include this new field during serialization.pull/5233/head^2
parent
5bfefd6a12
commit
7f5c50dfeb
|
@ -1,13 +1,16 @@
|
|||
class ReportRequestBody {
|
||||
final String category;
|
||||
final List<String> tests;
|
||||
final bool mock;
|
||||
|
||||
ReportRequestBody({required this.category, required this.tests});
|
||||
ReportRequestBody(
|
||||
{required this.category, required this.tests, required this.mock});
|
||||
|
||||
Map<String, dynamic> toJson() {
|
||||
return {
|
||||
'category': category,
|
||||
'tests': tests,
|
||||
'mock': mock,
|
||||
};
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue