Class FormFieldService
- Namespace
- Dynamicweb.Forms
- Assembly
- Dynamicweb.Forms.dll
- Inheritance
-
Form
Field Service
- Inherited Members
Methods
Copy(Field, int, bool)
Copies the specified field to a destination form identifier.
Parameters
field
FieldThe field to copy.
destinationFormId
intTo form identifier.
keepFieldName
boolif set to
true
[keep name].
Delete(Field)
Deletes the specified field.
Parameters
field
FieldThe field to delete.
Delete(IEnumerable<int>)
Deletes the fields matching the specified IDs.
Parameters
fieldIds
IEnumerable<int>The IDs of the fields to delete.
Delete(int)
Deletes the field matching the specified ID.
Parameters
fieldId
intThe ID of the field to delete.
GetAll()
Get the all fields.
Returns
GetById(int)
Get a form field by ID.
Parameters
fieldId
intThe ID of the form field.
Returns
GetByIds(IEnumerable<int>)
Get form fields by IDs.
Parameters
fieldIds
IEnumerable<int>The IDs of the form fields.
Returns
GetFormFields(Form)
Get fields for a given form.
Parameters
form
FormThe form.
Returns
GetFormFields(int)
Get fields for the form with the specified ID.
Parameters
formId
intThe ID of the form.
Returns
MoveFieldsUp(int, int)
Moves the fields up.
Parameters
Save(Field)
Saves the specified field.
Parameters
field
FieldThe field to save.
SortDown(Field)
Sorts the field down.
Parameters
field
FieldThe field to sort down.
SortOptions(Field, bool, Func<Option, string>)
Sorts the options of the field by the given method.
Parameters
field
FieldThe field.
descending
boolProvide
true
if sorting should be descending, otherwise it will be sorted ascending.methodDelegate
Func<Option, string>The method selector to indicate what property it should sort by.
SortOptions(int, bool, Func<Option, string>)
Sorts the options of the field by the given method.
Parameters
fieldId
intThe field identifier.
descending
boolProvide
true
if sorting should be descending, otherwise it will be sorted ascending.methodDelegate
Func<Option, string>The method selector to indicate what property it should sort by.
SortUp(Field)
Sorts the field up.
Parameters
field
FieldThe field to sort up.
ToggleActive(int)
Toggles the active.
Parameters
fieldId
intThe field identifier.
ToggleRequired(int)
Toggles the required.
Parameters
fieldId
intThe field identifier.