{"action":"closed","issue":{"url":"https://api.github.com/repos/xingrowth/fullstack-course/issues/4","repository_url":"https://api.github.com/repos/xingrowth/fullstack-course","labels_url":"https://api.github.com/repos/xingrowth/fullstack-course/issues/4/labels{/name}","comments_url":"https://api.github.com/repos/xingrowth/fullstack-course/issues/4/comments","events_url":"https://api.github.com/repos/xingrowth/fullstack-course/issues/4/events","html_url":"https://github.com/xingrowth/fullstack-course/issues/4","id":167751579,"number":4,"title":"model 和db 是什么关系？","user":{"login":"cuckoo8695","id":20467180,"avatar_url":"https://avatars.githubusercontent.com/u/20467180?v=3","gravatar_id":"","url":"https://api.github.com/users/cuckoo8695","html_url":"https://github.com/cuckoo8695","followers_url":"https://api.github.com/users/cuckoo8695/followers","following_url":"https://api.github.com/users/cuckoo8695/following{/other_user}","gists_url":"https://api.github.com/users/cuckoo8695/gists{/gist_id}","starred_url":"https://api.github.com/users/cuckoo8695/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cuckoo8695/subscriptions","organizations_url":"https://api.github.com/users/cuckoo8695/orgs","repos_url":"https://api.github.com/users/cuckoo8695/repos","events_url":"https://api.github.com/users/cuckoo8695/events{/privacy}","received_events_url":"https://api.github.com/users/cuckoo8695/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-07-27T01:54:34Z","updated_at":"2016-07-28T03:40:11Z","closed_at":"2016-07-28T03:40:11Z","body":"我们新建一个model \r\nrails g model group \r\n\r\n但是却在db/migrate 中看到定义的title，text信息，model和db是什么关系？\r\n之后判断admin的时候为什么在model中定义判断？\r\n\r\napp/models/user.rb\r\nclass User < ApplicationRecord\r\n  # ....\r\n\r\n  def admin?\r\n    email == 'xdite@growth.school'\r\n  end"}}
{"actor":{"display_login":"xdite"}}