List<String> docTypeListToJson(List<enums.DocType>? docType) { if (docType == null) { return []; } return docType.map((e) => enums.$DocTypeMap[e]!).toList(); }