tessitura_rest 2.0.7 → 2.0.8
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 +4 -4
- data/lib/tessitura_rest/crm/issues.rb +55 -0
- data/lib/tessitura_rest/custom/email.rb +14 -0
- data/lib/tessitura_rest/version.rb +1 -1
- data/lib/tessitura_rest/web/cart.rb +1 -1
- data/tessitura_rest.gemspec +11 -11
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1ce13f389ba623e3a2ef3df3907665bce79cdccefbd812a13320e74848c37085
|
4
|
+
data.tar.gz: d8282b8ed80d2d1fde8251f8b489a2ca067c1b741bc221c4db2b9590584d2882
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c4d99a8c11de1ba0e7d1a27a1a2fde2b25c21c65dff718e4037dd1ecc5d00514f01edd2e70d372a656d177b9841ce0a700d5f81ec835cb9bc1e9c3a7e695a035
|
7
|
+
data.tar.gz: 68b0b4ed64bd16ef7db75dbb968f289c3fbe2fc5e0bc676e93b7c5381cbc9562334ac23f1eebd36a208291fc470fad52c32dc85a61d7b3c708c310ecf543721b
|
@@ -1,4 +1,9 @@
|
|
1
1
|
module Issues
|
2
|
+
def get_issue(issue_id, options = {})
|
3
|
+
options.merge!(basic_auth: @auth, headers: @headers)
|
4
|
+
self.class.get(base_api_endpoint("CRM/Issues/#{issue_id}"), options)
|
5
|
+
end
|
6
|
+
|
2
7
|
def create_issue(activity_type, category_id, constituent_id, contact_type, notes, origin_id, options = {})
|
3
8
|
parameters =
|
4
9
|
{
|
@@ -25,4 +30,54 @@ module Issues
|
|
25
30
|
response = self.class.post(base_api_endpoint('CRM/Issues'), options)
|
26
31
|
JSON.parse(response.body)
|
27
32
|
end
|
33
|
+
|
34
|
+
def create_issue_step(constituent_id, issue_id, options = {})
|
35
|
+
parameters =
|
36
|
+
{
|
37
|
+
'Issue': {
|
38
|
+
'Id': issue_id,
|
39
|
+
},
|
40
|
+
'Constituent': {
|
41
|
+
'Id': constituent_id,
|
42
|
+
},
|
43
|
+
'Type': {
|
44
|
+
'Id': 330,
|
45
|
+
},
|
46
|
+
'Priority': {
|
47
|
+
'Id': 2,
|
48
|
+
},
|
49
|
+
'Recurrence': 'N',
|
50
|
+
'Description': 'Email Sent',
|
51
|
+
'StepDateTime': DateTime.now.strftime('%m/%d/%Y %H:%M:%S'),
|
52
|
+
'CompletedOnDateTime': DateTime.now.strftime('%m/%d/%Y %H:%M:%S'),
|
53
|
+
'Notes': "See Email for IsAc_no: #{issue_id}",
|
54
|
+
}
|
55
|
+
options.merge!(basic_auth: @auth, headers: @headers)
|
56
|
+
options.merge!(:body => parameters.to_json)
|
57
|
+
self.class.post(base_api_endpoint('CRM/IssueSteps'), options)
|
58
|
+
end
|
59
|
+
|
60
|
+
def update_issue(issue_id, is_closed, activity_type, category_id, contact_type, constituent_id, updated_datetime, options = {})
|
61
|
+
parameters =
|
62
|
+
{
|
63
|
+
'Id': issue_id,
|
64
|
+
'IsClosed': is_closed,
|
65
|
+
'UpdatedDateTime': updated_datetime,
|
66
|
+
'ActivityType': {
|
67
|
+
'Id': activity_type,
|
68
|
+
'Category': {
|
69
|
+
'Id': category_id,
|
70
|
+
},
|
71
|
+
},
|
72
|
+
'ContactType': {
|
73
|
+
'Id': contact_type,
|
74
|
+
},
|
75
|
+
'Constituent': {
|
76
|
+
'Id': constituent_id,
|
77
|
+
},
|
78
|
+
}
|
79
|
+
options.merge!(basic_auth: @auth, headers: @headers)
|
80
|
+
options.merge!(:body => parameters.to_json)
|
81
|
+
self.class.put(base_api_endpoint("CRM/Issues/#{issue_id}"), options)
|
82
|
+
end
|
28
83
|
end
|
@@ -27,4 +27,18 @@ module Email
|
|
27
27
|
post = self.class.post(base_api_endpoint("Emails/OrderConfirmation/#{order_id}/Send"), options)
|
28
28
|
post.success?
|
29
29
|
end
|
30
|
+
|
31
|
+
def send_email(recipient, body, subject, sender, options = {})
|
32
|
+
parameters =
|
33
|
+
{
|
34
|
+
'RecipientAddress': recipient,
|
35
|
+
'HtmlBody': body,
|
36
|
+
'FromAddress': sender,
|
37
|
+
'Subject': subject,
|
38
|
+
'EmailProfileId': 2,
|
39
|
+
}
|
40
|
+
options.merge!(basic_auth: @auth, headers: @headers)
|
41
|
+
options.merge!(:body => parameters.to_json)
|
42
|
+
self.class.post(base_api_endpoint('Emails/Send'), options)
|
43
|
+
end
|
30
44
|
end
|
@@ -320,7 +320,7 @@ module Cart
|
|
320
320
|
'ECommerce': true,
|
321
321
|
'AuthorizationCode': order_authorization_code,
|
322
322
|
'PaymentId': payment_id,
|
323
|
-
'PaymentReference': payment_reference
|
323
|
+
'PaymentReference': payment_reference,
|
324
324
|
}
|
325
325
|
options.merge!(basic_auth: @auth, headers: @headers)
|
326
326
|
options.merge!(:body => parameters.to_json)
|
data/tessitura_rest.gemspec
CHANGED
@@ -6,18 +6,18 @@ require 'tessitura_rest/version'
|
|
6
6
|
|
7
7
|
Gem::Specification.new do |spec|
|
8
8
|
spec.required_ruby_version = '>= 2.6.0'
|
9
|
-
spec.name
|
10
|
-
spec.version
|
11
|
-
spec.authors
|
12
|
-
spec.email
|
9
|
+
spec.name = 'tessitura_rest'
|
10
|
+
spec.version = TessituraRest::VERSION
|
11
|
+
spec.authors = ['Brittany Martin, Danielle Greaves, Craig Donavin, Patrick FitzGerald']
|
12
|
+
spec.email = ['webteam@trustarts.org']
|
13
13
|
|
14
|
-
spec.summary
|
15
|
-
spec.description
|
16
|
-
spec.homepage
|
17
|
-
spec.license
|
18
|
-
spec.files
|
19
|
-
spec.bindir
|
20
|
-
spec.executables
|
14
|
+
spec.summary = 'Rest API Endpoint for the Tessitura Rest API (v16+).'
|
15
|
+
spec.description = 'TessituraRest is an enterprise-wide, fully integrated software system for arts & cultural organizations.'
|
16
|
+
spec.homepage = 'https://github.com/pgharts/tessitura'
|
17
|
+
spec.license = 'MIT'
|
18
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
19
|
+
spec.bindir = 'exe'
|
20
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
21
21
|
spec.require_paths = ['lib']
|
22
22
|
|
23
23
|
spec.add_development_dependency 'bundler', '~> 2.0'
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: tessitura_rest
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brittany Martin, Danielle Greaves, Craig Donavin, Patrick FitzGerald
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-07
|
11
|
+
date: 2024-08-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -194,5 +194,5 @@ requirements: []
|
|
194
194
|
rubygems_version: 3.0.3.1
|
195
195
|
signing_key:
|
196
196
|
specification_version: 4
|
197
|
-
summary: Rest API Endpoint for the Tessitura Rest API (
|
197
|
+
summary: Rest API Endpoint for the Tessitura Rest API (v16+).
|
198
198
|
test_files: []
|