Compare commits

..

No commits in common. "e4865887499b1e40444790620c9971898da7d4cd" and "8a95ccc4a3deb7c3f79076ff886bd844a6e552cf" have entirely different histories.

View File

@ -242,7 +242,7 @@ func MetricsBusiness(req *bundle.MetricsBusinessReq) (result *bundle.MetricsBusi
Group("b_inner.user_id") // 相应地更新 Group By
statisticSubQuery = app.ModuleClients.BundleDB.Table("bundle_balance as bb").
Select("(bor.amount / nullif((bb.increase_video_number + bb.increase_limit_video_number + bb.increase_limit_video_expired_number), 0)) * (?) as bundle_add_price", countSubQuery).
Select("(bor.amount / nullif(((bb.increase_video_number + bb.increase_limit_video_number + bb.increase_limit_video_expired_number))), 0)) * (?) as bundle_add_price", countSubQuery).
Joins("left join bundle_order_records as bor on bor.uuid = bb.order_uuid collate utf8mb4_general_ci").
Joins("left join (?) as nb on bb.user_id = nb.user_id", newMonthSubQuery).
Where("nb.new_month = bb.month").