package com.steering.pss.pncost.base;

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

import com.steering.comm.db.DBCommon;
import com.steering.comm.tools.SqlBuilder;

public class ComBaseCountProcesscost extends DBCommon{
    public CoreReturnObject querypai(String nianyue,String yue,String str2){
        SqlBuilder b = new SqlBuilder("ComBaseCountProcesscost.querypai");
        b.Fill(new String[]{nianyue,yue,str2});
        String sql = b.toString().replaceAll("#F#", str2);
        return this.getData(sql);
    }
    
    public CoreReturnObject queryMonthone(String chanxian,String year){
        String sql = CoreXmlSqlParsersFactory.getSql("ComBaseCountProcesscost.queryMonthone");
        if(!chanxian.equals("")){
            sql += " AND PLINE_CODE = '" + chanxian + "'";
        }
        if(!year.equals("")){
            sql += " AND YEAR = '" + year + "'";
        }
        return this.getData(sql);
    }
    public CoreReturnObject queryzonge(String gang,String str1,String str2){
        SqlBuilder b = new SqlBuilder("ComBaseCountProcesscost.queryzonge");
        b.Fill(new String[]{gang,str1,str2});
        String sql = b.toString().replaceAll("#F#", str2);
        return this.getData(sql);
    }
}
