source: branches/version-2_5-dev/data/Smarty/templates/admin/products/index.tpl @ 19909

Revision 19909, 12.6 KB checked in by uemoto, 13 years ago (diff)

#382(管理画面XHTMLに変更)

  • デザインを刷新
  • Property svn:eol-style set to LF
  • Property svn:mime-type set to text/x-smarty-template; charset=UTF-8
Line 
1<!--{*
2/*
3 * This file is part of EC-CUBE
4 *
5 * Copyright(c) 2000-2010 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();"> &gt;&gt; カテゴリ表示<\/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();"> &gt;&gt; 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="?">
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|h}-->" />
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|h}-->" size="30" class="box30" style="<!--{$arrErr.search_product_id|sfGetErrorColor}-->"/>
77      </td>
78            <th>規格名称</th>
79            <td>
80        <!--{if $arrErr.search_product_class_name}-->
81        <span class="attention"><!--{$arrErr.search_product_class_name}--></span>
82        <!--{/if}-->
83        <input type="text" name="search_product_class_name" value="<!--{$arrForm.search_product_class_name|h}-->" size="30" class="box30"style="<!--{$arrErr.search_product_class_name|sfGetErrorColor}-->" />
84      </td>
85    </tr>
86    <tr>
87      <th>商品コード</th>
88      <td><input type="text" name="search_product_code" value="<!--{$arrForm.search_product_code|h}-->" size="30" class="box30" /></td>
89      <th>商品名</th>
90      <td><input type="text" name="search_name" value="<!--{$arrForm.search_name|h}-->" size="30" class="box30" /></td>
91    </tr>
92    <tr>
93      <th>カテゴリ</th>
94      <td>
95        <select name="search_category_id" style="<!--{if $arrErr.search_category_id != ""}-->background-color: <!--{$smarty.const.ERR_COLOR}-->;<!--{/if}-->">
96        <option value="">選択してください</option>
97        <!--{html_options options=$arrCatList selected=$arrForm.search_category_id}-->
98        </select>
99      </td>
100      <th>種別</th>
101      <td><!--{html_checkboxes name="search_status" options=$arrDISP selected=$arrForm.search_status}--></td>
102    </tr>
103    <tr>
104      <th>登録・更新日</th>
105      <td colspan="3">
106        <!--{if $arrErr.search_startyear || $arrErr.search_endyear}-->
107        <span class="attention"><!--{$arrErr.search_startyear}--></span>
108        <span class="attention"><!--{$arrErr.search_endyear}--></span>
109        <!--{/if}-->
110        <select name="search_startyear" style="<!--{$arrErr.search_startyear|sfGetErrorColor}-->">
111        <option value="">----</option>
112        <!--{html_options options=$arrStartYear selected=$arrForm.search_startyear}-->
113        </select>年
114        <select name="search_startmonth" style="<!--{$arrErr.search_startyear|sfGetErrorColor}-->">
115        <option value="">--</option>
116        <!--{html_options options=$arrStartMonth selected=$arrForm.search_startmonth}-->
117        </select>月
118        <select name="search_startday" style="<!--{$arrErr.search_startyear|sfGetErrorColor}-->">
119        <option value="">--</option>
120        <!--{html_options options=$arrStartDay selected=$arrForm.search_startday}-->
121        </select>日~
122        <select name="search_endyear" style="<!--{$arrErr.search_endyear|sfGetErrorColor}-->">
123        <option value="">----</option>
124        <!--{html_options options=$arrEndYear selected=$arrForm.search_endyear}-->
125        </select>年
126        <select name="search_endmonth" style="<!--{$arrErr.search_endyear|sfGetErrorColor}-->">
127        <option value="">--</option>
128        <!--{html_options options=$arrEndMonth selected=$arrForm.search_endmonth}-->
129        </select>月
130        <select name="search_endday" style="<!--{$arrErr.search_endyear|sfGetErrorColor}-->">
131        <option value="">--</option>
132        <!--{html_options options=$arrEndDay selected=$arrForm.search_endday}-->
133        </select>日
134      </td>
135    </tr>
136    <tr>
137      <th>ステータス</th>
138      <td colspan="3">
139      <!--{html_checkboxes name="search_product_flag" options=$arrSTATUS selected=$arrForm.search_product_flag}-->
140      </td>
141    </tr>
142  </table>
143  <div class="btn">
144    検索結果表示件数
145    <!--{assign var=key value="search_page_max"}-->
146    <!--{if $arrErr[$key]}-->
147    <span class="attention"><!--{$arrErr[$key]}--></span>
148    <!--{/if}-->
149    <select name="<!--{$key}-->" style="<!--{$arrErr[$key]|sfGetErrorColor}-->">
150    <!--{html_options options=$arrPageMax selected=$arrForm.search_page_max}-->
151    </select> 件
152
153    <div class="btn-area">
154        <ul>
155            <li><a class="btn-action" href="javascript:;" onclick="fnFormModeSubmit('search_form', 'search', '', '');"><span class="btn-next">この条件で検索する</span></a></li>
156        </ul>
157    </div>
158
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="?">
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|h}-->" />
173  <!--{/foreach}--> 
174  <h2>検索結果一覧</h2>
175  <div class="btn">
176    <span class="attention"><!--検索結果数--><!--{$tpl_linemax}-->件</span>&nbsp;が該当しました。
177    <!--検索結果-->
178    <!--{if $smarty.const.ADMIN_MODE == '1'}-->
179    <a class="btn-normal" href="javascript:;" onclick="fnModeSubmit('delete_all','','');">検索結果をすべて削除</a>
180    <!--{/if}-->
181    <a class="btn-tool" href="javascript:;" onclick="fnModeSubmit('csv','','');">CSV ダウンロード</a>
182    <a class="btn-tool" href="../contents/csv.php?tpl_subno_csv=product">CSV 出力項目設定</a>
183  </div>
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 nowrap><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 class="id" rowspan="2"><!--{$arrProducts[cnt].product_id}--></td>
214      <td class="thumbnail" rowspan="2">
215      <img src="<!--{$smarty.const.URL_PATH}-->resize_image.php?image=<!--{$arrProducts[cnt].main_list_image|sfNoImageMainList|h}-->&amp;width=65&amp;height=65">      </td>
216      <td rowspan="2"><!--{$arrProducts[cnt].product_code_min|h}-->
217        <!--{if $arrProducts[cnt].product_code_min != $arrProducts[cnt].product_code_max}-->
218          <br />~ <!--{$arrProducts[cnt].product_code_max|h}-->
219        <!--{/if}-->      </td>
220      <!--{* 価格 *}-->
221      <td rowspan="2" class="right">
222        <!--{$arrProducts[cnt].price02_min|number_format}-->
223        <!--{if $arrProducts[cnt].price02_min != $arrProducts[cnt].price02_max}-->
224          <br />~ <!--{$arrProducts[cnt].price02_max|number_format}-->
225        <!--{/if}-->      </td>
226      <td><!--{$arrProducts[cnt].name|h}--></td>
227      <!--{* 在庫 *}-->
228      <!--{* XXX 複数規格でかつ、全ての在庫数量が等しい場合は先頭に「各」と入れたれたら良いと思う。 *}-->
229      <td class="menu" rowspan="2">
230        <!--{if $arrProducts[cnt].stock_unlimited_min}-->無制限<!--{else}--><!--{$arrProducts[cnt].stock_min|number_format}--><!--{/if}-->
231        <!--{if $arrProducts[cnt].stock_unlimited_min != $arrProducts[cnt].stock_unlimited_max || $arrProducts[cnt].stock_min != $arrProducts[cnt].stock_max}-->
232          <br />~ <!--{if $arrProducts[cnt].stock_unlimited_max}-->無制限<!--{else}--><!--{$arrProducts[cnt].stock_max|number_format}--><!--{/if}-->
233        <!--{/if}-->      </td>
234      <!--{* 表示 *}-->
235      <!--{assign var=key value=$arrProducts[cnt].status}-->
236      <td class="menu" rowspan="2"><!--{$arrDISP[$key]}--></td>
237      <td class="menu" rowspan="2"><span class="icon_edit"><a href="<!--{$smarty.const.URL_PATH}-->" onclick="fnChangeAction('./product.php'); fnModeSubmit('pre_edit', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;" >編集</a></span></td>
238      <td class="menu" rowspan="2"><span class="icon_confirm"><a href="<!--{$smarty.const.HTTP_URL|sfTrimURL}-->/products/detail.php?product_id=<!--{$arrProducts[cnt].product_id}-->&amp;admin=on" target="_blank">確認</a></span></td>
239      <!--{if $smarty.const.OPTION_CLASS_REGIST == 1}-->
240      <td class="menu" rowspan="2"><span class="icon_class"><a href="<!--{$smarty.const.URL_PATH}-->" onclick="fnChangeAction('./product_class.php'); fnModeSubmit('pre_edit', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;" >規格</a></span></td>
241      <!--{/if}-->
242      <td class="menu" rowspan="2"><span class="icon_delete"><a href="<!--{$smarty.const.URL_PATH}-->" onclick="fnSetFormValue('category_id', '<!--{$arrProducts[cnt].category_id}-->'); fnModeSubmit('delete', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;">削除</a></span></td>
243      <td class="menu" rowspan="2"><span class="icon_copy"><a href="<!--{$smarty.const.URL_PATH}-->" onclick="fnChangeAction('./product.php'); fnModeSubmit('copy', 'product_id', <!--{$arrProducts[cnt].product_id}-->); return false;" >複製</a></span></td>
244    </tr>
245    <tr style="background:<!--{$arrPRODUCTSTATUS_COLOR[$status]}-->;">
246      <td>
247        <!--{* カテゴリ名 *}-->
248        <div id="disp_cat<!--{$smarty.section.cnt.iteration}-->" style="display:<!--{$cat_flg}-->">
249          <!--{foreach from=$arrProducts[cnt].categories item=category_id name=categories}-->
250            <!--{$arrCatList[$category_id]|sfTrim}-->
251            <!--{if !$smarty.foreach.categories.last}--><br /><!--{/if}-->
252          <!--{/foreach}-->
253        </div>
254
255        <!--{* URL *}-->
256        <div id="disp_url<!--{$smarty.section.cnt.iteration}-->" style="display:none">
257        <!--{$smarty.const.HTTP_URL|sfTrimURL}-->/products/detail.php?product_id=<!--{$arrProducts[cnt].product_id}-->
258        </div>      </td>
259    </tr>
260    <!--▲商品<!--{$smarty.section.cnt.iteration}-->-->
261    <!--{/section}-->
262  </table>
263  <input type="hidden" name="item_cnt" value="<!--{$arrProducts|@count}-->" />
264  <!--検索結果表示テーブル-->
265  <!--{/if}-->
266
267</form>
268
269<!--★★検索結果一覧★★-->   
270<!--{/if}-->
271</div>
Note: See TracBrowser for help on using the repository browser.