zerofetcher 0.0.26 → 0.0.27
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/zerofetcher.rb +6 -6
- 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: 7415a6fc87d85ac694b550124ba2677ce683bf28
|
4
|
+
data.tar.gz: b081a5de4c433a98edecfded0426baa1d1e5e32d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7056697cdae13151a6a5e9a8b89f5c81d0eb9c8a841fb26ad589fdc93e332e4e280bd81175bc3c50a1de7e235084d34523f480c22bcf64c7c4ccdae0a38b562f
|
7
|
+
data.tar.gz: c741fec1d32ee9d70be82e609d594a60e82f767d22765f262f65207b5baaebf4a764428085ec1fe3994ad4432b72e887ee20edbb247c4cc785c147f7ca3c3fe6
|
data/lib/zerofetcher.rb
CHANGED
@@ -301,10 +301,7 @@ class ZeroFetcher
|
|
301
301
|
end
|
302
302
|
|
303
303
|
# Properties
|
304
|
-
if data.key?("properties")
|
305
|
-
# Save Json Data
|
306
|
-
File.write(jekyll_path+'/_data/properties.json', JSON.pretty_generate(data['properties']))
|
307
|
-
|
304
|
+
if data.key?("properties")
|
308
305
|
# Make Dir
|
309
306
|
FileUtils::mkdir_p jekyll_path+'/assets/images/properties'
|
310
307
|
|
@@ -319,7 +316,7 @@ class ZeroFetcher
|
|
319
316
|
files_saved = Array.new
|
320
317
|
|
321
318
|
# Save Individual Collection Files
|
322
|
-
data['properties'].
|
319
|
+
data['properties'].each_with_index do |row,pidx|
|
323
320
|
row_data = row.clone;
|
324
321
|
row_data.delete('id')
|
325
322
|
id_key = 'property_id'
|
@@ -337,7 +334,7 @@ class ZeroFetcher
|
|
337
334
|
|
338
335
|
src_image = end_point + '/media/images/properties/'+row['id']+'/' + image['image']
|
339
336
|
|
340
|
-
|
337
|
+
data['properties'][pidx]['images'][idx]['image'] = self.getAndSaveImages(src_image, image_path+'/' + image['image'])
|
341
338
|
end
|
342
339
|
end
|
343
340
|
|
@@ -348,6 +345,9 @@ class ZeroFetcher
|
|
348
345
|
|
349
346
|
self.log('Saving Property File ' + jfile.getFileName)
|
350
347
|
end
|
348
|
+
|
349
|
+
# Save Json Data
|
350
|
+
File.write(jekyll_path+'/_data/properties.json', JSON.pretty_generate(data['properties']))
|
351
351
|
|
352
352
|
# Clean up unused collection files
|
353
353
|
self.cleanUpFolder(collection_path, files_saved)
|