Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > Making Custom Tables Contributable View modes: 
User avatar
Certified Developer 12
Certified Developer 12
chetan2309-gmail - 11/17/2013 5:02:54 PM
   
Making Custom Tables Contributable
I was in process of deciding what to use in my project out of Custom tables and Document types.

I have partially concluded that Custom tables would may help solve my purpose. However, I read in one of the blogs that CT are not contributable

"Data can be populated/edited by CMS Editors" - No by default (can be overridden)

So I would like to know how it can be done. Any good example as a reference would help solve my case.

Thanks
Chetan

User avatar
Kentico Consulting
Kentico Consulting
Kentico_RichardS - 11/19/2013 3:48:16 AM
   
RE:Making Custom Tables Contributable
Hi Chetan,

Thank you for your message.

If I understand your issue correctly you want to add a records to your custom table on the front page, is that correct?

If so you are right that be default we dont have webparts which would allow such thing, but you can develop your own which could.

So what you need to do is develop a webpart (some kind of form for your custom table) as per http://devnet.kentico.com/docs/devguide/developing_web_parts.htm

In code behind of this webpart you need to need to get the CustomTableClassName - you can hardcode it to match your own custom table - easiest way.

Next you can insert a data in your custom table based on the http://devnet.kentico.com/docs/devguide/custom_tables_api_examples_managing_custom_table_data.htm. There is an example of how exactly can you insert new record in given custom table. In your goal you simply adjust your fields and custo table class name.

This should basically be it :-)

Let me know if you have further questions.

Kind regards,
Richard Sustek