PageSourceSearch

https://bookstore.lakeareatech.edu/innerweb/v3.1/include/js/set_modal_div_and_cart_summary_values.js

js lakeareatech.edu collected 2026-09-24 10:33:28 UTC 1,208 bytes, 40 lines download raw bytes

1	
2	function setModalValues(r) {
3
4		var info = "<p>";
5		for (i = 0; i < r.state.length; i++) {
6			info += r.state[i].message + "<br />";
7		}
8		info += "</p>";
9		$('#flash').html(info);
10
11		$('#flash').removeClass("success");
12		$('#flash').removeClass("error");	
13		if (r.state[0].returnCode != '0') {
14			$('#flash').addClass("error");
15		} else {
16			$('#flash').addClass("success");
17		}
18
19		var totalQty = 0;
20
21		for (i = 0; i < r.items.length; i++) {
22			$('.modal-qty').html("QTY: " + r.items[i].quantity);
23			$('.modal-total').html(r.items[i].totalPrice);
24			$('.modal-product-details').html(r.items[i].attributes);
25			totalQty += r.items[i].quantity * 1;
26		}
27
28
29		if (r.cartSummary.length > 0) {
30			$('.modal-my-cart-totals').html('<p>Total Items: ' + r.cartSummary[0].numItems + '</p><p>SubTotal: ' + r.cartSummary[0].orderTotal + '</p>');
31		    $('#qtyAdded').html(r.cartSummary[0].numItems - 1);
32		}
33		
34	}
35
36	function setCartSummary(r) {
37		$('#cartSummaryValues').text(r.cartSummary[0].numItems + ' items |' + r.cartSummary[0].orderTotal);
38		$('#cartSummaryLink').html('<strong><a href=\"' + r.cartSummary[0].cartSummaryLink + '\">View Cart &raquo;</a></strong>');
39	}
40	

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.