toJson method

Map<String, dynamic> toJson()

Implementation

core.Map<core.String, core.dynamic> toJson() => {
      if (dateString != null)
        'dateString': dateString!
            .map((value) =>
                "${value.year.toString().padLeft(4, '0')}-${value.month.toString().padLeft(2, '0')}-${value.day.toString().padLeft(2, '0')}")
            .toList(),
      if (id != null) 'id': id!,
      if (integer != null) 'integer': integer!,
      if (kind != null) 'kind': kind!,
      if (selection != null) 'selection': selection!,
      if (text != null) 'text': text!,
      if (user != null) 'user': user!,
      if (valueType != null) 'valueType': valueType!,
    };