portatext 1.1.6 → 1.1.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/portatext/command/api/variables.rb +9 -0
- data/portatext.gemspec +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6bcb91124b2df5df27bea7468a7092127469e3d3
|
4
|
+
data.tar.gz: b4576f0e8d25ac13183b79e8f8b750f1d1d29e76
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 57c623a573e571b7e6cb83697d06631aeca778705e1e2e22132ad59deb03385ccc184619eec81b57b3af37d187256991800283cab5cd7eef4463a3f1a93b63bf
|
7
|
+
data.tar.gz: c4d5aa5f84fa85b9551978005f0f4e5d93bb838dd22371c6ebe8514a5b58d7bdf169a694ac376fcd456190ba1e7144139b5ddaef6d57be6f8f2f23afc80e84f6
|
@@ -21,6 +21,14 @@ module PortaText
|
|
21
21
|
set :value, value
|
22
22
|
end
|
23
23
|
|
24
|
+
def csv(file)
|
25
|
+
set :file, file
|
26
|
+
end
|
27
|
+
|
28
|
+
def save_to(file)
|
29
|
+
set :accept_file, file
|
30
|
+
end
|
31
|
+
|
24
32
|
# rubocop:disable Style/AccessorMethodName
|
25
33
|
def set_all(variables)
|
26
34
|
variables = variables.reduce([]) do |acc, v|
|
@@ -31,6 +39,7 @@ module PortaText
|
|
31
39
|
# rubocop:enable Style/AccessorMethodName
|
32
40
|
|
33
41
|
def endpoint(_method)
|
42
|
+
return 'contacts/variables' if @args[:number].nil?
|
34
43
|
number = @args[:number]
|
35
44
|
@args.delete :number
|
36
45
|
return "contacts/#{number}/variables" if @args[:name].nil?
|
data/portatext.gemspec
CHANGED