<?php
/**
 * @copyright ONE/DEPO Project
 * @license   PHP License 3.01 <http://www.php.net/license/3_01.txt>
 */


/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */

/**
 * 出品情報詳細
 *
 * @package     Seller.Itemexhibit.Now.Info
 * @author      S.Oguma <shinichiro.oguma@netnee.jp>
 * @access      public
 */
class Seller_Itemexhibit_Now_Info
{

    var $auth;
    var $itemexhibit;
    var $session;
    var $tname;

    var $bodyid;
    var $title;

    var $itemcd;
    var $structcd;
    var $stockcd;
    var $curnum;
    var $lowprice;
    var $makeritemcd;
    var $mediacd;
    var $result;
    var $results;
    var $itemregist;
    var $itemregist_serial;
    var $actionChain;


	var $sort;
	var $pageID;
	var $listsize;


    /**
     * Actionの実行
     *
     * @access  public
     */
    function execute()
    {
        $log =& LogFactory::getLog();
        $log->debug("Seller_Itemexhibit_Now_Infoが実行されました", "Seller_Itemexhibit_Now_Info#execute");

        //$log->debug("this=".print_r($this->auth->auth->session['data']['membercd'] true), "Seller_Itemexhibit_Now_Info#execute");

        $sellercd=$this->auth->getAuthData("membercd");
        $this->results = array($this->itemcd, $this->structcd, $this->stockcd, $sellercd);
        //$log->debug("param=".print_r($this->results, true), "Seller_Itemexhibit_Now_Info#execute");
    	// DBからリスト取得
        $this->results = $this->itemexhibit->getOneItemexhibit($this->itemcd,
                                                               $this->structcd,
                                                               $this->stockcd,
                                                               $sellercd);
                                                               

        $this->result = $this->results[0];
        if (empty($this->result)) { 
            header("location:" . ERROR_URL); 
            exit; 
        } 
        //$log->debug("result=".print_r($this->result, true), "Seller_Itemexhibit_Now_Info#execute");

        return 'success';
    }

	function setItemregist(&$newmember)
	{
   		 $this -> itemregist =& $newmember;
	}

    function getItemregist()
	{
    	return $this -> itemregist;
	}
    
    function setItemregist_serial($value)
    {
        $value = urldecode($value);
        $this -> itemregist_serial = $value;
        $this -> itemregist = unserialize($value);
    }

    function getItemregist_serial()
    {
        return urlencode(serialize($this -> itemregist));
    }

}
?>