boolean excluirCategoria = itensAtivosCategoria.size() > 1 ? false : true;
ConfiguracaoDao dao = new ConfiguracaoDao(request);
ConfiguracaoCfg config = dao.getConfiguracao();
HistoricoMaster historicoMaster = new HistoricoMaster();
if("S".equals(config.getIndGerarHistoricoCfg())) {
historicoMaster.setDataHoraHistorico(new Date());
historicoMaster.setUsuManutencao(upload.getUsuarioUsuManutencao() == null?usuario:upload.getUsuarioUsuManutencao());
historicoMaster.setCodReferenciaGeral(upload.getItemEstruturaIett().getCodIett());
historicoMaster.setHistoricoMotivo((HistoricoMotivo)super.buscar(HistoricoMotivo.class, Long.valueOf(26)));
session.save(historicoMaster);
HistoricoIettupH iettuph = new HistoricoIettupH();
ItemEstrutUploadIettup iettup = (ItemEstrutUploadIettup)super.buscar(ItemEstrutUploadIettup.class, upload.getCodIettup());