-
Notifications
You must be signed in to change notification settings - Fork 13
create:field:relationship
Create a Relationships field.
$ eecli create:field:relationship <label> <short_name> <field_group>
The label of the field.
The short name of the field.
The ID or name of the field group.
Instructions for authors on how or what to enter into this field when submitting an entry.
Make this field required.
Make this field searchable.
Make this field hidden.
Set this field's order.
ID or name of channel(s) to relate (Leave blank to allow all). You may use this option more than once to provide multiple values.
Show expired entries.
Show future entries.
ID of category(s) to show (Leave blank to allow all). You may use this option more than once to provide multiple values.
ID of author(s) to show (Leave blank to allow all). You may use this option more than once to provide multiple values.
ID of authored by member group(s) to show (Leave blank to allow all). You may use this option more than once to provide multiple values.
Stasus(es) to show (Leave blank to allow all). You may use this option more than once to provide multiple values.
Limit. Default: 100.
title or entry_date. Default: title.
asc or desc. Default: asc.
Allow multiple relationships?
Create a Relationships field in field group 1
$ eecli create:field:relationship "Your Field Name" your_field_name 1
Create a Relationships field with multiple channels
$ eecli create:field:relationship --channel=1 --channel=blogs "Your Field Name" your_field_name 1
Create a Relationships field with multiple statuses
$ eecli create:field:relationship --status=closed --status=open "Your Field Name" your_field_name 1
Create a Relationships field with multiple selection
$ eecli create:field:relationship --multiple "Your Field Name" your_field_name 1
- create:category
- create:category_group
- create:channel
- create:field:<fieldtype>
- create:field_group
- create:global_variable
- create:member
- create:member_group
- create:snippet
- create:status
- create:status_group
- create:template
- create:template_group
- create:upload_pref