{include file="admin/header.html"}
{include file="admin/gnavi.html"}

<div id="container">

{include file="admin/menu/submenu_item.html"}

<!-- ↓段組み　メイン側 -->
<div id="main">

<form action="{$scriptName}" method="POST">
  <input type="hidden" name="div" value="{$action.div}">
  <input type="hidden" id="ac" name="action" value="">
  <input type="hidden" id="cd" name="cd" value="">
  <input type="hidden" id="structcd" name="structcd" value="">
  <input type="hidden" id="stockcd" name="stockcd" value="">
  <input type="hidden" id="janc" name="jancode" value="{$action.jancode}">
  <input type="hidden" id="hb" name="hinban" value="{$action.hinban}">
  <input type="hidden" id="t" name="itemtitle" value="{$action.itemtitle}">
  <input type="hidden" id="rds" name="release_date_start" value="{$action.release_date_start}">
  <input type="hidden" id="rde" name="release_date_end" value="{$action.release_date_end}">
  <input type="hidden" id="pds" name="publish_date_start" value="{$action.publish_date_start}">
  <input type="hidden" id="pde" name="publish_date_end" value="{$action.publish_date_end}">
  <input type="hidden" id="mc" name="maker_capital" value="{$action.maker_capital}">
  <input type="hidden" id="mn" name="maker_name" value="{$action.maker_name}">
  <input type="hidden" id="mda" name="media" value="{$action.media}">
  <input type="hidden" id="cst" name="cast" value="{$action.cast}">
  <input type="hidden" id="stut" name="situation" value="{$action.situation}">
  <input type="hidden" id="phs" name="photo_situation" value="{$action.photo_situation}">
  <input type="hidden" id="pus" name="publish_situation" value="{$action.publish_situation}">
  <input type="hidden" id="srt" name="sort" value="{$action.sort}">
{foreach name=list from=$action.genre_select item=genre}
  <input type="hidden" name="genre_select[]" value="{$genre}">
{/foreach}
  <input type="hidden" id="itd" name="imgtypediv" value="">
  <input type="hidden" id="gcd" name="generalcd" value="">
  <input type="hidden" id="iit" name="imgintotitle" value="{$action.itemnm}">
  <input type="hidden" id="frac" name="fromaction" value="admin_itemmanage_reference">
  <input type="hidden" name="itemnm"        value="{$action.itemnm}">
  <input type="hidden" name="makeritemcd"   value="{$action.makeritemcd}">
  <input type="hidden" name="medianm"       value="{$action.medianm}">
  <input type="hidden" name="fromlist_salestartdate" value="{$action.fromlist_salestartdate}">
  <input type="hidden" name="fromlist_orderclosedate" value="{$action.fromlist_orderclosedate}">
  <input type="hidden" name="from" value="{$action.from}">
  
  <!-- ↓項目（上） --> 
    <table border="0" cellspacing="0" cellpadding="0" class="hyou">
      <tr>
        <th align="left">品目コード</th>
        <td align="left" colspan="2">{$action.cd}</td>
        <td align="right">
          <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_reference'; 
                                        document.getElementById('cd').value='{$action.cd}';" value="詳細画面へ">
          <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_change_stock_list'; 
                                        document.getElementById('cd').value='{$action.cd}'; 
                                        document.getElementById('structcd').value='{$action.structcd}';" value="在庫入力へ"></td>
      </tr>
      <tr>
        <th align="left">タイトル</th>
        <td align="left" colspan="3">{$action.itemnm}</td>
      </tr>
      <tr>
        <th align="left">品番</th>
        <td align="left" colspan="3">{$action.makeritemcd}</td>
        {*<th align="left">メディア</th>*}
        {*<td align="left">{$action.medianm}</td>*}
      </tr>
      {*<tr>
        <th align="left">メーカー定価</th>
        <td align="left" colspan="3">
          {if $action.makerprice==0}オープンプライス{else}{$action.makerprice}円{/if}
        </td>
      </tr>
      *}
    </table>
  <!-- ↑項目（上） --> 

  <!-- ↓項目（下） --> 
    <table border="0" cellspacing="0" cellpadding="0" class="hyou">
      <input type="hidden" name="updcnt"       value="{$action.updcnt}">
      <input type="hidden" name="sellingprice" value="{$action.sellingprice}">
      <input type="hidden" name="costprice"    value="{$action.costprice}">
      <input type="hidden" name="souryouprc"   value="{$action.souryouprc}">
      <input type="hidden" name="supplidiv"    value="{$action.supplidiv}">

      <input type="hidden" name="condition"    value="{$action.condition}">
      <input type="hidden" name="stockstate"   value="{$action.stockstate}">
      <input type="hidden" name="itemexp"      value="{$action.itemexp}">
      <input type="hidden" name="actionnm"     value="{$action.actionnm}"> 
      <input type="hidden" name="stocktype"       value="{$action.stocktype}">
      <input type="hidden" name="stocktitlecd"       value="{$action.stocktitlecd}">
      
      <input type="hidden" name="sellingprice2" value="{$action.sellingprice2}">
      <input type="hidden" name="souryouprc2" value="{$action.souryouprc2}">
      <input type="hidden" name="condition2" value="{$action.condition2}">
      
      
{if $action.stockstate == 1 AND $action.stocktitlecdcont2<>NULL}
     <input type="hidden" name="stocktitlecdcont" value="{$action.stocktitlecdcont2}">
{else}
      <input type="hidden" name="stocktitlecdcont" value="{$action.stocktitlecdcont}">
{/if}
      <input type="hidden" name="stocktitlecdcont2" value="{$action.stocktitlecdcont2}">
      
