End of evening commit, changing supplier to JSONAPI
This commit is contained in:
@@ -1,11 +1,6 @@
|
||||
class Suppliers::PageSerializer < Qwaiter::Serializer
|
||||
self.root = :page
|
||||
attributes :name, :title, :body, :locale, :position
|
||||
def name
|
||||
object.name.to_s.sub /^suppliers-/, ''
|
||||
end
|
||||
|
||||
def id
|
||||
name
|
||||
end
|
||||
class Suppliers::PageSerializer
|
||||
include Qwaiter::SupplierBaseSerializer
|
||||
attributes :title, :body, :locale, :position
|
||||
attribute(:name) { object.name.to_s.sub /^suppliers-/, '' }
|
||||
attribute(:id) { object.name.to_s.sub /^suppliers-/, '' }
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user