@@ -129,7 +129,7 @@ where {where} group by oc.OrderId,oc.UserId,oc.Grade,oc.Type order by oc.Grade a
where+=$@" and oc.{nameof(RB_Goods_OrderCommission.OrderDetailId)} in({dmodel.OrderDetailIds})";
}
stringsql=$@"SELECT oc.OrderId,oc.OrderDetailId,oc.UserId,oc.Grade,oc.Type,oc.CommissionState,SUM(oc.Commission) as Commission,oc.CommissionType FROM All_Commission oc
stringsql=$@"SELECT oc.OrderId,oc.OrderDetailId,oc.UserId,oc.Grade,oc.Type,oc.CommissionState,SUM(oc.Commission) as Commission,oc.CommissionType,IFNULL(oc.IsRemit,0 ) as IsRemit FROM All_Commission oc
left join rb_goods_orderaftersale oa on oc.OrderDetailId= oa.OrderDetialId and oa.Type=1 and oa.Status=0 and oa.ReOrderStatus in (2,3,4,5)
where {where} group by oc.OrderDetailId,oc.UserId,oc.Grade,oc.Type,oc.CommissionType order by oc.Grade asc";