{if $action.actionnm == "delete"}
      <tr>
        <td colspan="7">
            <strong><font color="#ff0000">本当に削除しますか?</font></strong>
        </td>
      </tr>
{/if}

      <tr>

        <th>販売価格</th>
        <th>送料</th>
        <th>仕入単価</th>
        {*<th>仕入区分</th>*}
        <th>在庫数</th>
        {*<th>コンディション</th>*}
        <th>ステータス</th>
      </tr>
      <tr>
        <td>{$action.sellingprice|number_format} {if $action.sellingprice|number_format}&nbsp;円&nbsp;{/if}</td>
        <td>{$action.souryouprc|number_format}  {if $action.souryouprc|number_format}&nbsp;円&nbsp;{/if}</td>
        <td>{$action.costprice|number_format}  {if $action.costprice|number_format}&nbsp;円&nbsp;{/if}</td>
        {*<td>{action->getSupplidivName|escape}</td>*}

{if $action.actionnm == "delete"}
   {if $action.stockstate == 1}
        <td>0</td>
   {else}
        <td>{$action.stocktitlecdcont|number_format} </td>
   {/if}
{else}
        <td>{$action.stocktitlecdcont|number_format} </td>
{/if}
        
        
        {*<td>{action->getConditionName|escape} </td>*}
        <td>{action->getStockstateName|escape} </td>
      </tr>
      <tr>
        <th colspan="10">在庫コメント（ポータルにて複数在庫の表示を許可している場合のみ、在庫ごとのメッセージとして表示されます。<br />
        許可していない場合は、内部的なコメントとしてお使いください。）</th>
      </tr>
      <tr>
        <td colspan="10">{$action.itemexp|nl2br|default:"　"}</td>
      </tr>

      <tr>
        <td align="right" colspan="10">
{if $action.actionnm == "insert"}
                <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_change_stock_insert_done'; 
                                              document.getElementById('cd').value='{$action.cd}'; 
                                              document.getElementById('structcd').value='{$action.structcd}';" value="登録">
                <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_change_stock_insert_form'; 
                                              document.getElementById('cd').value='{$action.cd}'; 
                                              document.getElementById('structcd').value='{$action.structcd}';" value="戻る">
{elseif $action.actionnm == "delete"}
                <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_change_stock_delete_done'; 
                                              document.getElementById('cd').value='{$action.cd}'; 
                                              document.getElementById('structcd').value='{$action.structcd}'; 
                                              document.getElementById('stockcd').value='{$action.stockcd}';" value="削除">
{else}
                <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_change_stock_update_done'; 
                                              document.getElementById('cd').value='{$action.cd}'; 
                                              document.getElementById('structcd').value='{$action.structcd}'; 
                                              document.getElementById('stockcd').value='{$action.stockcd}';" value="変更">
                <input type="submit" onClick="document.getElementById('ac').value='admin_itemmanage_change_stock_update_form'; 
                                              document.getElementById('cd').value='{$action.cd}'; 
                                              document.getElementById('structcd').value='{$action.structcd}'; 
                                              document.getElementById('stockcd').value='{$action.stockcd}';" value="戻る">
{/if}
        </td>
      </tr>
    </table>
  <!-- ↑項目（下） --> 
</form>

<div class="pagetop" title="ページトップへ"><a href="#top">ページトップへ</a></div>

</div>
<!--End of main-->

<div class="cr"></div>
</div>
<!--End of container-->

{include file="admin/footer.html"}
