{"id":39163,"date":"2024-12-24T05:12:39","date_gmt":"2024-12-24T05:12:39","guid":{"rendered":"https:\/\/www.icreativetechnologies.com\/?p=39163"},"modified":"2024-12-24T05:12:39","modified_gmt":"2024-12-24T05:12:39","slug":"creating-custom-fields-for-each-cart-line-item","status":"publish","type":"post","link":"https:\/\/www.icreativetechnologies.com\/de\/creating-custom-fields-for-each-cart-line-item\/","title":{"rendered":"Creating custom fields for each cart line item"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"39163\" class=\"elementor elementor-39163\" data-elementor-post-type=\"post\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-34b9d773 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"34b9d773\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-825707b\" data-id=\"825707b\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-a8215d3 elementor-widget elementor-widget-theme-post-featured-image elementor-widget-image\" data-id=\"a8215d3\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"theme-post-featured-image.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<img fetchpriority=\"high\" decoding=\"async\" width=\"800\" height=\"527\" src=\"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields-1024x675.jpg\" class=\"attachment-large size-large wp-image-39164\" alt=\"custom fields\" srcset=\"\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields-1024x675.jpg 1024w, \/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields-300x198.jpg 300w, \/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields-768x506.jpg 768w, \/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg 1517w\" sizes=\"(max-width: 800px) 100vw, 800px\" \/>\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-66e8983 elementor-widget elementor-widget-text-editor\" data-id=\"66e8983\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t\t\t\n<p>Creating custom fields for each cart line item in <a href=\"https:\/\/www.icreativetechnologies.com\/shopware-development-services\/\">Shopware 6 <\/a>can increase the flexibility and customization of your eCommerce platform, especially when dealing with Shopware checkout processes. Here\u2019s a simple guide on how to do it:<\/p>\n\n<h2 class=\"wp-block-heading\"><strong>Step 1: Understanding the Requirements<\/strong><\/h2>\n\n<p>Before diving into the implementation, it&#8217;s important to understand what custom fields per cart line item mean. Custom fields let you add extra information to each product in the cart. This can be useful for things like adding special instructions, gift messages, or any other custom data relevant to your business needs.<\/p>\n\n<h2 class=\"wp-block-heading\"><strong>Step 2: Creating Custom Fields<\/strong><\/h2>\n\n<ul class=\"wp-block-list\">\n<li><strong>For creating the custom fields via code you can refer to this: <\/strong><a href=\"https:\/\/www.icreativetechnologies.com\/shopware-6-add-custom-field\/\">https:\/\/www.icreativetechnologies.com\/shopware-6-add-custom-field\/<\/a><\/li>\n\n<li><strong>For creating custom fields via the backend :\u00a0\u00a0<\/strong><\/li>\n<\/ul>\n\n<ol class=\"wp-block-list\">\n<li><strong>Access Administration Panel<\/strong>: Log in to your Shopware 6 administration panel.<\/li>\n\n<li><strong>Navigate to Custom Fields<\/strong>:\n<ul class=\"wp-block-list\">\n<li>Go to <strong>Settings<\/strong> &gt; <strong>System<\/strong> &gt; <strong>Custom fields<\/strong>.<\/li>\n\n<li>Click on <strong>Add Custom Field Set<\/strong>.<\/li>\n<\/ul>\n<\/li>\n\n<li><strong>Create a Custom Field Set<\/strong>:\n<ul class=\"wp-block-list\">\n<li>Name your custom field set (e.g., &#8220;Cart Line Item Custom Fields&#8221;).<\/li>\n\n<li>Assign it to an appropriate entity. For cart line items, you should choose the entity related to line items, such as line_item.<\/li>\n<\/ul>\n<\/li>\n\n<li><strong>Add Custom Fields<\/strong>:\n<ul class=\"wp-block-list\">\n<li>Click on <strong>Add Custom Field<\/strong>.<\/li>\n\n<li>Define the properties of your custom field:\n<ul class=\"wp-block-list\">\n<li><strong>Name<\/strong>: A unique identifier for your custom field.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n<ul class=\"wp-block-list\">\n<li><strong>Type<\/strong>: Choose the appropriate type (e.g., text, number, date).<\/li>\n\n<li><strong>Label<\/strong>: A name for the custom field.<\/li>\n\n<li><strong>Configuration<\/strong>: Additional settings specific to the type of custom field.<\/li>\n<\/ul>\n\n<h2><strong>Step 3: Extending the Cart Line Item<\/strong><\/h2>\n\n<p>To ensure that your custom fields are included in the cart line item, you need to extend the cart functionality in Shopware 6.<\/p>\n\n<ol class=\"wp-block-list\">\n<li><strong>Extend the Cart Service<\/strong>:\n<ul class=\"wp-block-list\">\n<li>In your plugin, extend the cart service to include your custom fields. This involves modifying the cart data structure to include the new fields.<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n<p>Example:<br \/><br \/><strong>&lt;plugin root&gt;\/src\/Service\/CartService.php<\/strong><\/p>\n\n<p>namespace YourNamespace\\Service;<\/p>\n\n<p>use Shopware\\Core\\Checkout\\Cart\\Cart;<\/p>\n\n<p>use Shopware\\Core\\Checkout\\Cart\\LineItem\\LineItem;<\/p>\n\n<p>class CartService<\/p>\n\n<p>{<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0public function addCustomFieldToCartLineItem(Cart $cart, LineItem $lineItem, array $customFields)<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0{<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$lineItem-&gt;setPayloadValue(&#8216;customFields&#8217;, $customFields);<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$cart-&gt;add($lineItem);<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0}<\/p>\n\n<p>}<\/p>\n\n<ol class=\"wp-block-list\" start=\"2\">\n<li><strong>Subscribe to Cart Events<\/strong>:\n<ul class=\"wp-block-list\">\n<li>Listen for cart events to ensure your custom fields are processed correctly..<\/li>\n<\/ul>\n<\/li>\n<\/ol>\n\n<p>Example:<br \/><br \/><strong>&lt;plugin root&gt;\/src\/Subscriber\/CartSubscriber.php<\/strong><\/p>\n\n<p>namespace YourNamespace\\Subscriber;<\/p>\n\n<p>use Shopware\\Core\\Framework\\Context;<\/p>\n\n<p>use Symfony\\Component\\EventDispatcher\\EventSubscriberInterface;<\/p>\n\n<p>use Shopware\\Core\\Checkout\\Cart\\Event\\CartAddedEvent;<\/p>\n\n<p>class CartSubscriber implements EventSubscriberInterface<\/p>\n\n<p>{<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0public static function getSubscribedEvents(): array<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0{<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0return [<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0CartAddedEvent::class =&gt; &#8216;onCartAdded&#8217;,<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0];<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0}<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0public function onCartAdded(CartAddedEvent $event): void<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0{<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$cart = $event-&gt;getCart();<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$lineItem = $event-&gt;getLineItem();<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$context = $event-&gt;getContext();<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\/\/ Add your custom fields logic here<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$customFields = [&#8216;exampleField&#8217; =&gt; &#8216;exampleValue&#8217;];<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0$lineItem-&gt;setPayloadValue(&#8216;customFields&#8217;, $customFields);<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0}<\/p>\n\n<p>}<\/p>\n\n<h2 class=\"wp-block-heading\"><strong>Step 4: Displaying Custom Fields in the Frontend<\/strong><\/h2>\n\n<p>To display the custom fields on the front end, you need to modify the template files.<\/p>\n\n<ol class=\"wp-block-list\">\n<li><strong>Override Line Item Template:<\/strong><\/li>\n<\/ol>\n\n<ul class=\"wp-block-list\">\n<li>Create a new template file or modify an existing one to include your custom fields.<\/li>\n<\/ul>\n\n<p><strong>src\/Resources\/views\/storefront\/component\/line-item\/line-item.html.twig<\/strong>\u00a0<\/p>\n\n<p>{% sw_extends &#8216;@Storefront\/storefront\/component\/line-item\/line-item.html.twig&#8217; %}<\/p>\n\n<p>{% block component_line_item %}<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0{{ parent() }}<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0{% if lineItem.payload.customFields %}<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0&lt;div class=&#8221;custom-fields&#8221;&gt;<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0{% for key, value in lineItem.payload.customFields %}<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0&lt;p&gt;{{ key }}: {{ value }}&lt;\/p&gt;<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0{% endfor %}<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0&lt;\/div&gt;<\/p>\n\n<p>\u00a0\u00a0\u00a0\u00a0{% endif %}<\/p>\n\n<p>{% endblock %}<\/p>\n\n<h3><strong>Conclusion<\/strong><\/h3>\n\n<p>Setting custom fields for each cart line item in Shopware 6 involves several steps: creating custom fields, extending the cart service, handling cart events, and modifying frontend templates. This guide offers a detailed approach to implementing this feature, enhancing the flexibility and customization of your Shopware 6 store.<\/p>\n\t\t\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>Creating custom fields for each cart line item in Shopware 6 can [&hellip;]<\/p>\n","protected":false},"author":5,"featured_media":39164,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[86],"tags":[447,246,448],"class_list":["post-39163","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-shopware","tag-custom-fields","tag-shopware-6","tag-shopware-checkout"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Creating custom fields for each cart line item<\/title>\n<meta name=\"description\" content=\"Learn how to add and manage custom fields for each cart line item in Shopware 6, enhancing flexibility in the Shopware checkout process.\" \/>\n<meta name=\"robots\" content=\"noindex, follow\" \/>\n<meta property=\"og:locale\" content=\"de_DE\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Creating custom fields for each cart line item\" \/>\n<meta property=\"og:description\" content=\"Learn how to add and manage custom fields for each cart line item in Shopware 6, enhancing flexibility in the Shopware checkout process.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.icreativetechnologies.com\/de\/creating-custom-fields-for-each-cart-line-item\/\" \/>\n<meta property=\"og:site_name\" content=\"iCreative Technologies\" \/>\n<meta property=\"article:published_time\" content=\"2024-12-24T05:12:39+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1517\" \/>\n\t<meta property=\"og:image:height\" content=\"1000\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"Bhavya Shah\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Bhavya Shah\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3\u00a0Minuten\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/\"},\"author\":{\"name\":\"Bhavya Shah\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#\\\/schema\\\/person\\\/dc57fa9f205d886138374edc2464e992\"},\"headline\":\"Creating custom fields for each cart line item\",\"datePublished\":\"2024-12-24T05:12:39+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/\"},\"wordCount\":560,\"publisher\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/wp-content\\\/uploads\\\/2024\\\/12\\\/custom-fields.jpg\",\"keywords\":[\"custom fields\",\"Shopware 6\",\"shopware checkout\"],\"articleSection\":[\"Shopware\"],\"inLanguage\":\"de\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/\",\"url\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/\",\"name\":\"Creating custom fields for each cart line item\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/wp-content\\\/uploads\\\/2024\\\/12\\\/custom-fields.jpg\",\"datePublished\":\"2024-12-24T05:12:39+00:00\",\"description\":\"Learn how to add and manage custom fields for each cart line item in Shopware 6, enhancing flexibility in the Shopware checkout process.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#breadcrumb\"},\"inLanguage\":\"de\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"de\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/wp-content\\\/uploads\\\/2024\\\/12\\\/custom-fields.jpg\",\"contentUrl\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/wp-content\\\/uploads\\\/2024\\\/12\\\/custom-fields.jpg\",\"width\":1517,\"height\":1000,\"caption\":\"custom fields\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/creating-custom-fields-for-each-cart-line-item\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Creating custom fields for each cart line item\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#website\",\"url\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/\",\"name\":\"iCreative Technologies\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"de\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#organization\",\"name\":\"iCreative Technologies\",\"url\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"de\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/wp-content\\\/uploads\\\/2024\\\/11\\\/logo-e1628229333795.png.png\",\"contentUrl\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/wp-content\\\/uploads\\\/2024\\\/11\\\/logo-e1628229333795.png.png\",\"width\":240,\"height\":66,\"caption\":\"iCreative Technologies\"},\"image\":{\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.icreativetechnologies.com\\\/#\\\/schema\\\/person\\\/dc57fa9f205d886138374edc2464e992\",\"name\":\"Bhavya Shah\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"de\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/7897a7168f53fb5a48af86d4570a1e86b8354d56bb303aa45b6aaf8f477ac46d?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/7897a7168f53fb5a48af86d4570a1e86b8354d56bb303aa45b6aaf8f477ac46d?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/7897a7168f53fb5a48af86d4570a1e86b8354d56bb303aa45b6aaf8f477ac46d?s=96&d=mm&r=g\",\"caption\":\"Bhavya Shah\"},\"description\":\"Bhavya Shah is a Business Analyst at iCreative Technologies. He specializes in the eCommerce consulting for all business domains. He is working hand-in-hand with developers and clients to produce requirements and specifications that accurately reflect business needs and are technologically achievable.\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Creating custom fields for each cart line item","description":"Learn how to add and manage custom fields for each cart line item in Shopware 6, enhancing flexibility in the Shopware checkout process.","robots":{"index":"noindex","follow":"follow"},"og_locale":"de_DE","og_type":"article","og_title":"Creating custom fields for each cart line item","og_description":"Learn how to add and manage custom fields for each cart line item in Shopware 6, enhancing flexibility in the Shopware checkout process.","og_url":"https:\/\/www.icreativetechnologies.com\/de\/creating-custom-fields-for-each-cart-line-item\/","og_site_name":"iCreative Technologies","article_published_time":"2024-12-24T05:12:39+00:00","og_image":[{"width":1517,"height":1000,"url":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg","type":"image\/jpeg"}],"author":"Bhavya Shah","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Bhavya Shah","Est. reading time":"3\u00a0Minuten"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#article","isPartOf":{"@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/"},"author":{"name":"Bhavya Shah","@id":"https:\/\/www.icreativetechnologies.com\/#\/schema\/person\/dc57fa9f205d886138374edc2464e992"},"headline":"Creating custom fields for each cart line item","datePublished":"2024-12-24T05:12:39+00:00","mainEntityOfPage":{"@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/"},"wordCount":560,"publisher":{"@id":"https:\/\/www.icreativetechnologies.com\/#organization"},"image":{"@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#primaryimage"},"thumbnailUrl":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg","keywords":["custom fields","Shopware 6","shopware checkout"],"articleSection":["Shopware"],"inLanguage":"de"},{"@type":"WebPage","@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/","url":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/","name":"Creating custom fields for each cart line item","isPartOf":{"@id":"https:\/\/www.icreativetechnologies.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#primaryimage"},"image":{"@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#primaryimage"},"thumbnailUrl":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg","datePublished":"2024-12-24T05:12:39+00:00","description":"Learn how to add and manage custom fields for each cart line item in Shopware 6, enhancing flexibility in the Shopware checkout process.","breadcrumb":{"@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#breadcrumb"},"inLanguage":"de","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/"]}]},{"@type":"ImageObject","inLanguage":"de","@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#primaryimage","url":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg","contentUrl":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/12\/custom-fields.jpg","width":1517,"height":1000,"caption":"custom fields"},{"@type":"BreadcrumbList","@id":"https:\/\/www.icreativetechnologies.com\/creating-custom-fields-for-each-cart-line-item\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.icreativetechnologies.com\/"},{"@type":"ListItem","position":2,"name":"Creating custom fields for each cart line item"}]},{"@type":"WebSite","@id":"https:\/\/www.icreativetechnologies.com\/#website","url":"https:\/\/www.icreativetechnologies.com\/","name":"iCreative Technologies","description":"","publisher":{"@id":"https:\/\/www.icreativetechnologies.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.icreativetechnologies.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"de"},{"@type":"Organization","@id":"https:\/\/www.icreativetechnologies.com\/#organization","name":"iCreative Technologies","url":"https:\/\/www.icreativetechnologies.com\/","logo":{"@type":"ImageObject","inLanguage":"de","@id":"https:\/\/www.icreativetechnologies.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/11\/logo-e1628229333795.png.png","contentUrl":"https:\/\/www.icreativetechnologies.com\/wp-content\/uploads\/2024\/11\/logo-e1628229333795.png.png","width":240,"height":66,"caption":"iCreative Technologies"},"image":{"@id":"https:\/\/www.icreativetechnologies.com\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/www.icreativetechnologies.com\/#\/schema\/person\/dc57fa9f205d886138374edc2464e992","name":"Bhavya Shah","image":{"@type":"ImageObject","inLanguage":"de","@id":"https:\/\/secure.gravatar.com\/avatar\/7897a7168f53fb5a48af86d4570a1e86b8354d56bb303aa45b6aaf8f477ac46d?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/7897a7168f53fb5a48af86d4570a1e86b8354d56bb303aa45b6aaf8f477ac46d?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/7897a7168f53fb5a48af86d4570a1e86b8354d56bb303aa45b6aaf8f477ac46d?s=96&d=mm&r=g","caption":"Bhavya Shah"},"description":"Bhavya Shah is a Business Analyst at iCreative Technologies. He specializes in the eCommerce consulting for all business domains. He is working hand-in-hand with developers and clients to produce requirements and specifications that accurately reflect business needs and are technologically achievable."}]}},"_links":{"self":[{"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/posts\/39163","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/comments?post=39163"}],"version-history":[{"count":0,"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/posts\/39163\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/media\/39164"}],"wp:attachment":[{"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/media?parent=39163"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/categories?post=39163"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.icreativetechnologies.com\/de\/wp-json\/wp\/v2\/tags?post=39163"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}