postman_mta 0.2.1 → 0.2.2
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/.rubocop.yml +2 -10
- data/app/controllers/postman_mta/archive/conversations_controller.rb +23 -0
- data/app/models/postman_mta/archive/conversation.rb +13 -0
- data/app/models/postman_mta/conversation.rb +5 -1
- data/config/routes.rb +4 -0
- data/lib/postman_mta/version.rb +1 -1
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7d6d5fffa4743f5f68aca42d85ce8504cd3b1438e87b08b9aab67f8c86dcd1a8
|
4
|
+
data.tar.gz: 9e533b9344643973321ed86143708bd19db68424f995499478a24c0e5b5c05e6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f1eec23222904c934a81f5e1a867f9a0bb0a670403e984274ae4a941a6acd6d702c630fd623c05bb6c155b2fe3a32280699be1e8aa58d2c750de866aa5f100f1
|
7
|
+
data.tar.gz: ca7da62ced3248c0735e49f7fa4f4f323fab93cd72e59cd32f2a7d65d5ba836ba9c70fcc544d038eab9b231d8989f37292ecb2dbba66317b4df205080130014a
|
data/.rubocop.yml
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
AllCops:
|
2
|
+
NewCops: disable
|
2
3
|
TargetRubyVersion: 2.4
|
3
|
-
|
4
4
|
Exclude:
|
5
5
|
- "Guardfile"
|
6
6
|
- "Rakefile"
|
@@ -30,7 +30,7 @@ Lint/AmbiguousBlockAssociation:
|
|
30
30
|
|
31
31
|
##################### Metrics ##################################
|
32
32
|
|
33
|
-
|
33
|
+
Layout/LineLength:
|
34
34
|
Max: 110
|
35
35
|
|
36
36
|
Metrics/ClassLength:
|
@@ -45,11 +45,3 @@ Metrics/BlockLength:
|
|
45
45
|
Max: 50
|
46
46
|
Exclude:
|
47
47
|
- "**/*_spec.rb"
|
48
|
-
|
49
|
-
##################### Rails ##################################
|
50
|
-
|
51
|
-
Rails:
|
52
|
-
Enabled: true
|
53
|
-
|
54
|
-
Rails/SkipsModelValidations:
|
55
|
-
Enabled: false
|
@@ -0,0 +1,23 @@
|
|
1
|
+
module PostmanMta
|
2
|
+
module Archive
|
3
|
+
class ConversationsController < ApplicationController
|
4
|
+
def index
|
5
|
+
render conversation.index(permitted_params)
|
6
|
+
end
|
7
|
+
|
8
|
+
def show
|
9
|
+
render conversation.find(params[:id])
|
10
|
+
end
|
11
|
+
|
12
|
+
private
|
13
|
+
|
14
|
+
def conversation
|
15
|
+
@conversation ||= PostmanMta::Archive::Conversation.new
|
16
|
+
end
|
17
|
+
|
18
|
+
def permitted_params
|
19
|
+
params.permit!
|
20
|
+
end
|
21
|
+
end
|
22
|
+
end
|
23
|
+
end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
module PostmanMta
|
2
|
+
module Archive
|
3
|
+
class Conversation < PostmanMta::Conversation
|
4
|
+
def index(params = {})
|
5
|
+
get('/archive/conversations', body: params)
|
6
|
+
end
|
7
|
+
|
8
|
+
def find(conversation_id)
|
9
|
+
get("/archive/conversations/#{conversation_id}")
|
10
|
+
end
|
11
|
+
end
|
12
|
+
end
|
13
|
+
end
|
@@ -4,10 +4,14 @@ module PostmanMta
|
|
4
4
|
get('/conversations', body: params)
|
5
5
|
end
|
6
6
|
|
7
|
+
def archive(params = {})
|
8
|
+
get('/archive/conversations', body: params)
|
9
|
+
end
|
10
|
+
|
7
11
|
def folder(folder, params = {})
|
8
12
|
params = {
|
9
13
|
folder: folder
|
10
|
-
}.merge(params)
|
14
|
+
}.merge!(params)
|
11
15
|
|
12
16
|
get('/conversations', body: params)
|
13
17
|
end
|
data/config/routes.rb
CHANGED
data/lib/postman_mta/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: postman_mta
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Igor Malinovskiy
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-08-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -148,6 +148,7 @@ files:
|
|
148
148
|
- README.md
|
149
149
|
- Rakefile
|
150
150
|
- app/controllers/postman_mta/application_controller.rb
|
151
|
+
- app/controllers/postman_mta/archive/conversations_controller.rb
|
151
152
|
- app/controllers/postman_mta/attachments_controller.rb
|
152
153
|
- app/controllers/postman_mta/conversations_controller.rb
|
153
154
|
- app/controllers/postman_mta/domains_controller.rb
|
@@ -157,6 +158,7 @@ files:
|
|
157
158
|
- app/controllers/postman_mta/stats/messages_controller.rb
|
158
159
|
- app/controllers/postman_mta/tags_controller.rb
|
159
160
|
- app/models/postman_mta/application_model.rb
|
161
|
+
- app/models/postman_mta/archive/conversation.rb
|
160
162
|
- app/models/postman_mta/attachment.rb
|
161
163
|
- app/models/postman_mta/bookmark.rb
|
162
164
|
- app/models/postman_mta/conversation.rb
|