Commit 23ed04dadd561f0f5d688587241c77a10c0906db
1 parent
03da991f
Exists in
master
Redmine #5043 Tela visualizar atendimento
Showing
4 changed files
with
11 additions
and
3 deletions
Show diff stats
cit-almoxarifado-api/src/main/java/br/com/centralit/api/service/impl/RequisicaoConsumoServiceImpl.java
| @@ -523,7 +523,9 @@ public class RequisicaoConsumoServiceImpl extends GenericServiceImpl<RequisicaoC | @@ -523,7 +523,9 @@ public class RequisicaoConsumoServiceImpl extends GenericServiceImpl<RequisicaoC | ||
| 523 | @Override | 523 | @Override |
| 524 | public List<RequisicaoConsumo> findRequisicoesParaAtendimento(AtendimentoVH atendimentoVH) { | 524 | public List<RequisicaoConsumo> findRequisicoesParaAtendimento(AtendimentoVH atendimentoVH) { |
| 525 | List<RequisicaoConsumo> requisicoes = this.requisicaoConsumoDao.findRequisicoesParaAtendimento(atendimentoVH); | 525 | List<RequisicaoConsumo> requisicoes = this.requisicaoConsumoDao.findRequisicoesParaAtendimento(atendimentoVH); |
| 526 | - this.atualizarStatusAtendimento(requisicoes); | 526 | + if(atendimentoVH.isBloquearAtendimento()){ |
| 527 | + this.atualizarStatusAtendimento(requisicoes); | ||
| 528 | + } | ||
| 527 | return requisicoes; | 529 | return requisicoes; |
| 528 | } | 530 | } |
| 529 | 531 |
cit-almoxarifado-web/src/main/webapp/assets/js/angular/custom/controller/AtendimentoRequisicaoConsumoController.js
| @@ -297,7 +297,7 @@ citApp.controller( 'AtendimentoRequisicaoConsumoController', | @@ -297,7 +297,7 @@ citApp.controller( 'AtendimentoRequisicaoConsumoController', | ||
| 297 | $scope.idsRequisicoesSelecionados = atendimentoVH.idsRequisicao; | 297 | $scope.idsRequisicoesSelecionados = atendimentoVH.idsRequisicao; |
| 298 | 298 | ||
| 299 | if ($scope.idsRequisicoesSelecionados && $scope.requisicoesSelecionadas && $scope.idsRequisicoesSelecionados.length > 0) { | 299 | if ($scope.idsRequisicoesSelecionados && $scope.requisicoesSelecionadas && $scope.idsRequisicoesSelecionados.length > 0) { |
| 300 | - | 300 | + atendimentoVH.bloquearAtendimento = $scope.edit; |
| 301 | iniciarAtendimentoRequisicoes(atendimentoVH); | 301 | iniciarAtendimentoRequisicoes(atendimentoVH); |
| 302 | } else { | 302 | } else { |
| 303 | $scope.showAlert("warning", $translate.instant('MSG.NENHUM_ITEM_SELECIONADO')); | 303 | $scope.showAlert("warning", $translate.instant('MSG.NENHUM_ITEM_SELECIONADO')); |
cit-almoxarifado-web/src/main/webapp/assets/js/angular/custom/controller/AtendimentoRequisicaoConsumoListController.js
| @@ -221,6 +221,7 @@ citApp.controller('AtendimentoRequisicaoConsumoListController', ['$scope', 'Aten | @@ -221,6 +221,7 @@ citApp.controller('AtendimentoRequisicaoConsumoListController', ['$scope', 'Aten | ||
| 221 | }else{ | 221 | }else{ |
| 222 | permiteExcluir = false; | 222 | permiteExcluir = false; |
| 223 | $scope.showAlert('warning', $translate.instant('ALMOXARIFADO.MSG.EXCLUIR_ATENDIMENTO_SOMENTE_ATENDIMENTO_PARCIAL_FINALIZADA')); | 223 | $scope.showAlert('warning', $translate.instant('ALMOXARIFADO.MSG.EXCLUIR_ATENDIMENTO_SOMENTE_ATENDIMENTO_PARCIAL_FINALIZADA')); |
| 224 | + return; | ||
| 224 | } | 225 | } |
| 225 | }); | 226 | }); |
| 226 | 227 |
cit-almoxarifado-web/src/main/webapp/html/atendimentoRequisicaoConsumo/atendimentoRequisicaoConsumoEdit.html
| @@ -16,10 +16,15 @@ | @@ -16,10 +16,15 @@ | ||
| 16 | </li> | 16 | </li> |
| 17 | </ul> | 17 | </ul> |
| 18 | </div> | 18 | </div> |
| 19 | - <button class="btn btn-clear" ng-click="$showPageSearchWorkspace(workspace); atualizaPaginaPesquisa();"> | 19 | + <button ng-show="edit" class="btn btn-clear" ng-click="$showPageSearchWorkspace(workspace); atualizaPaginaPesquisa();"> |
| 20 | <i class="fa fa-reply"></i> | 20 | <i class="fa fa-reply"></i> |
| 21 | <translate>ALMOXARIFADO.LABEL.CANCELAR_ATENDIMENTO_INICIADO</translate> | 21 | <translate>ALMOXARIFADO.LABEL.CANCELAR_ATENDIMENTO_INICIADO</translate> |
| 22 | </button> | 22 | </button> |
| 23 | + <button ng-show="!edit" class="btn btn-clear" ng-click="$showPageSearchWorkspace(workspace); atualizaPaginaPesquisa();"> | ||
| 24 | + <i class="fa fa-search"></i> | ||
| 25 | + <translate>LABEL.PESQUISAR</translate> | ||
| 26 | + </button> | ||
| 27 | + | ||
| 23 | </div><!-- .col --> | 28 | </div><!-- .col --> |
| 24 | <div class="col-sm-4 text-right"> | 29 | <div class="col-sm-4 text-right"> |
| 25 | <favorito /> | 30 | <favorito /> |