Foren

How to programmatically add message board to an organization site

Jianbin LIN, geändert vor 12 Jahren.

How to programmatically add message board to an organization site

New Member Beiträge: 10 Beitrittsdatum: 24.12.11 Neueste Beiträge
Hi everyone,

I ve created the an organization and add sites to it like this.



Organization organization = OrganizationLocalServiceUtil
				.addOrganization(userId, parentOrganizationId, label, type,
						recursable, regionId, countryId, statusId, comments,
						true, serviceContext);

		Layout layout = addLayout(organization.getGroup(), "Home", false,
				"/home", "2_columns_ii");
		Layout layout2 = addLayout(organization.getGroup(), "Home", true,
				"/home", "2_columns_ii");



Now I want to add a message board to this site.
Does any one know how to do it or show me an example code ?

Thanks.

Jianbin
thumbnail
Olaf Kock, geändert vor 12 Jahren.

RE: How to programmatically add message board to an organization site

Liferay Legend Beiträge: 6403 Beitrittsdatum: 23.09.08 Neueste Beiträge
The sevencogs sample site (installed out-of-the-box with CE installations) has a forum - you should inspect the source code for sevencogs-hook. This hook generates all the pages through the API and provides a great documentation resource for this kind of jobs.