{"id":1083260,"date":"2016-02-29T05:38:05","date_gmt":"2016-02-29T13:38:05","guid":{"rendered":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/"},"modified":"2016-03-25T08:23:02","modified_gmt":"2016-03-25T15:23:02","slug":"strange-behaviour-of-stock-management","status":"closed","type":"topic","link":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/","title":{"rendered":"Strange behaviour of Stock management"},"content":{"rendered":"<p>Hello,<br \/>\nwe are experiencing some strange behaviours in stock management using event tickets + woocommerce.<br \/>\nMost of the problems we have happen in case of order that have been placed by admin in the backend.<\/p>\n<p>EG:<\/p>\n<p>&#8211; edit an event and add a ticket X.<br \/>\n&#8211; set to 10 the stock field and save<br \/>\n&#8211; now stock = 10, Woocommerce \u201cstock qty\u201d = 10 and total_sales = 0<br \/>\n&#8211; go to order and place a new order adding 10 items of X<br \/>\n&#8211; save the order<\/p>\n<p>Here we have the first strange thing:<br \/>\nThe order is on \u201cpending payment\u201d,  Woocommerce \u201cstock qty\u201d = 10, total_sales = 0, but the Event ticket \u201cstock\u201d field is already set to 0.  So, why event tickets updates the stock value before woocommerce does?<\/p>\n<p>Proceeding:<br \/>\n&#8211; set the order to complete status,<br \/>\n&#8211; woocommerce \u201cstock qty\u201d = 10 and total_sales = 10.<br \/>\n&#8211; then use the option \u201creduce line item stock\u201d to update the stock (woo commerce doesn\u2019t update it automatically for orders coming from the backend)<br \/>\n&#8211; now woocommerce stock qty = 0, total_sales = 10, BUT Event tickets stock = -10 (???????)<\/p>\n<p>Why stock -10? This doesn\u2019t happen when an order is placed by customers on the front-end and it is source of many problems when we try to refund orders \/ cancelling orders or modify again the stock amount.<\/p>\n<p>Thanks.<\/p>\n","protected":false},"template":"","class_list":["post-1083260","topic","type-topic","status-closed","hentry"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v25.2 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Strange behaviour of Stock management -<\/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:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Strange behaviour of Stock management -\" \/>\n<meta property=\"og:description\" content=\"Hello, we are experiencing some strange behaviours in stock management using event tickets + woocommerce. Most of the problems we have happen in case of order that have been placed by admin in the backend. EG: &#8211; edit an event and add a ticket X. &#8211; set to 10 the stock field and save &#8211; [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/\" \/>\n<meta property=\"article:modified_time\" content=\"2016-03-25T15:23:02+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/\",\"url\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/\",\"name\":\"Strange behaviour of Stock management -\",\"isPartOf\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\"},\"datePublished\":\"2016-02-29T13:38:05+00:00\",\"dateModified\":\"2016-03-25T15:23:02+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/theeventscalendar.com\/support\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Topics\",\"item\":\"https:\/\/theeventscalendar.com\/support\/topics\/\"},{\"@type\":\"ListItem\",\"position\":3,\"name\":\"Ticket Products\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/event-tickets\/\"},{\"@type\":\"ListItem\",\"position\":4,\"name\":\"Event Tickets Plus\",\"item\":\"https:\/\/theeventscalendar.com\/support\/forums\/forum\/event-tickets\/event-tickets-plus\/\"},{\"@type\":\"ListItem\",\"position\":5,\"name\":\"Strange behaviour of Stock management\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/theeventscalendar.com\/support\/#website\",\"url\":\"https:\/\/theeventscalendar.com\/support\/\",\"name\":\"\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Strange behaviour of Stock management -","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:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/","og_locale":"en_US","og_type":"article","og_title":"Strange behaviour of Stock management -","og_description":"Hello, we are experiencing some strange behaviours in stock management using event tickets + woocommerce. Most of the problems we have happen in case of order that have been placed by admin in the backend. EG: &#8211; edit an event and add a ticket X. &#8211; set to 10 the stock field and save &#8211; [&hellip;]","og_url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/","article_modified_time":"2016-03-25T15:23:02+00:00","twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/","url":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/","name":"Strange behaviour of Stock management -","isPartOf":{"@id":"https:\/\/theeventscalendar.com\/support\/#website"},"datePublished":"2016-02-29T13:38:05+00:00","dateModified":"2016-03-25T15:23:02+00:00","breadcrumb":{"@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/theeventscalendar.com\/support\/forums\/topic\/strange-behaviour-of-stock-management\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/theeventscalendar.com\/support\/"},{"@type":"ListItem","position":2,"name":"Topics","item":"https:\/\/theeventscalendar.com\/support\/topics\/"},{"@type":"ListItem","position":3,"name":"Ticket Products","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/event-tickets\/"},{"@type":"ListItem","position":4,"name":"Event Tickets Plus","item":"https:\/\/theeventscalendar.com\/support\/forums\/forum\/event-tickets\/event-tickets-plus\/"},{"@type":"ListItem","position":5,"name":"Strange behaviour of Stock management"}]},{"@type":"WebSite","@id":"https:\/\/theeventscalendar.com\/support\/#website","url":"https:\/\/theeventscalendar.com\/support\/","name":"","description":"","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/theeventscalendar.com\/support\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"}]}},"_links":{"self":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1083260","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":2,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1083260\/revisions"}],"predecessor-version":[{"id":1094015,"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/topic\/1083260\/revisions\/1094015"}],"wp:attachment":[{"href":"https:\/\/theeventscalendar.com\/support\/wp-json\/wp\/v2\/media?parent=1083260"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}