PageSourceSearch

https://www.goo-net.com/shop/js/shop_collection_v2.js?20250219

js goo-net.com collected 2026-10-01 10:30:13 UTC 9,270 bytes, 255 lines download raw bytes

1/**
2*
3* 2407 20160719 ¤ªµ¤¤ËÆþ¤êÈÎÇäŹ²èÌ̤ÎÄɲÃ
4* author hyf
5*
6**/
7
8var COLLECTION_LIST_MAX_COUNT = 30;  //¤ªµ¤¤ËÆþ¤êŹÊޤκÇÂç·ï¿ô
9
10
11var UA = navigator.userAgent;
12var isIE6 = (UA.indexOf('MSIE 6') > -1)?true:false;
13var isIE7 = (UA.indexOf('MSIE 7') > -1)?true:false;
14
15
16$(function(){
17    var shop_id;
18    var cookies = document.cookie.split(';');
19    var data = '';
20
21    for ( var i = 0; i < cookies.length; i++) {
22        var str = cookies[i].split('=');
23
24        if ($.trim(str[0]) == 'cc_id') {
25            data = $.trim(str[1]);
26            break;
27        }
28    }
29
30    if (data == "") {
31        var h_param = {
32            request_url : '15'
33        };
34
35        if(typeof sendTTAPI == 'function'){
36            sendTTAPI (h_param, function(){});
37        }
38    }
39
40
41    if($('.btnsetHead').attr('id') != undefined ){
42        shop_id =  $('.btnsetHead').attr('id');
43        if(shop_id.length > 0){
44            var col_view = {
45                collection_view_id : shop_id,
46                use_graphql: true,
47                graphql_url: '7'
48            }
49           //¤ªµ¤¤ËÆþ¤ê¤ËÄɲúѤߤ«¤É¤¦¤«¤Î½èÍý
50           localStorage.getItem('idToken') && sendGraphQLAPI (col_view,function(data){
51           if (data.is_favorite_seller) {
52               document.getElementById(shop_id).style.display = "none";
53               if(isIE6){
54                   document.getElementById('col_shop_view_'+shop_id).style.display = 'inline';
55               }else if(isIE7){
56                   document.getElementById('col_shop_view_'+shop_id).style.display = 'inline';
57               }else{
58                   document.getElementById('col_shop_view_'+shop_id).style.display = 'inline-block';
59               }
60           }
61           if (data.id_token && data.refresh_token && data.identifier && data.password) {
62               localStorage.setItem('idToken', data.id_token);
63               localStorage.setItem('refreshToken', data.refresh_token);
64               localStorage.setItem('identifier', data.identifier);
65               localStorage.setItem('password', data.password);
66           }
67
68         });
69      }
70    }
71});
72
73
74$(function(){
75  if($(".used_car_shop").size() > 0 && $("#resultTable02").size() > 0 ){
76    var floatArea01 = $(".used_car_shop #resultTable02");
77    var floatLine01 = floatArea01.offset().top;
78    var endLine01 = $(".used_car_shop .itemDetail").filter(":last").offset().top + $(".used_car_shop .itemDetail").height();
79    var endLineFix = endLine01 - floatArea01.outerHeight(true);
80
81    $(window).scroll(function(){
82      var winScroll = $(window).scrollTop();
83
84      if(winScroll > floatLine01){
85        floatArea01.addClass('scroll_on');
86        $(".itemDetailArea").css('margin-top', floatArea01.height() + "px");
87
88        if(winScroll > endLineFix){
89          var stopPosition = floatArea01.height() * 2;
90          $(".scroll_on").css({'position':'absolute','top': endLine01 - floatLine01 - stopPosition});
91        }
92        else{
93          $(".scroll_on").css({'position':'','top': '-1px'});
94        }
95      }
96      else if(winScroll < floatLine01){
97        floatArea01.removeClass('scroll_on');
98        $(".itemDetailArea").css('margin-top',"");
99      }
100    });
101  }
102});
103
104
105//===================================
106// ¤ªµ¤¤ËÆþ¤ê¤ËÄɲåܥ¿¥ó¤Î½èÍý 
107//===================================
108function  changeCollectionShopBtn(shop_id,shop_area_id){
109
110
111    if(typeof sendGraphQLAPI == 'function'){
112       var h_param = {
113            use_graphql    : true,
114            graphql_url    : '8'
115       };
116
117       var func_param = {
118           shop_id : shop_id,
119           shop_area_id : shop_area_id
120       };
121      sendGraphQLAPI (h_param, getCollectionCount_changeCollectionShopBtn, func_param);
122      sysloger_v2('', '', '', shop_id, '', '', '', 'collectionshop', 'shop_collection');
123
124 }
125
126}
127
128//==============================================
129// ¤ªµ¤¤ËÆþ¤ê¤ËÄɲåܥ¿¥ó¤ò²¡¤·¡¢callback¤Î½èÍý
130//==============================================
131function  getCollectionCount_changeCollectionShopBtn(data,f_param){
132
133         var ret = confirmAddShopList(data, 1);
134
135         if (data.id_token && data.refresh_token && data.identifier && data.password) {
136            localStorage.setItem('idToken', data.id_token);
137            localStorage.setItem('refreshToken', data.refresh_token);
138            localStorage.setItem('identifier', data.identifier);
139            localStorage.setItem('password', data.password);
140         }
141         if(ret){
142
143            var shop_id = f_param.shop_id ;
144
145            var shop_area_id = f_param.shop_area_id;
146
147            var outHTML = '';
148
149            var h_param = {
150                 shop_collection : shop_id,
151                 use_graphql     : true,
152                 graphql_url     : '3'
153             };
154              sendGraphQLAPI (h_param, function(data) {
155            // ¥¢¥¤¥³¥ó¤òÊѹ¹¤¹¤ë¡£
156            document.getElementById(shop_id).style.display = "none";
157           if(isIE6){
158               document.getElementById('col_shop_view_'+shop_id).style.display = 'inline';
159           }else if(isIE7){
160               document.getElementById('col_shop_view_'+shop_id).style.display = 'inline';
161           }else{
162               document.getElementById('col_shop_view_'+shop_id).style.display = 'inline-block';
163           }
164
165           if (data.id_token && data.refresh_token && data.identifier && data.password) {
166               localStorage.setItem('idToken', data.id_token);
167               localStorage.setItem('refreshToken', data.refresh_token);
168               localStorage.setItem('identifier', data.identifier);
169               localStorage.setItem('password', data.password);
170           }
171           return;
172        });
173     }
174}
175
176//==============================================
177// ¤ªµ¤¤ËÆþ¤ê¤ËÄɲúѤ߷ï¤Îºï½ü
178//==============================================
179function deleteCollectionShopBtn(shop_id){
180       var del_col_id = {
181           delete_col_id : shop_id,
182           use_graphql: true,
183           graphql_url: '4'
184       }
185
186       if(typeof sendGraphQLAPI == 'function'){
187            sendGraphQLAPI(del_col_id,function(data){
188             // alert("ÅÐÏ¿Æü»þ¤Î¸Å¤¤¤â¤Î¤òºï½ü¤·"); 
189                location.reload();
190            });
191       }
192
193
194}
195
196//==============================================
197// ¤ªµ¤¤ËÆþ¤ê¤ËÄɲ÷ï¿ô¤Î³Îǧ
198//==============================================
199function confirmAddShopList(data, shop_count){
200    var ret = false;
201    var count_col = 0;
202    var max_count = COLLECTION_LIST_MAX_COUNT;
203    if(data.collection_count){
204       count_col = data.collection_count + shop_count;
205       if(count_col > max_count){
206          count_col = max_count;
207       }
208       if((data.collection_count + shop_count) > max_count){
209           const modalHTML = `
210           	<div id="confirmAddCompareDialog" style="display: block;position: fixed;top: 0;left: 0;width: 100%;height: 100%;z-index: 99999;background: rgba(0,0,0,0.3);">
211           		<div style="position: absolute;top: 50%;margin-top: -60px;width: 100%;">
212           			<div style="width: 90%;max-width: 310px;background: #ffffff;padding: 15px 0 0;margin: auto;border-radius: 10px;border: 1px solid #c6c6c6;">
213           				<p style="width: 100%;font-size: 18px;text-align: center;max-width: 250px;font-weight: bold;line-height: 24px;margin: 0 auto 20px;">¤ªµ¤¤ËÆþ¤êÈÎÇäŹ¤Ï¤³¤ì°Ê¾åÅÐÏ¿¤Ç¤­¤Þ¤»¤ó¡£</br>¤¹¤Ç¤ËÅÐÏ¿ºÑ¤ß¤Îʪ·ï¤òºï½ü¤·¡¢ÅÐÏ¿¤·Ä¾¤·¤Æ²¼¤µ¤¤¡£</p>
214           				<ul style="width: 100%;height: 36px;margin: auto;border-top: 1px solid #c6c6c6;">
215           					<li style="float: left;width: 49%;height: 100%;cursor: pointer;list-style: none;"><a class="confirmAddCompareClear" style="display: block;width: 100%;padding: 8px 0;color: #6666ff;text-align: center;font-size: 18px;text-decoration: none" href="javascript:void(0)">ÊĤ¸¤ë</a></li>
216           					<li style="float: right;border-left: 1px solid #c6c6c6;width: 50%;height: 100%;cursor: pointer;list-style: none;"><a style="display: block;width: 100%;padding: 8px 0;color: #6666ff;text-align: center;font-size: 18px;text-decoration: none"  href='/php/mysearch/compare_list.php?baitai=goo&tab_flag=2'>¤ªµ¤¤ËÆþ¤ê¤ò¸«¤ë</a></li>
217           			</ul>
218           			</div>
219           		</div>
220           </div>
221           `;
222           $('#confirmAddCompareDialog').remove();
223           $('body').append(modalHTML);
224           $('.confirmAddCompareClear').on('click', function() {
225           	$('#confirmAddCompareDialog').hide();
226           });
227           return false;
228       }else{
229            ret = true;
230       }
231     }else{
232        ret = true;
233     }
234     return ret;
235}
236
237//==============================================
238// ¤ªµ¤¤ËÆþ¤êÈÎÇ䏰ìÍ÷¤Ç¥½¡¼¥È¤Î½èÍý
239//==============================================
240function CollectionSort(str,sort_value,disp_mode) {
241    document.form1.sort_flag.value = str ;
242    document.form1.sort_value.value = sort_value ;
243    document.form1.action = "/php/mysearch/compare_list.php";
244    document.form1.submit();
245}
246
247//==============================================
248// ¤ªµ¤¤ËÆþ¤êÈÎÇ䏰ìÍ÷¤Ç¡Ö¸µ¤ËÌ᤹¡×¥ê¥ó¥¯¤Î½èÍý
249//==============================================
250function ResetSort() {
251    document.form1.sort_flag.value = '';
252    document.form1.sort_value.value = '';
253    document.form1.action = '/php/mysearch/compare_list.php';
254    document.form1.submit();
255}

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.