ResponseAtivacao.fromSat constructor

ResponseAtivacao.fromSat(
  1. List<String?> consulta
)

Implementation

factory ResponseAtivacao.fromSat(List<String?> consulta) {
  final consultaMap = consulta.asMap();
  final status = ResponseAtivacao(
    numeroSessao: consulta[0] ?? '',
    codStatus: consulta[1] ?? '',
    mensagem: consulta[2] ?? '',
    cod: consulta[3] ?? '',
    mensagemSefaz: consultaMap.containsKey(4) ? consulta[4]! : '',
  );

  return status;
}