mirror of
https://github.com/ditkrg/rswag.git
synced 2026-01-25 07:16:40 +00:00
rename to rswag plus major refactor - almost a rewrite
This commit is contained in:
0
test-app/app/models/.gitkeep
Normal file
0
test-app/app/models/.gitkeep
Normal file
11
test-app/app/models/blog.rb
Normal file
11
test-app/app/models/blog.rb
Normal file
@@ -0,0 +1,11 @@
|
||||
class Blog < ActiveRecord::Base
|
||||
validates :content, presence: true
|
||||
|
||||
def as_json(options)
|
||||
{
|
||||
id: id,
|
||||
title: title,
|
||||
content: content
|
||||
}
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user