Example #1
0
        public SysCreditConfigDetails get_SysCreditConfigDetails()
        {
            SysCreditConfigDetails clsSysCreditConfigDetails = new SysCreditConfigDetails();

            clsSysCreditConfigDetails.BILLING_DATE               = get_BILLING_DATE();
            clsSysCreditConfigDetails.CREDIT_CUTOFF_DATE         = get_CREDIT_CUTOFF_DATE();
            clsSysCreditConfigDetails.CREDIT_FINANCE_CHARGE      = get_CREDIT_FINANCE_CHARGE();
            clsSysCreditConfigDetails.CREDIT_LATE_PENALTY_CHARGE = get_CREDIT_LATE_PENALTY_CHARGE();

            clsSysCreditConfigDetails.CRED_MIN_AMOUNT_DUE              = get_CRED_MIN_AMOUNT_DUE();
            clsSysCreditConfigDetails.CRED_MIN_PERCENTAGE_DUE          = get_CRED_MIN_PERCENTAGE_DUE();
            clsSysCreditConfigDetails.CREDIT_USE_LASTDAY_CUTT_OFF_DATE = get_CREDIT_USE_LASTDAY_CUTT_OFF_DATE();

            return(clsSysCreditConfigDetails);
        }
Example #2
0
        public Int32 Save(SysCreditConfigDetails Details)
        {
            try
            {
                string SQL = "CALL procSaveSysCreditConfig(@ConfigName, @ConfigValue, @Remarks, @CreatedOn, @LastModified);";

                MySqlCommand cmd = new MySqlCommand();
                cmd.CommandType = System.Data.CommandType.Text;
                cmd.CommandText = SQL;

                cmd.Parameters.AddWithValue("Configname", Details.ConfigName);
                cmd.Parameters.AddWithValue("ConfigValue", Details.ConfigValue);
                cmd.Parameters.AddWithValue("Remarks", Details.Remarks);
                cmd.Parameters.AddWithValue("CreatedOn", Details.CreatedOn == DateTime.MinValue ? Constants.C_DATE_MIN_VALUE : Details.CreatedOn);
                cmd.Parameters.AddWithValue("LastModified", Details.LastModified == DateTime.MinValue ? Constants.C_DATE_MIN_VALUE : Details.LastModified);

                return(base.ExecuteNonQuery(cmd));
            }

            catch (Exception ex)
            {
                throw base.ThrowException(ex);
            }
        }
Example #3
0
        public SysCreditConfigDetails get_SysCreditConfigDetails()
        {
            SysCreditConfigDetails clsSysCreditConfigDetails = new SysCreditConfigDetails();

            clsSysCreditConfigDetails.BILLING_DATE = get_BILLING_DATE();
            clsSysCreditConfigDetails.CREDIT_CUTOFF_DATE = get_CREDIT_CUTOFF_DATE();
            clsSysCreditConfigDetails.CREDIT_FINANCE_CHARGE = get_CREDIT_FINANCE_CHARGE();
            clsSysCreditConfigDetails.CREDIT_LATE_PENALTY_CHARGE = get_CREDIT_LATE_PENALTY_CHARGE();
            
            clsSysCreditConfigDetails.CRED_MIN_AMOUNT_DUE = get_CRED_MIN_AMOUNT_DUE();
            clsSysCreditConfigDetails.CRED_MIN_PERCENTAGE_DUE = get_CRED_MIN_PERCENTAGE_DUE();
            clsSysCreditConfigDetails.CREDIT_USE_LASTDAY_CUTT_OFF_DATE = get_CREDIT_USE_LASTDAY_CUTT_OFF_DATE();

            return clsSysCreditConfigDetails;
        }
Example #4
0
        public Int32 Save(SysCreditConfigDetails Details)
        {
            try
            {
                string SQL = "CALL procSaveSysCreditConfig(@ConfigName, @ConfigValue, @Remarks, @CreatedOn, @LastModified);";

                MySqlCommand cmd = new MySqlCommand();
                cmd.CommandType = System.Data.CommandType.Text;
                cmd.CommandText = SQL;

                cmd.Parameters.AddWithValue("Configname", Details.ConfigName);
                cmd.Parameters.AddWithValue("ConfigValue", Details.ConfigValue);
                cmd.Parameters.AddWithValue("Remarks", Details.Remarks);
                cmd.Parameters.AddWithValue("CreatedOn", Details.CreatedOn == DateTime.MinValue ? Constants.C_DATE_MIN_VALUE : Details.CreatedOn);
                cmd.Parameters.AddWithValue("LastModified", Details.LastModified == DateTime.MinValue ? Constants.C_DATE_MIN_VALUE : Details.LastModified);

                return base.ExecuteNonQuery(cmd);
            }

            catch (Exception ex)
            {
                throw base.ThrowException(ex);
            }	
        }