Update archive_files_controller.rb

This commit is contained in:
chiu 2019-09-19 19:06:18 +08:00
parent 95a775c7ac
commit 56563df6e1
1 changed files with 1 additions and 1 deletions

View File

@ -15,7 +15,7 @@ class Admin::ArchiveFilesController < OrbitAdminController
key.slice! 'sort_number-'
end
keys.each_with_index do |key,index|
archivecategory = ArchiveCategory.all.where(category_id: key)
archivecategory = ArchiveCategory.where(category_id: key)
archivecategory.first.sort_number = values[index]
archivecategory.first.save!
end