package com.steering.pss.ydm.Stuffmanage;

import CoreFS.SA06.CoreReturnObject;
import CoreFS.SA08.CoreXmlSqlParsersFactory;

import com.steering.comm.converter.CoreConverter;
import com.steering.comm.db.DBCommon;

public class FrmStuffBase extends DBCommon{

	 /***
     * 获取所有管坯的目标库
     * @param storeNo
     * @return
     */
    public CoreReturnObject getStoreAll(String storeNo,String[] arr)
    {
    	String sql = CoreXmlSqlParsersFactory.getSql("FrmStuffBase.getStoreAll");
    	sql +=CoreConverter.nOtoSqlConditionString("T.STORAGE_NO", arr);
    	sql += " ORDER BY T.STORAGE_NO, T.STORAGE_NAME";
    	return this.getData(sql, new Object[]{storeNo});
    }
    
    /***
     * 获取本身权限仓库
     * @param storeNo
     * @param arr
     * @return
     */
    public CoreReturnObject getValidDataStore(String storeNo,String[] arr)
    {
    	String sql = CoreXmlSqlParsersFactory.getSql("FrmStuffBase.getStoreAll");
    	sql += CoreConverter.toSqlConditionString("T.STORAGE_NO", arr);
    	sql += " ORDER BY T.STORAGE_NO, T.STORAGE_NAME";
    	return this.getData(sql, new Object[]{storeNo});
    }
}
