|
@@ -594,7 +594,7 @@
|
|
|
<select id="getFeeByType" resultType="com.ym.mec.biz.dal.dto.StudentPaymentOrderExportDto">
|
|
|
SELECT MAX(spo.expect_amount_) expectAmount,
|
|
|
SUM(IF(g.type_ = 'INSTRUMENT', so.expect_amount_, 0)) musicalFee,
|
|
|
- SUM(IF(g.type_ != 'INSTRUMENT' || g.type_ IS NULL, so.expect_amount_, 0)) teachingFee
|
|
|
+ SUM(IF(g.type_ != 'INSTRUMENT', so.expect_amount_, 0)) teachingFee
|
|
|
FROM student_payment_order spo
|
|
|
LEFT JOIN sell_order so ON spo.id_ = so.order_id_
|
|
|
LEFT JOIN goods g ON IF(so.parent_goods_id_ IS NOT NULL,g.id_ = so.parent_goods_id_,g.id_ = so.goods_id_)
|