irb(main):019:0> a = Admin.first
=> #<Admin _id: 514b318da61654dd05000002, email: "email@email.com", encrypted_password: "$2a$10$b.cWtfPNgUcCubJRX2vjAO6vEsds9OTGO2tn6Lfz2cBU.mwTYsHw.">
irb(main):020:0> a.class.name
=> "Admin"
irb(main):021:0> a = Admin.all
=> #<Mongoid::Criteria
selector: {}
options: {}
class: Admin
embedded: false>
irb(main):022:0> a.class.name
=> "Mongoid::Criteria"
如何在“Mongoid::Criteria”类中获取模型名称?
谢谢!