File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,13 +5,13 @@ import "encoding/json"
55// Config is the configuration for the Action
66type Config struct {
77 //inline action
8- Ref string `json:"ref"`
9- Type string `json:"type"` //an alias to the ref, can be used if imported
10- Settings map [string ]interface {} `json:"settings"`
8+ Ref string `json:"ref,omitempty "`
9+ Type string `json:"type,omitempty "` //an alias to the ref, can be used if imported
10+ Settings map [string ]interface {} `json:"settings,omitempty "`
1111
1212 //referenced action
13- Id string `json:"id"`
13+ Id string `json:"id,omitempty "`
1414
1515 //DEPRECATED
16- Data json.RawMessage `json:"data"`
16+ Data json.RawMessage `json:"data,omitempty "`
1717}
Original file line number Diff line number Diff line change @@ -13,11 +13,12 @@ type Config struct {
1313 Type string `json:"type"`
1414 Version string `json:"version"`
1515 Description string `json:"description"`
16+ AppModel string `json:"appModel"`
1617
17- Imports []string `json:"imports"`
18- Properties []* data.Attribute `json:"properties"`
19- Channels []string `json:"channels"`
20- Triggers []* trigger.Config `json:"triggers"`
21- Resources []* resource.Config `json:"resources"`
22- Actions []* action.Config `json:"actions"`
18+ Imports []string `json:"imports,omitempty "`
19+ Properties []* data.Attribute `json:"properties,omitempty "`
20+ Channels []string `json:"channels,omitempty "`
21+ Triggers []* trigger.Config `json:"triggers,omitempty "`
22+ Resources []* resource.Config `json:"resources,omitempty "`
23+ Actions []* action.Config `json:"actions,omitempty "`
2324}
Original file line number Diff line number Diff line change 55 " type" ,
66 " version" ,
77 " description" ,
8- " imports" ,
9- " properties" ,
10- " channels" ,
11- " triggers" ,
12- " resources" ,
13- " actions"
8+ " appModel"
149 ],
1510 "properties" : {
1611 "actions" : {
2015 },
2116 "type" : " array"
2217 },
18+ "appModel" : {
19+ "type" : " string"
20+ },
2321 "channels" : {
2422 "items" : {
2523 "type" : " string"
7573 " type" ,
7674 " version" ,
7775 " description" ,
78- " imports" ,
79- " properties" ,
80- " channels" ,
81- " triggers" ,
82- " resources" ,
83- " actions"
76+ " appModel"
8477 ],
8578 "properties" : {
8679 "actions" : {
9083 },
9184 "type" : " array"
9285 },
86+ "appModel" : {
87+ "type" : " string"
88+ },
9389 "channels" : {
9490 "items" : {
9591 "type" : " string"
140136 "type" : " object"
141137 },
142138 "action.Config" : {
143- "required" : [
144- " ref" ,
145- " type" ,
146- " settings" ,
147- " id" ,
148- " data"
149- ],
150139 "properties" : {
151140 "data" : {
152141 "type" : " object"
188177 "type" : " object"
189178 },
190179 "trigger.ActionConfig" : {
191- "required" : [
192- " ref" ,
193- " type" ,
194- " settings" ,
195- " id" ,
196- " data" ,
197- " Act"
198- ],
199180 "properties" : {
200- "Act" : {
201- "additionalProperties" : true ,
202- "type" : " object"
203- },
204181 "data" : {
205182 "type" : " object"
206183 },
232209 "trigger.Config" : {
233210 "required" : [
234211 " id" ,
235- " type" ,
236- " ref" ,
237212 " settings" ,
238213 " handlers"
239214 ],
Original file line number Diff line number Diff line change @@ -12,8 +12,8 @@ import (
1212// Config is the configuration for a Trigger
1313type Config struct {
1414 Id string `json:"id"`
15- Type string `json:"type"` //an alias to the ref, can be used if imported
16- Ref string `json:"ref"`
15+ Type string `json:"type,omitempty "` //an alias to the ref, can be used if imported
16+ Ref string `json:"ref,omitempty "`
1717 Settings map [string ]interface {} `json:"settings"`
1818 Handlers []* HandlerConfig `json:"handlers"`
1919}
@@ -94,7 +94,7 @@ type ActionConfig struct {
9494 Input map [string ]interface {} `json:"input,omitempty"`
9595 Output map [string ]interface {} `json:"output,omitempty"`
9696
97- Act action.Action
97+ Act action.Action `json:"-,omitempty"`
9898}
9999
100100// UnmarshalJSON overrides the default UnmarshalJSON for TaskInst
You can’t perform that action at this time.
0 commit comments