Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

Update Spree::DataFeed serializer

Rafal Cymerysa1d00a5e76f2
diff --git a/api/app/serializers/spree/api/v2/platform/data_feed_serializer.rb b/api/app/serializers/spree/api/v2/platform/data_feed_serializer.rb
index 4f55f9d455..f9404c5611 100644
--- a/api/app/serializers/spree/api/v2/platform/data_feed_serializer.rb
+++ b/api/app/serializers/spree/api/v2/platform/data_feed_serializer.rb
@@ -3,7 +3,9 @@ module Spree
module V2
module Platform
class DataFeedSerializer < BaseSerializer
- include ResourceSerializerConcern
+ set_type :data_feed
+
+ attributes :name, :type, :slug, :active
end
end
end
diff --git a/api/docs/v2/platform/index.yaml b/api/docs/v2/platform/index.yaml
index 03b57f08a6..88e38c6da7 100644
--- a/api/docs/v2/platform/index.yaml
+++ b/api/docs/v2/platform/index.yaml
@@ -2235,11 +2235,6 @@ paths:
type: Spree::DataFeed::Google
slug: e593ae1f-630a-4f77-832f-0489da1c921b
active: true
- relationships:
- store:
- data:
- id: '1'
- type: store
- id: '2'
type: data_feed
attributes:
@@ -2247,11 +2242,6 @@ paths:
type: Spree::DataFeed::Google
slug: 52f060f2-76cf-4983-89a3-714419941463
active: true
- relationships:
- store:
- data:
- id: '1'
- type: store
meta:
count: 2
total_count: 2
@@ -2299,11 +2289,6 @@ paths:
type: Spree::DataFeed::Google
slug: e593ae1f-630a-4f77-832f-0489da1c921b
active: true
- relationships:
- store:
- data:
- id: '1'
- type: store
schema:
"$ref": "#/components/schemas/resource"
'422':
@@ -2317,8 +2302,6 @@ paths:
errors:
name:
- can't be blank
- store:
- - can't be blank
type:
- can't be blank
schema:
@@ -2416,11 +2399,6 @@ paths:
type: Spree::DataFeed::Google
slug: e593ae1f-630a-4f77-832f-0489da1c921b
active: true
- relationships:
- store:
- data:
- id: '1'
- type: store
schema:
"$ref": "#/components/schemas/resource"
'422':
@@ -19491,7 +19469,6 @@ components:
required:
- name
- type
- - store_id
properties:
name:
type: string
@@ -19502,9 +19479,6 @@ components:
type:
type: string
example: 'Spree::DataFeed::Google'
- store_id:
- type: string
- example: '1'
active:
type: boolean
x-internal: false
@@ -19516,7 +19490,6 @@ components:
required:
- name
- type
- - store_id
properties:
name:
type: string
@@ -19527,9 +19500,6 @@ components:
type:
type: string
example: 'Spree::DataFeed::Google'
- store_id:
- type: string
- example: '1'
active:
type: boolean
x-internal: false