Merge branch 'dev_item_bank' of https://bdgit.educoder.net/Hjqreturn/educoder into dev_item_bank

dev_jupyter
杨树林 5 years ago
commit 2a909d6166

@ -5,7 +5,7 @@ class ExaminationBank < ApplicationRecord
has_many :tag_discipline_containers, as: :container, dependent: :destroy
has_many :tag_disciplines, through: :tag_discipline_containers
has_many :examination_items, dependent: :destroy
has_many :examination_items, -> {order(position: :asc)}, dependent: :destroy
def question_count
examination_items.size

Loading…
Cancel
Save