I have problem regarding the if else condition within the listview in the nativescript (js and xml).
I currently want to make the listview highlighted when the actual date already behind the plan date. in other word, want to indicate the listview as late job so that people are aware on it.
all the late job has the value of 1 which I want to use it to differentiate the highlight.
<lv:RadListView.listViewLayout>
<lv:ListViewLinearLayout scrollDirection="Vertical"/>
</lv:RadListView.listViewLayout>
<lv:RadListView.itemTemplate>
<StackLayout class="ListStackOuter" tap="onJobListTap">
<GridLayout class="ListGrid" columns="80, *, 30" rows="auto,auto" >
<Label id="lblJobId" class="ListLabelMediumBold" text="" row="0" col="0" textWrap="true" colSpan="2"/>
<Label id="lblNext" class="ListLabelNext" text=">" row="0" col="2"/>
<Label id="lblJobDesc" class="ListLabelSmall" text="" row="1" col="0" colSpan="3"/>
<Label id="lblJobLate" class="ListLabelSmall" text="" row="1" col="2" colSpan="3"/>
</GridLayout>
</StackLayout>
</lv:RadListView.itemTemplate>
</lv:RadListView>
</ScrollView>
I expect all the job with late_job status = 1 will be in red colour. while others will remain normal.
Aucun commentaire:
Enregistrer un commentaire