Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Fields from custom table included in Event Calendar View modes: 
User avatar
Member
Member
paul.truman-sunmed.co - 9/25/2012 6:56:24 AM
   
Fields from custom table included in Event Calendar
Hi,
I'm using the Event Booking calendar on my site. It works great and looks good. The only problem I have is that I would like to display an additional field on the Calendar from a Custom Table (that shares a common field of 'EventCode' with the Event Booking document type). Is this possible to do?

User avatar
Certified Developer 8
Certified Developer 8
Jiveabillion - 9/25/2012 7:17:26 AM
   
RE:Fields from custom table included in Event Calendar
There are a few ways to do this. One way would be to create a custom macro method to retrieve the custom table item by passing it the event code, then you will have access to all of the fields of that item in your transformation. You should cache these for performance

Another way would be to use a SQL Query Datasource to query your event data joined on your custom table and use that as the Datasource for your calendar (I haven't done this for the calendar before, but I think it works) this would be much more efficient than the first method I mentioned because it won't make a query for every event being transformed.

I would find some links to help you, but I am on my phone.

User avatar
Kentico Developer
Kentico Developer
kentico_ivanat - 9/25/2012 7:21:24 AM
   
RE:Fields from custom table included in Event Calendar
Hi,

in the transformation which is used in Calendar web part, you can create a custom transformation function. In your custom function you can call custom table API to return correct result. You can use Eval("commonField") to pass parameter to your custom function to be able to select correct record.

Best regards,
Ivana Tomanickova