David, Thanks for your answer. I made the example because it would be easier to understand than the actual application. Using your suggestions, I was able to get the actual data going, but it turns out Timeline can't handle huge datasets.
Demo is at http://www.atletiek.be/timeline but I can't put any more data in than 3 months or it stalls Firefox. IE won't do it at all and Opera also reports errors. Kind regards, Wim David Huynh wrote: > Wim, > > Right now the way to express your data is as follows: > > { > items: [ > { type: "Call", > date: "2007-03-31", > label: "Morning", > id: "call-1", > props: [ "prop-1-1", "prop-1-2" ] > }, > { type: "Prop", > label: "prop-1-1", > country: "US", > avgtime: 3 > }, > { type: "Prop", > label: "prop-1-2", > country: "UK", > avgtime: 8 > }, > > > { type: "Call", > date: "2007-03-31", > label: "Afternoon", > props: [ "prop-2-1", "prop-2-2" ] > }, > { type: "Prop", > label: "prop-2-1", > country: "US", > avgtime: 4 > }, > { type: "Prop", > label: "prop-2-2", > country: "UK", > avgtime: 9 > } > ], > properties: { > props: { > valueType: "item" > } > } > } > > Essentially, the "props" things are first class items themselves. I > added "id" for the calls just in case you have several calls with the > same labels. If you don't have "id", then the label is used as the > item's locally unique id. And if you have several items with the same > label and no explicit id, Exhibit consider them to be the same > item--which isn't what you want. > > Say you are making a lens template for the calls, then to display the > properties of props, do something like this: > > <div ex:role="exhibit-lens"> > label of call: <span ex:content=".label"></span> > <ul ex:content=".props"> > <li>country: <span ex:content=".country"></span>, avgtime: <span > ex:content=".avgtime"></span></li> > </ul> > </div> > > What's happening there is that the HTML inside <ul> is used as a > template for the props of the call. > > If you're making a tabular view, then you can also display the props' > properties like so: > > <div ex:role="exhibit-view" ex:viewClass="Exhibit.TabularView" > ex:columns=".label, .date, .props.country"></div> > > You'll get 3 columns: labels of calls, dates of calls, and countries of > calls' props. > > To filter on country, specify a facet with the expression ".props.country". > > Hope that helps, > > David > > > Wim Godden wrote: > >> Hi, >> >> Is there a way to use an extra level in Exhibit. What I mean is : >> >> >> { >> "items" : [ >> { >> type : "Call", >> "date" : "2007-03-31", >> "label" : "Morning", >> "props" : [ >> { >> "country" : "US", >> "avgtime" : 3 >> ), >> { >> "country" : "UK", >> "avgtime" : 8 >> } >> ] >> }, >> { >> type : "Call", >> "date" : "2007-03-31", >> "label" : "Afternoon", >> "props" : [ >> { >> "country" : "US", >> "avgtime" : 4 >> ), >> { >> "country" : "UK", >> "avgtime" : 9 >> } >> ] >> } >> ] >> } >> >> Is there a way to filter on the country part ? >> I can't seem to even display the contents of 'props' anywhere. >> >> >> Any help much appreciated ! >> >> Kind regards, >> >> Wim >> >> _______________________________________________ >> General mailing list >> [email protected] >> http://simile.mit.edu/mailman/listinfo/general >> >> > > _______________________________________________ > General mailing list > [email protected] > http://simile.mit.edu/mailman/listinfo/general > > > _______________________________________________ General mailing list [email protected] http://simile.mit.edu/mailman/listinfo/general
