luis@393: class BibtexEntry < ActiveRecord::Base luis@544: unloadable luis@544: luis@393: belongs_to :publication luis@544: validates_presence_of :entry_type luis@544: luis@544: def entry_type_name luis@544: entry_type = self.entry_type luis@544: BibtexEntryType.find(entry_type).name luis@544: end luis@544: chris@586: def entry_type_label chris@586: entry_type = self.entry_type chris@586: BibtexEntryType.find(entry_type).label luis@685: end luis@393: end