PageSourceSearch

https://toutaku.co.jp/share/js/filter_room_list.js?d=20261002

js toutaku.co.jp collected 2026-10-05 04:16:49 UTC 3,569 bytes, 138 lines download raw bytes

1/*---------------------------------------------------------------------------------
2 建物詳細 部屋一覧絞り込み処理
3---------------------------------------------------------------------------------*/
4$(document).ready(function(){
5
6	$('.js-modal-open').on('click',function(){
7		$('.modal').fadeIn();
8		return false;
9	});
10	$('.js-modal-close').on('click',function(){
11		$('.modal').fadeOut();
12		return false;
13	});
14
15	$(".filter_reset").click(function(){
16		// 部屋リスト
17		var objs = document.getElementsByClassName("sort_item");
18		var sortItem = Array.from(objs);
19		
20		disp_count = 0;
21		sortItem.forEach(function( a ){
22			$(a).css('display', '');
23			disp_count = disp_count + 1;
24		});
25		$(".total-count").html(disp_count);
26		
27		$("#filter_price").val(0);
28		$("#filter_price_limit").val(0);
29		$("#filter_sikirei").prop('checked', false);
30		$("#filter_area").val(0);
31		$("#filter_area_limit").val(0);
32		for (var ix = 1; ix <= 11; ix ++) {
33			$("#filter_madori_" + ix).prop("checked", false);
34		}
35		$('#filter_message').css('display', 'none');
36		$('#filter_close').trigger('click');
37	});
38
39	$(".filter_apply").click(function(){
40
41		// 賃料
42		filterPrice = $("#filter_price").val();
43		filterPriceLimit = $("#filter_price_limit").val();
44		if (filterPriceLimit == 0) {
45			filterPriceLimit = 999999999999999;
46		}
47
48		// 敷金礼金ゼロ
49		filterSikirei = $("#filter_sikirei:checked").val();
50
51		// 専有面積
52		filterArea = $("#filter_area").val();
53		filterAreaLimit = $("#filter_area_limit").val();
54		if (filterAreaLimit == 0) {
55			filterAreaLimit = 999999999999999;
56		}
57
58		// 間取り
59		var madoriArr = [];
60		for (var ix = 1; ix <= 11; ix ++) {
61			if ( $('#filter_madori_' + ix).prop("checked") ) {
62				Array.prototype.push.apply(madoriArr, $('#filter_madori_' + ix + ':checked').val().split(','));
63			}
64			
65		}
66
67		// 部屋リスト
68		var objs = document.getElementsByClassName("sort_item");
69		var sortItem = Array.from(objs);
70
71		var disp_count = 0;
72		sortItem.forEach(function( a ){
73			// 部屋表示フラグ
74			var disp_flg = true;
75
76			// 賃料
77			var price = $(a).find(".sort_price").data("price");
78			if (price == '-') {
79				disp_flg = false;
80			} else {
81				if (parseFloat(filterPriceLimit) > parseFloat(price) && parseFloat(filterPrice) < parseFloat(price)) {
82					//
83				} else {
84					disp_flg = false;
85				}
86			}
87
88			// 敷金礼金ゼロ
89			var siki = $(a).find(".sort_siki").data("siki");
90			var rei = $(a).find(".sort_rei").data("rei");
91			if (filterSikirei == 1) {
92				if ( (siki == 0 || siki == '-') && (rei == 0 || rei == '-') ) {
93					//
94				} else {
95					disp_flg = false;
96				}
97			}
98
99			// 専有面積
100			var area = $(a).find(".sort_area").data("area");
101			if (area == '-') {
102				disp_flg = false;
103			} else {
104				if (parseFloat(filterAreaLimit) > parseFloat(area) && parseFloat(filterArea) < parseFloat(area)) {
105					//
106				} else {
107					disp_flg = false;
108				}
109			}
110
111			// 間取り
112			var madori = $(a).find(".sort_madori").data("madori");
113			if (madoriArr.length != 0) {
114				if ($.inArray(madori.toString(), madoriArr) === -1) {
115					disp_flg = false;
116				}
117			}
118
119			// 部屋表示・非表示処理
120			if (disp_flg) {
121				disp_count = disp_count + 1;
122				$(a).css('display', '');
123			} else {
124				$(a).css('display', 'none');
125			}
126		});
127		$("#sort_tbl").html('');
128		$("#sort_tbl").html(sortItem);
129		if (disp_count == 0) {
130			$('#filter_message').css('display', '');
131		} else {
132			$('#filter_message').css('display', 'none');
133		}
134		$(".total-count").html(disp_count);
135		$('#filter_close').trigger('click');
136		return false;
137	});
138});

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.