trophonius 1.1.4 → 1.1.5
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/trophonius_record.rb +3 -3
- metadata +2 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2b396a3a21ea6764173b3b4fed6300f00f332280132bd73986d02f77871f9f00
|
4
|
+
data.tar.gz: 6d7bf9d341969a63a2321283ac7cc26c40d842137bb2a29a677bf3de81b4c9cd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce349193edf1388c9404b0ef65a379b1b6187050b90dea35d81e7301a3d081de5be0cd731c068da73cf9e3bbdc399744974aa698b8d70e6e3d742c109507025a
|
7
|
+
data.tar.gz: 5a1d947924e1ba3fcf0ab8ceb2db5ade50ff5eabe6a2a33ba51942eb3f5edb38d434874c0eedd7196cfc24b47568dbc1266ec3c983ad4d43f0f1028bc70d103a
|
data/lib/trophonius_record.rb
CHANGED
@@ -79,12 +79,12 @@ module Trophonius
|
|
79
79
|
# Throws a FileMaker error if upload failed
|
80
80
|
#
|
81
81
|
# @param [String] container_name: Case sensitive name of the container field on the layout
|
82
|
-
# @param [Integer]
|
82
|
+
# @param [Integer] container_repetition: Number of the repetition of the container field to set
|
83
83
|
# @param [Tempfile or File] file: File to upload
|
84
84
|
#
|
85
85
|
# @return [True] if successful
|
86
|
-
def upload(container_name:,
|
87
|
-
url = URI("http#{Trophonius.config.ssl == true ? 's' : ''}://#{Trophonius.config.host}/fmi/data/v1/databases/#{Trophonius.config.database}/layouts/#{layout_name}/records/#{record_id}/containers/#{container_name}/#{
|
86
|
+
def upload(container_name:, container_repetition: 1, file:)
|
87
|
+
url = URI("http#{Trophonius.config.ssl == true ? 's' : ''}://#{Trophonius.config.host}/fmi/data/v1/databases/#{Trophonius.config.database}/layouts/#{layout_name}/records/#{record_id}/containers/#{container_name}/#{container_repetition}")
|
88
88
|
|
89
89
|
response = Request.upload_file_request(url, "Bearer #{Request.get_token}", file)
|
90
90
|
if response['messages'][0]['code'] != '0'
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: trophonius
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kempen Automatisering
|
@@ -87,8 +87,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
87
87
|
- !ruby/object:Gem::Version
|
88
88
|
version: '0'
|
89
89
|
requirements: []
|
90
|
-
|
91
|
-
rubygems_version: 2.7.9
|
90
|
+
rubygems_version: 3.0.3
|
92
91
|
signing_key:
|
93
92
|
specification_version: 4
|
94
93
|
summary: Link between Ruby (on Rails) and FileMaker.
|