bookingInfo.CreditCardList = airUserCreditCardList
.Distinct()
.OrderBy(o => o.Text)
.ToList();
I am trying to order the list based on the value inside the Text
property.Is there a way I can order the list only if the Object's property Text has value "Primary".
My list looks like this
Text="abc",Code="123"----0th index
Text ="Select",Code="1233"--1st Index
Text="Primary",Code="0000"--2ndIndex```
But i want it to look like this only if the Primary card is present in the list
```
Text="Primary",Code="0000"--0th Index
Text ="Select",Code="1233"--1st Index
Text ="abc",Code="123"--2nd Index