diff --git a/app/models/list.rb b/app/models/list.rb index d59786b3..3e576890 100644 --- a/app/models/list.rb +++ b/app/models/list.rb @@ -59,7 +59,8 @@ class List # Create, a list given a table and a user def self.from_table table, user return if user.has_active_list? - list = new table: table, supplier_id: table.supplier_id, section_id: table.section_id + list = new table: table, section_id: table.section_id + list.supplier_id = table.supplier_id list.add_user user list.save user.active_list_id = list.id