From fd1c53432c51bbf5caf68d88f8210b473e24bd3f Mon Sep 17 00:00:00 2001 From: Aung Myo Date: Wed, 7 Jun 2017 17:13:27 +0630 Subject: [PATCH] account model updated --- app/models/account.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/account.rb b/app/models/account.rb index a950865c..ee768fb6 100644 --- a/app/models/account.rb +++ b/app/models/account.rb @@ -2,7 +2,7 @@ class Account < ApplicationRecord validates_presence_of :title, :account_type has_many :menu_items - # belongs_to :lookup , :class_name => "Lookup" + def self.collection Account.select("id, title").map { |e| [e.title, e.id] } end