s3_relay 0.3.2 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -7
- data/lib/s3_relay/model.rb +1 -4
- data/lib/s3_relay/version.rb +1 -1
- data/test/dummy/log/development.log +14 -0
- data/test/dummy/log/test.log +1105 -0
- data/test/lib/s3_relay/model_test.rb +2 -17
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b7dcaafe6bb5112a54f7b4d19b69a7217280f43a
|
4
|
+
data.tar.gz: 7bacab9d71c6600560720e998ee3edd1c1e49fc8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 15d6b441802e588b243d951e4f94b3e2c4e049dc49009d6146b37018070f917a0fd3eb7ca78967062e54a28309b5436cd51155796a50c68c817fb629d5e9cec9
|
7
|
+
data.tar.gz: 30aae77630eaa6bc0ea0d5f3b2860dc6dc8783ae60641df64ab441ddeb963e38172f4a9e57ce32752b4c23bb10e27ad9bac3cda9cfa2159e85d1b3aa0ef09d5c
|
data/README.md
CHANGED
@@ -127,7 +127,7 @@ end
|
|
127
127
|
|
128
128
|
```ruby
|
129
129
|
product_params = params.require(:product)
|
130
|
-
.permit(:name, :
|
130
|
+
.permit(:name, :new_icon_upload_uuids: [], new_photo_uploads_uuids: [])
|
131
131
|
|
132
132
|
@product = Product.new(product_params)
|
133
133
|
```
|
@@ -235,12 +235,6 @@ end
|
|
235
235
|
4. Push to the branch (`git push origin my-new-feature`)
|
236
236
|
5. [Create a Pull Request](https://github.com/kjohnston/s3_relay/pull/new)
|
237
237
|
|
238
|
-
## Contributors
|
239
|
-
|
240
|
-
Many thanks go to the following who have contributed to making this gem even better:
|
241
|
-
|
242
|
-
[your name here]
|
243
|
-
|
244
238
|
## License
|
245
239
|
|
246
240
|
* Freely distributable and licensed under the [MIT license](http://kjohnston.mit-license.org/license.html).
|
data/lib/s3_relay/model.rb
CHANGED
@@ -15,8 +15,6 @@ module S3Relay
|
|
15
15
|
upload_type: upload_type
|
16
16
|
)
|
17
17
|
end
|
18
|
-
|
19
|
-
virtual_attribute = "new_#{attribute}_uuids"
|
20
18
|
else
|
21
19
|
has_one attribute, as: :parent, class_name: "S3Relay::Upload"
|
22
20
|
|
@@ -29,10 +27,9 @@ module S3Relay
|
|
29
27
|
)
|
30
28
|
.order("pending_at DESC").last
|
31
29
|
end
|
32
|
-
|
33
|
-
virtual_attribute = "new_#{attribute}_uuid"
|
34
30
|
end
|
35
31
|
|
32
|
+
virtual_attribute = "new_#{attribute}_uuids"
|
36
33
|
attr_accessor virtual_attribute
|
37
34
|
|
38
35
|
association_method = "associate_#{attribute}"
|
data/lib/s3_relay/version.rb
CHANGED
@@ -0,0 +1,14 @@
|
|
1
|
+
[1m[36m (1.9ms)[0m [1mCREATE TABLE "schema_migrations" ("version" character varying(255) NOT NULL) [0m
|
2
|
+
[1m[35m (1.3ms)[0m CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
|
3
|
+
[1m[36mActiveRecord::SchemaMigration Load (0.2ms)[0m [1mSELECT "schema_migrations".* FROM "schema_migrations"[0m
|
4
|
+
Migrating to CreateS3RelayUploads (20141009000804)
|
5
|
+
[1m[35m (0.1ms)[0m BEGIN
|
6
|
+
[1m[36m (3.2ms)[0m [1mCREATE TABLE "s3_relay_uploads" ("id" serial primary key, "uuid" bytea, "user_id" integer, "parent_type" character varying(255), "parent_id" integer, "upload_type" character varying(255), "filename" text, "content_type" character varying(255), "state" character varying(255), "data" json DEFAULT '{}', "pending_at" timestamp, "imported_at" timestamp, "created_at" timestamp, "updated_at" timestamp) [0m
|
7
|
+
[1m[35mSQL (0.5ms)[0m INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20141009000804"]]
|
8
|
+
[1m[36m (0.5ms)[0m [1mCOMMIT[0m
|
9
|
+
Migrating to CreateProducts (20141021002149)
|
10
|
+
[1m[35m (5.9ms)[0m BEGIN
|
11
|
+
[1m[36m (7.5ms)[0m [1mCREATE TABLE "products" ("id" serial primary key, "name" character varying(255), "created_at" timestamp, "updated_at" timestamp) [0m
|
12
|
+
[1m[35mSQL (0.3ms)[0m INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20141021002149"]]
|
13
|
+
[1m[36m (6.2ms)[0m [1mCOMMIT[0m
|
14
|
+
[1m[35mActiveRecord::SchemaMigration Load (0.2ms)[0m SELECT "schema_migrations".* FROM "schema_migrations"
|