I have installed the News package on a new site running v4.1. I am needing to customize the package a bit.
I have everything done except I need to know how to add the correct widget element to the NewsItem.xml file. I have two additional fields I need to add to the NewsItems.xml
I have everything done except I need to know how to add the correct widget element to the NewsItem.xml file. I have two additional fields I need to add to the NewsItems.xml
- I need to add a <DataReferenceSelector /> to select a MediaFolder, the DataFolder field name is GallerFolder
-
I need to add a <KeySelector /> to select an MediaImage, the DataFolder field name is TeaserImage
<cms:formdefinition xmlns:cms="http://www.composite.net/ns/management/bindingforms/1.0" xmlns="http://www.composite.net/ns/management/bindingforms/std.ui.controls.lib/1.0" xmlns:f="http://www.composite.net/ns/management/bindingforms/std.function.lib/1.0">
<cms:bindings>
<cms:binding name="Title" type="System.String" optional="true" />
<cms:binding name="Date" type="System.DateTime" optional="true" />
<cms:binding name="Teaser" type="System.String" optional="true" />
<cms:binding name="YoutubeVideo" type="System.String" optional="true" />
<cms:binding name="Description" type="System.String" optional="true" />
<cms:binding name="TitleUrl" type="System.String" optional="true" />
</cms:bindings>
<cms:layout>
<cms:layout.label>
<cms:read source="Title" />
</cms:layout.label>
<TabPanels>
<PlaceHolder Label="Settings">
<FieldGroup>
<TextBox Label="Title" Help="The title of the news item">
<TextBox.Text>
<cms:bind source="Title" />
</TextBox.Text>
</TextBox>
<DateTimeSelector Label="Date" Help="The date of the news item">
<DateTimeSelector.Date>
<cms:bind source="Date" />
</DateTimeSelector.Date>
</DateTimeSelector>
<TextArea Label="Teaser" Help="The short description of the news item">
<TextArea.Text>
<cms:bind source="Teaser" />
</TextArea.Text>
</TextArea>
<TextBox Label="Youtube Video" Help="Insert Youtube Video">
<TextBox.Text>
<cms:bind source="YoutubeVideo" />
</TextBox.Text>
</TextBox>
<DataReferenceSelector Label="Gallery Folder" Help="The date of the news item">
<DataReferenceSelector>
<cms:bind source="GalleryFolder" />
</DataReferenceSelector>
</DataReferenceSelector>
</FieldGroup>
</PlaceHolder>
<XhtmlEditor Label="News Story" Help="News Story" ClassConfigurationName="common">
<XhtmlEditor.Xhtml>
<cms:bind source="Description" />
</XhtmlEditor.Xhtml>
</XhtmlEditor>
</TabPanels>
</cms:layout>
</cms:formdefinition>