Changeset 18311


Ignore:
Timestamp:
2009/09/22 11:57:28 (15 years ago)
Author:
Seasoft
Message:

merge r18155
・取得元: version-2_4

  • 真偽値の判定記述をスマートに改修
  • テンプレート上でのセルの重複を改修

【取得元のログメッセージ】

  • #503 お支払い方法選択画面にてお支払いの画像がある場合のレイアウト崩れを修正。
Location:
branches/comu-ver2/data
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/comu-ver2/data/Smarty/templates/default/shopping/payment.tpl

    r18254 r18311  
    2222<!--▼CONTENTS--> 
    2323<div id="under02column"> 
    24   <div id="under02column_shopping"> 
    25     <p class="flowarea"> 
    26       <img src="<!--{$TPL_DIR}-->img/shopping/flow02.gif" width="700" height="36" alt="購入手続きの流れ" /> 
    27     </p> 
    28     <h2 class="title"><!--{$tpl_title|escape}--></h2> 
     24    <div id="under02column_shopping"> 
     25        <p class="flowarea"> 
     26            <img src="<!--{$TPL_DIR}-->img/shopping/flow02.gif" width="700" height="36" alt="購入手続きの流れ" /> 
     27        </p> 
     28        <h2 class="title"><!--{$tpl_title|escape}--></h2> 
    2929 
    30     <form name="form1" id="form1" method="post" action="?"> 
    31       <input type="hidden" name="mode" value="confirm" /> 
    32       <input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->" /> 
    33       <div class="payarea"> 
    34         <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle01.gif" width="670" height="33" alt="お支払方法の指定" /></h3> 
    35         <p>お支払方法をご選択ください。</p> 
     30        <form name="form1" id="form1" method="post" action="?"> 
     31            <input type="hidden" name="mode" value="confirm" /> 
     32            <input type="hidden" name="uniqid" value="<!--{$tpl_uniqid}-->" /> 
     33            <div class="payarea"> 
     34                <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle01.gif" width="670" height="33" alt="お支払方法の指定" /></h3> 
     35                <p>お支払方法をご選択ください。</p> 
    3636 
    37         <!--{assign var=key value="payment_id"}--> 
    38         <!--{if $arrErr[$key] != ""}--> 
    39         <p class="attention"><!--{$arrErr[$key]}--></p> 
    40         <!--{/if}--> 
    41         <table summary="お支払方法選択"> 
    42           <tr> 
    43             <th>選択</th> 
    44             <th colspan="<!--{if $arrPayment[cnt].payment_image|strlen >= 1}-->2<!--{/if}-->">お支払方法</th> 
    45           </tr> 
    46           <!--{section name=cnt loop=$arrPayment}--> 
    47           <tr> 
    48             <td class="centertd"><input type="radio" id="pay_<!--{$smarty.section.cnt.iteration}-->" name="<!--{$key}-->" onclick="fnModeSubmit('payment', '', '');" value="<!--{$arrPayment[cnt].payment_id}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" <!--{$arrPayment[cnt].payment_id|sfGetChecked:$arrForm[$key].value}--> /> 
    49             </td> 
    50             <td> 
    51               <label for="pay_<!--{$smarty.section.cnt.iteration}-->"><!--{$arrPayment[cnt].payment_method|escape}--><!--{if $arrPayment[cnt].note != ""}--><!--{/if}--></label> 
    52             </td> 
    53             <!--{if $arrPayment[cnt].payment_image != ""}--> 
    54             <td> 
    55               <img src="<!--{$smarty.const.IMAGE_SAVE_URL}--><!--{$arrPayment[cnt].payment_image}-->" /> 
    56             </td> 
     37                <!--{assign var=key value="payment_id"}--> 
     38                <!--{if $arrErr[$key] != ""}--> 
     39                <p class="attention"><!--{$arrErr[$key]}--></p> 
     40                <!--{/if}--> 
     41                <table summary="お支払方法選択"> 
     42                    <tr> 
     43                        <th>選択</th> 
     44                        <th colspan="<!--{if !$img_show}-->2<!--{else}-->3<!--{/if}-->">お支払方法</th> 
     45                    </tr> 
     46                    <!--{section name=cnt loop=$arrPayment}--> 
     47                    <tr> 
     48                        <td class="centertd"><input type="radio" id="pay_<!--{$smarty.section.cnt.iteration}-->" name="<!--{$key}-->" onclick="fnModeSubmit('payment', '', '');" value="<!--{$arrPayment[cnt].payment_id}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" <!--{$arrPayment[cnt].payment_id|sfGetChecked:$arrForm[$key].value}--> /> 
     49                        </td> 
     50                        <td> 
     51                            <label for="pay_<!--{$smarty.section.cnt.iteration}-->"><!--{$arrPayment[cnt].payment_method|escape}--><!--{if $arrPayment[cnt].note != ""}--><!--{/if}--></label> 
     52                        </td> 
     53                        <!--{if $img_show}--> 
     54                            <td> 
     55                                <!--{if $arrPayment[cnt].payment_image != ""}--> 
     56                                    <img src="<!--{$smarty.const.IMAGE_SAVE_URL}--><!--{$arrPayment[cnt].payment_image}-->" /> 
     57                                <!--{/if}--> 
     58                            </td> 
     59                        <!--{/if}--> 
     60                    </tr> 
     61                    <!--{/section}--> 
     62                </table> 
     63            </div> 
     64 
     65            <div class="payarea02"> 
     66                <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle02.gif" width="670" height="33" alt="お届け時間の指定" /></h3> 
     67                <p>ご希望の方は、お届け時間を選択してください。</p> 
     68                <div> 
     69                    <!--★お届け日★--> 
     70                    <!--{assign var=key value="deliv_date"}--> 
     71                    <span class="attention"><!--{$arrErr[$key]}--></span> 
     72                    <em>お届け日:</em> 
     73                    <!--{if !$arrDelivDate}--> 
     74                        ご指定頂けません。 
     75                    <!--{else}--> 
     76                        <select name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"> 
     77                            <option value="" selected="">指定なし</option> 
     78                            <!--{html_options options=$arrDelivDate selected=$arrForm[$key].value}--> 
     79                        </select> 
     80                    <!--{/if}--> 
     81                    <!--★お届け時間★--> 
     82                    <!--{assign var=key value="deliv_time_id"}--> 
     83                    <span class="attention"><!--{$arrErr[$key]}--></span> 
     84                    <em>お届け時間:</em> 
     85                    <select name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"> 
     86                        <option value="" selected="">指定なし</option> 
     87                        <!--{html_options options=$arrDelivTime selected=$arrForm[$key].value}--> 
     88                    </select> 
     89                 </div> 
     90            </div> 
     91 
     92            <div class="payarea02"> 
     93                <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle03.gif" width="670" height="33" alt="その他お問い合わせ" /></h3> 
     94                <p>その他お問い合わせ事項がございましたら、こちらにご入力ください。</p> 
     95                <div> 
     96                    <!--★その他お問い合わせ事項★--> 
     97                    <!--{assign var=key value="message"}--> 
     98                    <span class="attention"><!--{$arrErr[$key]}--></span> 
     99                    <textarea name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" cols="80" rows="8" class="area660" wrap="head"><!--{$arrForm[$key].value|escape}--></textarea> 
     100                    <span class="attention"> (<!--{$smarty.const.LTEXT_LEN}-->文字まで)</span> 
     101                </div> 
     102            </div> 
     103 
     104            <!-- ▼ポイント使用 ここから --> 
     105            <!--{if $tpl_login == 1 && $smarty.const.USE_POINT !== false}--> 
     106                <div class="pointarea"> 
     107                    <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle_point.jpg" width="670" height="32" alt="ポイント使用の指定" /></h3> 
     108 
     109                        <p><span class="attention">1ポイントを1円</span>として使用する事ができます。<br /> 
     110                            使用する場合は、「ポイントを使用する」にチェックを入れた後、使用するポイントをご記入ください。</p> 
     111                    <div> 
     112                        <p><!--{$objCustomer->getValue('name01')|escape}--> <!--{$objCustomer->getValue('name02')|escape}-->様の、現在の所持ポイントは「<em><!--{$tpl_user_point|default:0}-->Pt</em>」です。</p> 
     113                        <p>今回ご購入合計金額:<span class="price"><!--{$arrData.subtotal|number_format}-->円</span><span class="attention">(送料、手数料を含みません。)</span></p> 
     114                        <ul> 
     115                            <li><input type="radio" id="point_on" name="point_check" value="1" <!--{$arrForm.point_check.value|sfGetChecked:1}--> onclick="fnCheckInputPoint();" /><label for="point_on">ポイントを使用する</label></li> 
     116                             <!--{assign var=key value="use_point"}--> 
     117 
     118                             <li class="underline">今回のお買い物で、<input type="text" name="<!--{$key}-->" value="<!--{$arrForm[$key].value|default:$tpl_user_point}-->" maxlength="<!--{$arrForm[$key].length}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" size="6" class="box60" />&nbsp;ポイントを使用する。<span class="attention"><!--{$arrErr[$key]}--></span></li> 
     119                             <li><input type="radio" id="point_off" name="point_check" value="2" <!--{$arrForm.point_check.value|sfGetChecked:2}--> onclick="fnCheckInputPoint();" /><label for="point_off">ポイントを使用しない</label></li> 
     120                        </ul> 
     121                    </div> 
     122                </div> 
    57123            <!--{/if}--> 
    58           </tr> 
    59           <!--{/section}--> 
    60         </table> 
    61       </div> 
     124            <!-- ▲ポイント使用 ここまで --> 
    62125 
    63       <div class="payarea02"> 
    64         <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle02.gif" width="670" height="33" alt="お届け時間の指定" /></h3> 
    65         <p>ご希望の方は、お届け時間を選択してください。</p> 
    66         <div> 
    67           <!--★お届け日★--> 
    68           <!--{assign var=key value="deliv_date"}--> 
    69           <span class="attention"><!--{$arrErr[$key]}--></span> 
    70           <em>お届け日:</em> 
    71           <!--{if !$arrDelivDate}--> 
    72             ご指定頂けません。 
    73           <!--{else}--> 
    74             <select name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"> 
    75               <option value="" selected="">指定なし</option> 
    76               <!--{html_options options=$arrDelivDate selected=$arrForm[$key].value}--> 
    77             </select> 
    78           <!--{/if}--> 
    79           <!--★お届け時間★--> 
    80           <!--{assign var=key value="deliv_time_id"}--> 
    81           <span class="attention"><!--{$arrErr[$key]}--></span> 
    82           <em>お届け時間:</em> 
    83           <select name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->"> 
    84             <option value="" selected="">指定なし</option> 
    85             <!--{html_options options=$arrDelivTime selected=$arrForm[$key].value}--> 
    86           </select> 
    87          </div> 
    88       </div> 
    89  
    90       <div class="payarea02"> 
    91         <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle03.gif" width="670" height="33" alt="その他お問い合わせ" /></h3> 
    92         <p>その他お問い合わせ事項がございましたら、こちらにご入力ください。</p> 
    93         <div> 
    94          <!--★その他お問い合わせ事項★--> 
    95          <!--{assign var=key value="message"}--> 
    96          <span class="attention"><!--{$arrErr[$key]}--></span> 
    97          <textarea name="<!--{$key}-->"  style="<!--{$arrErr[$key]|sfGetErrorColor}-->" cols="80" rows="8" class="area660" wrap="head"><!--{$arrForm[$key].value|escape}--></textarea> 
    98          <span class="attention"> (<!--{$smarty.const.LTEXT_LEN}-->文字まで)</span> 
    99         </div> 
    100       </div> 
    101  
    102       <!-- ▼ポイント使用 ここから --> 
    103       <!--{if $tpl_login == 1 && $smarty.const.USE_POINT !== false}--> 
    104         <div class="pointarea"> 
    105           <h3><img src="<!--{$TPL_DIR}-->img/shopping/subtitle_point.jpg" width="670" height="32" alt="ポイント使用の指定" /></h3> 
    106  
    107             <p><span class="attention">1ポイントを1円</span>として使用する事ができます。<br /> 
    108               使用する場合は、「ポイントを使用する」にチェックを入れた後、使用するポイントをご記入ください。</p> 
    109           <div> 
    110             <p><!--{$objCustomer->getValue('name01')|escape}--> <!--{$objCustomer->getValue('name02')|escape}-->様の、現在の所持ポイントは「<em><!--{$tpl_user_point|default:0}-->Pt</em>」です。</p> 
    111             <p>今回ご購入合計金額:<span class="price"><!--{$arrData.subtotal|number_format}-->円</span><span class="attention">(送料、手数料を含みません。)</span></p> 
    112             <ul> 
    113               <li><input type="radio" id="point_on" name="point_check" value="1" <!--{$arrForm.point_check.value|sfGetChecked:1}--> onclick="fnCheckInputPoint();" /><label for="point_on">ポイントを使用する</label></li> 
    114                <!--{assign var=key value="use_point"}--> 
    115  
    116                <li class="underline">今回のお買い物で、<input type="text" name="<!--{$key}-->" value="<!--{$arrForm[$key].value|default:$tpl_user_point}-->" maxlength="<!--{$arrForm[$key].length}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->" size="6" class="box60" />&nbsp;ポイントを使用する。<span class="attention"><!--{$arrErr[$key]}--></span></li> 
    117                <li><input type="radio" id="point_off" name="point_check" value="2" <!--{$arrForm.point_check.value|sfGetChecked:2}--> onclick="fnCheckInputPoint();" /><label for="point_off">ポイントを使用しない</label></li> 
    118              </ul> 
    119           </div> 
    120         </div> 
    121       <!--{/if}--> 
    122       <!-- ▲ポイント使用 ここまで --> 
    123  
    124       <div class="tblareabtn"> 
    125         <a href="<!--{$tpl_back_url|escape}-->" onmouseover="chgImg('<!--{$TPL_DIR}-->img/common/b_back_on.gif','back03')" onmouseout="chgImg('<!--{$TPL_DIR}-->img/common/b_back.gif','back03')"> 
    126           <img src="<!--{$TPL_DIR}-->img/common/b_back.gif" width="150" height="30" alt="戻る" border="0" name="back03" id="back03" /></a>&nbsp; 
    127         <input type="image" onmouseover="chgImgImageSubmit('<!--{$TPL_DIR}-->img/common/b_next_on.gif',this)" onmouseout="chgImgImageSubmit('<!--{$TPL_DIR}-->img/common/b_next.gif',this)" src="<!--{$TPL_DIR}-->img/common/b_next.gif" class="box150" alt="次へ" name="next" id="next" /> 
    128       </div> 
    129     </form> 
    130   </div> 
     126            <div class="tblareabtn"> 
     127                <a href="<!--{$tpl_back_url|escape}-->" onmouseover="chgImg('<!--{$TPL_DIR}-->img/common/b_back_on.gif','back03')" onmouseout="chgImg('<!--{$TPL_DIR}-->img/common/b_back.gif','back03')"> 
     128                    <img src="<!--{$TPL_DIR}-->img/common/b_back.gif" width="150" height="30" alt="戻る" border="0" name="back03" id="back03" /></a>&nbsp; 
     129                <input type="image" onmouseover="chgImgImageSubmit('<!--{$TPL_DIR}-->img/common/b_next_on.gif',this)" onmouseout="chgImgImageSubmit('<!--{$TPL_DIR}-->img/common/b_next.gif',this)" src="<!--{$TPL_DIR}-->img/common/b_next.gif" class="box150" alt="次へ" name="next" id="next" /> 
     130            </div> 
     131        </form> 
     132    </div> 
    131133</div> 
    132134<!--▲CONTENTS--> 
  • branches/comu-ver2/data/class/pages/shopping/LC_Page_Shopping_Payment.php

    r18275 r18311  
    148148        // 支払い方法の取得 
    149149        $this->arrPayment = $this->lfGetPayment($total_pretax); 
     150        // 支払い方法の画像があるなしを取得($img_show true:ある false:なし) 
     151        $this->img_show = $this->lfGetImgShow($this->arrPayment); 
    150152        // お届け時間の取得 
    151153        $arrRet = $objDb->sfGetDelivTime($this->objFormParam->getValue('payment_id')); 
     
    534536        return $this->objFormParam; 
    535537    } 
     538 
     539    /* 支払い方法の画像があるなしを取得($img_show true:ある false:なし) */ 
     540    function lfGetImgShow($arrPayment) { 
     541        $img_show = false; 
     542        foreach ($this->arrPayment as $payment) { 
     543            if (strlen($payment["payment_image"]) > 0 ){ 
     544                $img_show = true; 
     545                break; 
     546            } 
     547        } 
     548        return $img_show; 
     549    } 
    536550} 
    537551?> 
Note: See TracChangeset for help on using the changeset viewer.