mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-31 04:32:06 +08:00
14 lines
269 B
Ruby
14 lines
269 B
Ruby
# frozen_string_literal: true
|
|
|
|
module Api
|
|
module V1
|
|
class TableSerializer < ActiveModel::Serializer
|
|
type :tables
|
|
attributes :id, :name, :contents
|
|
|
|
def contents
|
|
object.contents&.force_encoding(Encoding::UTF_8)
|
|
end
|
|
end
|
|
end
|
|
end
|