|
@@ -137,6 +137,12 @@ namespace MySystem
|
|
decimal QrDebitProfitRate = 0;
|
|
decimal QrDebitProfitRate = 0;
|
|
decimal QrDebitProfitStandardRate = 0;
|
|
decimal QrDebitProfitStandardRate = 0;
|
|
decimal QrDebitAddOrSubRate = 0;
|
|
decimal QrDebitAddOrSubRate = 0;
|
|
|
|
+ decimal ProfitCreditTradeProfit = 0;
|
|
|
|
+ decimal ProfitCreditProfitRate = 0;
|
|
|
|
+ decimal ProfitCreditTradeAmt = 0;
|
|
|
|
+ decimal ProfitDebitNonCapTradeAmt = 0;
|
|
|
|
+ decimal ProfitDebitNonTradeCapProfit = 0;
|
|
|
|
+ decimal ProfitDebitProfitRate = 0;
|
|
if (j == 1)
|
|
if (j == 1)
|
|
{
|
|
{
|
|
CreditTradeAmt = TradeAmt; //贷记卡交易总金额
|
|
CreditTradeAmt = TradeAmt; //贷记卡交易总金额
|
|
@@ -157,6 +163,12 @@ namespace MySystem
|
|
HelpCreditProfitRate = ProfitRate; //(扶持期)(非云闪付)贷记卡商户交易对应分润比例
|
|
HelpCreditProfitRate = ProfitRate; //(扶持期)(非云闪付)贷记卡商户交易对应分润比例
|
|
HelpCreditTradeAmt = TradeAmt; //(扶持期)(非云闪付)贷记卡交易总金额
|
|
HelpCreditTradeAmt = TradeAmt; //(扶持期)(非云闪付)贷记卡交易总金额
|
|
}
|
|
}
|
|
|
|
+ else if(sub.HelpFlag == 2)
|
|
|
|
+ {
|
|
|
|
+ ProfitCreditTradeProfit = ProfitAmt; //(扶持期)(非云闪付)贷记卡分润总金额
|
|
|
|
+ ProfitCreditProfitRate = ProfitRate; //(扶持期)(非云闪付)贷记卡商户交易对应分润比例
|
|
|
|
+ ProfitCreditTradeAmt = TradeAmt; //(扶持期)(非云闪付)贷记卡交易总金额
|
|
|
|
+ }
|
|
else
|
|
else
|
|
{
|
|
{
|
|
NotHelpCreditTradeAmt = TradeAmt; //(非扶持期)(非云闪付)贷记卡交易总金额
|
|
NotHelpCreditTradeAmt = TradeAmt; //(非扶持期)(非云闪付)贷记卡交易总金额
|
|
@@ -203,6 +215,15 @@ namespace MySystem
|
|
}
|
|
}
|
|
HelpDebitProfitRate = ProfitRate; //(扶持期)(非云闪付)借记卡商户交易对应分润比例
|
|
HelpDebitProfitRate = ProfitRate; //(扶持期)(非云闪付)借记卡商户交易对应分润比例
|
|
}
|
|
}
|
|
|
|
+ else if (sub.HelpFlag == 2)
|
|
|
|
+ {
|
|
|
|
+ if (sub.Money < 1)
|
|
|
|
+ {
|
|
|
|
+ ProfitDebitNonCapTradeAmt = TradeAmt; //(盈利期)(非云闪付)借记卡非封顶交易总金额
|
|
|
|
+ ProfitDebitNonTradeCapProfit = ProfitAmt; //(盈利期)(非云闪付)借记卡非封顶交易分润总金额
|
|
|
|
+ }
|
|
|
|
+ ProfitDebitProfitRate = ProfitRate; //(盈利期)(非云闪付)借记卡商户交易对应分润比例
|
|
|
|
+ }
|
|
else
|
|
else
|
|
{
|
|
{
|
|
if (sub.Money < 1)
|
|
if (sub.Money < 1)
|
|
@@ -268,6 +289,12 @@ namespace MySystem
|
|
QrDebitProfitRate = QrDebitProfitRate, //(云闪付)借记卡非封顶交易分润比例
|
|
QrDebitProfitRate = QrDebitProfitRate, //(云闪付)借记卡非封顶交易分润比例
|
|
QrDebitProfitStandardRate = QrDebitProfitStandardRate, //(云闪付)借记卡非封顶交易分润基准
|
|
QrDebitProfitStandardRate = QrDebitProfitStandardRate, //(云闪付)借记卡非封顶交易分润基准
|
|
QrDebitAddOrSubRate = QrDebitAddOrSubRate, //(云闪付)借记卡非封顶交易分润比例或增或减
|
|
QrDebitAddOrSubRate = QrDebitAddOrSubRate, //(云闪付)借记卡非封顶交易分润比例或增或减
|
|
|
|
+ ProfitCreditTradeProfit = ProfitCreditTradeProfit, //(盈利期)(非云闪付)贷记卡分润总金额
|
|
|
|
+ ProfitCreditProfitRate = ProfitCreditProfitRate, //(盈利期)(非云闪付)贷记卡商户交易对应分润比例
|
|
|
|
+ ProfitCreditTradeAmt = ProfitCreditTradeAmt, //(盈利期)(非云闪付)贷记卡交易总金额
|
|
|
|
+ ProfitDebitNonCapTradeAmt = ProfitDebitNonCapTradeAmt, //(盈利期)(非云闪付)借记卡非封顶交易总金额
|
|
|
|
+ ProfitDebitNonTradeCapProfit = ProfitDebitNonTradeCapProfit, //(盈利期)(非云闪付)借记卡非封顶交易分润总金额
|
|
|
|
+ ProfitDebitProfitRate = ProfitDebitProfitRate, //(盈利期)(非云闪付)借记卡商户交易对应分润比例
|
|
});
|
|
});
|
|
// db.SaveChanges();
|
|
// db.SaveChanges();
|
|
}
|
|
}
|
|
@@ -395,12 +422,15 @@ namespace MySystem
|
|
function.WriteLog(DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff") + ":借记卡", "分润监控日志");
|
|
function.WriteLog(DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff") + ":借记卡", "分润监控日志");
|
|
decimal HelpDirectDebitTradeAmt = decimal.Parse(dr[2].ToString()); //借记卡扶持期交易额
|
|
decimal HelpDirectDebitTradeAmt = decimal.Parse(dr[2].ToString()); //借记卡扶持期交易额
|
|
decimal NotHelpDirectDebitTradeAmt = decimal.Parse(dr[3].ToString()); //借记卡稳定期交易额
|
|
decimal NotHelpDirectDebitTradeAmt = decimal.Parse(dr[3].ToString()); //借记卡稳定期交易额
|
|
|
|
+ decimal ProfitDirectDebitTradeAmt = decimal.Parse(dr[8].ToString()); //借记卡扶持期交易额
|
|
decimal HelpDirectDebitCapTradeAmt = decimal.Parse(dr[4].ToString()); //借记卡扶持期封顶交易额
|
|
decimal HelpDirectDebitCapTradeAmt = decimal.Parse(dr[4].ToString()); //借记卡扶持期封顶交易额
|
|
decimal NotHelpDirectDebitCapTradeAmt = decimal.Parse(dr[5].ToString()); //借记卡稳定期封顶交易额
|
|
decimal NotHelpDirectDebitCapTradeAmt = decimal.Parse(dr[5].ToString()); //借记卡稳定期封顶交易额
|
|
|
|
+ decimal ProfitDirectDebitCapTradeAmt = decimal.Parse(dr[9].ToString()); //借记卡扶持期封顶交易额
|
|
int HelpDirectDebitCapNum = int.Parse(dr[6].ToString().Split('.')[0]); //借记卡扶持期封顶交易笔数
|
|
int HelpDirectDebitCapNum = int.Parse(dr[6].ToString().Split('.')[0]); //借记卡扶持期封顶交易笔数
|
|
int NotHelpDirectDebitCapNum = int.Parse(dr[7].ToString().Split('.')[0]); //借记卡稳定期封顶交易笔数
|
|
int NotHelpDirectDebitCapNum = int.Parse(dr[7].ToString().Split('.')[0]); //借记卡稳定期封顶交易笔数
|
|
|
|
+ int ProfitDirectDebitCapNum = int.Parse(dr[10].ToString().Split('.')[0]); //借记卡扶持期封顶交易笔数
|
|
int UserLevel = selfUser.UserLevel; //当前会员等级
|
|
int UserLevel = selfUser.UserLevel; //当前会员等级
|
|
- decimal getLevelProfit = (HelpDirectDebitTradeAmt + NotHelpDirectDebitTradeAmt - HelpDirectDebitCapTradeAmt - NotHelpDirectDebitCapTradeAmt) * 0.0006M + HelpDirectDebitCapNum + NotHelpDirectDebitCapNum;
|
|
|
|
|
|
+ decimal getLevelProfit = (HelpDirectDebitTradeAmt + NotHelpDirectDebitTradeAmt + ProfitDirectDebitTradeAmt - HelpDirectDebitCapTradeAmt - NotHelpDirectDebitCapTradeAmt - ProfitDirectDebitCapTradeAmt) * 0.0006M + HelpDirectDebitCapNum + NotHelpDirectDebitCapNum + ProfitDirectDebitCapNum;
|
|
result.Add(new ProfitResult()
|
|
result.Add(new ProfitResult()
|
|
{
|
|
{
|
|
UserId = selfUser.Id,
|
|
UserId = selfUser.Id,
|
|
@@ -413,7 +443,7 @@ namespace MySystem
|
|
BrandId = BrandId,
|
|
BrandId = BrandId,
|
|
DirectFlag = 1,
|
|
DirectFlag = 1,
|
|
IsSubsidy = 0,
|
|
IsSubsidy = 0,
|
|
- TradeAmount = HelpDirectDebitTradeAmt + NotHelpDirectDebitTradeAmt,
|
|
|
|
|
|
+ TradeAmount = HelpDirectDebitTradeAmt + NotHelpDirectDebitTradeAmt + ProfitDirectDebitTradeAmt,
|
|
});
|
|
});
|
|
}
|
|
}
|
|
else
|
|
else
|