After retrieving a JSON file using $http()
, the structure looks something like this:
[ {
"sno": "3",
"eventname": "hockey",
"event-type": "sports",
"A-team": "mme",
"B-team": "eee",
"Gender": "male",
"time": "2017-11-24 00:00:00",
"isresult": "0",
"result": "",
"match-type": "semi",
"venue": "downs"
}]
I am trying to figure out how to display item.result
as N/A when item.isresult==0
and as a string when item.isresult==1
. Any suggestions on how to achieve this?