<div ng-controller="conferenciasController">

    <div class="modal-header">
        <h4>Falhas encontradas</h4>
        <nav class="navbar navbar-default" role="navigation">
            <div class="container-fluid">
                <form class="navbar-form navbar-right" role="navigation">
                    <div class="form-group">
                        <input type="text" class="form-control" placeholder="Procurar..." ng-model="procurar" ng-change="">
                    </div>

                    <button popover-placement="top"
                            popover-trigger="mouseenter"
                            data-popover="Remover"
                            ng-click="deleteErrosConferencias(selectedConferenciaErro.Id,selected.item.lst)"
                            type="button"
                            ng-show="selected.item.lst.length>0"
                            ng-disabled=""
                            class="btn btn-warning">
                        <span class="glyphicon glyphicon-remove"></span>
                    </button>
                    
                    
                </form>
            </div>
        </nav>

    </div>

    <div class="modal-body">
        <div class="table-responsive" style="border: 1px solid #DDD;  overflow:auto; min-height:300px; height:300px">

            <table class="table table-striped table-hover">
                <thead>
                    <tr>
                        <th style="width:80px">Nº Inv</th>
                        <th>Observações</th>
                    </tr>

                </thead>

                <tbody>
                    <tr ng-repeat="item in selected.item.lst | filter:procurar"
                        class="apontar"
                        ng-class="{info:selectedConferenciaErro.Id==item.Id}"
                        ng-click="selConf(item)">
                        <td>{{item.NumInventario}}</td>
                        <td>{{item.ErrosObs}}</td>
                    </tr>
                </tbody>
            </table>

        </div>        
    </div>
    <div class="modal-footer">
        <button class="btn btn-primary"
                ng-click="corrigirLocal(selectedConferenciaErro,selected.item.lst)"
                ng-disabled="!(selected.item.lst.length>0 && selectedConferenciaErro.FK_Inventario>0) || emExecucao==true">
            Mover para este local
        </button>
        <button class="btn btn-warning" ng-click="ok()">Fechar</button>
    </div>

</div>
