PageSourceSearch

https://www.ullmann-farben.de/_ui/responsive/common/js/acc.multidgrid.js

js ullmann-farben.de collected 2026-10-06 15:23:31 UTC 2,112 bytes, 79 lines download raw bytes

1ACC.multidgrid = {
2
3	populateAndShowGridOverlay: function(element, event)
4	{
5		event.preventDefault();
6
7		var itemIndex = $(element).data("index");
8		var gridEntries = $('#grid' + itemIndex);
9
10		var strSubEntries = gridEntries.data("sub-entries");
11		var productName = gridEntries.data("product-name");
12		var arrSubEntries= strSubEntries.split(',');
13		var firstVariantCode = arrSubEntries[0].split(':')[0];
14
15		var targetUrl = gridEntries.data("target-url") + '?productCode=' + encodeURIComponent(firstVariantCode);
16
17		ACC.colorbox.open(productName,{
18			href:   targetUrl,
19			className: 'read-only-grid',
20			close:'<span class="glyphicon glyphicon-remove"></span>',
21			width: window.innerWidth > parseInt(cboxOptions.maxWidth) ? cboxOptions.maxWidth : cboxOptions.width,
22			height: window.innerHeight > parseInt(cboxOptions.maxHeight) ? cboxOptions.maxHeight : cboxOptions.height,
23			onComplete: function() {
24
25				$('body').addClass('offcanvas');
26				var oH = $('#cboxLoadedContent').height();
27				$('#cboxLoadedContent').height((oH - $('#cboxTitle').height()) +'px');
28
29			},
30
31			onClosed: function() {
32				$('body').removeClass('offcanvas');
33			}
34
35		});
36	},
37	
38	populateAndShowGrid: function(element, event, readOnly)
39	{
40		var itemIndex = $(element).data("index");
41		grid = $("#ajaxGrid" + itemIndex);
42		var gridEntries = $('#grid' + itemIndex);
43		
44		$(element).toggleClass('open');
45		
46		if (!grid.is(":hidden")) {
47        	grid.slideUp();
48        	return;
49        }
50
51		if(grid.html() != "") {
52			grid.slideToggle("slow");
53			return;
54		}
55
56		var strSubEntries = gridEntries.data("sub-entries");
57		var arrSubEntries= strSubEntries.split(',');
58		var firstVariantCode = arrSubEntries[0].split(':')[0];
59
60		var targetUrl = gridEntries.data("target-url");
61
62		var method = "GET";
63		$.ajax({
64			url: targetUrl,
65			data: {productCode: firstVariantCode},
66			type: method,
67			success: function(data)
68			{
69				grid.html(data);
70				grid.slideDown("slow");
71			},
72			error: function(xht, textStatus, ex)
73			{
74				alert("Failed to get variant matrix. Error details [" + xht + ", " + textStatus + ", " + ex + "]");
75			}
76
77		});
78	}
79};

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.