Пример #1
0
        public static A2ZHRPARAMETERDTO GetParameterValue()
        {
            A2ZHRPARAMETERDTO p = new A2ZHRPARAMETERDTO();

            DataTable dt = CommonManager.Instance.GetDataTableByQuery("SELECT * FROM A2ZHRPARAMETER", "A2ZHRMCUS");

            p.CurrentMonth     = Converter.GetSmallInteger(dt.Rows[0]["CurrentMonth"]);
            p.FinancialMonth   = Converter.GetSmallInteger(dt.Rows[0]["FinancialMonth"]);
            p.CurrentYear      = Converter.GetSmallInteger(dt.Rows[0]["CurrentYear"]);
            p.SystemBatchNo    = Converter.GetString(dt.Rows[0]["SystemBatchNo"]);
            p.IncomeCode       = Converter.GetLong(dt.Rows[0]["IncomeCode"]);
            p.PLCode           = Converter.GetLong(dt.Rows[0]["PLCode"]);
            p.BackupDir        = Converter.GetString(dt.Rows[0]["BackupDir"]);
            p.FinancialMonth   = Converter.GetSmallInteger(dt.Rows[0]["FinancialMonth"]);
            p.FinancialBegYear = Converter.GetSmallInteger(dt.Rows[0]["FinancialBegYear"]);
            p.FinancialEndYear = Converter.GetSmallInteger(dt.Rows[0]["FinancialEndYear"]);
            p.ProcessDate      = Converter.GetDateTime(dt.Rows[0]["ProcessDate"]);

            return(p);
        }
Пример #2
0
        public static int UpdateParameterValue(A2ZHRPARAMETERDTO dto)
        {
            string strQuery = "UPDATE A2ZHRPARAMETER   SET BackupDir ='" + dto.BackupDir + "'  WHERE SystemBatchNo='" + dto.SystemBatchNo + "'";

            return(Converter.GetInteger(CommonManager.Instance.ExecuteNonQuery(strQuery, "A2ZHRMCUS")));
        }