doubts with json

-2

I have a json, in my form I have a "Next" and "Previous" button, I need to create a code that shows the next one or the previous one, as it clicks the buttons, I am using angular, someone could give a hint how could this code be?

json

[{
    "Type": "Debito",
    "Date": "01/11/2016",
    "TransactionValue": 371.6,
    "Id": "388354",
    "Description": "ENVIO TEV",
    "Checksum": 388354,
    "lancado": "Não"
}, {
    "Type": "Debito",
    "Date": "01/11/2016",
    "TransactionValue": 148.0,
    "Id": "389749",
    "Description": "ENVIO TEV",
    "Checksum": 389749,
    "lancado": "Não"
}, {
    "Type": "Debito",
    "Date": "04/11 /2016 ",
    "TransactionValue ": 508.2,
    "Id ": "33531 ",
    "Description ": "PAG BOLETO ",
    "Checksum ": "33531",
    "lancado ": "Não "
}]

I could not adjust json aki, aki has a picture

    
asked by anonymous 11.11.2016 / 20:37

1 answer

0

No controller vc arrow atual = 0

Assuming your list is in a variable called registros

<div class="local_exibicao_dados">{{registros[atual]}}</div>


<a ng-click="atual--" ng-show="atual > 0">Anterior</a>
{{atual}}
<a ng-click="atual++" ng-show="atual < registros.length">Próximo</a>
    
11.11.2016 / 21:24