mio-config 2.3.0 → 2.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ebb01782fede6f0e8f83cc84eacc98bcf13b2a98
4
- data.tar.gz: f5645b0e827640c097d58c2edc8c079197fabc73
3
+ metadata.gz: e89eebb32948e70e99580986e17078ed767c0175
4
+ data.tar.gz: 7364a61d783d97994c2f4b7d0e2cc77dc3fa80be
5
5
  SHA512:
6
- metadata.gz: 2aff49bc4af3ac170af91b0c53b7541a2af4245a52b5f46adbddff4c3d4f2e098149080a8963bef5c26808a7a65d0bddd7a853915cb9a4b70b8da8c81eef7b3b
7
- data.tar.gz: 74d12e1cde8508020bc2917710fde4e5d08728ab78d6d0c840bd755f6e6d2657d6152ea96d6f256f923a0d8947b3b737f9ddfa72e1cec80f13e97b2313aae449
6
+ metadata.gz: 6f1713418b1c39742fa3318d3d2e96a0c2eeeb55a7c96a6497dbb0966ec07eeceebb7a287311ba30f6551876b4eba7f8c50f112e91678f3403a97ec2aed8eb53
7
+ data.tar.gz: 6dc11edcc8664cc6b8bc492b99828032407a6b5b0f05299aedda57ce2e4a0fdad55d042b7790a2fe42294d2ac625cd69660a85c6bafb4aa240bed7881c047ae1
@@ -0,0 +1,38 @@
1
+ class Mio
2
+ class Model
3
+ class EmailMessageAction < Model
4
+ set_resource :actions
5
+
6
+ field :name, String, 'Name of the Email Message Action'
7
+ field :visibility, Array, 'Ids of the accounts which may see the import action', [4]
8
+ field :template, Fixnum, 'Id of email template'
9
+ field :recipientExpression, String, 'Evaluated Expression value which generates an email address', '${job.mioObject.owner.email}'
10
+
11
+ # @TODO mio api does not currently support templates
12
+ # templates CRUD needs to be automated via mio-config
13
+ # templates should be looked up by name rather than by id ^^
14
+
15
+ field :enable, Symbol, ':true or :false', :true
16
+ field :start, Symbol, ':true or :false', :true
17
+
18
+ def create_hash
19
+ plugin = 'tv.nativ.mio.enterprise.execution.action.file.process.impl.message.email.SendEmailMessageCommand'
20
+ {name: @args.name,
21
+ pluginClass: plugin,
22
+ visibilityIds: @args.visibility,
23
+ type: 'message',
24
+ runRuleExpression: ''
25
+ }
26
+ end
27
+
28
+ def config_hash
29
+ # @TODO Get the Email Template id from the template name
30
+
31
+ { :'message-template' => { id: @args.template },
32
+ recipients: { expression: [ { value: @args.recipientExpression, isExpression: false } ] }
33
+ }
34
+ end
35
+
36
+ end
37
+ end
38
+ end
@@ -7,7 +7,7 @@ class Mio
7
7
  field :displayName, String, 'Script Display name'
8
8
  field :key, String, 'AWS API Key with access to S3'
9
9
  field :secret, String, 'AWS secret'
10
- field :visibility, Array, 'Ids of the accounts which may see the import action'
10
+ field :visibility, Array, 'Ids of the accounts which may see the import action', [4]
11
11
  field :script, String, 'The groovy script (inline) ', '"File.read(/path/to/script.groovy)"'
12
12
  field :jars, Array, 'JARs to load on remote, empty for none', []
13
13
  field :imports, Array, 'Imports to reference within groovy script, empty for none', []
@@ -7,7 +7,7 @@ class Mio
7
7
  field :displayName, String, 'Script Display name'
8
8
  field :key, String, 'AWS API Key with access to S3'
9
9
  field :secret, String, 'AWS secret'
10
- field :visibility, Array, 'Ids of the accounts which may see the import action'
10
+ field :visibility, Array, 'Ids of the accounts which may see the import action', [4]
11
11
  field :script, String, 'The groovy script (inline) ', '"File.read(/path/to/script.groovy)"'
12
12
  field :jars, Array, 'JARs to load on remote, empty for none', []
13
13
  field :imports, Array, 'Imports to reference within groovy script, empty for none', []
@@ -6,7 +6,7 @@ class Mio
6
6
  field :key, String, 'AWS API Key with access to S3'
7
7
  field :secret, String, 'AWS secret'
8
8
  field :bucket, String, 'AWS bucket name'
9
- field :visibility, Array, 'Ids of the accounts which may see the import action'
9
+ field :visibility, Array, 'Ids of the accounts which may see the import action', [4]
10
10
 
11
11
  field :enable, Symbol, ':true or :false', :true
12
12
  field :start, Symbol, ':true or :false', :true
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mio-config
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.0
4
+ version: 2.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - jspc
@@ -109,6 +109,7 @@ files:
109
109
  - "./lib/mio/migrations.rb"
110
110
  - "./lib/mio/model.rb"
111
111
  - "./lib/mio/model/autoload.rb"
112
+ - "./lib/mio/model/email_message_action.rb"
112
113
  - "./lib/mio/model/groovy_script.rb"
113
114
  - "./lib/mio/model/groovy_script_wait.rb"
114
115
  - "./lib/mio/model/hotfolder.rb"