-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy paththinger.yaml
27 lines (26 loc) · 996 Bytes
/
thinger.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
---
# A note on optional/required:
# Default value is "optional". If both are present, rgen will error out.
model:
# camel-case this name
name: Thinger
attributes:
# <attribute name>: <space-separated settings>
# -> One of those attributes *must* be a datatype: string/integer/decimal/boolean
# -> 'factory_sequence' (strings only) means the factory setter should be a sequence
name: string unique required factory_sequence
qty: integer optional
weight: decimal
approved: boolean
# Only belongs_to associations are supported right now.
belongs_to:
# Each key is the association name.
# Under that, "model" specifies the associated model.
# ("model" is optional if association name and model name are the same)
# "Properties" can be omitted if defaults are fine with you.
product_line:
properties: required inverse_is_plural
managing_owner:
model: owner
properties: optional inverse_is_plural
manufacturer: