mirror of
http://git.coreshop.cn/jianweie/coreshoppro.git
synced 2025-12-06 17:43:26 +08:00
修复拼团针对同一个商品设置多个拼团规则时,金额计算错误的问题
This commit is contained in:
@@ -35,12 +35,14 @@ namespace CoreCms.Net.Repository
|
||||
}
|
||||
|
||||
#region 取购物车数据的时候,更新价格
|
||||
|
||||
/// <summary>
|
||||
/// 取购物车数据的时候,更新价格
|
||||
/// </summary>
|
||||
/// <param name="list"></param>
|
||||
/// <param name="ruleId">规则序列</param>
|
||||
/// <returns></returns>
|
||||
public WebApiCallBack PinTuanInfo(List<CartProducts> list)
|
||||
public WebApiCallBack PinTuanInfo(List<CartProducts> list, int ruleId)
|
||||
{
|
||||
var res = new WebApiCallBack();
|
||||
foreach (var item in list)
|
||||
@@ -50,7 +52,7 @@ namespace CoreCms.Net.Repository
|
||||
{
|
||||
JoinType.Inner, pinTuanGoods.ruleId == pinTuanRule.id
|
||||
}).Where((pinTuanGoods, pinTuanRule) =>
|
||||
pinTuanGoods.goodsId == item.products.goodsId && pinTuanRule.isStatusOpen == true)
|
||||
pinTuanGoods.goodsId == item.products.goodsId && pinTuanRule.isStatusOpen == true && pinTuanRule.id == ruleId)
|
||||
.Select((pinTuanGoods, pinTuanRule) => pinTuanRule).First();
|
||||
if (ruleModel == null)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user