Commit d81f4a12 by 泽锋 李

母sku不必分析最大利润

parent 8e0c9d34
...@@ -1352,7 +1352,10 @@ where t1.gmt_modified>=@btime and t1.gmt_modified<=@etime ...@@ -1352,7 +1352,10 @@ where t1.gmt_modified>=@btime and t1.gmt_modified<=@etime
var result = GetModel(bailun_sku, warehouse_code); var result = GetModel(bailun_sku, warehouse_code);
if (result.is_mother_sku == 1)
{
return null;
}
var result_air = GetModelAir(bailun_sku, warehouse_code); var result_air = GetModelAir(bailun_sku, warehouse_code);
var result_ocean = GetModelOcean(bailun_sku, warehouse_code); var result_ocean = GetModelOcean(bailun_sku, warehouse_code);
var base_wa = _connection.QueryFirstOrDefault<string>(" select t2.`code` from dc_base_warehouse as t1 left join dc_base_country as t2 on t1.area_name = t2.`name` where warehouse_code=@warehouse_code ", new { warehouse_code }); var base_wa = _connection.QueryFirstOrDefault<string>(" select t2.`code` from dc_base_warehouse as t1 left join dc_base_country as t2 on t1.area_name = t2.`name` where warehouse_code=@warehouse_code ", new { warehouse_code });
...@@ -2073,6 +2076,10 @@ where t1.gmt_modified>=@btime and t1.gmt_modified<=@etime ...@@ -2073,6 +2076,10 @@ where t1.gmt_modified>=@btime and t1.gmt_modified<=@etime
// 查询利润数据 // 查询利润数据
var profit_data = TransferProfitList(bailun_sku, warehouse_code, DateTime.Now).today_data; var profit_data = TransferProfitList(bailun_sku, warehouse_code, DateTime.Now).today_data;
if (profit_data == null)
{
return;
}
profit_data.ocean_purchase = Math.Max(0, profit_data.quantity_final_advise_ocean - profit_data.turnover); profit_data.ocean_purchase = Math.Max(0, profit_data.quantity_final_advise_ocean - profit_data.turnover);
profit_data.ocean_purchase_amount = profit_data.ocean_purchase * profit_data.unit_price; profit_data.ocean_purchase_amount = profit_data.ocean_purchase * profit_data.unit_price;
profit_data.freight_stock_amount_ocean = profit_data.quantity_final_ocean_difference_amount <= 0 ? 0 : ((profit_data.freight_price_ocean_difference_amount) / (profit_data.quantity_final_ocean_difference_amount)); profit_data.freight_stock_amount_ocean = profit_data.quantity_final_ocean_difference_amount <= 0 ? 0 : ((profit_data.freight_price_ocean_difference_amount) / (profit_data.quantity_final_ocean_difference_amount));
......
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