int32 id = 2; string email = 3; } module PersonAttributes extend ActiveSupport::Concern included do attribute :name attribute :id attribute :email end end QSPUPpMF SVCZ QSPUPGJMF͔ΒTFSWFSTJEFͷίʔυੜ w "DUJWF.PEFM4FSJBMJ[FSͷίʔυΛੜ
QSPUPGJMF͔ΒTFSWFSTJEFͷίʔυੜ w ੜͨ͠ίʔυΛTFSJBMJ[FS͔Βར༻ class PeopleController < ApplicationController def show @person = Person.find(params[:id]) render json: @person end end
int32 id = 2; string email = 3; } module PersonAttributes extend ActiveSupport::Concern included do attribute :name attribute :id attribute :email end end QSPUPpMF SVCZ QSPUPGJMF͔ΒDMJFOUTJEFͷίʔυੜ w NBQQJOHDMBTTͷίʔυΛੜʢTFSWFSͱಉ͡