Changeset 20046


Ignore:
Timestamp:
2011/01/30 04:31:27 (13 years ago)
Author:
Seasoft
Message:

#628(未使用処理・定義などの削除)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_5-dev/data/Smarty/templates/sphone/products/list.tpl

    r19983 r20046  
    2121 *}--> 
    2222<script type="text/javascript">//<![CDATA[ 
    23 // 規格2に選択肢を割り当てる。 
    24 function fnSetClassCategories(form, classcat_id2_selected) { 
    25     sele1 = form.classcategory_id1; 
    26     sele2 = form.classcategory_id2; 
    27     product_id = form.product_id.value; 
    28  
    29     if (sele1) { 
    30         if (sele2) { 
    31             // 規格2の選択肢をクリア 
    32             count = sele2.options.length; 
    33             for(i = count; i >= 0; i--) { 
    34                 sele2.options[i] = null; 
    35             } 
    36              
    37             // 規格2に選択肢を割り当てる 
    38             classcats = productsClassCategories[product_id][sele1.value]; 
    39             i = 0; 
    40             for (var classcat_id2_key in classcats) { 
    41                 sele2.options[i] = new Option(classcats[classcat_id2_key].name, classcat_id2_key); 
    42                 if (classcat_id2_key == classcat_id2_selected) { 
    43                     sele2.options[i].selected = true; 
    44                 } 
    45                 i++; 
    46             } 
    47         } 
    48         fnCheckStock(form); 
    49     } 
    50 } 
    5123// 並び順を変更 
    5224function fnChangeOrderby(orderby) { 
     
    6032    fnSetVal('pageno', 1); 
    6133    fnSubmit(); 
    62 } 
    63 // カゴに入れる 
    64 function fnInCart(productForm) { 
    65     var product_id = productForm["product_id"].value; 
    66     fnChangeAction("?#product" + product_id); 
    67     if (productForm["classcategory_id1"]) { 
    68         fnSetVal("classcategory_id1", productForm["classcategory_id1"].value); 
    69     } 
    70     if (productForm["classcategory_id2"]) { 
    71         fnSetVal("classcategory_id2", productForm["classcategory_id2"].value); 
    72     } 
    73     fnSetVal("quantity", productForm["quantity"].value); 
    74     fnSetVal("product_id", productForm["product_id"].value); 
    75     fnSetVal("product_class_id", productForm["product_class_id"].value); 
    76     fnSetVal("product_type", productForm["product_type"].value); 
    77     fnSubmit(); 
    78 } 
    79 function fnCheckStock(form) { 
    80     product_id = form.product_id.value; 
    81     classcat_id1 = form.classcategory_id1.value; 
    82     classcat_id2 = form.classcategory_id2 ? form.classcategory_id2.value : 0; 
    83     classcat2 = productsClassCategories[product_id][classcat_id1][classcat_id2]; 
    84      
    85     // 在庫(品切れ) 
    86     eleDefault = document.getElementById('cartbtn_default_' + product_id); 
    87     eleDynamic = document.getElementById('cartbtn_dynamic_' + product_id); 
    88     if ( 
    89            classcat2 
    90         && classcat2.stock_find === false 
    91     ) { 
    92         eleDefault.style.display = 'none'; 
    93         eleDynamic.innerHTML = '申し訳ございませんが、只今品切れ中です。'; 
    94     } else { 
    95         eleDefault.style.display = ''; 
    96         eleDynamic.innerHTML = ''; 
    97     } 
    98      
    99     // 販売価格 
    100     eleDefault = document.getElementById('price02_default_' + product_id); 
    101     eleDynamic = document.getElementById('price02_dynamic_' + product_id); 
    102     if ( 
    103            classcat2 
    104         && typeof classcat2.price02 != 'undefined' 
    105         && String(classcat2.price02).length >= 1 
    106     ) { 
    107         eleDefault.style.display = 'none'; 
    108         eleDynamic.innerHTML = classcat2.price02; 
    109     } else { 
    110         eleDefault.style.display = ''; 
    111         eleDynamic.innerHTML = ''; 
    112     } 
    113     // 商品規格 
    114     eleDynamic = document.getElementById('product_class_id' + product_id); 
    115     if ( 
    116            classcat2 
    117         && typeof classcat2.product_class_id != 'undefined' 
    118         && String(classcat2.product_class_id).length >= 1 
    119     ) { 
    120         eleDynamic.value = classcat2.product_class_id; 
    121     } else { 
    122         eleDynamic.value = '' 
    123     } 
    124     // 商品種別 
    125     eleDynamic = document.getElementById('product_type' + product_id); 
    126     if ( 
    127            classcat2 
    128         && typeof classcat2.product_type != 'undefined' 
    129         && String(classcat2.product_type).length >= 1 
    130     ) { 
    131         eleDynamic.value = classcat2.product_type; 
    132     } else { 
    133         eleDynamic.value = '' 
    134     } 
    13534} 
    13635//]]> 
Note: See TracChangeset for help on using the changeset viewer.