淘宝买手拍单30%
This commit is contained in:
1 parent
080fc7e4c4
commit
f27ddca730
13 files changed
+378
-184
No files matched your search
@@ -348,15 +348,15 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
||||
// 关联拍单关系 // 危险物品禁止拍单,仅关联安全商品
|
||||
//if (!GlobalConfig.lstDangerItemWord.Any(d => (item.title).ParseToString().Contains(d)))
|
||||
{
|
||||
item.BuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.out_sku_id && b.spu_code == item.out_product_id);
|
||||
if (item.BuyMap == null)
|
||||
item.BuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.sku_attr_str && b.spu_code == item.out_product_id);
|
||||
if (item.BuyMap == null)
|
||||
item.BuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.out_sku_id && b.spu_code == item.product_id);
|
||||
if (item.BuyMap == null)
|
||||
item.BuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.sku_attr_str && b.spu_code == item.product_id);
|
||||
item.PddBuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.out_sku_id && b.spu_code == item.out_product_id);
|
||||
if (item.PddBuyMap == null)
|
||||
item.PddBuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.sku_attr_str && b.spu_code == item.out_product_id);
|
||||
if (item.PddBuyMap == null)
|
||||
item.PddBuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.out_sku_id && b.spu_code == item.product_id);
|
||||
if (item.PddBuyMap == null)
|
||||
item.PddBuyMap = buyMapList.FirstOrDefault(b => b.sku_code == item.sku_attr_str && b.spu_code == item.product_id);
|
||||
}
|
||||
item.BuyMapSkus = buyMapSkusList.Where(s => s.spu_code == item.out_product_id || s.spu_code == item.product_id).OrderByDescending(s => s.mdy_time).ToList();
|
||||
item.PddBuyMapSkus = buyMapSkusList.Where(s => s.spu_code == item.out_product_id || s.spu_code == item.product_id).OrderByDescending(s => s.mdy_time).ToList();
|
||||
|
||||
// 中转仓订单
|
||||
if (item.ItemOrder.orderItems.Count > 1)
|
||||
@@ -1658,11 +1658,11 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
||||
}
|
||||
if (!order.IsWaitBuy)
|
||||
return true;
|
||||
if (chkMapSku.IsChecked == true && order.orderItems.Any(oi => oi.BuyMap == null))
|
||||
if (chkMapSku.IsChecked == true && order.orderItems.Any(oi => oi.PddBuyMap == null))
|
||||
return true;
|
||||
if (chkMapProd.IsChecked == true && order.orderItems.All(oi => oi.BuyMapSkus == null || oi.BuyMapSkus.Count == 0 || oi.BuyMap != null))
|
||||
if (chkMapProd.IsChecked == true && order.orderItems.All(oi => oi.PddBuyMapSkus == null || oi.PddBuyMapSkus.Count == 0 || oi.PddBuyMap != null))
|
||||
return true;
|
||||
if (chkNoMapProd.IsChecked == true && (order.orderItems.All(oi => oi.BuyMap != null) || order.orderItems.All(oi => oi.BuyMapSkus != null && oi.BuyMapSkus.Count > 0)))
|
||||
if (chkNoMapProd.IsChecked == true && (order.orderItems.All(oi => oi.PddBuyMap != null) || order.orderItems.All(oi => oi.PddBuyMapSkus != null && oi.PddBuyMapSkus.Count > 0)))
|
||||
return true;
|
||||
}
|
||||
if (filterHeadStr.StartsWith("待发货"))
|
||||
@@ -2939,7 +2939,7 @@ namespace _29WxOrderWpf.Ctrls.OrderCtrls
|
||||
|
||||
private async void btnAutoBuy_Click(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var buyOrders = GlobalConfig.lstFilterOrder.Where(o => o.IsWaitBuy && o.orderItems?.Count == 1 && o.orderItems.FirstOrDefault()?.BuyMap != null && o.IsSelect == true).ToList();
|
||||
var buyOrders = GlobalConfig.lstFilterOrder.Where(o => o.IsWaitBuy && o.orderItems?.Count == 1 && o.orderItems.FirstOrDefault()?.PddBuyMap != null && o.IsSelect == true).ToList();
|
||||
if (buyOrders.Count == 0)
|
||||
{
|
||||
BaseMsgWindow.ShowError("未勾选符合条件的订单!");
|
||||
|
||||
Reference in new issue
Block a user