Changeset 21032


Ignore:
Timestamp:
2011/07/13 19:28:49 (13 years ago)
Author:
sunat134
Message:

refs #1329 (商品登録(商品規格)にて1行目を在庫無制限にし一行目のデータをコピーして登録しようとすると在庫無制限チェックが全てOFFになる)
チェックボックスのidを修正して対応しました

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_11-dev/data/Smarty/templates/admin/products/product_class.tpl

    r20970 r21032  
    2525$(function() { 
    2626    // 無制限チェックボックスの初期化 
    27     $('input[id^=stock_unlimited_]').each(function() { 
    28         var index = $(this).attr('id').replace(/^stock_unlimited_/ig, ''); 
     27    $('input[id^=chk_stock_unlimited_]').each(function() { 
     28        var index = $(this).attr('id').replace(/^chk_stock_unlimited_/ig, ''); 
    2929        var checked = $(this).attr('checked'); 
    3030 
     
    3737 
    3838    // 無制限チェックボックス 
    39     $('input[id^=stock_unlimited_]').change(function() { 
    40         var index = $(this).attr('id').replace(/^stock_unlimited_/ig, ''); 
     39    $('input[id^=chk_stock_unlimited_]').change(function() { 
     40        var index = $(this).attr('id').replace(/^chk_stock_unlimited_/ig, ''); 
    4141        var checked = $(this).attr('checked'); 
    4242 
     
    6363        $('input[id^=stock_]').val(stock); 
    6464 
    65         var stock_unlimited = $('#stock_unlimited_0').attr('checked'); 
    66         $('input[id^=stock_unlimited_]').each(function() { 
     65        var stock_unlimited = $('#chk_stock_unlimited_0').attr('checked'); 
     66        $('input[id^=chk_stock_unlimited_]').each(function() { 
    6767            var checked = stock_unlimited; 
    68             var index = $(this).attr('id').replace(/^stock_unlimited_/ig, ''); 
     68            var index = $(this).attr('id').replace(/^chk_stock_unlimited_/ig, ''); 
    6969            $(this).attr('checked', checked); 
    7070            if (checked) { 
     
    255255                        <span class="attention"><!--{$arrErr[$key][$index]}--></span> 
    256256                    <!--{/if}--> 
    257                     <input type="checkbox" name="<!--{$key}-->[<!--{$index}-->]" value="1" <!--{if $arrForm[$key].value[$index] == "1"}-->checked="checked"<!--{/if}--> id="<!--{$key}-->_<!--{$index}-->" /><label for="<!--{$key}-->_<!--{$index}-->">無制限</label> 
     257                    <input type="checkbox" name="<!--{$key}-->[<!--{$index}-->]" value="1" <!--{if $arrForm[$key].value[$index] == "1"}-->checked="checked"<!--{/if}--> id="chk_<!--{$key}-->_<!--{$index}-->" /><label for="chk_<!--{$key}-->_<!--{$index}-->">無制限</label> 
    258258                </td> 
    259259                <td class="center"> 
Note: See TracChangeset for help on using the changeset viewer.