2017-08-15 05:30:59 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableTextField:
|
|
|
|
basic-text:
|
2019-01-28 05:28:55 +01:00
|
|
|
Name: basic_text_name
|
2017-08-15 05:30:59 +02:00
|
|
|
Title: Basic Text Field
|
|
|
|
|
|
|
|
basic-text-2:
|
2020-01-10 05:36:04 +01:00
|
|
|
Name: basic_text_name_2
|
2017-08-15 05:30:59 +02:00
|
|
|
Title: Basic Text Field
|
|
|
|
|
|
|
|
required-text:
|
|
|
|
Name: required-text-field
|
|
|
|
Title: Required Text Field
|
|
|
|
CustomErrorMessage: Custom Error Message
|
|
|
|
Required: true
|
|
|
|
|
2017-04-28 00:22:15 +02:00
|
|
|
irdNumberField:
|
|
|
|
Name: IRDNumber
|
|
|
|
Title: "Enter your IRD Number"
|
2017-08-15 05:30:59 +02:00
|
|
|
|
2017-04-28 00:22:15 +02:00
|
|
|
countryTextField:
|
|
|
|
Name: CountryTextSelection
|
|
|
|
Title: "Enter your country (2 digit prefix)"
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
ShowOnLoad: false
|
2017-08-15 05:30:59 +02:00
|
|
|
|
2020-01-10 05:36:04 +01:00
|
|
|
# No rule
|
|
|
|
alwaysVisible:
|
|
|
|
Name: AlwaysVisible
|
|
|
|
Title: "This field is always visible"
|
|
|
|
ShowOnLoad: true
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
|
|
|
|
alwaysVisibleOr:
|
|
|
|
Name: AlwaysVisibleOr
|
|
|
|
Title: "This field is always visible"
|
|
|
|
ShowOnLoad: true
|
|
|
|
DisplayRulesConjunction: Or
|
|
|
|
|
|
|
|
neverVisible:
|
|
|
|
Name: NeverVisible
|
|
|
|
Title: "This field is never visible"
|
|
|
|
ShowOnLoad: false
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
|
|
|
|
neverVisibleOr:
|
|
|
|
Name: NeverVisibleOr
|
|
|
|
Title: "This field is never visible"
|
|
|
|
ShowOnLoad: false
|
|
|
|
DisplayRulesConjunction: Or
|
|
|
|
|
|
|
|
# Single rule
|
|
|
|
|
|
|
|
singleDisplayRule:
|
|
|
|
Name: SingleDisplayRule
|
|
|
|
Title: "This field will be displayed if the display rule is tripped"
|
|
|
|
ShowOnLoad: false
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
|
|
|
|
singleDisplayRuleOr:
|
|
|
|
Name: SingleDisplayRuleOr
|
|
|
|
Title: "This field will be displayed if the display rule is tripped"
|
|
|
|
ShowOnLoad: false
|
|
|
|
DisplayRulesConjunction: Or
|
|
|
|
|
|
|
|
singleHiddingRule:
|
|
|
|
Name: SingleHiddingRule
|
|
|
|
Title: "This field will be hidden if the display rule is tripped"
|
|
|
|
ShowOnLoad: true
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
|
|
|
|
singleHiddingRuleOr:
|
|
|
|
Name: SingleHiddingRuleOr
|
|
|
|
Title: "This field will be hidden if the display rule is tripped"
|
|
|
|
ShowOnLoad: true
|
|
|
|
DisplayRulesConjunction: Or
|
|
|
|
|
|
|
|
# Multi rule
|
|
|
|
multiDisplayRule:
|
|
|
|
Name: MultiDisplayRule
|
|
|
|
Title: "This field will be displayed if displayed if all the rule are met"
|
|
|
|
ShowOnLoad: false
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
|
|
|
|
multiDisplayRuleOr:
|
|
|
|
Name: MultiDisplayRuleOr
|
|
|
|
Title: "This field will be displayed if at least one rule is met"
|
|
|
|
ShowOnLoad: false
|
|
|
|
DisplayRulesConjunction: Or
|
|
|
|
|
|
|
|
multiHiddingRule:
|
|
|
|
Name: MultiHiddingRule
|
|
|
|
Title: "This field will be hidden if all the rule are met"
|
|
|
|
ShowOnLoad: true
|
|
|
|
DisplayRulesConjunction: And
|
|
|
|
|
|
|
|
multiHiddingRuleOr:
|
|
|
|
Name: MultiHiddingRuleOr
|
|
|
|
Title: "This field will be hidden if one rule is met"
|
|
|
|
ShowOnLoad: true
|
|
|
|
DisplayRulesConjunction: Or
|
|
|
|
|
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableCustomRule:
|
2017-04-28 00:22:15 +02:00
|
|
|
rule1:
|
|
|
|
Display: Show
|
|
|
|
ConditionOption: HasValue
|
|
|
|
FieldValue: NZ
|
2017-08-15 05:30:59 +02:00
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.countryTextField
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.irdNumberField
|
2015-07-24 04:37:48 +02:00
|
|
|
rule-1:
|
|
|
|
Display: Hide
|
|
|
|
ConditionOption: HasValue
|
|
|
|
FieldValue: 6
|
2017-08-15 05:30:59 +02:00
|
|
|
|
2020-01-10 05:36:04 +01:00
|
|
|
# Single rules
|
|
|
|
ruleSingleDisplay:
|
|
|
|
Display: Show
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.singleDisplayRule
|
|
|
|
ruleSingleDisplayOr:
|
|
|
|
Display: Show
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.singleDisplayRuleOr
|
|
|
|
ruleSingleHidding:
|
|
|
|
Display: Show
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.singleHiddingRule
|
|
|
|
ruleSingleHiddingOr:
|
|
|
|
Display: Show
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.singleHiddingRuleOr
|
|
|
|
|
|
|
|
# Multi rules
|
|
|
|
ruleMultiDisplay1:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiDisplayRule
|
|
|
|
ruleMultiDisplay2:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text-2
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiDisplayRule
|
|
|
|
|
|
|
|
ruleMultiDisplayOr1:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiDisplayRuleOr
|
|
|
|
ruleMultiDisplayOr2:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text-2
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiDisplayRuleOr
|
|
|
|
|
|
|
|
|
|
|
|
ruleMultiHidding1:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiHiddingRule
|
|
|
|
ruleMultiHidding2:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text-2
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiHiddingRule
|
|
|
|
|
|
|
|
ruleMultiHiddingOr1:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiHiddingRuleOr
|
|
|
|
ruleMultiHiddingOr2:
|
|
|
|
ConditionOption: IsNotBlank
|
|
|
|
ConditionField: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text-2
|
|
|
|
Parent: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.multiHiddingRuleOr
|
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableOption:
|
2015-07-15 23:23:43 +02:00
|
|
|
option-1:
|
|
|
|
Name: Option1
|
|
|
|
Title: Option 1
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: Option 1
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
option-2:
|
|
|
|
Name: Option2
|
|
|
|
Title: Option 2
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: Option 2
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
department-1:
|
|
|
|
Name: dept1
|
|
|
|
Title: sales@example.com
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: sales@example.com
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
department-2:
|
|
|
|
Name: dept2
|
|
|
|
Title: accounts@example.com
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: accounts@example.com
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
option-3:
|
|
|
|
Name: Option3
|
|
|
|
Title: Option 3
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: Option 3
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
option-4:
|
|
|
|
Name: Option4
|
|
|
|
Title: Option 4
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: Option 4
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
option-5:
|
|
|
|
Name: Option5
|
|
|
|
Title: Option 5
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: Option 5
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
option-6:
|
|
|
|
Name: Option6
|
|
|
|
Title: Option 6
|
2016-04-22 05:44:12 +02:00
|
|
|
Value: Option 6
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\Recipient\EmailRecipient:
|
2015-07-15 23:23:43 +02:00
|
|
|
recipient-1:
|
|
|
|
EmailAddress: test@example.com
|
|
|
|
EmailSubject: Email Subject
|
|
|
|
EmailFrom: no-reply@example.com
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
no-html:
|
|
|
|
EmailAddress: nohtml@example.com
|
|
|
|
EmailSubject: Email Subject
|
|
|
|
EmailFrom: no-reply@example.com
|
|
|
|
SendPlain: true
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
no-data:
|
|
|
|
EmailAddress: nodata@example.com
|
|
|
|
EmailSubject: Email Subject
|
2016-04-22 05:44:12 +02:00
|
|
|
EmailFrom: no-reply@example.com
|
2015-07-15 23:23:43 +02:00
|
|
|
HideFormData: true
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableDropdown:
|
2015-07-15 23:23:43 +02:00
|
|
|
basic-dropdown:
|
|
|
|
Name: basic-dropdown
|
|
|
|
Title: Basic Dropdown Field
|
2017-08-16 03:51:15 +02:00
|
|
|
Options:
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.option-1
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.option-2
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
department-dropdown:
|
|
|
|
Name: department
|
|
|
|
Title: Department
|
2017-08-16 03:51:15 +02:00
|
|
|
Options:
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.department-1
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.department-2
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableCheckbox:
|
2015-07-15 23:23:43 +02:00
|
|
|
checkbox-1:
|
|
|
|
Name: checkbox-1
|
|
|
|
Title: Checkbox 1
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
checkbox-2:
|
|
|
|
Name: checkbox-1
|
|
|
|
Title: Checkbox 1
|
2015-07-24 04:37:48 +02:00
|
|
|
|
|
|
|
checkbox-with-rule:
|
|
|
|
Name: checkbox-with-rule
|
|
|
|
Title: Checkbox with rule
|
2017-08-11 02:20:12 +02:00
|
|
|
DisplayRules: =>SilverStripe\UserForms\Model\EditableCustomRule.rule-1
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableCheckboxGroupField:
|
2015-07-15 23:23:43 +02:00
|
|
|
checkbox-group:
|
|
|
|
Name: check-box-group
|
|
|
|
Title: Check box group
|
2017-08-16 03:51:15 +02:00
|
|
|
Options:
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.option-3
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.option-4
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableEmailField:
|
2015-07-15 23:23:43 +02:00
|
|
|
email-field:
|
|
|
|
Name: email-field
|
|
|
|
Title: Email
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableRadioField:
|
2015-07-15 23:23:43 +02:00
|
|
|
radio-field:
|
|
|
|
Name: radio-option
|
|
|
|
Title: Radio Option
|
2017-08-16 03:51:15 +02:00
|
|
|
Options:
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.option-5
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableOption.option-6
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\EditableFormField\EditableFileField:
|
2015-07-15 23:23:43 +02:00
|
|
|
file-field:
|
|
|
|
Name: file-uploader
|
|
|
|
Title: Set file
|
2013-12-20 02:23:13 +01:00
|
|
|
|
2017-08-11 02:20:12 +02:00
|
|
|
SilverStripe\UserForms\Model\UserDefinedForm:
|
2015-07-15 23:23:43 +02:00
|
|
|
basic-form-page:
|
|
|
|
Title: User Defined Form
|
2017-08-11 02:20:12 +02:00
|
|
|
Fields: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text
|
2017-08-16 03:51:15 +02:00
|
|
|
EmailRecipients:
|
|
|
|
- =>SilverStripe\UserForms\Model\Recipient\EmailRecipient.recipient-1
|
|
|
|
- =>SilverStripe\UserForms\Model\Recipient\EmailRecipient.no-html
|
|
|
|
- =>SilverStripe\UserForms\Model\Recipient\EmailRecipient.no-data
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
form-with-reset-and-custom-action:
|
|
|
|
Title: Form with Reset Action
|
|
|
|
SubmitButtonText: Custom Button
|
|
|
|
ShowClearButton: true
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
validation-form:
|
|
|
|
Title: Validation Form
|
2017-08-11 02:20:12 +02:00
|
|
|
Fields: =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.required-text
|
2015-07-24 04:37:48 +02:00
|
|
|
|
2015-07-15 23:23:43 +02:00
|
|
|
custom-rules-form:
|
|
|
|
Title: Custom Rules Form
|
2017-08-16 03:51:15 +02:00
|
|
|
Fields:
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableCheckbox.checkbox-with-rule
|
|
|
|
- =>SilverStripe\UserForms\Model\EditableFormField\EditableTextField.basic-text-2
|
2015-07-15 23:23:43 +02:00
|
|
|
empty-form:
|
2017-08-11 02:20:12 +02:00
|
|
|
Title: Empty Form
|