Commit de408b19 authored by liudong1993's avatar liudong1993

1

parent 238cdb17
This diff is collapsed.
......@@ -2987,10 +2987,14 @@ namespace Mall.Module.User
//分销商等级
string GradeName = "默认等级";
int HpEnabled = 2;
int IsVip = 2;
if ((basicsModel?.IsEnableFXGrade ?? 0) == 1)
{
var gmodel = distributor_FXGradeRepository.GetEntity(model.FXGradeId);
GradeName = gmodel?.GradeName ?? "默认等级";
if (gmodel.IsGuest == 3) {
IsVip = 1;
}
}
else
{
......@@ -3097,6 +3101,8 @@ namespace Mall.Module.User
RemitMoney = remitMoney,
ReferralsNum = (basicsModel?.IsEnableFXGrade ?? 0) == 1 ? fxNum : (oneNum + twoNum + threeNum),
IsEnableFXGrade = (basicsModel?.IsEnableFXGrade ?? 0),
IsVip,
VipExpiryDate = model.VipExpiryDate.HasValue ? model.VipExpiryDate.Value.ToString("yyyy-MM-dd") : "",
VipBuyCommission
}
};
......
......@@ -884,11 +884,16 @@ and DATE_FORMAT(b.PaymentTime,'%y-%m-%d')<DATE_FORMAT('{endDate}','%y-%m-%d') A
{
if (item.PresentFXGrade > 0)
{
//有赠送粉象等级
GradeList.Add(item.PresentFXGrade ?? 0);
if (item.PresentFXGrade == (VIPModel?.Id ?? 0))
//查询是否有申请退款
var afterSaleList = goods_OrderAfterSaleRepository.GetList(new RB_Goods_OrderAfterSale_Extend() { OrderDetialId = item.Id, Type = 1, MallBaseId = demodel.MallBaseId, TenantId = demodel.TenantId });
if (!afterSaleList.Any())
{
VIPMonths += (item.PresentFXMonth ?? 0) * (item.Number ?? 0);
//有赠送粉象等级
GradeList.Add(item.PresentFXGrade ?? 0);
if (item.PresentFXGrade == (VIPModel?.Id ?? 0))
{
VIPMonths += (item.PresentFXMonth ?? 0) * (item.Number ?? 0);
}
}
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment