fix error
This commit is contained in:
parent
c1a5e89d57
commit
3aeb2a993b
|
@ -2,6 +2,7 @@ module Admin::GalleriesHelper
|
||||||
def import_this_image(row,album)
|
def import_this_image(row,album)
|
||||||
value = {}
|
value = {}
|
||||||
image = AlbumImage.new
|
image = AlbumImage.new
|
||||||
|
image.album = album
|
||||||
row.cells.each_with_index do |cell,index|
|
row.cells.each_with_index do |cell,index|
|
||||||
val = cell.value rescue nil
|
val = cell.value rescue nil
|
||||||
next if val.blank?
|
next if val.blank?
|
||||||
|
@ -14,7 +15,6 @@ module Admin::GalleriesHelper
|
||||||
image.description_translations = value
|
image.description_translations = value
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
image.album = album
|
|
||||||
image.save
|
image.save
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue