|
@@ -249,7 +249,7 @@ namespace ZhonTai.Admin.Services.ProjectStat
|
|
|
else
|
|
|
{
|
|
|
//项目单独设置
|
|
|
- var drawproject= listDraw.Where(m => m.DrawType == 2 && m.ProjectId == price.ProjectId && m.ProjectPriceId == price.Id && m.EffectDate >= EffectDate).OrderBy(m => m.EffectDate).FirstOrDefault();
|
|
|
+ var drawproject = listDraw.Where(m => m.DrawType == 2 && m.ProjectId == price.ProjectId && m.ProjectPriceId == price.Id && m.EffectDate >= EffectDate).OrderBy(m => m.EffectDate).FirstOrDefault();
|
|
|
if (drawproject != null)
|
|
|
{
|
|
|
drawway = 2;
|
|
@@ -263,10 +263,10 @@ namespace ZhonTai.Admin.Services.ProjectStat
|
|
|
{
|
|
|
drawway = 1;
|
|
|
ratio = drawcompany.DrawRatio;
|
|
|
- }
|
|
|
+ }
|
|
|
}
|
|
|
}
|
|
|
- var commission= GetCommission(price.Price, ratio, drawway);
|
|
|
+ var commission = GetCommission(price.Price, ratio, drawway);
|
|
|
var model = new ProjectStatEntity()
|
|
|
{
|
|
|
Num = num,
|
|
@@ -280,10 +280,10 @@ namespace ZhonTai.Admin.Services.ProjectStat
|
|
|
IsSettle = 0,
|
|
|
TenantId = link?.TenantId,
|
|
|
UsedUserId = link?.UsedUserId,
|
|
|
- CompanyCommission=commission.CompanyCommission,
|
|
|
- CompanyRatio=commission.CompanyRatio,
|
|
|
- TenantCommission=commission.TenantCommission,
|
|
|
- TenantyRatio=commission.TenantRatio,
|
|
|
+ CompanyCommission = commission.CompanyCommission,
|
|
|
+ CompanyRatio = commission.CompanyRatio,
|
|
|
+ TenantCommission = commission.TenantCommission,
|
|
|
+ TenantyRatio = commission.TenantRatio,
|
|
|
};
|
|
|
list.Add(model);
|
|
|
}
|
|
@@ -334,14 +334,12 @@ namespace ZhonTai.Admin.Services.ProjectStat
|
|
|
{
|
|
|
throw ResultOutput.Exception("无可结算数据");
|
|
|
}
|
|
|
- //更新项目
|
|
|
- await _projectStatRepository.UpdateDiy.SetSource(
|
|
|
- new ProjectStatEntity()
|
|
|
- {
|
|
|
+ //更新项目
|
|
|
+ await _projectStatRepository.UpdateDiy.SetDto(
|
|
|
+ new {
|
|
|
IsSettle = 1,
|
|
|
SettleTime = DateTime.Now
|
|
|
})
|
|
|
- .UpdateColumns(a => new { a.IsSettle, a.SettleTime })
|
|
|
.Where(m => m.ProjectId == ProjectId && m.EffectDateNum == EffecDate && m.IsSettle == 0)
|
|
|
.DisableGlobalFilter(FilterNames.Tenant).ExecuteAffrowsAsync();
|
|
|
}
|
|
@@ -362,7 +360,7 @@ namespace ZhonTai.Admin.Services.ProjectStat
|
|
|
}
|
|
|
else if (drawType == 2)
|
|
|
{
|
|
|
- compnayCommssion = price - ratio;
|
|
|
+ compnayCommssion = price - ratio;
|
|
|
}
|
|
|
|
|
|
var tenatCommssion = price - compnayCommssion;
|