| 1 |
<?php include_once( "../../../spider.inc.php" ); ?> |
| 2 |
{charset:UTF-8} |
| 3 |
{template:admin_default.tpl} |
| 4 |
{module:system.login.Require} |
| 5 |
{module:shopping.category.LoadList} |
| 6 |
{module:shopping.product.LoadList} |
| 7 |
{module:shopping.promotion.LoadList get(pr=1000)} |
| 8 |
{preset:page_title 'ショップ管理 > ' . SHOPPING_LABEL_PRODUCT . 'の一覧と検索'} |
| 9 |
|
| 10 |
<div class="panc"> |
| 11 |
{if:is_object(shopping.product.searchDataObject)} |
| 12 |
<a href="../../">管理パネルトップ</a> |
| 13 |
> <a href="../../search/data/detail.php?schdi={write:shopping.product.searchDataObject->'data_id'}">{write:shopping.product.searchDataObject->'subject'}</a> |
| 14 |
{else} |
| 15 |
<a href="../../">管理パネルトップ</a> |
| 16 |
> <a href="../">ショップ管理</a> |
| 17 |
{/if} |
| 18 |
> {write:SHOPPING_LABEL_PRODUCT}管理 |
| 19 |
</div> |
| 20 |
|
| 21 |
<h1> |
| 22 |
ショップ管理 > |
| 23 |
{if:is_object(shopping.product.searchDataObject)} |
| 24 |
{write:shopping.product.searchDataObject->'subject'}の |
| 25 |
{/if} |
| 26 |
{write:SHOPPING_LABEL_PRODUCT}一覧と検索 |
| 27 |
</h1> |
| 28 |
{if:is_object(shopping.product.searchDataObject)} |
| 29 |
<div style="width:95%;margin:0 auto;text-align:right;"> |
| 30 |
<a href="../../search/data/detail.php?schdi={write:shopping.product.searchDataObject->'data_id'}">{write:shopping.product.searchDataObject->'subject'}の詳細に戻る</a> |
| 31 |
</div> |
| 32 |
{/if} |
| 33 |
<style type="text/css"> |
| 34 |
<!-- |
| 35 |
.status_0 { background-color: #FFdddd; } |
| 36 |
.status_91 { background-color: #d0d0d0; } |
| 37 |
.status_101 { }; |
| 38 |
//--> |
| 39 |
</style> |
| 40 |
|
| 41 |
{if:IS_ERROR} |
| 42 |
<h2>エラー</h2> |
| 43 |
<ul class="error"> |
| 44 |
{foreach:errors error} |
| 45 |
<li>{write:error}</li> |
| 46 |
{/foreach} |
| 47 |
</ul> |
| 48 |
{/if} |
| 49 |
|
| 50 |
<form name="sform" action="./index.php" method="get"> |
| 51 |
<input type="hidden" name="pn" value="{write:shopping.product.page_number}" /> |
| 52 |
{if:is_object(shopping.product.searchDataObject)} |
| 53 |
<input type="hidden" name="schdi" value="{write:shopping.product.searchDataObject->'data_id'}" /> |
| 54 |
{/if} |
| 55 |
<table style="margin:0 auto;width:96%;"> |
| 56 |
<tbody> |
| 57 |
<tr> |
| 58 |
<td style="line-height:2em;vertical-align:top;"> |
| 59 |
カテゴリ:<select name="shpci" onchange="document.sform.submit();"> |
| 60 |
<option value=""{if:count(shopping.product.category_id_array)=0} selected{/if}>全て</option> |
| 61 |
{foreach:shopping.category.data_array num categoryObject} |
| 62 |
{set:childCategoryArray categoryObject->'child_category_object_array'} |
| 63 |
<option value="{write:categoryObject->'category_id'}" |
| 64 |
{if:in_array(categoryObject->'category_id',shopping.product.category_id_array)} selected{/if} |
| 65 |
>{write:categoryObject->'category_name'}({write:categoryObject->getTotalItemCount()})</option> |
| 66 |
{foreach:childCategoryArray childCategoryObject} |
| 67 |
{set:grandChildCategoryArray childCategoryObject->'child_category_object_array'} |
| 68 |
<option value="{write:childCategoryObject->'category_id'}" |
| 69 |
{if:in_array(childCategoryObject->'category_id',shopping.product.category_id_array)} selected{/if} |
| 70 |
> {if:childCategoryArray_loop_counter==count(childCategoryArray)}┗{else}┣{/if} {write:childCategoryObject->'category_name'}({write:childCategoryObject->getTotalItemCount()})</option> |
| 71 |
{foreach:grandChildCategoryArray grandChildCategoryObject} |
| 72 |
<option value="{write:grandChildCategoryObject->'category_id'}" |
| 73 |
{if:in_array(grandChildCategoryObject->'category_id',shopping.product.category_id_array)} selected{/if} |
| 74 |
> {if:grandChildCategoryArray_loop_counter==count(grandChildCategoryArray)}┗{else}┣{/if} {write:grandChildCategoryObject->'category_name'}({write:grandChildCategoryObject->getTotalItemCount()})</option> |
| 75 |
{/foreach} |
| 76 |
{/foreach} |
| 77 |
{/foreach} |
| 78 |
</select> |
| 79 |
<nobr>状態:<select name="shpstf" onchange="document.sform.submit();"> |
| 80 |
<option value=""{if:strlen(shopping.product.status_flag)=0} selected{/if}>全て</option> |
| 81 |
{foreach:SHOPPING_PRODUCT_STATUS_HASH key status_name} |
| 82 |
{if:key<=230} |
| 83 |
<option value="{write:key}" |
| 84 |
{if:key=shopping.product.status_flag and strlen(shopping.product.status_flag)>0} selected{/if} |
| 85 |
>{write:status_name}</option> |
| 86 |
{/if} |
| 87 |
{/foreach} |
| 88 |
</select></nobr> |
| 89 |
<span style="white-space:nowrap;"> |
| 90 |
価格帯:<input type="text" name="shpll" size="6" value="{write:shopping.product.lowerLimit}" />円 |
| 91 |
~ <input type="text" name="shpul" size="6" value="{write:shopping.product.upperLimit}" />円 |
| 92 |
</span> |
| 93 |
<br /> |
| 94 |
<nobr>検索ワード:<input type="text" name="shpq" value="{write:shopping.product.query}" /> <input type="submit" value="検索実行" /></nobr> |
| 95 |
</td> |
| 96 |
<td style="text-align:right;line-height:2em;"> |
| 97 |
<nobr> |
| 98 |
<input type="button" value="{write:SHOPPING_LABEL_PRODUCT}追加" onclick="window.location.href='./form.php{if:is_object(shopping.product.searchDataObject)}?schdi={write:shopping.product.searchDataObject->'data_id'}{/if}'" |
| 99 |
/><input type="button" value="CSVダウンロード" onclick="window.location.href='./download/form.php';" |
| 100 |
/><input type="button" value="CSV登録" onclick="window.location.href='./upload/form.php';" |
| 101 |
/><br /> |
| 102 |
<?php for ( $key=0;$key<=1;$key++ ) { $request_object->setAttribute('key',$key); ?> |
| 103 |
並べ替え項目<?php echo $key+1; ?>:<select name="shpsi[]" onchange="document.sform.submit();"> |
| 104 |
<option value="order"{if:shopping.product.sort_item_array[key]=='order'} selected{/if}>順序</option> |
| 105 |
<option value="reg"{if:shopping.product.sort_item_array[key]=='reg'} selected{/if}>登録日</option> |
| 106 |
<option value="upd"{if:shopping.product.sort_item_array[key]=='upd'} selected{/if}>更新日</option> |
| 107 |
<option value="dname"{if:shopping.product.sort_item_array[key]=='dname'} selected{/if}>{write:SHOPPING_LABEL_PRODUCT}名</option> |
| 108 |
<option value="did"{if:shopping.product.sort_item_array[key]=='did'} selected{/if}>{write:SHOPPING_LABEL_PRODUCT}ID</option> |
| 109 |
</select> |
| 110 |
並び順 <select name="shpso[]" onchange="document.sform.submit();"> |
| 111 |
<option value="asc"{if:shopping.product.sort_order_array[key]='ASC'} selected{/if}>昇順</option> |
| 112 |
<option value="desc"{if:shopping.product.sort_order_array[key]='DESC' or strlen(shopping.product.sort_item_array[key])==0} selected{/if}>降順</option> |
| 113 |
</select><br /> |
| 114 |
<?php } ?> |
| 115 |
ページ表示数:<select name="pr" onchange="document.sform.submit();"> |
| 116 |
<option value="1"{if:shopping.product.page_rows==1} selected{/if}>1</option> |
| 117 |
<option value="5"{if:shopping.product.page_rows==5} selected{/if}>5</option> |
| 118 |
<option value="10"{if:shopping.product.page_rows==10} selected{/if}>10</option> |
| 119 |
<option value="20"{if:shopping.product.page_rows==20} selected{/if}>20</option> |
| 120 |
<option value="50"{if:shopping.product.page_rows==50} selected{/if}>50</option> |
| 121 |
<option value="100"{if:shopping.product.page_rows==100} selected{/if}>100</option> |
| 122 |
</select> |
| 123 |
</nobr> |
| 124 |
</td> |
| 125 |
</tr> |
| 126 |
</tbody> |
| 127 |
</table> |
| 128 |
</form> |
| 129 |
<br /> |
| 130 |
<div style="width:96%;margin:0 auto;"> |
| 131 |
{if:shopping.product.total_page>1} |
| 132 |
{write:shopping.product.total_count}件の検索結果 {write:shopping.product.page_number}/{write:shopping.product.total_page}ページ {write:count(shopping.product.product_array)}件を表示 |
| 133 |
|
| 134 |
{if:shopping.product.page_number-5>1}...{/if} |
| 135 |
<?php for( $GLOBALS['pageNavi']=($GLOBALS['shopping.product.page_number']-5 >= 1 ? $GLOBALS['shopping.product.page_number']-5 : 1); |
| 136 |
$GLOBALS['pageNavi']<=$GLOBALS['shopping.product.total_page'] |
| 137 |
&& $GLOBALS['pageNavi']<=($GLOBALS['shopping.product.page_number']-5 >= 1 ? $GLOBALS['shopping.product.page_number']-5 : 1)+9; |
| 138 |
$GLOBALS['pageNavi']++ ) { ?> |
| 139 |
{if:trim(pageNavi)!=trim(shopping.product.page_number)} |
| 140 |
<a href="javascript:FormerCommon.jumpPage({write:pageNavi})" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">{write:pageNavi}</a> |
| 141 |
{else} |
| 142 |
{write:pageNavi} |
| 143 |
{/if} |
| 144 |
<?php } ?> |
| 145 |
{if:shopping.product.page_number+9 < shopping.product.total_page}...{/if} |
| 146 |
|
| 147 |
{if:shopping.product.page_number-5>1}<a href="javascript:FormerCommon.jumpPage(1)" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">最初</a>{/if} |
| 148 |
{if:shopping.product.page_number+9 < shopping.product.total_page}<a href="javascript:FormerCommon.jumpPage({write:shopping.product.total_page})" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">最後</a>{/if} |
| 149 |
{if:shopping.product.has_prev_page}<a href="javascript:FormerCommon.prevPage()" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">前頁</a>{/if} |
| 150 |
{if:shopping.product.has_next_page}<a href="javascript:FormerCommon.nextPage()" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">次頁</a>{/if} |
| 151 |
{else} |
| 152 |
{write:shopping.product.total_count}件の検索結果 |
| 153 |
{/if} |
| 154 |
</div> |
| 155 |
<table class="list" style="margin:0 auto;width:98%;"> |
| 156 |
<tbody> |
| 157 |
{foreach:shopping.product.product_array product} |
| 158 |
<tr class="status_{write:product->'status_flag'}"> |
| 159 |
<th colspan="2" style="width:100%;"><div style="width:100%;"> |
| 160 |
<div style="width:75%;float:left;"> |
| 161 |
<a href="./detail.php?shpdn={write:product->'product_number'}" |
| 162 |
title="{write:product->'product_name'}の詳細を表示" |
| 163 |
>{write:product->'product_id'}</a> |
| 164 |
: |
| 165 |
{write:product->'product_name'} |
| 166 |
|
| 167 |
<span style="font-size:x-small;"> |
| 168 |
[<a href="/shopping/detail.php?shpdi={write:product->'product_id'}" target="_blank">表示</a>] |
| 169 |
</span> |
| 170 |
</div> |
| 171 |
<div style="width:24%;float:right;text-align:right;white-space:nowrap;"> |
| 172 |
<select name="status_flag_{write:product->'product_number'}" |
| 173 |
onchange="shoppingProductStatusChange({write:product->'product_number'},this.options[this.selectedIndex].value)"> |
| 174 |
{foreach:SHOPPING_PRODUCT_STATUS_HASH key status_name} |
| 175 |
<option value="{write:key}" |
| 176 |
{if:key==product->'status_flag'} selected{/if} |
| 177 |
>{write:status_name}</option> |
| 178 |
{/foreach} |
| 179 |
</select> |
| 180 |
[<a href="./form.php?shpdn={write:product->'product_number'}" |
| 181 |
title="{write:product->'product_name'}の登録情報を編集" |
| 182 |
>編集</a>] |
| 183 |
</div> |
| 184 |
<div style="clear:both;text-align:right;font-size:x-small;"> |
| 185 |
閲覧<span style="background-color:#ffffff;line-height:1.8em;vertical-align:middle;"> |
| 186 |
{foreach:MEMBER_MEMBER_CLASS_HASH key value} |
| 187 |
<input type="checkbox" name="member_viewable_{write:product->'product_number'}" |
| 188 |
value="{write:key}"{if:in_array(key,product->'memberViewableArray')} checked{/if} |
| 189 |
style="vertical-align:middle;" |
| 190 |
onclick="shoppingProductOpenChange({write:product->'product_number'})" |
| 191 |
/>{write:mb_substr(value,0,1)} |
| 192 |
{/foreach} |
| 193 |
</span> |
| 194 |
{write:SHOPPING_LABEL_ORDER}<span style="background-color:#ffffff;line-height:1.8em;vertical-align:middle;"> |
| 195 |
{foreach:MEMBER_MEMBER_CLASS_HASH key value} |
| 196 |
<input type="checkbox" name="member_purchasable_{write:product->'product_number'}" value="{write:key}" |
| 197 |
{if:in_array(key,product->'memberPurchasableArray')} checked{/if} |
| 198 |
style="vertical-align:middle;" |
| 199 |
onclick="shoppingProductOpenChange({write:product->'product_number'})" |
| 200 |
/>{write:mb_substr(value,0,1)} |
| 201 |
{/foreach} |
| 202 |
</span> |
| 203 |
</div> |
| 204 |
<div style="clear:both;text-align:right;font-size:x-small;"> |
| 205 |
<?php for( $GLOBALS['num']=0; $GLOBALS['num']<12; $GLOBALS['num']++ ){ ?> |
| 206 |
<select name="shpci_{write:product->'product_number'}_{write:num}" |
| 207 |
onchange="shoppingProductCategoryChange({write:product->'product_number'},{write:num},this.options[this.selectedIndex].value)" |
| 208 |
style="font-size:9px;"> |
| 209 |
<option value="" {if:count(shopping.product.category_id_array)==0} selected{/if}>-</option> |
| 210 |
{foreach:shopping.category.data_array categoryObject} |
| 211 |
{set:childCategoryArray categoryObject->'child_category_object_array'} |
| 212 |
<option value="{write:categoryObject->'category_id'}" |
| 213 |
{if:isset(product->'categoryIdArray'[num]) && product->'categoryIdArray'[num]==categoryObject->'category_id'} selected{/if} |
| 214 |
>{write:categoryObject->'category_name'}</option> |
| 215 |
{foreach:childCategoryArray childCategoryObject} |
| 216 |
{set:grandChildCategoryArray childCategoryObject->'child_category_object_array'} |
| 217 |
<option value="{write:childCategoryObject->'category_id'}" |
| 218 |
{if:isset(product->'categoryIdArray'[num]) && product->'categoryIdArray'[num]==childCategoryObject->'category_id'} selected{/if} |
| 219 |
> {if:childCategoryArray_loop_counter==count(childCategoryArray)}┗{else}┣{/if} {write:childCategoryObject->'category_name'}</option> |
| 220 |
{foreach:grandChildCategoryArray grandChildCategoryObject} |
| 221 |
<option value="{write:grandChildCategoryObject->'category_id'}" |
| 222 |
{if:isset(product->'categoryIdArray'[num]) && product->'categoryIdArray'[num]==grandChildCategoryObject->'category_id'} selected{/if} |
| 223 |
> {if:grandChildCategoryObject_loop_counter==count(grandChildCategoryObject)}┗{else}┣{/if} {write:grandChildCategoryObject->'category_name'}</option> |
| 224 |
{/foreach} |
| 225 |
{/foreach} |
| 226 |
{/foreach} |
| 227 |
</select> |
| 228 |
<?php } ?> |
| 229 |
</div> |
| 230 |
</div></th> |
| 231 |
</tr> |
| 232 |
<tr class="status_{write:product->'status_flag'}" style="{if:product::is_lock}background-color:{if:product::is_editable}#FFFFDD{else}#FFE0E0{/if}{/if};"> |
| 233 |
<td class="status_{write:product->'status_flag'}" style="width:80px;vertical-align:middle;text-align:center;"> |
| 234 |
{set:fileIdArray product::fileIdArray} |
| 235 |
{if:strlen(fileIdArray[0])>0} |
| 236 |
<img src="/file/download.php?fi={write:fileIdArray[0]}&w=80&h=80" /> |
| 237 |
{else} |
| 238 |
画像なし |
| 239 |
{/if} |
| 240 |
</td> |
| 241 |
<td class="status_{write:product->'status_flag'}" style="font-size:x-small;vertical-align:top;padding:0px;"> |
| 242 |
<table style="border-style:none;border-collapse:collapse;width:100%;margin:0px;height:100%;"> |
| 243 |
<tbody> |
| 244 |
{foreach:product::unitObjectArray unitObject} |
| 245 |
<tr{if:unitObject->'status_flag'<100} style="background-color:#c0c0c0;"{/if}> |
| 246 |
<td style="border-bottom:dotted 1px #d0d0d0;white-space:nowrap;width:30%;{if:unitObject->'status_flag'<100}background-color:#c0c0c0;{/if}"> |
| 247 |
<a href="./unit/detail.php?shpun={write:unitObject->'unit_number'}">{write:unitObject->'unit_name'}</a> |
| 248 |
</td> |
| 249 |
<td style="border-bottom:dotted 1px #d0d0d0;white-space:nowrap;text-align:right;width:20%;{if:unitObject->'status_flag'<100}background-color:#c0c0c0;{/if}">¥{write:number_format(unitObject->'price_sell')}-</td> |
| 250 |
<td style="border-bottom:dotted 1px #d0d0d0;white-space:nowrap;text-align:right;width:15%;{if:unitObject->'status_flag'<100}background-color:#c0c0c0;{/if}"> |
| 251 |
{if:unitObject->'stock'==-1} |
| 252 |
無制限 |
| 253 |
{else-if:unitObject->'stock'<-1} |
| 254 |
{write:unitObject->'stock_view'}{if:strlen(unitObject->'unit_string')>0}{write:unitObject->'unit_string'}{else-if:strlen(product->'unit_string')>0}{write:product->'unit_string'}{else}個{/if} |
| 255 |
{else} |
| 256 |
<input type="text" size="3" name="stock_{write:unitObject->'unit_id'}" value="{write:unitObject->'stock'}" |
| 257 |
style="text-align:right;" |
| 258 |
onfocus="shoppingProductUnitSetCurrentStock(this.value)" |
| 259 |
onblur="shoppingProductUnitStockChange({write:unitObject->'unit_number'},this.value)" |
| 260 |
/>{if:strlen(unitObject->'unit_string')>0}{write:unitObject->'unit_string'}{else-if:strlen(product->'unit_string')>0}{write:product->'unit_string'}{else}個{/if} |
| 261 |
{/if} |
| 262 |
</td> |
| 263 |
<td style="font-size:x-small;border-bottom:dotted 1px #d0d0d0;white-space:nowrap;text-align:right;width:15%;{if:unitObject->'status_flag'<100}background-color:#c0c0c0;{/if}">{write:number_format(unitObject->'present_point')}Pt.</td> |
| 264 |
<td style="border-bottom:dotted 1px #d0d0d0;white-space:nowrap;text-align:right;width:15%;{if:unitObject->'status_flag'<100}background-color:#c0c0c0;{/if}"> |
| 265 |
<select name="status_flag_{write:product->'product_number'}_{write:unitObject->'unit_number'}" |
| 266 |
onchange="shoppingProductUnitStatusChange({write:unitObject->'unit_number'},this.options[this.selectedIndex].value)"> |
| 267 |
{foreach:SHOPPING_PRODUCT_STATUS_HASH key status_name} |
| 268 |
<option value="{write:key}" |
| 269 |
{if:key==unitObject->'status_flag'} selected{/if} |
| 270 |
>{write:status_name}</option> |
| 271 |
{/foreach} |
| 272 |
</select> |
| 273 |
[<a href="./unit/form.php?shpun={write:unitObject->'unit_number'}" |
| 274 |
title="{write:unitObject->'unit_name'}の編集" |
| 275 |
>編集</a>] |
| 276 |
{if:unitObject->'delivery_type'>=200} |
| 277 |
<br /> |
| 278 |
[<a href="../calendar/?shpdi={write:product->'product_id'}&shpui={write:unitObject->'unit_id'}" |
| 279 |
>日別価格設定</a>] |
| 280 |
|
| 281 |
{/if} |
| 282 |
</td> |
| 283 |
</tr> |
| 284 |
{/foreach} |
| 285 |
</tbody> |
| 286 |
</table> |
| 287 |
<div style="text-align:right;"> |
| 288 |
{if:product->'delivery_type'>=200} |
| 289 |
<a href="../calendar/?shpdi={write:product->'product_id'}" |
| 290 |
>個別営業日設定</a> |
| 291 |
|
| 292 |
{/if} |
| 293 |
<a href="./unit/form.php?shpdi={write:product->'product_id'}" |
| 294 |
title="{write:product->'product_name'}に販売単位を追加" |
| 295 |
>+販売単位の追加</a> |
| 296 |
</div> |
| 297 |
</td> |
| 298 |
</tr> |
| 299 |
{/foreach} |
| 300 |
</tbody> |
| 301 |
</table> |
| 302 |
<div style="width:96%;margin:0 auto;"> |
| 303 |
{if:shopping.product.total_page>1} |
| 304 |
{write:shopping.product.total_count}件の検索結果 {write:shopping.product.page_number}/{write:shopping.product.total_page}ページ {write:count(shopping.product.product_array)}件を表示 |
| 305 |
|
| 306 |
{if:shopping.product.page_number-5>1}...{/if} |
| 307 |
<?php for( $GLOBALS['pageNavi']=($GLOBALS['shopping.product.page_number']-5 >= 1 ? $GLOBALS['shopping.product.page_number']-5 : 1); |
| 308 |
$GLOBALS['pageNavi']<=$GLOBALS['shopping.product.total_page'] |
| 309 |
&& $GLOBALS['pageNavi']<=($GLOBALS['shopping.product.page_number']-5 >= 1 ? $GLOBALS['shopping.product.page_number']-5 : 1)+9; |
| 310 |
$GLOBALS['pageNavi']++ ) { ?> |
| 311 |
{if:trim(pageNavi)!=trim(shopping.product.page_number)} |
| 312 |
<a href="javascript:FormerCommon.jumpPage({write:pageNavi})" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">{write:pageNavi}</a> |
| 313 |
{else} |
| 314 |
{write:pageNavi} |
| 315 |
{/if} |
| 316 |
<?php } ?> |
| 317 |
{if:shopping.product.page_number+9 < shopping.product.total_page}...{/if} |
| 318 |
|
| 319 |
{if:shopping.product.page_number-5>1}<a href="javascript:FormerCommon.jumpPage(1)" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">最初</a>{/if} |
| 320 |
{if:shopping.product.page_number+9 < shopping.product.total_page}<a href="javascript:FormerCommon.jumpPage({write:shopping.product.total_page})" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">最後</a>{/if} |
| 321 |
{if:shopping.product.has_prev_page}<a href="javascript:FormerCommon.prevPage()" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">前頁</a>{/if} |
| 322 |
{if:shopping.product.has_next_page}<a href="javascript:FormerCommon.nextPage()" onmouseover="this.style.color='#0000ff';" onmouseout="this.style.color='#808080';">次頁</a>{/if} |
| 323 |
{else} |
| 324 |
{write:shopping.product.total_count}件の検索結果 |
| 325 |
{/if} |
| 326 |
</div> |
| 327 |
|
| 328 |
<hr style="width:95%;margin:0 auto;margin-top:1em;" /> |
| 329 |
<div style="width:95%;margin:0 auto;text-align:right;"> |
| 330 |
<a href="./download/form.php">>> CSVダウンロード</a> |
| 331 |
{if:is_object(shopping.product.searchDataObject)} |
| 332 |
|
| 333 |
<a href="../../search/data/detail.php?schdi={write:shopping.product.searchDataObject->'data_id'}">>> {write:shopping.product.searchDataObject->'subject'}の詳細に戻る</a> |
| 334 |
{/if} |
| 335 |
</div> |
| 336 |
|
| 337 |
<script type="text/javascript"><!-- |
| 338 |
var shoppingProductStatusHttpObject; |
| 339 |
// |
| 340 |
// {write:SHOPPING_LABEL_PRODUCT}の状態を変更する |
| 341 |
// |
| 342 |
function shoppingProductStatusChange(productNumber,statusFlag) { |
| 343 |
var contents = 'product_number='+productNumber |
| 344 |
+'&status_flag='+statusFlag; |
| 345 |
shoppingProductStatusHttpObject = FormerCommon.createHttpRequest(shoppingProductStatusChangeResult); |
| 346 |
if( shoppingProductStatusHttpObject ) { |
| 347 |
FormerCommon.displayGrayOut(9999); |
| 348 |
shoppingProductStatusHttpObject.open("POST",'./status.php',true); |
| 349 |
shoppingProductStatusHttpObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); |
| 350 |
shoppingProductStatusHttpObject.send(contents); |
| 351 |
} else { |
| 352 |
alert('サーバー通信作成に失敗しました!'); |
| 353 |
} |
| 354 |
} |
| 355 |
function shoppingProductStatusChangeResult(){ |
| 356 |
if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status == 200)){ |
| 357 |
setTimeout(FormerCommon.displayWhiteIn, 100); |
| 358 |
var lines = shoppingProductStatusHttpObject.responseText.cr2lf().split(LF); |
| 359 |
var result = ''; |
| 360 |
while( result.length == 0 && lines.length > 0 ) { |
| 361 |
result = lines.shift(); |
| 362 |
} |
| 363 |
if( 'OK' == result ) { |
| 364 |
} else { |
| 365 |
alert(shoppingProductStatusHttpObject.responseText); |
| 366 |
} |
| 367 |
} else if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status != 200)){ |
| 368 |
alert('状態変更中にサーバー通信に失敗しました'); |
| 369 |
} |
| 370 |
} |
| 371 |
// |
| 372 |
// 販売単位の状態を変更する |
| 373 |
// |
| 374 |
function shoppingProductUnitStatusChange(unitNumber,statusFlag) { |
| 375 |
var contents = 'unit_number='+unitNumber |
| 376 |
+'&status_flag='+statusFlag; |
| 377 |
shoppingProductStatusHttpObject = FormerCommon.createHttpRequest(shoppingProductUnitStatusChangeResult); |
| 378 |
if( shoppingProductStatusHttpObject ) { |
| 379 |
FormerCommon.displayGrayOut(9999); |
| 380 |
shoppingProductStatusHttpObject.open("POST",'./unit/status.php',true); |
| 381 |
shoppingProductStatusHttpObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); |
| 382 |
shoppingProductStatusHttpObject.send(contents); |
| 383 |
} else { |
| 384 |
alert('サーバー通信作成に失敗しました!'); |
| 385 |
} |
| 386 |
} |
| 387 |
function shoppingProductUnitStatusChangeResult(){ |
| 388 |
if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status == 200)){ |
| 389 |
setTimeout(FormerCommon.displayWhiteIn, 100); |
| 390 |
var lines = shoppingProductStatusHttpObject.responseText.cr2lf().split(LF); |
| 391 |
var result = ''; |
| 392 |
while( result.length == 0 && lines.length > 0 ) { |
| 393 |
result = lines.shift(); |
| 394 |
} |
| 395 |
if( 'OK' == result ) { |
| 396 |
} else { |
| 397 |
alert(shoppingProductStatusHttpObject.responseText); |
| 398 |
} |
| 399 |
} else if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status != 200)){ |
| 400 |
alert('状態変更中にサーバー通信に失敗しました'); |
| 401 |
} |
| 402 |
} |
| 403 |
// |
| 404 |
// {write:SHOPPING_LABEL_PRODUCT}のカテゴリを変更する |
| 405 |
// |
| 406 |
function shoppingProductCategoryChange(productNumber,categoryOrder,categoryId) { |
| 407 |
var contents = 'product_number='+productNumber |
| 408 |
+'&category_order='+categoryOrder |
| 409 |
+'&category_id='+categoryId; |
| 410 |
shoppingProductStatusHttpObject = FormerCommon.createHttpRequest(shoppingProductCategoryChangeResult); |
| 411 |
if( shoppingProductStatusHttpObject ) { |
| 412 |
FormerCommon.displayGrayOut(9999); |
| 413 |
shoppingProductStatusHttpObject.open("POST",'./category.php',true); |
| 414 |
shoppingProductStatusHttpObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); |
| 415 |
shoppingProductStatusHttpObject.send(contents); |
| 416 |
} else { |
| 417 |
alert('サーバー通信作成に失敗しました!'); |
| 418 |
} |
| 419 |
} |
| 420 |
function shoppingProductCategoryChangeResult(){ |
| 421 |
if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status == 200)){ |
| 422 |
setTimeout(FormerCommon.displayWhiteIn, 100); |
| 423 |
var lines = shoppingProductStatusHttpObject.responseText.cr2lf().split(LF); |
| 424 |
var result = ''; |
| 425 |
while( result.length == 0 && lines.length > 0 ) { |
| 426 |
result = lines.shift(); |
| 427 |
} |
| 428 |
if( 'OK' == result ) { |
| 429 |
} else { |
| 430 |
alert(shoppingProductStatusHttpObject.responseText); |
| 431 |
} |
| 432 |
} else if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status != 200)){ |
| 433 |
alert('状態変更中にサーバー通信に失敗しました'); |
| 434 |
} |
| 435 |
} |
| 436 |
// |
| 437 |
// {write:SHOPPING_LABEL_PRODUCT}の権限を変更する |
| 438 |
// |
| 439 |
function shoppingProductOpenChange(productNumber) { |
| 440 |
var contents = 'product_number='+productNumber; |
| 441 |
var checkName = 'member_viewable_'+productNumber; |
| 442 |
var viewCheckArray = document.getElementsByName(checkName); |
| 443 |
for( var num=0; num<viewCheckArray.length; num++ ) { |
| 444 |
if( viewCheckArray[num] && viewCheckArray[num].checked ) { |
| 445 |
contents += '&'+encodeURIComponent('member_viewable[]')+'='+viewCheckArray[num].value; |
| 446 |
} |
| 447 |
} |
| 448 |
checkName = 'member_purchasable_'+productNumber; |
| 449 |
var purchaseCheckArray = document.getElementsByName(checkName); |
| 450 |
for( var num=0; num<purchaseCheckArray.length; num++ ) { |
| 451 |
if( purchaseCheckArray[num] && purchaseCheckArray[num].checked ) { |
| 452 |
contents += '&'+encodeURIComponent('member_purchasable[]')+'='+purchaseCheckArray[num].value; |
| 453 |
} |
| 454 |
} |
| 455 |
shoppingProductStatusHttpObject = FormerCommon.createHttpRequest(shoppingProductOpenChangeResult); |
| 456 |
if( shoppingProductStatusHttpObject ) { |
| 457 |
FormerCommon.displayGrayOut(9999); |
| 458 |
shoppingProductStatusHttpObject.open("POST",'./memberclass.php',true); |
| 459 |
shoppingProductStatusHttpObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); |
| 460 |
shoppingProductStatusHttpObject.send(contents); |
| 461 |
} else { |
| 462 |
alert('サーバー通信作成に失敗しました!'); |
| 463 |
} |
| 464 |
} |
| 465 |
function shoppingProductOpenChangeResult(){ |
| 466 |
if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status == 200)){ |
| 467 |
setTimeout(FormerCommon.displayWhiteIn, 100); |
| 468 |
var lines = shoppingProductStatusHttpObject.responseText.cr2lf().split(LF); |
| 469 |
var result = ''; |
| 470 |
while( result.length == 0 && lines.length > 0 ) { |
| 471 |
result = lines.shift(); |
| 472 |
} |
| 473 |
if( 'OK' == result ) { |
| 474 |
} else { |
| 475 |
alert(shoppingProductStatusHttpObject.responseText); |
| 476 |
} |
| 477 |
} else if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status != 200)){ |
| 478 |
alert('状態変更中にサーバー通信に失敗しました'); |
| 479 |
} |
| 480 |
} |
| 481 |
// |
| 482 |
// 販売単位の在庫数を変更する |
| 483 |
// |
| 484 |
var shoppingProductUnitCurrentStock; |
| 485 |
function shoppingProductUnitSetCurrentStock(stock){ |
| 486 |
shoppingProductUnitCurrentStock = stock; |
| 487 |
} |
| 488 |
function shoppingProductUnitStockChange(unitNumber,stockCount) { |
| 489 |
if( stockCount == shoppingProductUnitCurrentStock ) { |
| 490 |
return; |
| 491 |
} |
| 492 |
var contents = 'unit_number='+unitNumber |
| 493 |
+'&stock='+stockCount; |
| 494 |
shoppingProductStatusHttpObject = FormerCommon.createHttpRequest(shoppingProductUnitStockChangeResult); |
| 495 |
if( shoppingProductStatusHttpObject ) { |
| 496 |
FormerCommon.displayGrayOut(9999); |
| 497 |
shoppingProductStatusHttpObject.open("POST",'./unit/stock.php',true); |
| 498 |
shoppingProductStatusHttpObject.setRequestHeader("Content-Type", "application/x-www-form-urlencoded"); |
| 499 |
shoppingProductStatusHttpObject.send(contents); |
| 500 |
} else { |
| 501 |
alert('サーバー通信作成に失敗しました!'); |
| 502 |
} |
| 503 |
} |
| 504 |
function shoppingProductUnitStockChangeResult(){ |
| 505 |
if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status == 200)){ |
| 506 |
setTimeout(FormerCommon.displayWhiteIn, 100); |
| 507 |
var lines = shoppingProductStatusHttpObject.responseText.cr2lf().split(LF); |
| 508 |
var result = ''; |
| 509 |
while( result.length == 0 && lines.length > 0 ) { |
| 510 |
result = lines.shift(); |
| 511 |
} |
| 512 |
if( 'OK' == result ) { |
| 513 |
} else { |
| 514 |
alert(shoppingProductStatusHttpObject.responseText); |
| 515 |
} |
| 516 |
} else if ((shoppingProductStatusHttpObject.readyState == 4) && (shoppingProductStatusHttpObject.status != 200)){ |
| 517 |
alert('在庫数変更中にサーバー通信に失敗しました'); |
| 518 |
} |
| 519 |
} |
| 520 |
//--></script> |