예제 #1
0
 public static DataSet GetListTakeOut(int p_Take_Out_Pk, ConfigItem p_ConfigItem)
 {
     COREBASE.COMMAND.SQL.AccessSQL _sql = new COREBASE.COMMAND.SQL.AccessSQL(p_ConfigItem);
     try
     {
         _sql.Connect(p_ConfigItem);
         string[] arrParaName  = new string[] { "@Take_Out_Pk" };
         object[] arrParaValue = new object[] { p_Take_Out_Pk };
         return(_sql.GetDataByStoredProcedure_DS("USP_RPT_TAKE_OUT", arrParaName, arrParaValue));
     }
     catch (Exception ex)
     {
         throw ex;
     }
     finally
     {
         _sql.Disconnect();
     }
 }
예제 #2
0
        public DataSet GetData(int type)
        {
            DataSet ds    = null;
            string  store = "USP_RPT_NHAPKHO";

            if (type == 1)
            {
                store = "USP_RPT_XUATKHO";
            }
            else if (type == 0)
            {
                store = "USP_RPT_NHAPKHO";
            }
            else if (type == 2)
            {
                store = "USP_RPT_PB_HH";
            }
            else
            {
                store = "USP_RPT_XUAT_PB";
            }
            COREBASE.COMMAND.SQL.AccessSQL _sql = new COREBASE.COMMAND.SQL.AccessSQL(_ConfigItem);
            try
            {
                string[] arrParaName = new string[] { "@Item_Id", "@From", "@To" };
                object[] arrValue    = new object[] { 79, dateFrom.EditValue, dateTo.EditValue };
                _sql.Connect(_ConfigItem);

                ds = _sql.GetDataByStoredProcedure_DS(store, arrParaName, arrValue);
            }
            catch (Exception ex)
            {
                throw ex;
            }
            finally
            {
                _sql.Disconnect();
            }
            return(ds);
        }
예제 #3
0
        public DataSet GetDataDetail()
        {
            DataSet ds    = null;
            string  store = "USP_RptTonKhoDetail";

            COREBASE.COMMAND.SQL.AccessSQL _sql = new COREBASE.COMMAND.SQL.AccessSQL(_ConfigItem);
            try
            {
                string[] arrParaName = new string[] { "@fromMonth", "@toMonth" };
                object[] arrValue    = new object[] { dateFrom.EditValue, dateTo.EditValue };
                _sql.Connect(_ConfigItem);

                ds = _sql.GetDataByStoredProcedure_DS(store, arrParaName, arrValue);
            }
            catch (Exception ex)
            {
                throw ex;
            }
            finally
            {
                _sql.Disconnect();
            }
            return(ds);
        }