Join us this Friday for AI in Action at the Virtual Happy Hour! This free virtual event is open to all—enroll now on Academy and don’t miss out.

 

Property of list object in page is not hidden even when attributed as [Ignore].

Vote:
 

Property of list object in page is not hidden even when attributed as [Ignore]. In the code below, Name is visible in editor as non-editable field.

 [PropertyDefinitionTypePlugIn]
public class StudentProperty : PropertyListBase<TestimonialList>
{

[Ignore]
public virtual XhtmlString Name { getset; }


}
public class Student
{
}

public class StudentBlock : BlockData
{
[EditorDescriptor(EditorDescriptorType = typeof(CollectionEditorDescriptor<Student>))]
public virtual IList<Student> Students{ get; set; }
}

#205251
Jul 03, 2019 8:19
Vote:
 

Hi,

Unless there's a specific reason why you need to use [Ignore], I'd use [ScaffoldColumn(false)] to hide a field. I've used that on properties of list item models without issue.

#205253
Jul 03, 2019 10:20
Vote:
 

 [ScaffoldColumn(false)] also does not work for me. It is not shown in the editor where we enter the values but it is shown in the grid after entering the value.

#205279
Edited, Jul 04, 2019 4:57
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.