source: branches/comu-ver2/data/Smarty/templates/default/admin/products/index.tpl @ 17364

Revision 17364, 11.9 KB checked in by Seasoft, 14 years ago (diff)

XHTML管理画面の不具合修正

  • Property svn:eol-style set to LF
  • Property svn:mime-type set to text/html; charset=UTF-8
Line 
1<!--{*
2/*
3 * This file is part of EC-CUBE
4 *
5 * Copyright(c) 2000-2008 LOCKON CO.,LTD. All Rights Reserved.
6 *
7 * http://www.lockon.co.jp/
8 *
9 * This program is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU General Public License
11 * as published by the Free Software Foundation; either version 2
12 * of the License, or (at your option) any later version.
13 *
14 * This program is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17 * GNU General Public License for more details.
18 *
19 * You should have received a copy of the GNU General Public License
20 * along with this program; if not, write to the Free Software
21 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
22 */
23*}-->
24<script type="text/javascript">
25// URLの表示非表示切り替え
26function lfnDispChange(){
27  inner_id = 'switch';
28
29  cnt = document.form1.item_cnt.value;
30 
31  if($('#disp_url1').css("display") == 'none'){
32    for (i = 1; i <= cnt; i++) {
33      disp_id = 'disp_url'+i;
34      $('#' + disp_id).css("display", "");
35 
36      disp_id = 'disp_cat'+i;
37      $('#' + disp_id).css("display", "none");
38     
39      $('#' + inner_id).html('  URL <a href="#" onClick="lfnDispChange();"> >> カテゴリ表示<\/a>');
40    }
41  }else{
42    for (i = 1; i <= cnt; i++) {
43      disp_id = 'disp_url'+i;
44      $('#' + disp_id).css("display", "none");
45 
46      disp_id = 'disp_cat'+i;
47      $('#' + disp_id).css("display", "");
48     
49      $('#' + inner_id).html('  カテゴリ <a href="#" onClick="lfnDispChange();"> >> URL表示<\/a>');
50    }
51  }
52
53}
54
55</script>
56
57
58<div id="products" class="contents-main">
59<form name="search_form" id="search_form" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
60  <input type="hidden" name="mode" value="search" />
61  <!--{foreach key=key item=item from=$arrHidden}-->
62  <!--{if $key == 'campaign_id' || $key == 'search_mode'}-->
63  <input type="hidden" name="<!--{$key}-->" value="<!--{$item|escape}-->" />
64  <!--{/if}-->
65  <!--{/foreach}-->
66  <h2>検索条件設定</h2>
67
68  <!--検索条件設定テーブルここから-->
69  <table>
70    <tr>
71      <th>商品ID</th>
72      <td>
73        <!--{if $arrErr.search_product_id}-->
74        <span class="attention"><!--{$arrErr.search_product_id}--></span>
75        <!--{/if}-->
76        <input type="text" name="search_product_id" value="<!--{$arrForm.search_product_id|escape}-->" size="30" class="box30" style="<!--{$arrErr.search_product_id|sfGetErrorColor}-->"/>
77      </td>
78    </tr>
79    <tr>
80      <th>商品コード</th>
81      <td><input type="text" name="search_product_code" value="<!--{$arrForm.search_product_code|escape}-->" size="30" class="box30" /></td>
82    </tr>
83    <tr>
84      <th>カテゴリ</th>
85      <td>
86        <select name="search_category_id" style="<!--{if $arrErr.search_category_id != ""}-->background-color: <!--{$smarty.const.ERR_COLOR}--><!--{/if}-->">
87        <option value="">選択してください</option>
88        <!--{html_options options=$arrCatList selected=$arrForm.search_category_id}-->
89        </select>
90      </td>
91    </tr>
92    <tr>
93      <th>規格名称</th>
94      <td>
95        <!--{if $arrErr.search_product_class_name}-->
96        <span class="attention"><!--{$arrErr.search_product_class_name}--></span>
97        <!--{/if}-->
98        <input type="text" name="search_product_class_name" value="<!--{$arrForm.search_product_class_name|escape}-->" size="30" class="box30"style="<!--{$arrErr.search_product_class_name|sfGetErrorColor}-->" />
99      </td>
100    </tr>
101    <tr>
102      <th>商品名</th>
103      <td><input type="text" name="search_name" value="<!--{$arrForm.search_name|escape}-->" size="30" class="box30" /></td>
104    </tr>
105    <tr>
106      <th>種別</th>
107      <td><!--{html_checkboxes name="search_status" options=$arrDISP selected=$arrForm.search_status}--></td>
108    </tr>
109    <tr>
110      <th>登録・更新日</th>
111      <td>
112        <!--{if $arrErr.search_startyear || $arrErr.search_endyear}-->
113        <span class="attention"><!--{$arrErr.search_startyear}--></span>
114        <span class="attention"><!--{$arrErr.search_endyear}--></span>
115        <!--{/if}-->
116        <select name="search_startyear" style="<!--{$arrErr.search_startyear|sfGetErrorColor}-->">
117        <option value="">----</option>
118        <!--{html_options options=$arrStartYear selected=$arrForm.search_startyear}-->
119        </select>年
120        <select name="search_startmonth" style="<!--{$arrErr.search_startyear|sfGetErrorColor}-->">
121        <option value="">--</option>
122        <!--{html_options options=$arrStartMonth selected=$arrForm.search_startmonth}-->
123        </select>月
124        <select name="search_startday" style="<!--{$arrErr.search_startyear|sfGetErrorColor}-->">
125        <option value="">--</option>
126        <!--{html_options options=$arrStartDay selected=$arrForm.search_startday}-->
127        </select>日~
128        <select name="search_endyear" style="<!--{$arrErr.search_endyear|sfGetErrorColor}-->">
129        <option value="">----</option>
130        <!--{html_options options=$arrEndYear selected=$arrForm.search_endyear}-->
131        </select>年
132        <select name="search_endmonth" style="<!--{$arrErr.search_endyear|sfGetErrorColor}-->">
133        <option value="">--</option>
134        <!--{html_options options=$arrEndMonth selected=$arrForm.search_endmonth}-->
135        </select>月
136        <select name="search_endday" style="<!--{$arrErr.search_endyear|sfGetErrorColor}-->">
137        <option value="">--</option>
138        <!--{html_options options=$arrEndDay selected=$arrForm.search_endday}-->
139        </select>日
140      </td>
141    </tr>
142    <tr>
143      <th>ステータス</th>
144      <td>
145      <!--{html_checkboxes name="search_product_flag" options=$arrSTATUS selected=$arrForm.search_product_flag}-->
146      </td>
147    </tr>
148  </table>
149  <div class="btn">
150    検索結果表示件数
151    <!--{assign var=key value="search_page_max"}-->
152    <!--{if $arrErr[$key]}-->
153    <span class="attention"><!--{$arrErr[$key]}--></span>
154    <!--{/if}-->
155    <select name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->">
156    <!--{html_options options=$arrPageMax selected=$arrForm.search_page_max}-->
157    </select> 件
158    <button type="submit"><span>この条件で検索する</span></button>
159  </div>
160  <!--検索条件設定テーブルここまで-->
161</form> 
162
163
164<!--{if count($arrErr) == 0 and ($smarty.post.mode == 'search' or $smarty.post.mode == 'delete')}-->
165
166<!--★★検索結果一覧★★-->
167<form name="form1" id="form1" method="post" action="<!--{$smarty.server.PHP_SELF|escape}-->">
168  <input type="hidden" name="mode" value="search" />
169  <input type="hidden" name="product_id" value="" />
170  <input type="hidden" name="category_id" value="" />
171  <!--{foreach key=key item=item from=$arrHidden}-->
172  <input type="hidden" name="<!--{$key}-->" value="<!--{$item|escape}-->" />
173  <!--{/foreach}--> 
174  <h2>検索結果一覧</h2>
175  <p>
176    <span class="attention"><!--検索結果数--><!--{$tpl_linemax}-->件</span>&nbsp;が該当しました。
177    <!--検索結果-->
178    <!--{if $smarty.const.ADMIN_MODE == '1'}-->
179    <button type="button" onclick="fnModeSubmit('delete_all','','');"><span>検索結果をすべて削除</span></button>
180    <!--{/if}-->
181    <button type="button" onclick="fnModeSubmit('csv','','');"><span>CSV DOWNLOAD</span></button>
182    <a href="../contents/csv.php?tpl_subno_csv=product"> >> CSV出力項目設定</a>
183  </p>
184  <!--{include file=$tpl_pager}-->
185
186  <!--{if count($arrProducts) > 0}-->
187  <!--検索結果表示テーブル-->
188  <table class="list" id="products-search-result">
189    <tr>
190      <th rowspan="2">商品ID</th>
191      <th rowspan="2">商品画像</th>
192      <th rowspan="2">商品コード</th>
193      <th rowspan="2">価格(円)</th>
194      <th>商品名</th>
195      <th rowspan="2">在庫</th>
196      <th rowspan="2">種別</th>
197      <th rowspan="2">編集</th>
198      <th rowspan="2">確認</th>
199      <!--{if $smarty.const.OPTION_CLASS_REGIST == 1}-->
200      <th rowspan="2">規格</th>
201      <!--{/if}-->
202      <th rowspan="2">削除</th>
203      <th rowspan="2">複製</th>
204    </tr>
205    <tr>
206      <th><a href="#" onClick="lfnDispChange(); return false;">カテゴリ ⇔ URL</a></th>
207    </tr>
208
209    <!--{section name=cnt loop=$arrProducts}-->
210    <!--▼商品<!--{$smarty.section.cnt.iteration}-->-->
211    <!--{assign var=status value="`$arrProducts[cnt].status`"}-->
212    <tr style="background:<!--{$arrPRODUCTSTATUS_COLOR[$status]}-->;">
213      <td rowspan="2"><!--{$arrProducts[cnt].product_id}--></td>
214      <td rowspan="2">
215        <!--{if $arrProducts[cnt].main_list_image != ""}-->
216          <!--{assign var=image_path value="`$arrProducts[cnt].main_list_image`"}-->
217        <!--{else}-->
218          <!--{assign var=image_path value="`$smarty.const.NO_IMAGE_DIR`"}-->
219        <!--{/if}-->
220      <img src="<!--{$smarty.const.SITE_URL}-->resize_image.php?image=<!--{$image_path|sfRmDupSlash}-->&amp;width=65&amp;height=65">
221      </td>
222      <td rowspan="2"><!--{$arrProducts[cnt].product_code|escape|default:"-"}--></td>
223      <td rowspan="2" class="right">
224        <!--{* 価格 *}-->
225        <!--{if $arrProducts[cnt].price02 != ""}-->
226        <!--{$arrProducts[cnt].price02|number_format}-->
227        <!--{else}-->
228        -
229        <!--{/if}-->
230      </td>
231      <td><!--{$arrProducts[cnt].name|escape}--></td>
232      <td rowspan="2">
233        <!--{* 在庫 *}-->
234        <!--{if $arrProducts[cnt].stock_unlimited == '1'}-->
235        無制限
236        <!--{else}-->
237        <!--{$arrProducts[cnt].stock|escape|default:"-"}-->
238        <!--{/if}-->
239      </td>
240      <!--{* 表示 *}-->
241      <!--{assign var=key value=$arrProducts[cnt].status}-->
242      <td rowspan="2"><!--{$arrDISP[$key]}--></td>
243      <td rowspan="2"><span class="icon_edit"><a href="<!--{$smarty.const.URL_DIR}-->" onclick="fnChangeAction('./product.php'); fnModeSubmit('pre_edit', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;" >編集</a></span></td>
244      <td rowspan="2"><span class="icon_confirm"><a href="<!--{$smarty.const.SITE_URL|sfTrimURL}-->/products/detail.php?product_id=<!--{$arrProducts[cnt].product_id}-->&amp;admin=on" target="_blank">確認</a></span></td>
245      <!--{if $smarty.const.OPTION_CLASS_REGIST == 1}-->
246      <td rowspan="2"><span class="icon_class"><a href="<!--{$smarty.const.URL_DIR}-->" onclick="fnChangeAction('./product_class.php'); fnModeSubmit('pre_edit', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;" >規格</a></span></td>
247      <!--{/if}-->
248      <td rowspan="2"><span class="icon_delete"><a href="<!--{$smarty.const.URL_DIR}-->" onclick="fnSetFormValue('category_id', '<!--{$arrProducts[cnt].category_id}-->'); fnModeSubmit('delete', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;">削除</a></span></td>
249      <td rowspan="2"><span class="icon_copy"><a href="<!--{$smarty.const.URL_DIR}-->" onclick="fnChangeAction('./product.php'); fnModeSubmit('copy', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;" >複製</a></span></td>
250    </tr>
251    <tr>
252      <td>
253        <!--{* カテゴリ名 *}-->
254        <div id="disp_cat<!--{$smarty.section.cnt.iteration}-->" style="display:<!--{$cat_flg}-->">
255          <!--{foreach from=$arrProducts[cnt].categories item=category_id name=categories}-->
256            <!--{$arrCatList[$category_id]|sfTrim}-->
257            <!--{if !$smarty.foreach.categories.last}--><br /><!--{/if}-->
258          <!--{/foreach}-->
259        </div>
260
261        <!--{* URL *}-->
262        <div id="disp_url<!--{$smarty.section.cnt.iteration}-->" style="display:none">
263        <!--{$smarty.const.SITE_URL|sfTrimURL}-->/products/detail.php?product_id=<!--{$arrProducts[cnt].product_id}-->
264        </div>
265      </td>
266    </tr>
267    <!--▲商品<!--{$smarty.section.cnt.iteration}-->-->
268    <!--{/section}-->
269  </table>
270  <input type="hidden" name="item_cnt" value="<!--{$arrProducts|@count}-->" />
271  <!--検索結果表示テーブル-->
272  <!--{/if}-->
273
274</form>
275
276<!--★★検索結果一覧★★-->   
277<!--{/if}-->
278</div>
Note: See TracBrowser for help on using the repository browser.