Hi,
I'm creating items via code-first, and having some difficulties. My code actually creates the item and I can see it both in the Management Center and in the XML-file. However, the corresponding table in the database is not created until I manually save the item in Management Center.
I can see that when I save it adds the following missing line to the XML-file:
<rule name="" type="Dynamicweb.Content.Items.Activation.ModuleAttachmentRestrictionRule, Dynamicweb" value="Nothing" />
I've tried adding this via the code, but I simply cannot find the attribute - I've looked everywhere at this forum, but I cannot seem to find anything resembling this attribute. So my code looks like this right now:
[Item("Tag", "Tags"),Category("Intranet")]
[AreaRule, StructureRule(StructureContextType.Paragraphs), ParentRule(ParentRestrictionRule.ParentType.RootOfWebsite, ParentRestrictionRule.ParentType.RegularPage)]
[CustomizedURLs]
public class Tag : ItemEntry
{
[Field("Tag name", typeof(Dynamicweb.Content.Items.Editors.TextEditor))]
public string TagName { get; set; }
}
Am I missing something in the list of attributes?
Regards, Peter