Commit 9ba783b86a1aa140d24e85b575520915fadca87a
1 parent
8632374c
Exists in
master
Redmine #3700 Correção de homologação
Showing
13 changed files
with
792 additions
and
758 deletions
Show diff stats
cit-ecm-api/src/main/java/br/com/centralit/api/service/impl/AnexoGedServiceImpl.java
... | ... | @@ -107,7 +107,7 @@ public class AnexoGedServiceImpl extends GenericServiceImpl<AnexoGed, Long> impl |
107 | 107 | |
108 | 108 | documentoGed.setConteudo(this.gedFileService.doOcr(anexo)); |
109 | 109 | |
110 | -// solrService.addDocumento(documentoGed); | |
110 | + /*solrService.addDocumento(documentoGed); */ | |
111 | 111 | |
112 | 112 | anexo.setDocumentoGed(documentoGed); |
113 | 113 | ... | ... |
cit-ecm-api/src/main/java/br/com/centralit/api/service/impl/DocumentoGedServiceImpl.java
... | ... | @@ -139,6 +139,8 @@ public class DocumentoGedServiceImpl extends GenericServiceImpl<DocumentoGed, Lo |
139 | 139 | |
140 | 140 | private static final String ICON_PICTURE = "glyphicon glyphicon-picture fa-2x"; |
141 | 141 | |
142 | + private static final String ICON_PLAY = "fa fa-file-audio-o fa-2x"; | |
143 | + | |
142 | 144 | /** |
143 | 145 | * quantidade de documentos que podem ser incluídos. |
144 | 146 | */ |
... | ... | @@ -565,7 +567,7 @@ public class DocumentoGedServiceImpl extends GenericServiceImpl<DocumentoGed, Lo |
565 | 567 | |
566 | 568 | entity.setConteudo(this.decrypted(entity.getConteudoCriptografado())); |
567 | 569 | |
568 | -// this.saveSolr(entity); | |
570 | + // this.saveSolr(entity); | |
569 | 571 | |
570 | 572 | try { |
571 | 573 | if (anexo != null) { |
... | ... | @@ -940,6 +942,8 @@ public class DocumentoGedServiceImpl extends GenericServiceImpl<DocumentoGed, Lo |
940 | 942 | |
941 | 943 | return DocumentoGedServiceImpl.ICON_CODE; |
942 | 944 | |
945 | + } else if (Dominio.TIPO_ANEXO_MP3_CODIGO.equals(tipoAnexo.getCodigo()) || Dominio.TIPO_ANEXO_WMA_CODIGO.equals(tipoAnexo.getCodigo()) || Dominio.TIPO_ANEXO_WAV_CODIGO.equals(tipoAnexo.getCodigo()) || Dominio.TIPO_ANEXO_AAC_CODIGO.equals(tipoAnexo.getCodigo()) || Dominio.TIPO_ANEXO_OGG_CODIGO.equals(tipoAnexo.getCodigo()) || Dominio.TIPO_ANEXO_M4A_CODIGO.equals(tipoAnexo.getCodigo()) || Dominio.TIPO_ANEXO_FLAC_CODIGO.equals(tipoAnexo.getCodigo())) { | |
946 | + return DocumentoGedServiceImpl.ICON_PLAY; | |
943 | 947 | } |
944 | 948 | |
945 | 949 | return DocumentoGedServiceImpl.ICON_FILE_SEM_FORMATO; | ... | ... |
cit-ecm-api/src/main/java/br/com/centralit/api/service/impl/ProcessoServiceImpl.java
... | ... | @@ -141,13 +141,13 @@ public class ProcessoServiceImpl extends GenericServiceImpl<Processo, Long> impl |
141 | 141 | |
142 | 142 | /*this.gerarCredenciais(processo);*/ |
143 | 143 | |
144 | - if (processo.getTipoProtocolo().getNome().equalsIgnoreCase("NUP_NOVO")) { | |
144 | + if (processo.getTipoProtocolo().getCodigo().equals(1L)) { | |
145 | 145 | this.gerarNUP(processo); |
146 | 146 | } |
147 | 147 | |
148 | 148 | try { |
149 | 149 | |
150 | - // this.solrService.addProcesso(processo); | |
150 | + this.solrService.addProcesso(processo); | |
151 | 151 | } catch (final Exception e) { |
152 | 152 | |
153 | 153 | e.printStackTrace(); |
... | ... | @@ -189,7 +189,7 @@ public class ProcessoServiceImpl extends GenericServiceImpl<Processo, Long> impl |
189 | 189 | |
190 | 190 | try { |
191 | 191 | |
192 | - // this.solrService.addProcesso(processo); | |
192 | + this.solrService.addProcesso(processo); | |
193 | 193 | } catch (final Exception e) { |
194 | 194 | |
195 | 195 | e.printStackTrace(); | ... | ... |
cit-ecm-web/src/main/java/br/com/centralit/listener/StartupListenerEcm.java
... | ... | @@ -193,8 +193,8 @@ public class StartupListenerEcm extends UtilStartup implements ApplicationListen |
193 | 193 | list.add(new Dominio("tipoFormaCriacao", "Anexo", "ANEXO", 2L)); |
194 | 194 | list.add(new Dominio("tipoFormaCriacao", "Ambos", "AMBOS", 3L)); |
195 | 195 | |
196 | - list.add(new Dominio("tipoProtocoloNup", "Automático", "EXTERNO", 1L, Boolean.FALSE)); | |
197 | - list.add(new Dominio("tipoProtocoloNup", "Informado", "NUP_NOVO", 2L, Boolean.FALSE)); | |
196 | + list.add(new Dominio("tipoProtocoloNup", "Automático", "NUP_NOVO", 1L, Boolean.FALSE)); | |
197 | + list.add(new Dominio("tipoProtocoloNup", "Informado", "EXTERNO", 2L, Boolean.FALSE)); | |
198 | 198 | |
199 | 199 | this.dominioService.saveListIfNotExist(list); |
200 | 200 | |
... | ... | @@ -370,6 +370,8 @@ public class StartupListenerEcm extends UtilStartup implements ApplicationListen |
370 | 370 | internacionalizacaoList.add(new Internacionalizacao("ECM.LABEL.PROPOSTA", "Proposta", dominio, modulo)); |
371 | 371 | internacionalizacaoList.add(new Internacionalizacao("ECM.LABEL.VALIDAR_NIVEL_ACESSO", "Validar nível de acesso", dominio, modulo)); |
372 | 372 | internacionalizacaoList.add(new Internacionalizacao("ECM.LABEL.RENUNCIAR_CREDENCIAL", "Renunciar credencial", dominio, modulo)); |
373 | + internacionalizacaoList.add(new Internacionalizacao("ECM.LABEL.AVANCAR_FLUXO", "Avançar no Fluxo", dominio, modulo)); | |
374 | + internacionalizacaoList.add(new Internacionalizacao("ECM.LABEL.JUSTIFICATIVA_CANCELAMENTO", "Justificativa Cancelado", dominio, modulo)); | |
373 | 375 | |
374 | 376 | } |
375 | 377 | ... | ... |
cit-ecm-web/src/main/webapp/assets/js/angular/custom/controller/DocumentoGedController.js
... | ... | @@ -633,5 +633,12 @@ citApp.controller('DocumentoGedController', ['$scope', 'DocumentoGedRepository', |
633 | 633 | }); |
634 | 634 | |
635 | 635 | }; |
636 | + | |
637 | + $scope.downloadArquivo = function(idDocumento){ | |
638 | + href = "/cit-ecm-web/rest/anexoGed/visualizar?idAnexo="+idDocumento; | |
639 | + | |
640 | + $window.location.href = (href); | |
641 | + | |
642 | + } | |
636 | 643 | |
637 | 644 | }]); | ... | ... |
cit-ecm-web/src/main/webapp/assets/js/angular/custom/controller/GerenciarProcessoController.js
1 | 1 | 'use strict'; |
2 | 2 | |
3 | +citApp.controller( 'GerenciarProcessoController', [ | |
4 | + '$scope', | |
5 | + '$translate', | |
6 | + '$timeout', | |
7 | + 'GerenciarProcessoRepository', | |
8 | + 'ProcessoRepository', | |
9 | + 'RuntimeManagerRepository', | |
10 | + '$rootScope', | |
11 | + 'DocumentoGedRepository', | |
12 | + 'HistoricoAlteracaoProcessoRepository', | |
13 | + 'UnidadeRepository', | |
14 | + 'UnidadeProcessoRepository', | |
15 | + 'CredencialProcessoRepository', | |
16 | + function GerenciarProcessoController ( $scope, $translate, $timeout, GerenciarProcessoRepository, ProcessoRepository, RuntimeManagerRepository, $rootScope, DocumentoGedRepository, | |
17 | + HistoricoAlteracaoProcessoRepository, UnidadeRepository, UnidadeProcessoRepository, CredencialProcessoRepository ) { | |
18 | + | |
19 | + $scope.processo = {}; | |
20 | + $scope.iconAnexo = {}; | |
21 | + $scope.taskVariables = []; | |
22 | + $scope.unidades = []; | |
23 | + | |
24 | + // INICIALIZA VARIAVEIS PARA HABILITAR E FECHAR DIVS DE AÇÕES DO PROCESSO | |
25 | + | |
26 | + $scope.isHistoricoProcesso = true; | |
27 | + $scope.fecharPagina = function () { | |
28 | + $scope.isProcessoRelacionado = false; | |
29 | + $scope.isDocumentoEdit = false; | |
30 | + $scope.isProcessoEdit = false; | |
31 | + $scope.isHistoricoProcesso = false; | |
32 | + $scope.isVersoesDocumento = false; | |
33 | + $scope.isEnviarProcesso = false; | |
34 | + $scope.isCancelarDocumento = false; | |
35 | + $scope.isJustificativaAcaoProcesso = false; | |
36 | + $scope.isHistoricoJustificativa = false; | |
37 | + $scope.isAnexarProcesso = false; | |
38 | + $scope.widgetExemploIsCollapsed = true; | |
39 | + $scope.tratimitado(); | |
40 | + $scope.isGerenciarCredencialProcesso = false; | |
3 | 41 | |
4 | -citApp.controller('GerenciarProcessoController', [ '$scope', '$translate', '$timeout','GerenciarProcessoRepository', 'ProcessoRepository', 'RuntimeManagerRepository','$rootScope', 'DocumentoGedRepository', 'HistoricoAlteracaoProcessoRepository','UnidadeRepository','UnidadeProcessoRepository','CredencialProcessoRepository', | |
5 | - function GerenciarProcessoController($scope, $translate, $timeout, GerenciarProcessoRepository, ProcessoRepository, RuntimeManagerRepository,$rootScope, DocumentoGedRepository, HistoricoAlteracaoProcessoRepository,UnidadeRepository, UnidadeProcessoRepository,CredencialProcessoRepository ) { | |
6 | - | |
7 | - $scope.processo = {}; | |
8 | - $scope.iconAnexo = {}; | |
9 | - $scope.taskVariables = []; | |
10 | - $scope.unidades = []; | |
11 | - | |
12 | - //INICIALIZA VARIAVEIS PARA HABILITAR E FECHAR DIVS DE AÇÕES DO PROCESSO | |
13 | - | |
14 | - $scope.isHistoricoProcesso = true; | |
15 | - $scope.fecharPagina = function() { | |
16 | - $scope.isProcessoRelacionado = false; | |
17 | - $scope.isDocumentoEdit = false; | |
18 | - $scope.isProcessoEdit = false; | |
19 | - $scope.isHistoricoProcesso = false; | |
20 | - $scope.isVersoesDocumento = false; | |
21 | - $scope.isEnviarProcesso = false; | |
22 | - $scope.isCancelarDocumento = false; | |
23 | - $scope.isJustificativaAcaoProcesso = false; | |
24 | - $scope.isHistoricoJustificativa = false; | |
25 | - $scope.isAnexarProcesso = false; | |
26 | - $scope.widgetExemploIsCollapsed = true; | |
27 | - $scope.tratimitado(); | |
28 | - $scope.isGerenciarCredencialProcesso = false; | |
29 | - | |
30 | - }; | |
31 | - | |
32 | - //CRIAR RELACIONAMENTO DE PROCESSO | |
33 | - $scope.editProcessoRelacionado = function(){ | |
34 | - | |
35 | - $scope.fecharPagina(); | |
36 | - $scope.isProcessoRelacionado = true; | |
37 | - | |
38 | - $timeout(function() { | |
39 | - angular.element("#editProcessoRelacionado").scope().getProcessoRelacionado(); | |
40 | - }); | |
41 | - | |
42 | - }; | |
43 | - | |
44 | - $scope.historicoJustificativa = function(){ | |
45 | - $scope.fecharPagina(); | |
46 | - $scope.isHistoricoJustificativa = true; | |
47 | - $timeout(function() { | |
48 | - angular.element("#justificativaAcaoProcessoList").scope().inicializarJustificativa(); | |
49 | - }); | |
50 | - }; | |
51 | - | |
52 | - $scope.abrirJustificativa = function(acao){ | |
53 | - $scope.fecharPagina(); | |
54 | - $scope.isCancelarDocumento = true; | |
55 | - }; | |
56 | - | |
57 | - | |
58 | - // CRIA NOVO DOCUMENTO | |
59 | - $scope.newDocument = function() { | |
60 | - | |
61 | - $scope.fecharPagina(); | |
62 | - $scope.isDocumentoEdit = true; | |
63 | - $scope.isVersoesDocumento = false; | |
64 | - $timeout(function() { | |
65 | - angular.element("#editDocumentoGed").scope().resetForm(); | |
66 | - }); | |
67 | - }; | |
68 | - | |
69 | - // Abre a tela de edição do documento | |
70 | - $scope.editDocument = function(editarDocumento, edit) { | |
71 | - | |
72 | - $scope.fecharPagina(); | |
73 | - $scope.isDocumentoEdit = true; | |
74 | - $scope.isVersoesDocumento = false; | |
75 | - | |
76 | - $timeout(function() { | |
77 | - angular.element("#editDocumentoGed").scope().getDocumentoGed(editarDocumento.id, edit); | |
78 | - }); | |
79 | - }; | |
80 | - | |
81 | - // ABRE ABA PARA CRIAR NOVO PROCESSO | |
82 | - $scope.novoProcesso = function() { | |
83 | - | |
84 | - var workspace = angular.element('#editProcessoEcm').scope().workspace; | |
85 | - if (workspace) { | |
86 | - angular.element("#citapp-controller").scope().removeWorkspace(workspace.id); | |
87 | - } | |
88 | - | |
89 | - $scope.openWorkspaceIfNotOpen($translate.instant('ECM.LABEL.PROCESSO'), '/cit-ecm-web/html/processo/processo.html', 'mod-orange'); | |
90 | - | |
91 | - $timeout(function() { | |
92 | - angular.element('#editProcessoEcm').scope().$showPageEditWorkspace(angular.element('#editProcessoEcm').scope().workspace); | |
93 | - angular.element('#editProcessoEcm').scope().resetForm(); | |
94 | - | |
95 | - }, 600); | |
96 | - | |
97 | - }; | |
98 | - | |
99 | - //Gerenciar as credenciais do processo | |
100 | - $scope.gerenciarCredenciaisProcesso = function() { | |
101 | - | |
102 | - $scope.fecharPagina(); | |
103 | - $scope.isGerenciarCredencialProcesso = true; | |
104 | - | |
105 | - $timeout(function() { | |
106 | - angular.element("#credencialProcessoEdit").scope().iniciarCredencial($scope.processo.id, $scope.credencialUsuarioProcesso); | |
107 | - }); | |
108 | - }; | |
109 | - | |
110 | - | |
111 | - //EXECUÇÃO PROCESSO | |
112 | - $scope.executarProcesso = function(action){ | |
113 | - $scope.flowAction = action; | |
114 | - | |
115 | - if(action.requireReason){ | |
116 | - $scope.fecharPagina(); | |
117 | - $scope.isJustificativaAcaoProcesso = true; | |
118 | - $timeout(function() { | |
119 | - angular.element("#justificativaAcaoProcesso").scope().resetForm(); | |
120 | - }); | |
121 | - }else{ | |
122 | - $scope.closeWidget(); | |
123 | - | |
124 | - DocumentoGedRepository.existeVinculo({'joinClass' : 'processo.id', 'id': $scope.processo.id}).then(function(result) { | |
125 | - if(!result){ | |
126 | - var mensagem = $translate.instant('ECM.MSG.PROCESSO_SEM_DOCUMENTO') + $scope.flowAction.name; | |
127 | - $scope.showAlert("warning", mensagem ); | |
128 | - } else{ | |
129 | - var mensagem = $translate.instant('ECM.MSG.CONFIRMA_EXECUCAO_FLUXO'); | |
130 | - mensagem += $scope.flowAction.name; | |
131 | - $scope.$openModalConfirm({message: mensagem, callback: $scope.avancarFluxo}); | |
132 | - } | |
133 | - }); | |
134 | - | |
135 | - $scope.saveHistoricoProcessoAcao(); | |
136 | - } | |
137 | - }; | |
138 | - | |
139 | - $scope.avancarFluxo = function (){ | |
140 | - $scope.$modalConfirmInstance.dismiss('cancel'); | |
141 | - $scope.updateTask(true); | |
142 | - | |
143 | - }; | |
144 | - | |
145 | - //Salvar Historico Execução Processo | |
146 | - $scope.saveHistoricoProcessoAcao = function(){ | |
147 | - | |
148 | - var historicoAlteracaoProcesso = { | |
149 | - descricaoAcao : $translate.instant('ECM.MSG_HISTORICO_ECM.ACAO_PROCESSO'), | |
150 | - processo : $scope.processo, | |
151 | - autor : $scope.usuarioLogado, | |
152 | - acaoAlteracao : "ACAO_PROCESSO", | |
153 | - mapaAtributos : {"protocolo" : $scope.processo.nup, "acao" : $scope.flowAction.name} | |
154 | - }; | |
155 | - | |
156 | - HistoricoAlteracaoProcessoRepository.saveParams(historicoAlteracaoProcesso).then(function(result){ | |
157 | - }); | |
158 | - }; | |
159 | - | |
160 | - | |
161 | - //Conclui o proceso | |
162 | - $scope.concluir = function(){ | |
163 | - | |
164 | - DocumentoGedRepository.existeVinculo({'joinClass' : 'processo.id', 'id': $scope.processo.id}).then(function(result) { | |
165 | - if(!result){ | |
166 | - var mensagem = $translate.instant('ECM.MSG.PROCESSO_SEM_DOCUMENTO') +" " +$translate.instant('ECM.LABEL.CONCLUIR') ; | |
167 | - $scope.showAlert("warning", mensagem ); | |
168 | - } else{ | |
169 | - | |
170 | - $scope.$openModalConfirm({message: $translate.instant('ECM.MSG.CONFIRMA_CONCLUIR_PROCESSO'), callback: $scope.saveConcluir}); | |
171 | - } | |
172 | - }); | |
173 | - }; | |
174 | - | |
175 | - $scope.saveConcluir = function(){ | |
176 | - | |
177 | - ProcessoRepository.concluir({"idProcesso" : $scope.processo.id, "idTask" : $scope.task.id}).then(function(result) { | |
178 | - | |
179 | - //Verifica se foi concluido em todas unidades. | |
180 | - $timeout(function() { | |
181 | - if(result){ | |
182 | - if($scope.task.flowElement.actions && $scope.task.flowElement.actions.length == 1){ | |
183 | - $scope.executarProcesso($scope.task.flowElement.actions[0]); | |
42 | + }; | |
43 | + | |
44 | + // CRIAR RELACIONAMENTO DE PROCESSO | |
45 | + $scope.editProcessoRelacionado = function () { | |
46 | + | |
47 | + $scope.fecharPagina(); | |
48 | + $scope.isProcessoRelacionado = true; | |
49 | + | |
50 | + $timeout( function () { | |
51 | + angular.element( "#editProcessoRelacionado" ).scope().getProcessoRelacionado(); | |
52 | + } ); | |
53 | + | |
54 | + }; | |
55 | + | |
56 | + $scope.historicoJustificativa = function () { | |
57 | + $scope.fecharPagina(); | |
58 | + $scope.isHistoricoJustificativa = true; | |
59 | + $timeout( function () { | |
60 | + angular.element( "#justificativaAcaoProcessoList" ).scope().inicializarJustificativa(); | |
61 | + } ); | |
62 | + }; | |
63 | + | |
64 | + $scope.abrirJustificativa = function ( acao ) { | |
65 | + $scope.fecharPagina(); | |
66 | + $scope.isCancelarDocumento = true; | |
67 | + }; | |
68 | + | |
69 | + // CRIA NOVO DOCUMENTO | |
70 | + $scope.newDocument = function () { | |
71 | + | |
72 | + $scope.fecharPagina(); | |
73 | + $scope.isDocumentoEdit = true; | |
74 | + $scope.isVersoesDocumento = false; | |
75 | + $timeout( function () { | |
76 | + angular.element( "#editDocumentoGed" ).scope().resetForm(); | |
77 | + } ); | |
78 | + }; | |
79 | + | |
80 | + // Abre a tela de edição do documento | |
81 | + $scope.editDocument = function ( editarDocumento, edit ) { | |
82 | + | |
83 | + $scope.fecharPagina(); | |
84 | + $scope.isDocumentoEdit = true; | |
85 | + $scope.isVersoesDocumento = false; | |
86 | + | |
87 | + $timeout( function () { | |
88 | + angular.element( "#editDocumentoGed" ).scope().getDocumentoGed( editarDocumento.id, edit ); | |
89 | + } ); | |
90 | + }; | |
91 | + | |
92 | + // ABRE ABA PARA CRIAR NOVO PROCESSO | |
93 | + $scope.novoProcesso = function () { | |
94 | + | |
95 | + var workspace = angular.element( '#editProcessoEcm' ).scope().workspace; | |
96 | + if ( workspace ) { | |
97 | + angular.element( "#citapp-controller" ).scope().removeWorkspace( workspace.id ); | |
98 | + } | |
99 | + | |
100 | + $scope.openWorkspaceIfNotOpen( $translate.instant( 'ECM.LABEL.PROCESSO' ), '/cit-ecm-web/html/processo/processo.html', 'mod-orange' ); | |
101 | + | |
102 | + $timeout( function () { | |
103 | + angular.element( '#editProcessoEcm' ).scope().$showPageEditWorkspace( angular.element( '#editProcessoEcm' ).scope().workspace ); | |
104 | + angular.element( '#editProcessoEcm' ).scope().resetForm(); | |
105 | + | |
106 | + }, 600 ); | |
107 | + | |
108 | + }; | |
109 | + | |
110 | + // Gerenciar as credenciais do processo | |
111 | + $scope.gerenciarCredenciaisProcesso = function () { | |
112 | + | |
113 | + $scope.fecharPagina(); | |
114 | + $scope.isGerenciarCredencialProcesso = true; | |
115 | + | |
116 | + $timeout( function () { | |
117 | + angular.element( "#credencialProcessoEdit" ).scope().iniciarCredencial( $scope.processo.id, $scope.credencialUsuarioProcesso ); | |
118 | + } ); | |
119 | + }; | |
120 | + | |
121 | + // EXECUÇÃO PROCESSO | |
122 | + $scope.executarProcesso = function ( action ) { | |
123 | + $scope.flowAction = action; | |
124 | + | |
125 | + if ( action.requireReason ) { | |
126 | + $scope.fecharPagina(); | |
127 | + $scope.isJustificativaAcaoProcesso = true; | |
128 | + $timeout( function () { | |
129 | + angular.element( "#justificativaAcaoProcesso" ).scope().resetForm(); | |
130 | + } ); | |
131 | + } else { | |
132 | + $scope.closeWidget(); | |
133 | + | |
134 | + DocumentoGedRepository.existeVinculo( { | |
135 | + 'joinClass' : 'processo.id', | |
136 | + 'id' : $scope.processo.id | |
137 | + } ).then( function ( result ) { | |
138 | + if ( !result ) { | |
139 | + var mensagem = $translate.instant( 'ECM.MSG.PROCESSO_SEM_DOCUMENTO' ) + $scope.flowAction.name; | |
140 | + $scope.showAlert( "warning", mensagem ); | |
141 | + } else { | |
142 | + var mensagem = $translate.instant( 'ECM.MSG.CONFIRMA_EXECUCAO_FLUXO' ); | |
143 | + mensagem += $scope.flowAction.name; | |
144 | + $scope.$openModalConfirm( { | |
145 | + message : mensagem, | |
146 | + callback : $scope.avancarFluxo | |
147 | + } ); | |
148 | + } | |
149 | + } ); | |
150 | + | |
151 | + $scope.saveHistoricoProcessoAcao(); | |
152 | + } | |
153 | + }; | |
154 | + | |
155 | + $scope.avancarFluxo = function () { | |
156 | + $scope.$modalConfirmInstance.dismiss( 'cancel' ); | |
157 | + $scope.updateTask( true ); | |
158 | + | |
159 | + }; | |
160 | + | |
161 | + // Salvar Historico Execução Processo | |
162 | + $scope.saveHistoricoProcessoAcao = function () { | |
163 | + | |
164 | + var historicoAlteracaoProcesso = { | |
165 | + descricaoAcao : $translate.instant( 'ECM.MSG_HISTORICO_ECM.ACAO_PROCESSO' ), | |
166 | + processo : $scope.processo, | |
167 | + autor : $scope.usuarioLogado, | |
168 | + acaoAlteracao : "ACAO_PROCESSO", | |
169 | + mapaAtributos : { | |
170 | + "protocolo" : $scope.processo.nup, | |
171 | + "acao" : $scope.flowAction.name | |
184 | 172 | } |
185 | - }else{ | |
186 | - var workspace = angular.element('#editProcessoEcm').scope().workspace; | |
187 | - if (workspace) { | |
188 | - $scope.$modalConfirmInstance.dismiss('cancel'); | |
189 | - angular.element("#citapp-controller").scope().removeWorkspace(workspace.id); | |
190 | - | |
191 | - angular.element("#citapp-controller").scope().showAlert("success", $translate.instant('MSG.PROCESSO_ENVIADO_SUCESSO')); | |
192 | - } | |
173 | + }; | |
174 | + | |
175 | + HistoricoAlteracaoProcessoRepository.saveParams( historicoAlteracaoProcesso ).then( function ( result ) { | |
176 | + } ); | |
177 | + }; | |
178 | + | |
179 | + // Conclui o proceso | |
180 | + $scope.concluir = function () { | |
181 | + | |
182 | + DocumentoGedRepository.existeVinculo( { | |
183 | + 'joinClass' : 'processo.id', | |
184 | + 'id' : $scope.processo.id | |
185 | + } ).then( function ( result ) { | |
186 | + if ( !result ) { | |
187 | + var mensagem = $translate.instant( 'ECM.MSG.PROCESSO_SEM_DOCUMENTO' ) + " " + $translate.instant( 'ECM.LABEL.CONCLUIR' ); | |
188 | + $scope.showAlert( "warning", mensagem ); | |
189 | + } else { | |
190 | + | |
191 | + $scope.$openModalConfirm( { | |
192 | + message : $translate.instant( 'ECM.MSG.CONFIRMA_CONCLUIR_PROCESSO' ), | |
193 | + callback : $scope.saveConcluir | |
194 | + } ); | |
195 | + } | |
196 | + } ); | |
197 | + }; | |
198 | + | |
199 | + $scope.saveConcluir = function () { | |
200 | + | |
201 | + ProcessoRepository.concluir( { | |
202 | + "idProcesso" : $scope.processo.id, | |
203 | + "idTask" : $scope.task.id | |
204 | + } ).then( function ( result ) { | |
205 | + | |
206 | + // Verifica se foi concluido em todas unidades. | |
207 | + $timeout( function () { | |
208 | + if ( result ) { | |
209 | + if ( $scope.task.flowElement.actions && $scope.task.flowElement.actions.length == 1 ) { | |
210 | + $scope.executarProcesso( $scope.task.flowElement.actions[ 0 ] ); | |
211 | + } | |
212 | + } else { | |
213 | + var workspace = angular.element( '#editProcessoEcm' ).scope().workspace; | |
214 | + if ( workspace ) { | |
215 | + $scope.$modalConfirmInstance.dismiss( 'cancel' ); | |
216 | + angular.element( "#citapp-controller" ).scope().removeWorkspace( workspace.id ); | |
217 | + | |
218 | + angular.element( "#citapp-controller" ).scope().showAlert( "success", $translate.instant( 'MSG.PROCESSO_ENVIADO_SUCESSO' ) ); | |
219 | + } | |
220 | + } | |
221 | + | |
222 | + }, 100 ); | |
223 | + | |
224 | + $scope.showAlert( "success", $translate.instant( 'ECM.MSG.SUCESSO_CONCLUIR_PROCESSO' ) ); | |
225 | + | |
226 | + $scope.$modalConfirmInstance.dismiss( 'cancel' ); | |
227 | + | |
228 | + $scope.saveHistoricoProcesso(); | |
229 | + } ); | |
230 | + }; | |
231 | + | |
232 | + // Salvar Historico processo UNIDADE | |
233 | + $scope.saveHistoricoProcesso = function ( unidadesProcessoList ) { | |
234 | + | |
235 | + var historicoAlteracaoProcesso = { | |
236 | + descricaoAcao : $translate.instant( 'ECM.MSG_HISTORICO_ECM.CONCLUSAO_PROCESSO_UNIDADE' ), | |
237 | + processo : $scope.processo, | |
238 | + autor : $scope.usuarioLogado, | |
239 | + acaoAlteracao : "CONCLUSAO_PROCESSO_UNIDADE" | |
240 | + }; | |
241 | + | |
242 | + HistoricoAlteracaoProcessoRepository.saveParams( historicoAlteracaoProcesso ).then( function ( result ) { | |
243 | + | |
244 | + } ); | |
245 | + | |
246 | + }; | |
247 | + | |
248 | + // MONTA O EDITAR DO PROCESSO | |
249 | + $scope.editProcessoECM = function () { | |
250 | + | |
251 | + $scope.fecharPagina(); | |
252 | + $scope.isProcessoEdit = true; | |
253 | + $scope.isVersoesDocumento = false; | |
254 | + | |
255 | + $timeout( function () { | |
256 | + angular.element( '#editProcessoEcm' ).scope().getProcesso( $scope.processo, true ); | |
257 | + angular.element( document.querySelector( '#topoMenu' ) ).remove(); | |
258 | + angular.element( document.querySelector( '#cabecalhoProcesso' ) ).remove(); | |
259 | + } ); | |
260 | + | |
261 | + }; | |
262 | + | |
263 | + // ATUALIZAR PADRÃO DE PROCESSO | |
264 | + $scope.atualizaProcesso = function () { | |
265 | + | |
266 | + $timeout( function () { | |
267 | + ProcessoRepository.get( $scope.processo.id ).then( function ( result ) { | |
268 | + $scope.processo = result.originalElement; | |
269 | + } ); | |
270 | + }, 100 ); | |
271 | + | |
272 | + }; | |
273 | + | |
274 | + // VERSOES DO DOCUMENTO | |
275 | + $scope.visualizarVersoes = function ( documento ) { | |
276 | + | |
277 | + $scope.fecharPagina(); | |
278 | + $scope.isVersoesDocumento = true; | |
279 | + $scope.idDocumento = documento.id; | |
280 | + var idRaiz = documento.idRaiz; | |
281 | + if ( !idRaiz ) { | |
282 | + idRaiz = documento.id; | |
193 | 283 | } |
194 | - | |
195 | - }, 100); | |
196 | - | |
197 | - $scope.showAlert("success", $translate.instant('ECM.MSG.SUCESSO_CONCLUIR_PROCESSO')); | |
198 | - | |
199 | - $scope.$modalConfirmInstance.dismiss('cancel'); | |
200 | - | |
201 | - $scope.saveHistoricoProcesso(); | |
202 | - }); | |
203 | - }; | |
204 | - | |
205 | - //Salvar Historico processo UNIDADE | |
206 | - $scope.saveHistoricoProcesso = function(unidadesProcessoList){ | |
207 | - | |
208 | - var historicoAlteracaoProcesso = { | |
209 | - descricaoAcao : $translate.instant('ECM.MSG_HISTORICO_ECM.CONCLUSAO_PROCESSO_UNIDADE'), | |
210 | - processo : $scope.processo, | |
211 | - autor : $scope.usuarioLogado, | |
212 | - acaoAlteracao : "CONCLUSAO_PROCESSO_UNIDADE" | |
213 | - }; | |
214 | - | |
215 | - HistoricoAlteracaoProcessoRepository.saveParams(historicoAlteracaoProcesso).then(function(result){ | |
216 | - | |
217 | - }); | |
218 | - | |
219 | - }; | |
220 | - | |
221 | - // MONTA O EDITAR DO PROCESSO | |
222 | - $scope.editProcessoECM = function() { | |
223 | - | |
224 | - $scope.fecharPagina(); | |
225 | - $scope.isProcessoEdit = true; | |
226 | - $scope.isVersoesDocumento = false; | |
227 | - | |
228 | - $timeout(function() { | |
229 | - angular.element('#editProcessoEcm').scope().getProcesso($scope.processo, true); | |
230 | - angular.element(document.querySelector('#topoMenu')).remove(); | |
231 | - angular.element(document.querySelector('#cabecalhoProcesso')).remove(); | |
232 | - }); | |
233 | - | |
234 | - | |
235 | - }; | |
236 | - | |
237 | - //ATUALIZAR PADRÃO DE PROCESSO | |
238 | - $scope.atualizaProcesso = function() { | |
239 | - | |
240 | - $timeout(function(){ | |
241 | - ProcessoRepository.get($scope.processo.id).then(function(result) { | |
242 | - $scope.processo = result.originalElement; | |
243 | - }); | |
244 | - }, 100); | |
245 | - | |
246 | - }; | |
247 | - | |
248 | - //VERSOES DO DOCUMENTO | |
249 | - $scope.visualizarVersoes = function(documento){ | |
250 | - | |
251 | - $scope.fecharPagina(); | |
252 | - $scope.isVersoesDocumento = true; | |
253 | - $scope.idDocumento = documento.id; | |
254 | - var idRaiz = documento.idRaiz; | |
255 | - if(!idRaiz){ | |
256 | - idRaiz = documento.id; | |
257 | - } | |
258 | - DocumentoGedRepository.findByIdDocumentoTodasVersoes(idRaiz).then(function(result) { | |
259 | - $scope.listVersoes = result; | |
260 | - }); | |
261 | - | |
262 | - }; | |
263 | - | |
264 | - //ENVIAR PROCESSO | |
265 | - $scope.enviarProcesso = function(){ | |
266 | - | |
267 | - DocumentoGedRepository.existeVinculo({'joinClass' : 'processo.id', 'id': $scope.processo.id}).then(function(result) { | |
268 | - if(result){ | |
284 | + DocumentoGedRepository.findByIdDocumentoTodasVersoes( idRaiz ).then( function ( result ) { | |
285 | + $scope.listVersoes = result; | |
286 | + } ); | |
287 | + | |
288 | + }; | |
289 | + | |
290 | + // ENVIAR PROCESSO | |
291 | + $scope.enviarProcesso = function () { | |
292 | + | |
293 | + DocumentoGedRepository.existeVinculo( { | |
294 | + 'joinClass' : 'processo.id', | |
295 | + 'id' : $scope.processo.id | |
296 | + } ).then( function ( result ) { | |
297 | + if ( result ) { | |
298 | + $scope.fecharPagina(); | |
299 | + $scope.isEnviarProcesso = true; | |
300 | + | |
301 | + $timeout( function () { | |
302 | + angular.element( "#enviarProcessoEdit" ).scope().iniciarEnvio( $scope.processo.id, $scope.task.id ); | |
303 | + } ); | |
304 | + } else { | |
305 | + $scope.showAlert( "warning", $translate.instant( 'ECM.MSG.PROCESSO_SEM_DOCUMENTO_ENVIO_UNIDADE' ) ); | |
306 | + } | |
307 | + } ); | |
308 | + }; | |
309 | + | |
310 | + // ANEXAR PROCESSO | |
311 | + $scope.anexarProcesso = function () { | |
269 | 312 | $scope.fecharPagina(); |
270 | - $scope.isEnviarProcesso = true; | |
271 | - | |
272 | - $timeout(function() { | |
273 | - angular.element("#enviarProcessoEdit").scope().iniciarEnvio($scope.processo.id, $scope.task.id); | |
274 | - }); | |
275 | - }else{ | |
276 | - $scope.showAlert("warning", $translate.instant('ECM.MSG.PROCESSO_SEM_DOCUMENTO_ENVIO_UNIDADE')); | |
277 | - } | |
278 | - }); | |
279 | - }; | |
280 | - | |
281 | - //ANEXAR PROCESSO | |
282 | - $scope.anexarProcesso = function(){ | |
283 | - $scope.fecharPagina(); | |
284 | - $scope.isAnexarProcesso = true; | |
285 | - $timeout(function() { | |
286 | - angular.element("#anexarProcessoEdit").scope().getProcessoAnexado(); | |
287 | - }); | |
288 | - }; | |
289 | - | |
290 | - //REMOVER DOCUMENTO | |
291 | - $scope.removeDocumento = function(documento, index){ | |
292 | - $scope.$openModalConfirm({ | |
293 | - message: $translate.instant('MSG.CONFIRMA_EXCLUSAO'), | |
294 | - callback: function () { | |
295 | - DocumentoGedRepository.remove(documento).then(function() { | |
296 | - | |
297 | - $scope.$modalConfirmInstance.dismiss('cancel'); | |
298 | - $scope.showAlert("success", $translate.instant('MSG.SUCESSO_EXCLUIR')); | |
299 | - $scope.isDocumentoEdit = false; | |
300 | - $scope.processo.documentos.splice(index , 1); | |
301 | - | |
302 | - var historicoAlteracaoProcesso = { | |
303 | - documentoGed : $scope.documentoGed, | |
304 | - descricaoAcao : $translate.instant('ECM.MSG_HISTORICO_ECM.REMOCAO_DOCUMENTO'), | |
305 | - processo : $scope.processo, | |
306 | - autor : $scope.usuarioLogado, | |
307 | - idTask : $scope.task.id, | |
308 | - acaoAlteracao : "REMOCAO_DOCUMENTO" | |
309 | - }; | |
310 | - HistoricoAlteracaoProcessoRepository.saveParams(historicoAlteracaoProcesso).then(function(result){ | |
311 | - | |
312 | - }); | |
313 | - }); | |
314 | - } | |
315 | - }); | |
316 | - }; | |
317 | - | |
318 | - //Exibir dialog para remover credencial do usuário | |
319 | - $scope.exibirDialogConfirmacaoRemoverCredencial = function(){ | |
320 | - | |
321 | - $scope.$openModalConfirm({message: $translate.instant('ECM.MSG.CONFIRMA_RENUNCIAR_CREDENCIAL'), callback: $scope.removeCredemcial}); | |
322 | - | |
323 | - }; | |
324 | - | |
325 | - //Remover a credencial do usuário | |
326 | - $scope.removeCredemcial = function(){ | |
327 | - | |
328 | - CredencialProcessoRepository.remove($scope.credencialUsuarioProcesso).then(function() { | |
329 | - | |
330 | - $scope.credencialUsuarioProcesso = null; | |
331 | - | |
332 | - $scope.voltarGerenciamentoTarefa(); | |
333 | - | |
334 | - }); | |
335 | - }; | |
336 | - | |
337 | - //Voltar para tela de gerenciamento de tarefa | |
338 | - $scope.voltarGerenciamentoTarefa = function(){ | |
339 | - | |
340 | - var workspace = angular.element('#searchGerenciarProcesso').scope().workspace; | |
341 | - if (workspace) { | |
342 | - $scope.$modalConfirmInstance.dismiss('cancel'); | |
343 | - angular.element("#citapp-controller").scope().removeWorkspace(workspace.id); | |
344 | - | |
345 | - angular.element("#citapp-controller").scope().showAlert("success", $translate.instant('ECM.MSG.CREDENCIAL_REMOVIDA_SUCESSO')); | |
346 | - } | |
347 | - | |
348 | - $timeout(function(){ | |
349 | - angular.element('#idGerenciamentoTarefas').scope().fetchResult(); | |
350 | - }); | |
351 | - | |
352 | - }; | |
353 | - | |
354 | - //Cancelar documento | |
355 | - $scope.cancelarDocumento = function(documento){ | |
356 | - | |
357 | - $scope.fecharPagina(); | |
358 | - $scope.isCancelarDocumento = true; | |
359 | - $timeout(function() { | |
360 | - angular.element("#cancelarDocumento").scope().resetForm(documento, $scope.task.id); | |
361 | - }); | |
362 | - }; | |
363 | - | |
364 | - $scope.getCancelamentoDocumento = function(documento){ | |
365 | - | |
366 | - $scope.fecharPagina(); | |
367 | - $scope.isCancelarDocumento = true; | |
368 | - $timeout(function() { | |
369 | - angular.element("#cancelarDocumento").scope().getCancelamentoDocumento(documento.cancelamentoDocumentoGed.id); | |
370 | - }); | |
371 | - }; | |
372 | - | |
373 | - // SALVA PROCESSO | |
374 | - $scope.saveOrUpdateProcessoECM = function() { | |
375 | - | |
376 | - // CHAMA GRAVAR DO PROCESSOCONTROLLER.JS | |
377 | - angular.element('#editProcessoEcm').scope().saveOrUpdate(); | |
378 | - | |
379 | - $scope.closeWidget(); | |
380 | - $scope.atualizaProcesso(); | |
381 | - }; | |
382 | - | |
383 | - | |
384 | - // ABRE A VIEW DE GERENCIAR PROCESSO ANEXO | |
385 | - $scope.viewProcessoAnexo = function (processoViewAnexo){ | |
386 | - if(processoViewAnexo != null){ | |
387 | - | |
388 | - var pagina = '/cit-ecm-web/html/gerenciarProcesso/gerenciarProcessoView.html'; | |
389 | - | |
390 | - $scope.openWorkspaceIfNotOpen($translate.instant('ECM.LABEL.PROCESSO'), pagina, 'mod-orange'); | |
313 | + $scope.isAnexarProcesso = true; | |
314 | + $timeout( function () { | |
315 | + angular.element( "#anexarProcessoEdit" ).scope().getProcessoAnexado(); | |
316 | + } ); | |
317 | + }; | |
318 | + | |
319 | + // REMOVER DOCUMENTO | |
320 | + $scope.removeDocumento = function ( documento, index ) { | |
321 | + $scope.$openModalConfirm( { | |
322 | + message : $translate.instant( 'MSG.CONFIRMA_EXCLUSAO' ), | |
323 | + callback : function () { | |
324 | + DocumentoGedRepository.remove( documento ).then( function () { | |
325 | + | |
326 | + $scope.$modalConfirmInstance.dismiss( 'cancel' ); | |
327 | + $scope.showAlert( "success", $translate.instant( 'MSG.SUCESSO_EXCLUIR' ) ); | |
328 | + $scope.isDocumentoEdit = false; | |
329 | + $scope.processo.documentos.splice( index, 1 ); | |
330 | + | |
331 | + var historicoAlteracaoProcesso = { | |
332 | + documentoGed : $scope.documentoGed, | |
333 | + descricaoAcao : $translate.instant( 'ECM.MSG_HISTORICO_ECM.REMOCAO_DOCUMENTO' ), | |
334 | + processo : $scope.processo, | |
335 | + autor : $scope.usuarioLogado, | |
336 | + idTask : $scope.task.id, | |
337 | + acaoAlteracao : "REMOCAO_DOCUMENTO" | |
338 | + }; | |
339 | + HistoricoAlteracaoProcessoRepository.saveParams( historicoAlteracaoProcesso ).then( function ( result ) { | |
340 | + | |
341 | + } ); | |
342 | + } ); | |
343 | + } | |
344 | + } ); | |
345 | + }; | |
346 | + | |
347 | + // Exibir dialog para remover credencial do usuário | |
348 | + $scope.exibirDialogConfirmacaoRemoverCredencial = function () { | |
349 | + | |
350 | + $scope.$openModalConfirm( { | |
351 | + message : $translate.instant( 'ECM.MSG.CONFIRMA_RENUNCIAR_CREDENCIAL' ), | |
352 | + callback : $scope.removeCredemcial | |
353 | + } ); | |
354 | + | |
355 | + }; | |
356 | + | |
357 | + // Remover a credencial do usuário | |
358 | + $scope.removeCredemcial = function () { | |
359 | + | |
360 | + CredencialProcessoRepository.remove( $scope.credencialUsuarioProcesso ).then( function () { | |
361 | + | |
362 | + $scope.credencialUsuarioProcesso = null; | |
363 | + | |
364 | + $scope.voltarGerenciamentoTarefa(); | |
365 | + | |
366 | + } ); | |
367 | + }; | |
368 | + | |
369 | + // Voltar para tela de gerenciamento de tarefa | |
370 | + $scope.voltarGerenciamentoTarefa = function () { | |
371 | + | |
372 | + var workspace = angular.element( '#searchGerenciarProcesso' ).scope().workspace; | |
373 | + if ( workspace ) { | |
374 | + $scope.$modalConfirmInstance.dismiss( 'cancel' ); | |
375 | + angular.element( "#citapp-controller" ).scope().removeWorkspace( workspace.id ); | |
376 | + | |
377 | + angular.element( "#citapp-controller" ).scope().showAlert( "success", $translate.instant( 'ECM.MSG.CREDENCIAL_REMOVIDA_SUCESSO' ) ); | |
378 | + } | |
379 | + | |
380 | + $timeout( function () { | |
381 | + angular.element( '#idGerenciamentoTarefas' ).scope().fetchResult(); | |
382 | + } ); | |
383 | + | |
384 | + }; | |
385 | + | |
386 | + // Cancelar documento | |
387 | + $scope.cancelarDocumento = function ( documento ) { | |
388 | + | |
389 | + $scope.fecharPagina(); | |
390 | + $scope.isCancelarDocumento = true; | |
391 | + $timeout( function () { | |
392 | + angular.element( "#cancelarDocumento" ).scope().resetForm( documento, $scope.task.id ); | |
393 | + } ); | |
394 | + }; | |
395 | + | |
396 | + $scope.getCancelamentoDocumento = function ( documento ) { | |
397 | + | |
398 | + $scope.fecharPagina(); | |
399 | + $scope.isCancelarDocumento = true; | |
400 | + $timeout( function () { | |
401 | + angular.element( "#cancelarDocumento" ).scope().getCancelamentoDocumento( documento.cancelamentoDocumentoGed.id ); | |
402 | + } ); | |
403 | + }; | |
404 | + | |
405 | + // SALVA PROCESSO | |
406 | + $scope.saveOrUpdateProcessoECM = function () { | |
407 | + | |
408 | + // CHAMA GRAVAR DO PROCESSOCONTROLLER.JS | |
409 | + angular.element( '#editProcessoEcm' ).scope().saveOrUpdate(); | |
410 | + | |
411 | + $scope.closeWidget(); | |
412 | + $scope.atualizaProcesso(); | |
413 | + }; | |
414 | + | |
415 | + // ABRE A VIEW DE GERENCIAR PROCESSO ANEXO | |
416 | + $scope.viewProcessoAnexo = function ( processoViewAnexo ) { | |
417 | + if ( processoViewAnexo != null ) { | |
418 | + | |
419 | + var pagina = '/cit-ecm-web/html/gerenciarProcesso/gerenciarProcessoView.html'; | |
420 | + | |
421 | + $scope.openWorkspaceIfNotOpen( $translate.instant( 'ECM.LABEL.PROCESSO' ), pagina, 'mod-orange' ); | |
422 | + | |
423 | + $timeout( function () { | |
424 | + angular.element( '#viewGerenciarProcesso' ).scope().getProcessoRelacionado( processoViewAnexo ); | |
425 | + | |
426 | + }, 400 ); | |
427 | + } | |
428 | + }; | |
429 | + // FIM | |
430 | + | |
431 | + // FECHA WIDGET E INICIA WIDGET PADRÃO | |
432 | + $scope.closeWidget = function () { | |
433 | + angular.element( "#widget-historico" ).scope().atualizar(); | |
434 | + | |
435 | + $scope.fecharPagina(); | |
436 | + $scope.widgetExemploIsCollapsed = false; | |
437 | + // WIDGET PRADAO | |
438 | + $scope.isHistoricoProcesso = true; | |
439 | + }; | |
440 | + | |
441 | + $scope.tratimitado = function () { | |
391 | 442 | |
392 | - $timeout(function() { | |
393 | - angular.element('#viewGerenciarProcesso').scope().getProcessoRelacionado(processoViewAnexo); | |
394 | - | |
395 | - }, 400); | |
396 | - } | |
397 | - }; | |
398 | - //FIM | |
399 | - | |
400 | - // FECHA WIDGET E INICIA WIDGET PADRÃO | |
401 | - $scope.closeWidget = function() { | |
402 | - angular.element("#widget-historico").scope().atualizar(); | |
403 | - | |
404 | - $scope.fecharPagina(); | |
405 | - $scope.widgetExemploIsCollapsed = false; | |
406 | - //WIDGET PRADAO | |
407 | - $scope.isHistoricoProcesso = true; | |
408 | - }; | |
409 | - | |
410 | - $scope.tratimitado = function(){ | |
411 | - UnidadeProcessoRepository.existeVinculo({'joinClass' : 'processo.id', 'id': $scope.processo.id}).then(function(result) { | |
412 | - if(result){ | |
413 | - $scope.isTramitado = true; | |
414 | - }else{ | |
415 | - $scope.isTramitado = false; | |
416 | - } | |
417 | - }); | |
418 | - }; | |
419 | - | |
420 | - | |
421 | - | |
422 | - // ------------------------------EXECUTA BPE------------------------------------ | |
423 | - | |
424 | - // ATUALIZAR TASK BPE | |
425 | - $scope.updateTask = function(complete) { | |
426 | - if ($scope.updateAction && (!$scope.flowAction || !$scope.flowAction.id)) { | |
427 | - $scope.showAlert("error", $translate.instant('ESI.MSG.SELECIONE_ACAO')); | |
428 | - return; | |
429 | - } | |
443 | + UnidadeProcessoRepository.existeVinculo( { | |
444 | + 'joinClass' : 'processo.id', | |
445 | + 'id' : $scope.processo.id | |
446 | + } ).then( function ( result ) { | |
447 | + if ( result ) { | |
448 | + $scope.isTramitado = true; | |
449 | + } else{ | |
450 | + $scope.isTramitado = false; | |
451 | + } | |
452 | + } ); | |
453 | + }; | |
430 | 454 | |
455 | + // ------------------------------EXECUTA BPE------------------------------------ | |
431 | 456 | |
432 | - // Executa regras criadas | |
433 | - if ($scope.businessRule && $scope.businessRule != '') { | |
434 | - $scope.buildBusinessRuleVariables(); | |
435 | - $scope[$scope.businessRule] = undefined; | |
436 | - RuntimeManagerRepository.executeBusinessRule($scope.businessRule, $scope.businessRuleVariables).then(function(result) { | |
437 | - $scope[$scope.businessRule] = result.originalElement.businessRule; | |
438 | - if ($scope[$scope.businessRule] && $scope[$scope.businessRule].valid) { | |
439 | - $scope.execute(complete); | |
440 | - } | |
441 | - }); | |
442 | - }else{ | |
443 | - $scope.execute(complete); | |
444 | - } | |
445 | - | |
446 | - }; | |
447 | - | |
448 | - // FIM | |
449 | - | |
450 | - $scope.hasTaskVariable = function(name) { | |
451 | - for (var i = 0; i < $scope.taskVariables.length; i++) { | |
452 | - if ($scope.taskVariables[i].name == name) { | |
453 | - return true; | |
454 | - } | |
455 | - } | |
456 | - return false; | |
457 | - }; | |
458 | - | |
459 | - | |
460 | - // EXCUTA TAREFA BPE | |
461 | - $scope.execute = function(complete) { | |
462 | - $scope.setLoading(true,$translate.instant('ESI.EXECUTANDO_TAREFA')+" "+$scope.task.flowElement.name); | |
463 | - $scope.runtimeManagerUtils.executeCode("beforeUpdate"); | |
464 | - | |
465 | - var idRetorno = ESI_RETURN+$scope.flowName; | |
466 | - var idParam = ESI_PARAM+$scope.flowName; | |
467 | - $scope[idParam] = new RuntimeEnvironmentInput($scope.flowName,$scope.taskVariables); | |
468 | - $scope[idParam].workItemId = $scope.task.id; | |
469 | - $scope[idParam].updateFlowAction = $scope.updateAction; | |
470 | - | |
471 | - // ADICIONA ACÃO DO FLUXO NO SCOPO | |
472 | - if ($scope.updateAction) { | |
473 | - $scope[idParam].flowAction = $scope.flowAction; | |
474 | - } | |
457 | + // ATUALIZAR TASK BPE | |
458 | + $scope.updateTask = function ( complete ) { | |
459 | + if ( $scope.updateAction && ( !$scope.flowAction || !$scope.flowAction.id ) ) { | |
460 | + $scope.showAlert( "error", $translate.instant( 'ESI.MSG.SELECIONE_ACAO' ) ); | |
461 | + return; | |
462 | + } | |
475 | 463 | |
476 | - $scope[idRetorno] = new RuntimeEnvironmentOutput(null); | |
477 | - | |
478 | - RuntimeManagerRepository.updateTask($scope[idParam], complete).then(function(result) { | |
479 | - $scope[idRetorno] = new RuntimeEnvironmentOutput(result.originalElement); | |
480 | - $scope.runtimeManagerUtils.setObjectValues($scope[idRetorno]); | |
481 | - | |
482 | - $scope.processInstance = result.originalElement.processInstance; | |
483 | - | |
484 | - $scope.runtimeManagerUtils.saveDocuments($scope[idRetorno].processInstance, $scope.task); | |
485 | - | |
486 | - $scope.runtimeManagerUtils.executeCode("afterUpdate"); | |
487 | - $scope.setLoading(false); | |
488 | - $scope.showExecuteButton = false; | |
489 | - if ($scope.callbackFunction != null) | |
490 | - $scope.callbackFunction(); | |
491 | - $rootScope.controllerScope.fetchResult(); | |
492 | - if ($scope.removeWorkspace) | |
493 | - $scope.close(); | |
494 | - $scope.showAlert("success","ESI.MSG.TAREFA_EXECUTADA",""); | |
495 | - | |
496 | - }); | |
497 | - }; | |
498 | - | |
499 | - // FIM | |
500 | - | |
501 | - $scope.close = function() { | |
502 | - var workspace = angular.element('#searchGerenciarProcesso').scope().workspace; | |
503 | - if (workspace) { | |
504 | - angular.element("#citapp-controller").scope().removeWorkspace(workspace.id); | |
505 | - } | |
506 | - }; | |
507 | - | |
508 | - | |
509 | - // RETORNA VARIAVEIS DA TASK BPE | |
510 | - $scope.buildTaskVariables = function() { | |
511 | - if ($scope.task.flowElement.variables) { | |
512 | - for (var i = 0; i < $scope.task.flowElement.variables.length; i++) { | |
513 | - var taskVariable = $scope.task.flowElement.variables[i]; | |
514 | - if (taskVariable.output) { | |
515 | - if ($scope[taskVariable.flowVariable.variable.name] != undefined && !$scope.hasTaskVariable(taskVariable.flowVariable.variable.name)) { | |
516 | - $scope.taskVariables.push(new RuntimeVariable(taskVariable.flowVariable.variable.name , taskVariable.flowVariable.variable.variableType, $scope[taskVariable.flowVariable.variable.name])); | |
464 | + // Executa regras criadas | |
465 | + if ( $scope.businessRule && $scope.businessRule != '' ) { | |
466 | + $scope.buildBusinessRuleVariables(); | |
467 | + $scope[ $scope.businessRule ] = undefined; | |
468 | + RuntimeManagerRepository.executeBusinessRule( $scope.businessRule, $scope.businessRuleVariables ).then( function ( result ) { | |
469 | + $scope[ $scope.businessRule ] = result.originalElement.businessRule; | |
470 | + if ( $scope[ $scope.businessRule ] && $scope[ $scope.businessRule ].valid ) { | |
471 | + $scope.execute( complete ); | |
517 | 472 | } |
473 | + } ); | |
474 | + } else { | |
475 | + $scope.execute( complete ); | |
476 | + } | |
477 | + | |
478 | + }; | |
479 | + | |
480 | + // FIM | |
481 | + | |
482 | + $scope.hasTaskVariable = function ( name ) { | |
483 | + for ( var i = 0; i < $scope.taskVariables.length; i++ ) { | |
484 | + if ( $scope.taskVariables[ i ].name == name ) { | |
485 | + return true; | |
518 | 486 | } |
519 | 487 | } |
488 | + return false; | |
520 | 489 | }; |
521 | - }; | |
522 | - // FIM | |
523 | - | |
524 | - // METODOS DE INICIACAO DO BPE | |
525 | - $scope.initialize = function() { | |
526 | - $scope.setLoading(true); | |
527 | - | |
528 | - RuntimeManagerRepository.initializeUserTask($scope.task.id).then(function(result) { | |
529 | - $scope.task = result.originalElement.workItem; | |
530 | - | |
531 | - //VERIFICA SE A TASK(WORKITEM) JÁ FOI EXECULTADO | |
532 | - if ($scope.task.status == 'CANCELLED' || $scope.task.status == 'COMPLETED') { | |
533 | - $scope.setLoading(false); | |
534 | - $scope.showAlert('error', $translate.instant('ESI.MSG.TAREFA_JA_EXECUTADA')); | |
535 | - return ; | |
490 | + | |
491 | + // EXCUTA TAREFA BPE | |
492 | + $scope.execute = function ( complete ) { | |
493 | + $scope.setLoading( true, $translate.instant( 'ESI.EXECUTANDO_TAREFA' ) + " " + $scope.task.flowElement.name ); | |
494 | + $scope.runtimeManagerUtils.executeCode( "beforeUpdate" ); | |
495 | + | |
496 | + var idRetorno = ESI_RETURN + $scope.flowName; | |
497 | + var idParam = ESI_PARAM + $scope.flowName; | |
498 | + $scope[ idParam ] = new RuntimeEnvironmentInput( $scope.flowName, $scope.taskVariables ); | |
499 | + $scope[ idParam ].workItemId = $scope.task.id; | |
500 | + $scope[ idParam ].updateFlowAction = $scope.updateAction; | |
501 | + | |
502 | + // ADICIONA ACÃO DO FLUXO NO SCOPO | |
503 | + if ( $scope.updateAction ) { | |
504 | + $scope[ idParam ].flowAction = $scope.flowAction; | |
536 | 505 | } |
537 | - | |
538 | - // COLOCA AS VARIAVEIS DE RETORNO NO SCOPO | |
539 | - $scope.runtimeManagerUtils = new RuntimeManagerUtils($scope, $scope, $translate, RuntimeManagerRepository); | |
540 | - var idRetorno = ESI_RETURN+$scope.task.processInstance.id; | |
541 | - $scope[idRetorno] = new RuntimeEnvironmentOutput(result.originalElement); | |
542 | - $scope.runtimeManagerUtils.setObjectValues($scope[idRetorno]); | |
543 | - // FIM | |
544 | - | |
545 | - //VERIFICA SE EXISTE MAIS DE UMA AÇÃO NA EXECUÇÃO DO WORK ITEM | |
546 | - $scope.updateAction = $scope.task.flowElement.actions && $scope.task.flowElement.actions.length > 0; | |
547 | - if ($scope.task.flowElement.actions.length == 1) { | |
548 | - $scope.flowAction = $scope.task.flowElement.actions[0]; | |
506 | + | |
507 | + $scope[ idRetorno ] = new RuntimeEnvironmentOutput( null ); | |
508 | + | |
509 | + RuntimeManagerRepository.updateTask( $scope[ idParam ], complete ).then( function ( result ) { | |
510 | + $scope[ idRetorno ] = new RuntimeEnvironmentOutput( result.originalElement ); | |
511 | + $scope.runtimeManagerUtils.setObjectValues( $scope[ idRetorno ] ); | |
512 | + | |
513 | + $scope.processInstance = result.originalElement.processInstance; | |
514 | + | |
515 | + $scope.runtimeManagerUtils.saveDocuments( $scope[ idRetorno ].processInstance, $scope.task ); | |
516 | + | |
517 | + $scope.runtimeManagerUtils.executeCode( "afterUpdate" ); | |
518 | + $scope.setLoading( false ); | |
519 | + $scope.showExecuteButton = false; | |
520 | + if ( $scope.callbackFunction != null ) | |
521 | + $scope.callbackFunction(); | |
522 | + $rootScope.controllerScope.fetchResult(); | |
523 | + if ( $scope.removeWorkspace ) | |
524 | + $scope.close(); | |
525 | + $scope.showAlert( "success", "ESI.MSG.TAREFA_EXECUTADA", "" ); | |
526 | + | |
527 | + } ); | |
528 | + }; | |
529 | + | |
530 | + // FIM | |
531 | + | |
532 | + $scope.close = function () { | |
533 | + var workspace = angular.element( '#searchGerenciarProcesso' ).scope().workspace; | |
534 | + if ( workspace ) { | |
535 | + angular.element( "#citapp-controller" ).scope().removeWorkspace( workspace.id ); | |
549 | 536 | } |
550 | - $scope.siglas = []; | |
551 | - | |
537 | + }; | |
552 | 538 | |
553 | - // CARREGA O PROCESSO VINCULADO A TAREFA | |
554 | - $timeout(function(){ | |
555 | - // console.log('idProcesso:' + $scope.idProcesso); | |
556 | - ProcessoRepository.get($scope.idProcesso).then(function(result) { | |
557 | - $scope.processo = result.originalElement; | |
558 | - | |
559 | - CredencialProcessoRepository.obterCredencialUsuarioLogado($scope.idProcesso).then(function(result) { | |
560 | - $scope.credencialUsuarioProcesso = result.originalElement; | |
561 | - }); | |
562 | - | |
563 | - if ($scope.$parent != undefined) { | |
564 | - $scope.$parent.idProcesso = $scope.idProcesso; | |
565 | - } | |
566 | - | |
567 | - if (angular.element('#viewGerenciarProcesso').scope() != undefined) { | |
568 | - var workspace = angular.element('#viewGerenciarProcesso').scope().workspace; | |
569 | - angular.element("#citapp-controller").scope().removeWorkspace(workspace.id); | |
539 | + // RETORNA VARIAVEIS DA TASK BPE | |
540 | + $scope.buildTaskVariables = function () { | |
541 | + if ( $scope.task.flowElement.variables ) { | |
542 | + for ( var i = 0; i < $scope.task.flowElement.variables.length; i++ ) { | |
543 | + var taskVariable = $scope.task.flowElement.variables[ i ]; | |
544 | + if ( taskVariable.output ) { | |
545 | + if ( $scope[ taskVariable.flowVariable.variable.name ] != undefined && !$scope.hasTaskVariable( taskVariable.flowVariable.variable.name ) ) { | |
546 | + $scope.taskVariables.push( new RuntimeVariable( taskVariable.flowVariable.variable.name, taskVariable.flowVariable.variable.variableType, | |
547 | + $scope[ taskVariable.flowVariable.variable.name ] ) ); | |
548 | + } | |
570 | 549 | } |
571 | - | |
572 | - $scope.tratimitado(); | |
573 | - | |
574 | - $scope.setLoading(false); | |
575 | - }); | |
576 | - | |
577 | - }, 400); | |
578 | - }); | |
579 | - }; | |
580 | - // FIM EXECUTAR BPE | |
581 | - | |
582 | - $scope.initialize(); | |
583 | - | |
584 | - $scope.getProcesso = function(processo){ | |
585 | - | |
586 | - $scope.setLoadingGet(true); | |
587 | - | |
588 | - $scope.isHistoricoProcesso = true; | |
589 | - | |
590 | - $scope.processo = processo; | |
591 | - $scope.idProcesso = $scope.processo.id; | |
592 | - | |
593 | - $scope.setLoading(false); | |
594 | - | |
595 | - }; | |
596 | - | |
597 | - | |
598 | -}]); | |
550 | + } | |
551 | + } | |
552 | + ; | |
553 | + }; | |
554 | + // FIM | |
555 | + | |
556 | + // METODOS DE INICIACAO DO BPE | |
557 | + $scope.initialize = function () { | |
558 | + $scope.setLoading( true ); | |
559 | + | |
560 | + RuntimeManagerRepository.initializeUserTask( $scope.task.id ).then( function ( result ) { | |
561 | + $scope.task = result.originalElement.workItem; | |
562 | + | |
563 | + // VERIFICA SE A TASK(WORKITEM) JÁ FOI EXECULTADO | |
564 | + if ( $scope.task.status == 'CANCELLED' || $scope.task.status == 'COMPLETED' ) { | |
565 | + $scope.setLoading( false ); | |
566 | + $scope.showAlert( 'error', $translate.instant( 'ESI.MSG.TAREFA_JA_EXECUTADA' ) ); | |
567 | + return; | |
568 | + } | |
569 | + | |
570 | + // COLOCA AS VARIAVEIS DE RETORNO NO SCOPO | |
571 | + $scope.runtimeManagerUtils = new RuntimeManagerUtils( $scope, $scope, $translate, RuntimeManagerRepository ); | |
572 | + var idRetorno = ESI_RETURN + $scope.task.processInstance.id; | |
573 | + $scope[ idRetorno ] = new RuntimeEnvironmentOutput( result.originalElement ); | |
574 | + $scope.runtimeManagerUtils.setObjectValues( $scope[ idRetorno ] ); | |
575 | + // FIM | |
576 | + | |
577 | + // VERIFICA SE EXISTE MAIS DE UMA AÇÃO NA EXECUÇÃO DO WORK ITEM | |
578 | + $scope.updateAction = $scope.task.flowElement.actions && $scope.task.flowElement.actions.length > 0; | |
579 | + if ( $scope.task.flowElement.actions.length == 1 ) { | |
580 | + $scope.flowAction = $scope.task.flowElement.actions[ 0 ]; | |
581 | + } | |
582 | + $scope.siglas = []; | |
583 | + | |
584 | + // CARREGA O PROCESSO VINCULADO A TAREFA | |
585 | + $timeout( function () { | |
586 | + // console.log('idProcesso:' + $scope.idProcesso); | |
587 | + ProcessoRepository.get( $scope.idProcesso ).then( function ( result ) { | |
588 | + $scope.processo = result.originalElement; | |
589 | + | |
590 | + /* | |
591 | + * CredencialProcessoRepository.obterCredencialUsuarioLogado($scope.idProcesso).then(function(result) { $scope.credencialUsuarioProcesso = result.originalElement; }); | |
592 | + */ | |
593 | + | |
594 | + if ( $scope.$parent != undefined ) { | |
595 | + $scope.$parent.idProcesso = $scope.idProcesso; | |
596 | + } | |
597 | + | |
598 | + if ( angular.element( '#viewGerenciarProcesso' ).scope() != undefined ) { | |
599 | + var workspace = angular.element( '#viewGerenciarProcesso' ).scope().workspace; | |
600 | + angular.element( "#citapp-controller" ).scope().removeWorkspace( workspace.id ); | |
601 | + } | |
602 | + | |
603 | + $scope.tratimitado(); | |
604 | + | |
605 | + $scope.setLoading( false ); | |
606 | + } ); | |
607 | + | |
608 | + }, 400 ); | |
609 | + } ); | |
610 | + }; | |
611 | + // FIM EXECUTAR BPE | |
612 | + | |
613 | + $scope.initialize(); | |
614 | + | |
615 | + $scope.getProcesso = function ( processo ) { | |
616 | + | |
617 | + $scope.setLoadingGet( true ); | |
618 | + | |
619 | + $scope.isHistoricoProcesso = true; | |
620 | + | |
621 | + $scope.processo = processo; | |
622 | + $scope.idProcesso = $scope.processo.id; | |
623 | + | |
624 | + $scope.setLoading( false ); | |
625 | + | |
626 | + }; | |
627 | + | |
628 | + } | |
629 | +] ); | ... | ... |
cit-ecm-web/src/main/webapp/html/documentoGed/documentoAnexoVisualizacao.html
... | ... | @@ -16,14 +16,6 @@ |
16 | 16 | <div collapse="widgetAnexoIsCollapsed" class="widget-body"> |
17 | 17 | <div class="widget-main clearfix"> |
18 | 18 | <div id="anexoGed" class="page-content clearfix"> |
19 | - <div class="row"> | |
20 | - <div class="col-md-4"> | |
21 | - <div class="form-group"> | |
22 | - <label class='control-label'><translate>ECM.LABEL.DATA_REFERENCIA</translate></label> | |
23 | - <label>{{documentoGed.dataReferencia | date:'dd-MM-yyyy'}}</label> | |
24 | - </div> | |
25 | - </div> | |
26 | - </div> | |
27 | 19 | <div class="row" ng-show='documentoGed.anexo.id && !edit'> |
28 | 20 | <div class="col-sm-6"> |
29 | 21 | <strong><label>{{ documentoGed.anexo.descricao}}</label></strong> | ... | ... |
cit-ecm-web/src/main/webapp/html/documentoGed/documentoGedEdit.html
1 | 1 | |
2 | 2 | <div ng-controller="DocumentoGedController as documentoGedController"> |
3 | 3 | <form name="documentoGedController.documentoGedForm" novalidate autocomplete="off"> |
4 | - | |
4 | + | |
5 | 5 | <div ng-if="!edit"> |
6 | 6 | <div ng-include src="'/cit-ecm-web/html/documentoGed/documentoAnexoVisualizacao.html'" /> |
7 | 7 | ... | ... |
cit-ecm-web/src/main/webapp/html/documentoGed/metadadosDocumentoEdit.html
... | ... | @@ -5,9 +5,8 @@ |
5 | 5 | </h2> |
6 | 6 | |
7 | 7 | <div class="widget-toolbar"> |
8 | - <a href="#void" ng-click="widgetDocumentoIsCollapsed = !widgetDocumentoIsCollapsed"> | |
9 | - <i class="fa" ng-class="{'fa-chevron-up': !widgetDocumentoIsCollapsed, 'fa-chevron-down': widgetDocumentoIsCollapsed}"></i></a> | |
10 | - <a href="#void" ng-click="closeWidget('widget-processo')"> <i class="fa fa-close"></i></a> | |
8 | + <a href="#void" ng-click="widgetDocumentoIsCollapsed = !widgetDocumentoIsCollapsed"> <i class="fa" | |
9 | + ng-class="{'fa-chevron-up': !widgetDocumentoIsCollapsed, 'fa-chevron-down': widgetDocumentoIsCollapsed}"></i></a> <a href="#void" ng-click="closeWidget('widget-processo')"> <i class="fa fa-close"></i></a> | |
11 | 10 | </div> |
12 | 11 | </div> |
13 | 12 | <div id="metadadosDocumentoGedCollapsed" collapse="widgetDocumentoIsCollapsed" class="widget-body"> |
... | ... | @@ -43,6 +42,16 @@ |
43 | 42 | ng-custom-maxlength="255" ng-type="text" ng-disabled="!edit || documentoGed.formaCriacao.codigo == 1" /> |
44 | 43 | </div> |
45 | 44 | |
45 | + <div class="row" ng-show='documentoGed.formaCriacao.codigo == 2'> | |
46 | + <div class="col-md-4"> | |
47 | + <label-input-data ng-id="documentoGed.dataReferencia" form="documentoGedForm" ng-label="ECM.LABEL.DATA_REFERENCIA" ng-obrigatorio="documentoGed.formaCriacao.codigo == 2" ng-disabled="!edit" | |
48 | + ng-model="documentoGed.dataReferencia" /> | |
49 | + </div> | |
50 | + </div> | |
51 | + </div> | |
52 | + | |
53 | + <div class="row"> | |
54 | + | |
46 | 55 | <div class="col-md-8"> |
47 | 56 | <auto-complete ng-id="documentoGed.tipoDocumento" ng-set-result="construirRelacionamento(item)" ng-label="ECM.LABEL.TIPODOCUMENTO" ng-model="documentoGed.tipoDocumento" form="documentoGedForm" |
48 | 57 | ng-obrigatorio="true" ng-acao-borracha='limparCamposTipoProcesso()' ng-disabled="!edit ||(documentoGed.id && documentoGed.formaCriacao.codigo == 1)" |
... | ... | @@ -153,7 +162,8 @@ |
153 | 162 | <div class="row"> |
154 | 163 | |
155 | 164 | <div class="col-md-10"> |
156 | - <auto-complete ng-id="interessado" ng-label="ECM.LABEL.INTERESSADO" ng-disabled="!edit" form='documentoGedForm' ng-model="interessado" ng-find="findAutoCompleteInteressados(value)" ng-item="item.nome" ng-set-result="setInteressados(item)" /> | |
165 | + <auto-complete ng-id="interessado" ng-label="ECM.LABEL.INTERESSADO" ng-disabled="!edit" form='documentoGedForm' ng-model="interessado" ng-find="findAutoCompleteInteressados(value)" | |
166 | + ng-item="item.nome" ng-set-result="setInteressados(item)" /> | |
157 | 167 | </div> |
158 | 168 | |
159 | 169 | <div class="col-md-12"> |
... | ... | @@ -176,9 +186,8 @@ |
176 | 186 | </thead> |
177 | 187 | <tbody> |
178 | 188 | <tr ng-repeat="interessado in documentoGed.interessados"> |
179 | - <td class="text-center"> | |
180 | - <input type="radio" name="interessadoChecked" id="interessadoChecked" ng-value="interessado" ng-model="$parent.interessadoChecked" ng-click="setInteressadoRemocao(interessado, $index)" /> | |
181 | - </td> | |
189 | + <td class="text-center"><input type="radio" name="interessadoChecked" id="interessadoChecked" ng-value="interessado" ng-model="$parent.interessadoChecked" | |
190 | + ng-click="setInteressadoRemocao(interessado, $index)" /></td> | |
182 | 191 | |
183 | 192 | <td class="text-center">{{interessado.interessado.nome}}</td> |
184 | 193 | |
... | ... | @@ -219,13 +228,6 @@ |
219 | 228 | </label> |
220 | 229 | </legend> |
221 | 230 | |
222 | - <div class="row"> | |
223 | - <div class="col-md-6"> | |
224 | - <label-input-data ng-id="documentoGed.dataReferencia" form="documentoGedForm" ng-label="ECM.LABEL.DATA_REFERENCIA" ng-obrigatorio="documentoGed.formaCriacao.codigo == 2" ng-disabled="!edit" | |
225 | - ng-model="documentoGed.dataReferencia" /> | |
226 | - </div> | |
227 | - </div> | |
228 | - | |
229 | 231 | <div class="row" style="padding: 0px 12px 0px 12px !important;" ng-show='uploader.queue < 1 && !documentoGed.anexo.id'> |
230 | 232 | <div nv-file-drop="" uploader="uploader" id="actionUploadArquivos" onclick="$('#uploadArquivos').click();"> |
231 | 233 | <div nv-file-over="" uploader="uploader" over-class="another-file-over-class" class="well my-drop-zone"> | ... | ... |
cit-ecm-web/src/main/webapp/html/gerenciarProcesso/includeAcaoProcesso.html
1 | - | |
2 | - <div ng-include src="'/cit-ecm-web/html/processoRelacionado/processoRelacionadoEdit.html'" ng-if="isProcessoRelacionado" /> | |
3 | 1 | |
4 | - <div ng-include src="'/cit-ecm-web/html/documentoGed/documentoGedEdit.html'" ng-show="isDocumentoEdit" /> | |
2 | +<div ng-include src="'/cit-ecm-web/html/processoRelacionado/processoRelacionadoEdit.html'" ng-show="isProcessoRelacionado" /> | |
5 | 3 | |
6 | - <div ng-include src="'/cit-ecm-web/html/grupoProcesso/enviarProcesso.html'" ng-if="isEnviarProcesso" /> | |
4 | +<div ng-include src="'/cit-ecm-web/html/documentoGed/documentoGedEdit.html'" ng-show="isDocumentoEdit" /> | |
7 | 5 | |
8 | - <div ng-include src="'/cit-ecm-web/html/anexarProcesso/anexarProcesso.html'" ng-if="isAnexarProcesso" /> | |
6 | +<div ng-include src="'/cit-ecm-web/html/grupoProcesso/enviarProcesso.html'" ng-show="isEnviarProcesso" /> | |
9 | 7 | |
10 | - <div ng-include src="'/cit-ecm-web/html/versaoDocumentoGed/versaoDocumentoGedList.html'" ng-if="isVersoesDocumento" /> | |
8 | +<div ng-include src="'/cit-ecm-web/html/anexarProcesso/anexarProcesso.html'" ng-show="isAnexarProcesso" /> | |
11 | 9 | |
12 | - <div ng-include src="'/cit-ecm-web/html/historicoAlteracaoProcesso/historicoAlteracaoProcesso.html'" ng-show="isHistoricoProcesso" /> | |
10 | +<div ng-include src="'/cit-ecm-web/html/versaoDocumentoGed/versaoDocumentoGedList.html'" ng-show="isVersoesDocumento" /> | |
13 | 11 | |
14 | - <div ng-include src="'/cit-ecm-web/html/documentoGed/cancelarDocumento.html'" ng-if="isCancelarDocumento" /> | |
12 | +<div ng-include src="'/cit-ecm-web/html/historicoAlteracaoProcesso/historicoAlteracaoProcesso.html'" ng-show="isHistoricoProcesso" /> | |
15 | 13 | |
16 | - <div ng-include src="'/cit-ecm-web/html/justificativaProcesso/justificativaAcaoProcesso.html'" ng-if="isJustificativaAcaoProcesso" /> | |
14 | +<div ng-include src="'/cit-ecm-web/html/documentoGed/cancelarDocumento.html'" ng-show="isCancelarDocumento" /> | |
17 | 15 | |
18 | - <div ng-include src="'/cit-ecm-web/html/justificativaProcesso/justificativaAcaoProcessoList.html'" ng-if="isHistoricoJustificativa" /> | |
19 | - | |
20 | - <div ng-include src="'/cit-ecm-web/html/credencialProcesso/credencialProcesso.html'" ng-show="isGerenciarCredencialProcesso" /> | |
16 | +<div ng-include src="'/cit-ecm-web/html/justificativaProcesso/justificativaAcaoProcesso.html'" ng-show="isJustificativaAcaoProcesso" /> | |
21 | 17 | |
22 | - <div ng-include src="'/cit-ecm-web/html/classificarProcessoDocumento/classificarProcessoDocumento.html'" ng-if="isClassificarProcessoDocumento" /> | |
18 | +<div ng-include src="'/cit-ecm-web/html/justificativaProcesso/justificativaAcaoProcessoList.html'" ng-show="isHistoricoJustificativa" /> | |
23 | 19 | |
24 | - | |
20 | +<div ng-include src="'/cit-ecm-web/html/credencialProcesso/credencialProcesso.html'" ng-show="isGerenciarCredencialProcesso" /> | |
25 | 21 | |
26 | - <div id="widget-processo" ng-show="isProcessoEdit" class="widget-box margin-bottom"> | |
27 | - <div class="widget-header"> | |
28 | - <h2 class="widget-title"> | |
29 | - <translate>ECM.LABEL.PROCESSO</translate> | |
30 | - </h2> | |
22 | +<div ng-include src="'/cit-ecm-web/html/classificarProcessoDocumento/classificarProcessoDocumento.html'" ng-show="isClassificarProcessoDocumento" /> | |
31 | 23 | |
32 | - <div class="widget-toolbar"> | |
33 | - <a href="#void" ng-click="closeWidget('widget-processo')"> <i class="fa fa-close"></i> | |
34 | - </a> | |
35 | - </div> | |
36 | - </div> | |
37 | - <div class="widget-body"> | |
38 | - <div class="widget-main clearfix"> | |
39 | - <div ng-include src="'/cit-ecm-web/html/processo/processoEdit.html'" /> | |
40 | - </div> | |
41 | - </div> | |
42 | 24 | |
43 | - <div class="row"> | |
44 | - <div style="margin-top: -38px; margin-left: 17px;" class="col-md-12"> | |
45 | - <button class="btn btn-sm btn-primary" ng-click="saveOrUpdateProcessoECM()" ng-show="true"> | |
46 | - <translate>LABEL.SALVAR</translate> | |
47 | - </button> | |
48 | 25 | |
49 | - <button class="btn btn-sm btn-primary" ng-click="closeWidget('widget-processo')" ng-show="true"> | |
50 | - <translate>LABEL.CANCELAR</translate> | |
51 | - </button> | |
52 | - </div> | |
53 | - </div> | |
54 | - </div> | |
55 | 26 | \ No newline at end of file |
27 | +<div id="widget-processo" ng-show="isProcessoEdit" class="widget-box margin-bottom"> | |
28 | + <div class="widget-header"> | |
29 | + <h2 class="widget-title"> | |
30 | + <translate>ECM.LABEL.PROCESSO</translate> | |
31 | + </h2> | |
32 | + | |
33 | + <div class="widget-toolbar"> | |
34 | + <a href="#void" ng-click="closeWidget('widget-processo')"> <i class="fa fa-close"></i> | |
35 | + </a> | |
36 | + </div> | |
37 | + </div> | |
38 | + <div class="widget-body"> | |
39 | + <div class="widget-main clearfix"> | |
40 | + <div ng-include src="'/cit-ecm-web/html/processo/processoEdit.html'" /> | |
41 | + </div> | |
42 | + </div> | |
43 | + | |
44 | + <div class="row"> | |
45 | + <div style="margin-top: -38px; margin-left: 17px;" class="col-md-12"> | |
46 | + <button class="btn btn-sm btn-primary" ng-click="saveOrUpdateProcessoECM()" ng-show="true"> | |
47 | + <translate>LABEL.SALVAR</translate> | |
48 | + </button> | |
49 | + | |
50 | + <button class="btn btn-sm btn-primary" ng-click="closeWidget('widget-processo')" ng-show="true"> | |
51 | + <translate>LABEL.CANCELAR</translate> | |
52 | + </button> | |
53 | + </div> | |
54 | + </div> | |
55 | +</div> | |
56 | 56 | \ No newline at end of file | ... | ... |
cit-ecm-web/src/main/webapp/html/gerenciarProcesso/includeCabecalhoGerenciarProcesso.html
1 | 1 | |
2 | - <button ng-show="task.flowElement.actions && task.flowElement.actions.length == 1" title="{{$translate.instant('ESI.EXECUCAO_TAREFA.GRAVAR_TAREFA_AVANCAR')}}" | |
3 | - alt="{{$translate.instant('ESI.EXECUCAO_TAREFA.GRAVAR_TAREFA_AVANCAR')}}" class="btn btn-clear" ng-click="executarProcesso(task.flowElement.actions[0])"> | |
2 | +<button ng-show="task.flowElement.actions && task.flowElement.actions.length == 1" title="{{$translate.instant('ESI.EXECUCAO_TAREFA.GRAVAR_TAREFA_AVANCAR')}}" | |
3 | + alt="{{$translate.instant('ESI.EXECUCAO_TAREFA.GRAVAR_TAREFA_AVANCAR')}}" class="btn btn-clear" ng-click="executarProcesso(task.flowElement.actions[0])"> | |
4 | + <i class="fa fa-play-circle green"></i> | |
5 | + <translate>ECM.LABEL.AVANCAR_FLUXO</translate> | |
6 | +</button> | |
7 | + | |
8 | +<div class="btn-group dropdown" role="group" dropdown ng-show=" task.flowElement.actions && task.flowElement.actions.length > 1"> | |
9 | + <button type="button" class="btn btn-clear" dropdown-toggle> | |
4 | 10 | <i class="fa fa-play-circle green"></i> |
5 | - <translate>LABEL.AVANCAR_FLUXO</translate> | |
11 | + <translate>ECM.LABEL.AVANCAR_FLUXO</translate> | |
12 | + <span class="fa fa-caret-down icon-on-right"></span> | |
6 | 13 | </button> |
7 | 14 | |
8 | - <div class="btn-group dropdown" role="group" dropdown ng-show=" task.flowElement.actions && task.flowElement.actions.length > 1"> | |
9 | - <button type="button" class="btn btn-clear" dropdown-toggle> | |
10 | - <i class="fa fa-play-circle green"></i> | |
11 | - <translate>LABEL.AVANCAR_FLUXO</translate> | |
12 | - <span class="fa fa-caret-down icon-on-right"></span> | |
13 | - </button> | |
15 | + <ul class="dropdown-menu-center dropdown-menu dropdown-caret" role="menu" ng-repeat="action in task.flowElement.actions"> | |
16 | + <li ng-repeat="action in task.flowElement.actions"><a href="javascript: return false;" ng-click='executarProcesso(action);'><i class="fa fa-circle"> <translate>{{action.name}}</translate></i></a> | |
17 | + </li> | |
14 | 18 | |
15 | - <ul class="dropdown-menu-center dropdown-menu dropdown-caret" role="menu" ng-repeat="action in task.flowElement.actions"> | |
16 | - <li ng-repeat="action in task.flowElement.actions"><a href="javascript: return false;" ng-click='executarProcesso(action);'><i class="fa fa-circle"> <translate>{{action.name}}</translate></i></a> | |
17 | - </li> | |
19 | + </ul> | |
20 | +</div> | |
18 | 21 | |
19 | - </ul> | |
20 | - </div> | |
22 | +<span class="divider-vertical"></span> | |
21 | 23 | |
22 | - <span class="divider-vertical"></span> | |
24 | +<button type="button" class="btn btn-clear" ng-click="novoProcesso();"> | |
25 | + <i class="fa fa-plus-circle yellow-dark"></i> | |
26 | + <translate>ECM.LABEL.NOVOPROCESSO</translate> | |
27 | +</button> | |
23 | 28 | |
24 | - <button type="button" class="btn btn-clear" ng-click="novoProcesso();"> | |
25 | - <i class="fa fa-plus-circle yellow-dark"></i> | |
26 | - <translate>ECM.LABEL.NOVOPROCESSO</translate> | |
27 | - </button> | |
29 | +<button type="button" class="btn btn-clear" ng-click="editProcessoECM()"> | |
30 | + <i class="fa fa-pencil blue"></i> | |
31 | + <translate>LABEL.EDITAR</translate> | |
32 | +</button> | |
28 | 33 | |
29 | - <button type="button" class="btn btn-clear" ng-click="editProcessoECM()"> | |
30 | - <i class="fa fa-pencil blue"></i> | |
31 | - <translate>LABEL.EDITAR</translate> | |
32 | - </button> | |
34 | +<button type="button" class="btn btn-clear" ng-click="concluir()"> | |
35 | + <i class="ace-icon fa fa-check green"></i> | |
36 | + <translate>ECM.LABEL.CONCLUIR</translate> | |
37 | +</button> | |
33 | 38 | |
34 | - <button type="button" class="btn btn-clear" ng-click="concluir()"> | |
35 | - <i class="ace-icon fa fa-check green"></i> | |
36 | - <translate>ECM.LABEL.CONCLUIR</translate> | |
37 | - </button> | |
38 | 39 | |
40 | +<button type="button" class="btn btn-clear" ng-click="newDocument()"> | |
41 | + <i class="fa fa-book blue"></i> | |
42 | + <translate>ECM.LABEL.INCLUIRDOCUMENTO</translate> | |
43 | +</button> | |
44 | + | |
45 | +<span class="divider-vertical"></span> | |
39 | 46 | |
40 | - <button type="button" class="btn btn-clear" ng-click="newDocument()"> | |
41 | - <i class="fa fa-book blue"></i> | |
42 | - <translate>ECM.LABEL.INCLUIRDOCUMENTO</translate> | |
47 | +<div class="btn-group dropdown" role="group" dropdown> | |
48 | + <button type="button" class="btn btn-clear" dropdown-toggle> | |
49 | + <i class="fa fa-list"></i> | |
50 | + <translate>ECM.LABEL.ACAODEPROCESSO</translate> | |
51 | + <span class="fa fa-caret-down icon-on-right"></span> | |
43 | 52 | </button> |
44 | 53 | |
45 | - <span class="divider-vertical"></span> | |
46 | - | |
47 | - <div class="btn-group dropdown" role="group" dropdown> | |
48 | - <button type="button" class="btn btn-clear" dropdown-toggle> | |
49 | - <i class="fa fa-list"></i> | |
50 | - <translate>ECM.LABEL.ACAODEPROCESSO</translate> | |
51 | - <span class="fa fa-caret-down icon-on-right"></span> | |
52 | - </button> | |
53 | - | |
54 | - <ul class="dropdown-menu-center dropdown-menu dropdown-caret" role="menu"> | |
55 | - <li><a href="#void" ng-click="editProcessoRelacionado();"><i class="fa fa-link"></i> | |
56 | - <translate>ECM.LABEL.PROCESSORELACIONADOS</translate></a></li> | |
57 | - <li><a href="#void" ng-click='enviarProcesso();'><i class="fa fa-share-square-o">  </i> | |
58 | - <translate>ECM.LABEL.ENVIAR_PROCESSO</translate> </a></li> | |
59 | - <li><a href="#void" ng-click='anexarProcesso();'><i class="fa fa-paperclip">  </i> | |
60 | - <translate>ECM.LABEL.ANEXAR_ESTE_PROCESSO</translate> </a></li> | |
61 | - <li><a href="#void;" ng-click='gerenciarCredenciaisProcesso();'><i class="fa fa-user-plus">  </i> | |
62 | - <translate>ECM.LABEL.GERENCIAR_CREDENCIAIS_ACESSO</translate> </a></li> | |
63 | - <li><a href="javascript: return false;" ng-click='exibirDialogConfirmacaoRemoverCredencial()' ng-if="credencialUsuarioProcesso.id"><i class="fa fa-user-plus">  </i> | |
64 | - <translate>ECM.LABEL.RENUNCIAR_CREDENCIAL</translate> </a></li> | |
65 | - <li><a href="#void" ng-click='classificarDocumentoProceso();'><i class="fa fa fa-eye">  </i> | |
66 | - <translate>ECM.LABEL.VALIDAR_NIVEL_ACESSO</translate> </a></li> | |
67 | - | |
68 | - | |
69 | - <!-- <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.ENVIARCORRESPONDENCIA</translate></a></li> | |
54 | + <ul class="dropdown-menu-center dropdown-menu dropdown-caret" role="menu"> | |
55 | + <li><a href="#void" ng-click="editProcessoRelacionado();"><i class="fa fa-link"></i> <translate>ECM.LABEL.PROCESSORELACIONADOS</translate></a></li> | |
56 | + <li><a href="#void" ng-click='enviarProcesso();'><i class="fa fa-share-square-o">  </i> <translate>ECM.LABEL.ENVIAR_PROCESSO</translate> </a></li> | |
57 | + <li><a href="#void" ng-click='anexarProcesso();'><i class="fa fa-paperclip">  </i> <translate>ECM.LABEL.ANEXAR_ESTE_PROCESSO</translate> </a></li> | |
58 | + <li><a href="#void;" ng-click='gerenciarCredenciaisProcesso();'><i class="fa fa-user-plus">  </i> <translate>ECM.LABEL.GERENCIAR_CREDENCIAIS_ACESSO</translate> </a></li> | |
59 | + <li><a href="javascript: return false;" ng-click='exibirDialogConfirmacaoRemoverCredencial()' ng-if="credencialUsuarioProcesso.id"><i class="fa fa-user-plus">  </i> <translate>ECM.LABEL.RENUNCIAR_CREDENCIAL</translate> | |
60 | + </a></li> | |
61 | + <li><a href="#void" ng-click='classificarDocumentoProceso();'><i class="fa fa fa-eye">  </i> <translate>ECM.LABEL.VALIDAR_NIVEL_ACESSO</translate> </a></li> | |
62 | + | |
63 | + | |
64 | + <!--<li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.ENVIARCORRESPONDENCIA</translate></a></li> | |
70 | 65 | <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.CIENCIA</translate></a></li> |
71 | 66 | <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.DUPLICARPROCESSO</translate></a></li> </a></li> |
72 | 67 | <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.GERENCIARDISPONIBILIZACAOACESSOEXTERNO</translate></a></li> |
73 | 68 | <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.ACOMPANHAMENTOESPECIAL</translate> </a></li> |
74 | 69 | <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.ANEXARPROCESSO</translate> </a></li> |
75 | 70 | <li><a href="#void"><i class="fa fa-file-o"></i> <translate>LABEL.GERARARQUIVOPROCESSO</translate></a></li> --> |
76 | - </ul> | |
77 | - </div> | |
78 | - | |
71 | + </ul> | |
72 | +</div> | |
73 | + | |
79 | 74 | ... | ... |
cit-ecm-web/src/main/webapp/html/gerenciarProcesso/includeDocumentosProcesso.html
1 | 1 | <div class="itemdiv commentdiv" ng-repeat="documento in processo.documentos | orderBy:'-dataCriacao'"> |
2 | 2 | |
3 | - <div class="user"> | |
4 | - <i class="{{documento.icon}}" title="{{documento.anexo.dominioTipoAnexo.descricao}}"></i> | |
3 | + <div class="user"> | |
4 | + <i class="{{documento.icon}}" title="{{documento.anexo.dominioTipoAnexo.descricao}}"></i> | |
5 | + </div> | |
6 | + | |
7 | + <div class="body"> | |
8 | + <div class="text ellipsis" tooltip="{{documento.tipoDocumento.nome}} - {{documento.numero}}"> | |
9 | + <a ng-show='!documento.cancelado' href="#void" ng-click="editDocument(documento, false)">{{documento.tipoDocumento.nome}} - {{documento.numero}}</a> <a ng-show='documento.cancelado' href="#void" | |
10 | + ng-click="getCancelamentoDocumento(documento);"> {{documento.tipoDocumento.nome}} - {{documento.numero}}</a> | |
5 | 11 | </div> |
6 | 12 | |
7 | - <div class="body"> | |
8 | - <div class="text ellipsis" tooltip="{{documento.tipoDocumento.nome}} - {{documento.numero}}"> | |
9 | - <a ng-show='!documento.cancelado' href="#void" ng-click="editDocument(documento, false)">{{documento.tipoDocumento.nome}} - {{documento.numero}}</a> | |
10 | - <a ng-show='documento.cancelado' href="#void" ng-click="getCancelamentoDocumento(documento);"> {{documento.tipoDocumento.nome}} - {{documento.numero}}</a> | |
11 | - </div> | |
12 | - | |
13 | - <div class="time hidden-md"> | |
14 | - <i class="ace-icon fa fa-clock-o"></i> <span class="blue">{{documento.dataCriacao | date: 'dd/MM/yyyy HH:mm:ss'}} </span> | |
15 | - </div> | |
16 | - | |
17 | - <div class="text ellipsis" tooltip="{{documento.assuntoComplementar}}">{{documento.assuntoComplementar}} </div> | |
18 | - | |
19 | - <div class="itemdiv-informacoes" > | |
20 | - <span class="label label-gray" ng-show="documento.sigilo.tipoSigilo.codigo == 0 ">{{documento.sigilo.tipoSigilo.descricao}}</span> | |
21 | - <span class="label label-danger" ng-show="documento.sigilo.tipoSigilo.codigo == 1 ">{{documento.sigilo.tipoSigilo.descricao}}</span> | |
22 | - <span class="label label-black" ng-show="documento.sigilo.tipoSigilo.codigo == 2 ">{{documento.sigilo.tipoSigilo.descricao}}</span> | |
23 | - <span class="label label-warning" ng-show="documento.nivelAcesso.nivelAcesso.codigo == 1">{{documento.nivelAcesso.nivelAcesso.descricao}}</span> | |
24 | - <span class="label label-success" ng-show="documento.nivelAcesso.nivelAcesso.codigo == 2">{{documento.nivelAcesso.nivelAcesso.descricao}}</span> | |
25 | - <span class="label label-info" ng-show="documento.origem">Anexado</span> <span class="label label-info" ng-show="false">Assinado</span> | |
26 | - <span class="label label-success" ng-show="false">Habilitado</span> <span class="label label-warning" ng-show="false">Ciência</span> | |
27 | - <span class="label label-danger" ng-show="documento.cancelado">Cancelado</span> | |
28 | - </div> | |
13 | + <div class="time hidden-md"> | |
14 | + <i class="ace-icon fa fa-clock-o"></i> <span class="blue">{{documento.dataCriacao | date: 'dd/MM/yyyy HH:mm:ss'}} </span> | |
29 | 15 | </div> |
30 | 16 | |
31 | - | |
32 | - <div ng-if = "!isProcessoView" class="tools btn-group dropdown" role="group" dropdown > | |
17 | + <div class="text ellipsis" tooltip="{{documento.assuntoComplementar}}">{{documento.assuntoComplementar}}</div> | |
18 | + | |
19 | + <div class="itemdiv-informacoes"> | |
20 | + <span class="label label-gray" ng-show="documento.sigilo.tipoSigilo.codigo == 0 ">{{documento.sigilo.tipoSigilo.descricao}}</span> <span class="label label-danger" | |
21 | + ng-show="documento.sigilo.tipoSigilo.codigo == 1 ">{{documento.sigilo.tipoSigilo.descricao}}</span> <span class="label label-black" ng-show="documento.sigilo.tipoSigilo.codigo == 2 ">{{documento.sigilo.tipoSigilo.descricao}}</span> | |
22 | + <span class="label label-warning" ng-show="documento.nivelAcesso.nivelAcesso.codigo == 1">{{documento.nivelAcesso.nivelAcesso.descricao}}</span> <span class="label label-success" | |
23 | + ng-show="documento.nivelAcesso.nivelAcesso.codigo == 2">{{documento.nivelAcesso.nivelAcesso.descricao}}</span> <span class="label label-info" ng-show="documento.origem">Anexado</span> <span | |
24 | + class="label label-info" ng-show="false">Assinado</span> <span class="label label-success" ng-show="false">Habilitado</span> <span class="label label-warning" ng-show="false">Ciência</span> <span | |
25 | + class="label label-danger" ng-show="documento.cancelado">Cancelado</span> | |
26 | + </div> | |
27 | + </div> | |
28 | + | |
29 | + | |
30 | + <div ng-if="!isProcessoView" class="tools btn-group dropdown" role="group" dropdown> | |
33 | 31 | <button type="button" class="btn btn-success btn-xs" dropdown-toggle> |
34 | 32 | <translate>LABEL.ACOES</translate> |
35 | 33 | <span class="fa fa-caret-down icon-on-right"></span> |
36 | 34 | </button> |
37 | 35 | |
38 | - <ul class="dropdown-menu-center dropdown-menu dropdown-caret" role="menu"> | |
39 | - <li ng-if='!documento.cancelado'><a href="#void" ng-click="editDocument(documento, true);"><translate>LABEL.EDITAR</translate></a></li> | |
40 | - <li ng-if='!isTramitado || (documento.cancelado && documento.unidade.id === usuarioLogado.unidade.id) '><a href="#void" ng-click="removeDocumento(documento, $index);"><translate>LABEL.REMOVER</translate></a></li> | |
41 | - <li ng-if='isTramitado || (!documento.cancelado && documento.unidade.id === usuarioLogado.unidade.id)'><a href="#void" ng-click='cancelarDocumento(documento)'> <translate>LABEL.CANCELARDOCUMENTO</translate></a></li> | |
42 | - <li ng-if='!documento.cancelado'><a href="#void" ng-click="visualizarVersoes(documento);"> <translate>LABEL.VERSOESDODOCUMENTO</translate></a></li> | |
43 | - <li ng-if='documento.cancelado'><a href="#void" ng-click="getCancelamentoDocumento(documento);"> <translate>LABEL.CANCELAMENTO</translate></a></li> | |
36 | + <ul class="dropdown-menu-center dropdown-menu dropdown-caret" role="menu"> | |
37 | + <li ng-if='!documento.cancelado'><a href="#void" ng-click="editDocument(documento, true);"><translate>LABEL.EDITAR</translate></a></li> | |
38 | + <li ng-if='!isTramitado && (!documento.cancelado && documento.unidade.id === usuarioLogado.unidade.id)'><a href="#void" ng-click="removeDocumento(documento, $index);"><translate>LABEL.REMOVER</translate></a></li> | |
39 | + <li ng-if='isTramitado && (!documento.cancelado && documento.unidade.id === usuarioLogado.unidade.id)'><a href="#void" ng-click='cancelarDocumento(documento)'> <translate>ECM.LABEL.CANCELARDOCUMENTO</translate></a></li> | |
40 | + <li ng-if='!documento.cancelado'><a href="#void" ng-click="visualizarVersoes(documento);"> <translate>ECM.LABEL.VERSOESDODOCUMENTO</translate></a></li> | |
41 | + <li ><a ng-if='documento.cancelado'href="#void" ng-click="getCancelamentoDocumento(documento);"> <translate>ECM.LABEL.JUSTIFICATIVA_CANCELAMENTO</translate></a></li> | |
44 | 42 | </ul> |
43 | + | |
45 | 44 | </div> |
46 | 45 | </div> |
47 | 46 | \ No newline at end of file | ... | ... |
cit-ecm-web/src/main/webapp/html/gerenciarProcessoView/gerenciarProcessoView.html
... | ... | @@ -2,7 +2,7 @@ |
2 | 2 | |
3 | 3 | <div id="viewGerenciarProcesso" class="page-content" ng-controller="GerenciarProcessoViewController"> |
4 | 4 | <div class="bar-buttons-action fixed"> |
5 | - <span class="divider-vertical"></span> | |
5 | + <span class="divider-vertical"></span> | |
6 | 6 | </div> |
7 | 7 | |
8 | 8 | <div id="informacaoProcesso"> |
... | ... | @@ -13,18 +13,18 @@ |
13 | 13 | <div class="widget-box margin-bottom"> |
14 | 14 | <div class="widget-header"> |
15 | 15 | <h2 class="widget-title"> |
16 | - <translate>LABEL.INFORMACAODOPROCESSO</translate> | |
16 | + <translate>ECM.LABEL.INFORMACAODOPROCESSO</translate> | |
17 | 17 | - {{processo.nup}} |
18 | 18 | </h2> |
19 | 19 | |
20 | 20 | <div class="widget-toolbar"> |
21 | - <a href="#void" ng-click="widgetExemploIsCollapsed = !widgetExemploIsCollapsed"> | |
22 | - <i class="fa" ng-class="{'fa-chevron-up': !widgetExemploIsCollapsed, 'fa-chevron-down': widgetExemploIsCollapsed}"></i> | |
21 | + <a href="#void" ng-click="widgetExemploIsCollapsed = !widgetExemploIsCollapsed"> <i class="fa" | |
22 | + ng-class="{'fa-chevron-up': !widgetExemploIsCollapsed, 'fa-chevron-down': widgetExemploIsCollapsed}"></i> | |
23 | 23 | </a> |
24 | 24 | </div> |
25 | - </div> | |
26 | - <div collapse="widgetExemploIsCollapsed" class="widget-body"> | |
27 | - <div ng-include src="'/cit-ecm-web/html/gerenciarProcesso/includeInformacaoProcesso.html'" /> | |
25 | + </div> | |
26 | + <div collapse="widgetExemploIsCollapsed" class="widget-body"> | |
27 | + <div ng-include src="'/cit-ecm-web/html/gerenciarProcesso/includeInformacaoProcesso.html'" /> | |
28 | 28 | </div> |
29 | 29 | </div> |
30 | 30 | </div> |
... | ... | @@ -39,17 +39,19 @@ |
39 | 39 | <div class="widget-box documentos margin-bottom"> |
40 | 40 | <div class="widget-header"> |
41 | 41 | <h2 class="widget-title"> |
42 | - <translate>LABEL.DOCUMENTOS</translate> | |
42 | + <translate>ECM.LABEL.DOCUMENTOS</translate> | |
43 | 43 | </h2> |
44 | - | |
45 | - </div> | |
44 | + | |
45 | + </div> | |
46 | 46 | <div class="widget-body"> |
47 | - | |
48 | - | |
47 | + | |
48 | + | |
49 | 49 | <div class="widget-main clearfix"> |
50 | - | |
51 | - <div id="documentoProcesso"> <div ng-include src="'/cit-ecm-web/html/gerenciarProcesso/includeDocumentosProcesso.html'" /> </div> | |
52 | - | |
50 | + | |
51 | + <div id="documentoProcesso"> | |
52 | + <div ng-include src="'/cit-ecm-web/html/gerenciarProcesso/includeDocumentosProcesso.html'" /> | |
53 | + </div> | |
54 | + | |
53 | 55 | </div> |
54 | 56 | </div> |
55 | 57 | </div> |
... | ... | @@ -57,11 +59,11 @@ |
57 | 59 | </div> |
58 | 60 | |
59 | 61 | <div id="content-container" class="col-md-8"> |
60 | - | |
62 | + | |
61 | 63 | <div ng-include src="'/cit-ecm-web/html/documentoGed/documentoGedView.html'" ng-show="isDocumentoEdit" /> |
62 | 64 | |
63 | - <div ng-include src="'/cit-ecm-web/html/documentoGed/cancelarDocumentoView.html'" ng-show="isCancelarDocumento" /> | |
64 | - | |
65 | + <div ng-include src="'/cit-ecm-web/html/documentoGed/cancelarDocumentoView.html'" ng-show="isCancelarDocumento" /> | |
66 | + | |
65 | 67 | </div> |
66 | 68 | |
67 | 69 | </div> | ... | ... |