{"id":461,"date":"2023-07-12T13:59:06","date_gmt":"2023-07-12T07:59:06","guid":{"rendered":"https:\/\/gastech.kz\/?page_id=461"},"modified":"2023-07-12T13:59:06","modified_gmt":"2023-07-12T07:59:06","slug":"%d0%ba%d0%b0%d1%82%d0%b0%d0%bb%d0%be%d0%b3-%d0%b7%d0%b0%d0%bf%d1%87%d0%b0%d1%81%d1%82%d0%b5%d0%b9-protherm","status":"publish","type":"page","link":"https:\/\/gastech.kz\/?page_id=461","title":{"rendered":"\u041a\u0430\u0442\u0430\u043b\u043e\u0433 \u0437\u0430\u043f\u0447\u0430\u0441\u0442\u0435\u0439 Protherm"},"content":{"rendered":"\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"366\" src=\"https:\/\/gastech.kz\/wp-content\/uploads\/2022\/12\/service2-1024x366.png\" alt=\"\" class=\"wp-image-315\" srcset=\"https:\/\/gastech.kz\/wp-content\/uploads\/2022\/12\/service2-1024x366.png 1024w, https:\/\/gastech.kz\/wp-content\/uploads\/2022\/12\/service2-300x107.png 300w, https:\/\/gastech.kz\/wp-content\/uploads\/2022\/12\/service2-768x275.png 768w, https:\/\/gastech.kz\/wp-content\/uploads\/2022\/12\/service2.png 1536w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<div class=\"wp-block-columns is-layout-flex wp-container-core-columns-is-layout-8f761849 wp-block-columns-is-layout-flex\">\n<div class=\"wp-block-column is-layout-flow wp-block-column-is-layout-flow\" style=\"flex-basis:100%\"><!DOCTYPE html>\r\n <html>\r\n <head>\r\n <meta charset=\"utf-8\">\r\n <style>\r\n div#spcatalog\u2212attachpoint {\r\n width: 1000px;\r\n height: 800px;\r\n }\r\n <\/style>\r\n\r\n <!\u2212\u2212 The API key must be passed to the widget loader \u2212\u2212>\r\n <script src=\"https:\/\/sparepart.vaillant-group.com\/loader\/widget.js\/c4f30eb2-4ca9-4701-bf40-48d540e4ad3d\"><\/script>\r\n <\/head>\r\n <body>\r\n <div id=\"spcatalog\u2212attachpoint\"><\/div>\r\n <input type=\"button\" value=\"Get basket contents\" id=\"get\u2212basket\u2212button\"\/>\r\n <input type=\"button\" value=\"Clear basket\" id=\"clear\u2212basket\u2212button\"\/>\r\n <input type=\"button\" value=\"Close widget\" id=\"close\u2212button\"\/>\r\n <script type=\"text\/javascript\">\r\n \/\/ VaillantSPCatalog.Widget is available after the API has been loaded.\r\n \/\/ 1st step: Create a new widget instance, passing the div serving as attach point as a parameter.\r\nvar widget = new VaillantSPCatalog.Widget(\r\ndocument.getElementById('spcatalog\u2212attachpoint'),\r\n{\r\n\/\/ Further configuration of the widget instance\r\nsearchPanelMinimized: true\r\n}\r\n);\r\n\r\n\/\/ 2nd step: Attach a bunch of event listeners.\r\nwidget.attachListeners({\r\nready: function () {\r\n\/\/ The ready event signals that the widget has fully loaded and the communication has been setup.\r\n\/\/ We ignore this for our simple example, but any access to the widget API must be deferred until\r\n\/\/ ready has been thrown.\r\nconsole.log('Widget ready!');\r\n},\r\nbasketItemAdded: function(item) {\r\nconsole.log('Item added to basket: ', item);\r\n}\r\n}, widget);\r\n\/\/ 3rd step: Connect the API buttons to the widget.\r\n\r\ndocument.getElementById('get\u2212basket\u2212button').onclick = function () {\r\nif (!VaillantSPCatalog.instance) {\r\nreturn;\r\n}\r\n\/\/ Note the promise \u2212\u2212\u2212 API methods return their values asynchronously via promises!\r\nVaillantSPCatalog.instance.getBasket().then(function (contents) {\r\nconsole.log('Basket contents:', contents);\r\n});\r\n};\r\ndocument.getElementById('clear\u2212basket\u2212button').onclick = function () {\r\nif (!VaillantSPCatalog.instance) {\r\nreturn;\r\n}\r\nVaillantSPCatalog.instance.clearBasket();\r\n6};\r\n\r\n\/\/ 4th step: It is convenient to store the widget instance in the VaillantSPCatalog\r\n\/\/namespace \u2212\u2212\u2212 the\r\n\/\/ VaillantSPCatalog.instance property is reserved for this purpose.\r\nVaillantSPCatalog.instance = widget;\r\n\r\n\/\/ 5th step: Connect the close button\r\ndocument.getElementById('close\u2212button').onclick = function () {\r\nif (!VaillantSPCatalog.instance) {\r\nreturn;\r\n}\r\n\/\/ The destructor destroys the widget instance and removes the widget from its container\r\nVaillantSPCatalog.instance.destroy();\r\n\/\/ After destroying the widget, we nullify the instance reference\r\nVaillantSPCatalog.instance = null;\r\n}\r\n<\/script>\r\n<\/body>\r\n<\/html>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"neve_meta_sidebar":"","neve_meta_container":"","neve_meta_enable_content_width":"","neve_meta_content_width":0,"neve_meta_title_alignment":"","neve_meta_author_avatar":"","neve_post_elements_order":"","neve_meta_disable_header":"","neve_meta_disable_footer":"","neve_meta_disable_title":"","footnotes":""},"class_list":["post-461","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/gastech.kz\/index.php?rest_route=\/wp\/v2\/pages\/461","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/gastech.kz\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/gastech.kz\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/gastech.kz\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/gastech.kz\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=461"}],"version-history":[{"count":1,"href":"https:\/\/gastech.kz\/index.php?rest_route=\/wp\/v2\/pages\/461\/revisions"}],"predecessor-version":[{"id":462,"href":"https:\/\/gastech.kz\/index.php?rest_route=\/wp\/v2\/pages\/461\/revisions\/462"}],"wp:attachment":[{"href":"https:\/\/gastech.kz\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=461"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}