/// <summary>
        /// 个性化资金设置
        /// </summary>
        /// <param name="amount">设置金额</param>
        /// <param name="account">资金账号</param>
        /// <param name="currencyType">币种</param>
        /// <param name="db">数据连接对象</param>
        /// <param name="trm">开启事务</param>
        public void PersonalizationCapital(decimal amount, string account, GTA.VTS.Common.CommonObject.Types.CurrencyType currencyType, Database db, DbTransaction trm)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.Append("UPDATE [XH_CapitalAccountTable]   SET ");
            strSql.Append(" AvailableCapital = @amount");
            strSql.Append(" WHERE UserAccountDistributeLogo=@UserAccountDistributeLogo");
            strSql.Append("    And  TradeCurrencyType=@TradeCurrencyType");
            DbCommand dbCommand = db.GetSqlStringCommand(strSql.ToString());

            db.AddInParameter(dbCommand, "amount", DbType.Decimal, amount);
            db.AddInParameter(dbCommand, "TradeCurrencyType", DbType.Int32, (int)currencyType);
            db.AddInParameter(dbCommand, "UserAccountDistributeLogo", DbType.AnsiString, account);
            db.ExecuteNonQuery(dbCommand, trm);
        }
        public void TwoAccountsFreeTransferFundsTest()
        {
            AccountAndCapitalManagementService target = new AccountAndCapitalManagementService();                               // TODO: 初始化为适当的值
            FreeTransferEntity freeTransfer           = null;                                                                   // TODO: 初始化为适当的值

            GTA.VTS.Common.CommonObject.Types.CurrencyType currencyType = new GTA.VTS.Common.CommonObject.Types.CurrencyType(); // TODO: 初始化为适当的值
            string outMessage         = string.Empty;                                                                           // TODO: 初始化为适当的值
            string outMessageExpected = string.Empty;                                                                           // TODO: 初始化为适当的值
            bool   expected           = false;                                                                                  // TODO: 初始化为适当的值
            bool   actual;

            actual = target.TwoAccountsFreeTransferFunds(freeTransfer, currencyType, out outMessage);
            Assert.AreEqual(outMessageExpected, outMessage);
            Assert.AreEqual(expected, actual);
            Assert.Inconclusive("验证此测试方法的正确性。");
        }
        /// <summary>
        /// 开户时根据银行账号和交易货币类型增加资金
        /// Create BY:李健华
        /// Crate Date:2009-07-12
        /// </summary>
        /// <param name="addAmount">增加总数</param>
        /// <param name="bankAccount">银行账号</param>
        /// <param name="currencyType">交易货币类型</param>
        /// <param name="db"></param>
        /// <param name="trm">开启事务</param>
        public void AddCapital(decimal addAmount, string bankAccount, GTA.VTS.Common.CommonObject.Types.CurrencyType currencyType, Database db, DbTransaction trm)
        {
            StringBuilder strSql = new StringBuilder();

            strSql.Append("UPDATE [UA_BankAccountTable]   SET ");
            strSql.Append(" CapitalRemainAmount = CapitalRemainAmount + @AddAmount");
            strSql.Append("  ,TodayOutInCapital = TodayOutInCapital + @AddAmount");
            strSql.Append("  ,AvailableCapital =AvailableCapital + @AddAmount");
            strSql.Append(" WHERE UserAccountDistributeLogo=@UserAccountDistributeLogo");
            strSql.Append("    And  TradeCurrencyTypeLogo=@TradeCurrencyTypeLogo");
            DbCommand dbCommand = db.GetSqlStringCommand(strSql.ToString());

            db.AddInParameter(dbCommand, "AddAmount", DbType.Decimal, addAmount);
            db.AddInParameter(dbCommand, "TradeCurrencyTypeLogo", DbType.Int32, (int)currencyType);
            db.AddInParameter(dbCommand, "UserAccountDistributeLogo", DbType.AnsiString, bankAccount);
            db.ExecuteNonQuery(dbCommand, trm);
        }