PageSourceSearch

https://stroikompleks-s.ru/assets/storefront-seo/b0b166f043db9d09/document-registry.js

js stroikompleks-s.ru collected 2026-10-05 00:19:25 UTC 15,643 bytes, 343 lines download raw bytes

1/* Global technical documents that are not yet tied to a live product card.
2 * Loaded after app.js and before documents-center.js. Synthetic records are
3 * removed on the next task so they never become catalog products.
4 *
5 * The TPE/TPE seal certificates are temporarily removed from real product
6 * records only while documents-center builds its immutable library index.
7 * They are immediately restored for product cards, and indexed through the
8 * dedicated "Уплотнители" library record instead of the TATPROF section.
9 */
10(() => {
11  'use strict';
12
13  const products = window.SK?.data?.products;
14  if (!Array.isArray(products)) return;
15
16  const marker = '__documentRegistryOnly';
17  const sealCertificateHrefs = new Set([
18    '/documents/certificates/tpe-vr-plast-certificate-2025-2028.pdf',
19    '/documents/certificates/tpe-vr-plast-test-protocol-8027-1125.pdf'
20  ]);
21
22  // Keep the product cards unchanged, but stop documents-center from assigning
23  // TPE certificates to TATPROF merely because the sale card has that brand.
24  const savedSealCertificates = [];
25  for (const product of products) {
26    const certificates = Array.isArray(product.certificates) ? product.certificates : null;
27    if (!certificates || !certificates.some(doc => sealCertificateHrefs.has(doc?.href))) continue;
28    savedSealCertificates.push([product, certificates]);
29    product.certificates = certificates.filter(doc => !sealCertificateHrefs.has(doc?.href));
30  }
31
32  const docs = [
33    {
34      slug:'doc-only-seals-tpe-certificates',
35      article:'TPE / ТЭП',
36      name:'Сертификаты на уплотнители ТЭП (TPE)',
37      category:'document-only',
38      brand:'Уплотнители',
39      system:'Уплотнители ТЭП (TPE)',
40      systemLabel:'Уплотнители',
41      hardwareSection:'hardware',
42      certificates:[
43        {
44          title:'Сертификат соответствия на уплотнители ТЭП (TPE) ООО «ВР-Пласт» · до 23.11.2028',
45          href:'/documents/certificates/tpe-vr-plast-certificate-2025-2028.pdf'
46        },
47        {
48          title:'Протокол испытаний № 8027/1125 от 24.11.2025 · уплотнители ТЭП (TPE)',
49          href:'/documents/certificates/tpe-vr-plast-test-protocol-8027-1125.pdf'
50        }
51      ]
52    },
53    {
54      slug:'doc-only-fural-catalog',
55      article:'',
56      name:'Общий каталог FURAL',
57      category:'document-only',
58      brand:'FURAL',
59      system:'Фурнитура для окон и дверей',
60      systemLabel:'FURAL',
61      hardwareSection:'door-hardware',
62      documents:[{
63        title:'Общий каталог FURAL · петли, ручки и дверная фурнитура',
64        href:'/documents/hardware/fural/fural-catalog.pdf',
65        kind:'Каталог'
66      }]
67    },
68    {
69      slug:'doc-only-stublina-catalog',
70      article:'',
71      name:'Общий каталог Stublina',
72      category:'document-only',
73      brand:'Stublina',
74      system:'Фурнитура для окон и дверей',
75      systemLabel:'Stublina',
76      hardwareSection:'window-hardware',
77      documents:[{
78        title:'Общий каталог Stublina · оконная и дверная фурнитура',
79        href:'/documents/hardware/stublina/stublina-catalog.pdf',
80        kind:'Каталог'
81      }]
82    },
83    {
84      slug:'doc-only-stn-1850-window-catalog',
85      article:'СТН-1850',
86      name:'Технический каталог СТН-1850',
87      category:'document-only',
88      brand:'Сатурн',
89      system:'СТН-1850',
90      systemLabel:'СТН-1850 · Европаз',
91      hardwareSection:'window-hardware',
92      documents:[{
93        title:'Технический каталог СТН-1850 · фурнитура для окон из алюминиевого профиля, Европаз',
94        href:'/documents/hardware/stn/stn-1850-window-europaz.pdf',
95        kind:'Каталог'
96      }]
97    },
98    {
99      slug:'doc-only-stn-1850-certificate',
100      article:'СТН-1850.2',
101      name:'Сертификат СТН на поворотные, откидные и поворотно-откидные устройства',
102      category:'document-only',
103      brand:'Сатурн',
104      system:'СТН-1850 / СТН-2400',
105      systemLabel:'СТН',
106      hardwareSection:'window-hardware',
107      certificates:[{
108        title:'Сертификат соответствия ФСКС RU.ОС01.Н.00068 и протокол испытаний №40 от 26.05.2025 · до 27.05.2027',
109        href:'/documents/certificates/stn-1850-certificate-protocol-2025-2027.pdf'
110      }]
111    },
112    {
113      slug:'doc-only-stn-door-hinges-certificate',
114      article:'СТН-0611 / 1420 / 2371 / 2746 / 2369 / 1350 / 1602 / 1605 / 3000',
115      name:'Сертификат СТН на дверные петли',
116      category:'document-only',
117      brand:'Сатурн',
118      system:'Дверные петли СТН',
119      systemLabel:'СТН',
120      hardwareSection:'door-hinges',
121      certificates:[{
122        title:'Сертификат соответствия ФСКС RU.ОС01.Н.00067 на дверные петли СТН · до 27.05.2027',
123        href:'/documents/certificates/stn-door-hinges-certificate-2025-2027.pdf'
124      }]
125    },
126    {
127      slug:'doc-only-kale-locks-class4-certificate',
128      article:'ФСКС TR.ОС01.Н.00019',
129      name:'Сертификат KALE на врезные замки 4 класса',
130      category:'document-only',
131      brand:'KALE',
132      system:'Замки',
133      systemLabel:'KALE',
134      hardwareSection:'door-hardware',
135      certificates:[{
136        title:'KALE · врезные замки 4 класса · ФСКС TR.ОС01.Н.00019 · до 28.11.2026',
137        href:'/documents/certificates/kale/kale-locks-class4-fsks-tr-os01-n00019.pdf'
138      }]
139    },
140    {
141      slug:'doc-only-kale-cylinder-locks-certificate',
142      article:'ФСКС TR.ОС01.Н.00020',
143      name:'Сертификат KALE на цилиндровые замки 2 класса',
144      category:'document-only',
145      brand:'KALE',
146      system:'Замки',
147      systemLabel:'KALE',
148      hardwareSection:'door-hardware',
149      certificates:[{
150        title:'KALE · цилиндровые замки 2 класса · ФСКС TR.ОС01.Н.00020 · до 28.11.2026',
151        href:'/documents/certificates/kale/kale-cylinder-locks-class2-fsks-tr-os01-n00020.pdf'
152      }]
153    },
154    {
155      slug:'doc-only-kale-cylinders-certificate',
156      article:'ФСКС TR.ОС01.Н.00021',
157      name:'Сертификат KALE на механизмы цилиндровые для замков',
158      category:'document-only',
159      brand:'KALE',
160      system:'Цилиндровые механизмы',
161      systemLabel:'KALE',
162      hardwareSection:'door-hardware',
163      certificates:[{
164        title:'KALE · механизмы цилиндровые для замков · ФСКС TR.ОС01.Н.00021 · до 28.11.2026',
165        href:'/documents/certificates/kale/kale-cylinders-fsks-tr-os01-n00021.pdf'
166      }]
167    },
168    {
169      slug:'doc-only-kale-latch-locks-certificate',
170      article:'ФСКС TR.ОС01.Н.00022',
171      name:'Сертификат KALE на врезные защёлки для межкомнатных дверей',
172      category:'document-only',
173      brand:'KALE',
174      system:'Замки и защёлки',
175      systemLabel:'KALE',
176      hardwareSection:'door-hardware',
177      certificates:[{
178        title:'KALE · защёлки врезные для межкомнатных дверей · ФСКС TR.ОС01.Н.00022 · до 28.11.2026',
179        href:'/documents/certificates/kale/kale-interior-latch-locks-fsks-tr-os01-n00022.pdf'
180      }]
181    },
182    {
183      slug:'doc-only-geze-door-closers-certificate',
184      article:'',
185      name:'Сертификат GEZE на дверные доводчиÐ
185ºÐ¸',
186      category:'document-only',
187      brand:'GEZE',
188      system:'Дверные доводчики',
189      systemLabel:'GEZE',
190      hardwareSection:'door-hardware',
191      certificates:[{
192        title:'GEZE · сертификат соответствия на дверные доводчики · до 17.03.2027',
193        href:'/documents/certificates/geze-door-closers-certificate-2024-2027.pdf'
194      }]
195    },
196    {
197      slug:'doc-only-specdetal-stainless-handles-certificate',
198      article:'СДР',
199      name:'Сертификат «Спецдеталь» на стационарные дверные ручки из нержавеющей стали',
200      category:'document-only',
201      brand:'Спецдеталь',
202      system:'Стационарные дверные ручки',
203      systemLabel:'Спецдеталь',
204      hardwareSection:'door-handles',
205      certificates:[{
206        title:'Спецдеталь · сертификат на стационарные дверные ручки СДР · до 09.01.2028',
207        href:'/documents/certificates/specdetal-stainless-door-handles-certificate-2025-2028.pdf'
208      }]
209    },
210    {
211      slug:'doc-only-dormakaba-refusal-letter',
212      article:'',
213      name:'Отказное письмо dormakaba на замки, цилиндры, ручки и антипанику',
214      category:'document-only',
215      brand:'dormakaba',
216      system:'Замки, цилиндры, ручки и антипаника',
217      systemLabel:'dormakaba',
218      hardwareSection:'door-hardware',
219      certificates:[{
220        title:'dormakaba · отказное письмо на замки, цилиндры, дверные ручки и устройства «антипаника» · 2017',
221        href:'/documents/certificates/dormakaba-locks-cylinders-handles-antipanic-refusal-letter-2017.pdf'
222      }]
223    },
224    {
225      slug:'doc-only-dorma-fire-closers-certificate',
226      article:'DORMA TS 68',
227      name:'Архивный противопожарный сертификат DORMA на дверные доводчики',
228      category:'document-only',
229      brand:'Dorma',
230      system:'Дверные доводчики',
231      systemLabel:'DORMA',
232      hardwareSection:'door-hardware',
233      certificates:[{
234        title:'DORMA · противопожарный сертификат на дверные доводчики · архивный, срок действия до 14.12.2025',
235        href:'/documents/certificates/dormakaba-door-closers-fire-certificate-2020-2025.pdf'
236      }]
237    },
238    {
239      slug:'doc-only-dormakaba-floor-closers-certificate',
240      article:'BTS 60 / BTS 65 / BTS 75 V / BTS 80 / BTS 84 / RTS 85',
241      name:'Сертификат dormakaba на напольные доводчики',
242      category:'document-only',
243      brand:'dormakaba',
244      system:'Напольные доводчики',
245      systemLabel:'dormakaba',
246      hardwareSection:'door-hardware',
247      certificates:[{
248        title:'dormakaba · сертификат на напольные доводчики и аксессуары · до 08.10.2028',
249        href:'/documents/certificates/dormakaba-floor-closers-certificate-2025-2028.pdf'
250      }]
251    },
252    {
253      slug:'doc-only-fasteners-certificate',
254      article:'',
255      name:'Сертификат на крепёжные изделия и метизы',
256      category:'document-only',
257      brand:'СПЕЦКРЕПЕЖ',
258      system:'Крепёжные изделия',
259      systemLabel:'Метизы',
260      hardwareSection:'hardware',
261      certificates:[{
262        title:'Сертификат соответствия РОСС RU.МЛ10.Н05881 на крепёжные изделия и метизы · до 27.07.2028',
263        href:'/documents/certificates/fasteners-speckrepezh-certificate-2025-2028.pdf'
264      }]
265    }
266  ];
267
268  for (const item of docs) {
269    item[marker] = true;
270    products.push(item);
271  }
272
273  // documents-center.js builds its own immutable index synchronously on load.
274  // Remove temporary records and restore the actual product-card certificates
275  // immediately afterwards so the catalog stays limited to real products.
276  setTimeout(() => {
277    for (let i = products.length - 1; i >= 0; i -= 1) {
278      if (products[i]?.[marker]) products.splice(i, 1);
279    }
280    for (const [product, certificates] of savedSealCertificates) {
281      product.certificates = certificates;
282    }
283  }, 0);
284
285  // Give "Уплотнители" its own visible certificate section. The immutable
286  // documents-center index still uses its existing generic grouping internally;
287  // this presentation layer exposes seals as a first-class section and keeps
288  // them out of the TATPROF branch.
289  const main = document.getElementById('main');
290  const sealBrand = 'уплотнители';
291  const sealHref = `#documents?type=certificates&group=hardware&brand=${encodeURIComponent(sealBrand)}`;
292
293  function enhanceCertificateNavigation() {
294    const currentRoute = window.SK_STOREFRONT_ROUTE ? '#'+window.SK_STOREFRONT_ROUTE.current() : location.hash;
295    if (!main || !currentRoute.startsWith('#documents')) return;
296    const params = new URLSearchParams(currentRoute.split('?')[1] || '');
297    if (params.get('type') !== 'certificates') return;
298
299    const group = params.get('group') || '';
300    const brand = params.get('brand') || '';
301
302    if (!group && !brand) {
303      const groups = main.querySelector('.dc-groups');
304      if (groups && !groups.querySelector('[data-seal-certificates]')) {
305        const card = document.createElement('a');
306        card.className = 'dc-group';
307        card.href = sealHref;
308        card.setAttribute('data-dc-route', '');
309        card.setAttribute('data-seal-certificates', '');
310        card.innerHTML = '<div class="dc-group-icon"><i data-lucide="badge-check" aria-hidden="true"></i></div><div><h3>Уплотнители</h3><p>Сертификаты и протоколы испытаний на уплотнители ТЭП (TPE) и EPDM</p></div><span>2</span><i data-lucide="chevron-right" aria-hidden="true"></i>';
311        groups.insertBefore(card, groups.children[1] || null);
312        window.lucide?.createIcons({attrs:{width:20,height:20,'stroke-width':1.7}});
313      }
314    }
315
316    // Do not duplicate the dedicated seals section inside the generic
317    // "Фурнитура и комплектующие" manufacturer selector.
318    if (group === 'hardware' && !brand) {
319      for (const link of main.querySelectorAll('.dc-group[href]')) {
320        try {
321          const url = new URL(link.href, location.href);
322          if ((url.hash || '').includes(`brand=${encodeURIComponent(sealBrand)}`)) link.remove();
323        } catch (_) {}
324      }
325    }
326
327    if (brand === sealBrand) {
328      const crumbs = main.querySelector('.dc-breadcrumbs');
329      if (crumbs) {
330        crumbs.innerHTML = '<a data-dc-route href="#documents">Все документы</a><b>/</b><a data-dc-route href="#documents?type=certificates">Сертификаты</a><b>/</b><span aria-current="page">Уплотнители</span>';
331      }
332    }
333  }
334
335  if (main && 'MutationObserver' in window) {
336    const observer = new MutationObserver(enhanceCertificateNavigation);
337    observer.observe(main, {childList:true, subtree:true});
338    addEventListener('pagehide', () => observer.disconnect(), {once:true});
339  }
340  addEventListener('hashchange', () => setTimeout(enhanceCertificateNavigation, 0));
341  addEventListener('popstate', () => setTimeout(enhanceCertificateNavigation, 0));
342  setTimeout(enhanceCertificateNavigation, 0);
343})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.