[TYPO3-calendar] Event view in list

Mario Matzulla mario at matzullas.de
Wed Jun 15 21:05:50 CEST 2011


Hi Michael,

Am 15.06.11 03:04, schrieb Michael McManus:
> Hi Everybody,
>
> I've searched through the list and found a few threads that address
> issues similar to the one I'm encountering, but there's a particular
> aspect of what I'm doing that I haven't seen discussed. Apologies in
> advance if this has in fact already been mentioned.
>
> Similarly to Sebastian's question from a few days ago, I'm trying to
> render an event and list view on the same page. I want to render the
> event view for the top-most item in the list.
>
> Just like Sebastian, "i have got a cal plugin on the left showing the
> event-list and another plugin on the right. The right one has got the
> allowed views list and singleEvent, so i can show the upcomingevent on
> page load (using the List) and when i click on an event(link) in the
> list(left plugin) the page reloads and the choosen event shows up in my
> right plugin."
>
> My question is, what's the best way to use the event (single) template
> for the upcoming event that shows on page load?
>
> My current solution is to make a few alternate templates and then
> override the typoscript used by the one list view, like so:
>
> view.list.listTemplate = fileadmin/ext/cal/single_and_list-list.html
> view.event.eventModelTemplate =
> fileadmin/ext/cal/single_and_list-model.html
>
> view.list.event.description < .view.event.event.description
> view.list.event.enddate < .view.event.event.enddate
> view.list.event.startdate < .view.event.event.startdate
> view.list.event.endtime < .view.event.event.endtime
> view.list.event.location < .view.event.event.location
>
> I'm thinking that there's gotta be a better/more efficient way to do
> this, no?
>
> Again, sorry if I'm missing something obvious :) Working on a really
> tight deadline.
>
> Alternatively, if there's a way to just use the event view to render the
> next upcoming event, advice on that approach would also be extremely
> appreciated.

What about a list view with max = 1 and starttime = now ?
BTW: you can adjust each plugin through its own typoscript field in the 
flexform. So you could have a different template for the next upcoming 
event, which could look like the single event ;)

Regards,
Mario
>
> All the Best,
> Michael



More information about the TYPO3-project-calendar mailing list