class License { final int? id; final int companyId; final String name; final int durationMonths; final String visitCycle; // 방문주기(월, 격월, 분기 등) License({ this.id, required this.companyId, required this.name, required this.durationMonths, required this.visitCycle, }); Map toJson() { return { 'id': id, 'companyId': companyId, 'name': name, 'durationMonths': durationMonths, 'visitCycle': visitCycle, }; } factory License.fromJson(Map json) { return License( id: json['id'], companyId: json['companyId'], name: json['name'], durationMonths: json['durationMonths'], visitCycle: json['visitCycle'] as String, ); } }