<?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     [[package名]]
 * @author      H.Watanabe <hiroshi.watanabe@netnee.jp>
 * @access      public
 */
class Admin_Itemmanage_Stock_Done
{
    /**
     * [[機能説明]]
     *
     * @access  public
     */
    var $title;
    var $pagename;
    var $div;
    
    var $lg_stock;
    
    var $maker_capi;
    var $makercd;
    var $labelcd;
    var $stock;
    var $src_title;
    var $from;
    
    var $itemcd;
    var $structcd;
    var $stockcd;
    var $stockcnt;
    
    function execute()
    {
        // 在庫数一括変更
        foreach( $this->stockcnt as $key => $value) {
            
            $results = $this->lg_stock->stockUpdate(
                         $this->itemcd[$key],
                         $this->structcd[$key],
                         $this->stockcd[$key],
                         $this->stockcnt[$key],
                         '');
            
            if($results == false) {
                return 'error';
            }
        }
        
        return 'success';
    }
}
?>
