Commit 65cce21a by 泽锋 李

fix

parent 630ef37f
...@@ -311,12 +311,15 @@ namespace AutoTurnOver.Models ...@@ -311,12 +311,15 @@ namespace AutoTurnOver.Models
/// <summary> /// <summary>
/// sku头程费 / kg /// sku头程费 / kg
/// </summary> /// </summary>
public decimal? cost_first_weight { get public decimal? cost_first_weight
{ {
if(cost_first==null || weight==null ) get
{
if (cost_first == null || weight == null)
{ {
return null; return null;
} else if (cost_first <= 0 || weight <= 0) }
else if (cost_first <= 0 || weight <= 0)
{ {
return 0; return 0;
} }
...@@ -325,7 +328,8 @@ namespace AutoTurnOver.Models ...@@ -325,7 +328,8 @@ namespace AutoTurnOver.Models
return Math.Round(cost_first.Value / (weight.Value / 1000), 2); return Math.Round(cost_first.Value / (weight.Value / 1000), 2);
} }
} } }
}
/// <summary> /// <summary>
/// 产品线 /// 产品线
...@@ -353,15 +357,23 @@ namespace AutoTurnOver.Models ...@@ -353,15 +357,23 @@ namespace AutoTurnOver.Models
/// <summary> /// <summary>
/// 供应链长度所需库存 (缺货) /// 供应链长度所需库存 (缺货)
/// </summary> /// </summary>
public decimal? turnover_days_outofstock_quantity { get { public decimal? turnover_days_outofstock_quantity
return Math.Max(0, (turnover_days_quantity??0) - sum_actual_stock); {
} } get
{
return Math.Max(0, (turnover_days_quantity ?? 0) - sum_actual_stock);
}
}
/// <summary> /// <summary>
/// 供应链长度所需库存 (冗余) /// 供应链长度所需库存 (冗余)
/// </summary> /// </summary>
public decimal? turnover_days_redundancy_quantity { get { public decimal? turnover_days_redundancy_quantity
return Math.Max(0, sum_actual_stock-(turnover_days_quantity??0) ); {
} } get
{
return Math.Max(0, sum_actual_stock - (turnover_days_quantity ?? 0));
}
}
public DateTime? lately_transfer_expect_arrival_time { get; set; } public DateTime? lately_transfer_expect_arrival_time { get; set; }
......
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