{"id":44,"date":"2018-03-08T16:38:20","date_gmt":"2018-03-08T16:38:20","guid":{"rendered":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/?p=44"},"modified":"2023-09-21T11:53:17","modified_gmt":"2023-09-21T11:53:17","slug":"creating-a-dependency","status":"publish","type":"post","link":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/","title":{"rendered":"Creating a dependency"},"content":{"rendered":"\n<p>This plugin allows you to create a net of dependencies in order to push the customer towards specific purchases in specific situations.<\/p>\n\n\n\n<p>From the Dependencies tab, clicking on \u201cAdd dependence\u201d you can create your first dependence:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"521\" height=\"460\" src=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg\" alt=\"How to create a dependency\" class=\"wp-image-315\" srcset=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg 521w, https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence-300x265.jpg 300w\" sizes=\"auto, (max-width: 521px) 100vw, 521px\" \/><\/a><\/figure><\/div>\n\n\n<p>Once created, we can assign it a name and a description and specify how the components are going to interact with each other:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependency.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"548\" height=\"345\" src=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependency.jpg\" alt=\"Dependency configuration\" class=\"wp-image-317\" srcset=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependency.jpg 548w, https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependency-300x189.jpg 300w\" sizes=\"auto, (max-width: 548px) 100vw, 548px\" \/><\/a><\/figure><\/div>\n\n\n<p>You will be able to choose between two actions for each component: \u201cIF\u201d means that specific component status will be the cause of the following actions, while \u201cDO\u201d means that the specified action will be the resulting effect.<\/p>\n\n\n\n<p>So, as you can see from the screen, if you want to set a specific choice made on the first component to affect the choice of the last one without affecting the middle component, you will need to insert the IF variable in the first one, DO (nothing) in the second one and DO (Force selection to) in the third one.<\/p>\n\n\n\n<p>The following statuses can execute an IF:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>No action \u2013 The dependency is inactive.<\/li>\n\n\n\n<li>No product is selected \u2013 In case no product is selected, the dependency is active.<\/li>\n\n\n\n<li>Any product is selected \u2013 In case any product is selected for a specific component, the dependency is active.<\/li>\n\n\n\n<li>Selection is \u2013 If one of the following products is selected (which you will specify in the additional displayed field), then the dependency is active.<\/li>\n\n\n\n<li>Selection is not \u2013 If none of the following products is selected (which you will specify in the additional displayed field), then the dependency is active.<\/li>\n<\/ul>\n\n\n\n<p>Many actions can be triggered by these effects, specifically, those related to DO:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Nothing \u2013 Do nothing.<\/li>\n\n\n\n<li>Force selection to \u2013 Force selection of a specific product towards a specific component.<\/li>\n\n\n\n<li>Exclude \u2013 Forbids the choice of a specific product for a certain component.<\/li>\n\n\n\n<li>Hide component \u2013 Hides a specific component.<\/li>\n<\/ul>\n\n\n\n<p>Let\u2019s take another look at the example screenshot:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/selection-1-1.jpg\"><img loading=\"lazy\" decoding=\"async\" width=\"544\" height=\"405\" src=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/selection-1-1.jpg\" alt=\"Force selection option\" class=\"wp-image-319\" srcset=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/selection-1-1.jpg 544w, https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/selection-1-1-300x223.jpg 300w\" sizes=\"auto, (max-width: 544px) 100vw, 544px\" \/><\/a><\/figure><\/div>\n\n\n<p>In this example, once 3 components are present, it\u2019s necessary for the selection of a specific product for the first one to bring the following consequences:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Nothing for the second component.<\/li>\n\n\n\n<li>Forcing the selection of a specific product for the third component.<\/li>\n<\/ul>\n\n\n\n<p>So, an IF filter was created in the first component, bearing the \u201cSelection is\u201d status and its related product, a DO filter bearing the action \u201cNothing\u201d for the second component and a DO filter with the \u201cForce Selection\u201d action for the third one, specifying the chosen product.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This plugin allows you to create a net of dependencies in order to push the customer towards specific purchases in specific situations. From the Dependencies tab, clicking on \u201cAdd dependence\u201d you can create your first dependence: Once created, we can assign it a name and a description and specify how the components are going to &hellip; <a href=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Creating a dependency<\/span><\/a><\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[],"class_list":["post-44","post","type-post","status-publish","format-standard","hentry","category-premium-version-settings"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.8.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>YITH Composite Products: Creating a dependency<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"YITH Composite Products: Creating a dependency\" \/>\n<meta property=\"og:description\" content=\"This plugin allows you to create a net of dependencies in order to push the customer towards specific purchases in specific situations. From the Dependencies tab, clicking on \u201cAdd dependence\u201d you can create your first dependence: Once created, we can assign it a name and a description and specify how the components are going to &hellip; Continue reading Creating a dependency\" \/>\n<meta property=\"og:url\" content=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/\" \/>\n<meta property=\"og:site_name\" content=\"YITH Composite Products for WooCommerce\" \/>\n<meta property=\"article:published_time\" content=\"2018-03-08T16:38:20+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-09-21T11:53:17+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg\" \/>\n<meta name=\"author\" content=\"Alessio Torrisi\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alessio Torrisi\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"3 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/\",\"url\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/\",\"name\":\"YITH Composite Products: Creating a dependency\",\"isPartOf\":{\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg\",\"datePublished\":\"2018-03-08T16:38:20+00:00\",\"dateModified\":\"2023-09-21T11:53:17+00:00\",\"author\":{\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#\/schema\/person\/cb8b9dbb75e34f325cc8329424e6a6c5\"},\"breadcrumb\":{\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#primaryimage\",\"url\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg\",\"contentUrl\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg\",\"width\":521,\"height\":460,\"caption\":\"How to create a dependency\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Creating a dependency\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#website\",\"url\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/\",\"name\":\"YITH Composite Products for WooCommerce\",\"description\":\"Plugin documentation\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#\/schema\/person\/cb8b9dbb75e34f325cc8329424e6a6c5\",\"name\":\"Alessio Torrisi\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/1dc305ade0adaba279202977d3352276?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/1dc305ade0adaba279202977d3352276?s=96&d=mm&r=g\",\"caption\":\"Alessio Torrisi\"},\"url\":\"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/author\/alessio\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"YITH Composite Products: Creating a dependency","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/","og_locale":"en_US","og_type":"article","og_title":"YITH Composite Products: Creating a dependency","og_description":"This plugin allows you to create a net of dependencies in order to push the customer towards specific purchases in specific situations. From the Dependencies tab, clicking on \u201cAdd dependence\u201d you can create your first dependence: Once created, we can assign it a name and a description and specify how the components are going to &hellip; Continue reading Creating a dependency","og_url":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/","og_site_name":"YITH Composite Products for WooCommerce","article_published_time":"2018-03-08T16:38:20+00:00","article_modified_time":"2023-09-21T11:53:17+00:00","og_image":[{"url":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg","type":"","width":"","height":""}],"author":"Alessio Torrisi","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Alessio Torrisi","Est. reading time":"3 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/","url":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/","name":"YITH Composite Products: Creating a dependency","isPartOf":{"@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#website"},"primaryImageOfPage":{"@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#primaryimage"},"image":{"@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#primaryimage"},"thumbnailUrl":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg","datePublished":"2018-03-08T16:38:20+00:00","dateModified":"2023-09-21T11:53:17+00:00","author":{"@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#\/schema\/person\/cb8b9dbb75e34f325cc8329424e6a6c5"},"breadcrumb":{"@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#primaryimage","url":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg","contentUrl":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-content\/uploads\/sites\/84\/2018\/03\/dependence.jpg","width":521,"height":460,"caption":"How to create a dependency"},{"@type":"BreadcrumbList","@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/premium-version-settings\/creating-a-dependency\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/"},{"@type":"ListItem","position":2,"name":"Creating a dependency"}]},{"@type":"WebSite","@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#website","url":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/","name":"YITH Composite Products for WooCommerce","description":"Plugin documentation","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#\/schema\/person\/cb8b9dbb75e34f325cc8329424e6a6c5","name":"Alessio Torrisi","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/1dc305ade0adaba279202977d3352276?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/1dc305ade0adaba279202977d3352276?s=96&d=mm&r=g","caption":"Alessio Torrisi"},"url":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/author\/alessio\/"}]}},"_links":{"self":[{"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/posts\/44","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/comments?post=44"}],"version-history":[{"count":6,"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/posts\/44\/revisions"}],"predecessor-version":[{"id":364,"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/posts\/44\/revisions\/364"}],"wp:attachment":[{"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/media?parent=44"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/categories?post=44"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.yithemes.com\/yith-composite-products-for-woocommerce\/wp-json\/wp\/v2\/tags?post=44"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}