Created
October 28, 2014 12:17
-
-
Save kgiszewski/941c0cc6f42087efd0ac to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@using Newtonsoft.Json; | |
@using Archetype.Models; | |
var myArchetype = JsonConvert.DeserializeObject<ArchetypeModel>(luceneResult.Fields[field]);//this has to be pure Archetype JSON | |
var firstFieldset = myArchetype.Fieldsets.FirstOrDefault();//assuming it's always one fieldset or less | |
if (firstFieldset != null) | |
{ | |
<div> | |
firstFieldset.GetValue("somePropertyOfArchetype"); | |
</div> | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment