Quantcast
Channel: C1 CMS Foundation - Open Source on .NET
Viewing all articles
Browse latest Browse all 2540

New Post: DataRefrence Data In Razor

$
0
0
I Have three Global Data Type
Tour
Hotel
Airline

I have Created A Razor Function To Display Tour With Relevant Hotel And Airline Information
But I Cant Get Airline and Hotel Data In My Function Here Is the Code :
@foreach (var Tour in Data.Get<Countries.Tour>())
{
     @Tour.Airline.Name 
    <img src='~/media(@Tour.Thumb)'  />
}
@Tour.Airline.Name is not working
I cant save the function
neither @Tour.Airline which only output the airline Guid not the airline name .

so what do you recommend ? using xslt function ? or creating helper function to pass airline Guid and get the airlone data back which I think make the system a bit complex.

thanks already for help and suggestions.

Viewing all articles
Browse latest Browse all 2540

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>