[ad_1]
PaymentMethod.all.each_with_index do |payment, n = 0|
payment.update_column(:enc_number, @enc[n])
n +=1
end
6
[ad_2]
solved Ruby/Rails update model attribute with array items? [closed]
[ad_1]
PaymentMethod.all.each_with_index do |payment, n = 0|
payment.update_column(:enc_number, @enc[n])
n +=1
end
6
[ad_2]
solved Ruby/Rails update model attribute with array items? [closed]