|
@@ -498,7 +498,7 @@ def get_channel_order_trend(channel,pitcher,start,end,page,page_size,order_by,or
|
|
|
|
|
|
sql=f"""select stage,pitcher,channel,toString(dt) date,book,
|
|
|
require_roi,require_mult,
|
|
|
- toDecimal32(r1*require_mult-cost,2),
|
|
|
+ toInt32(r1*require_mult-cost),
|
|
|
toDecimal32(cost,2),
|
|
|
toDecimal32(reg_order_amount,2),
|
|
|
toDecimal32(reg_order_amount-cost,2),
|
|
@@ -754,7 +754,7 @@ from order where dt>='{start}' {channel_op} group by formatDateTime(reg_time,'
|
|
|
count= len(data)
|
|
|
if count==0:
|
|
|
return [],0
|
|
|
- total_data={'cost':round(cost,2),'reg_amount':round(reg_amount,2),'profit':round(profit,2),'expect_profit':round(expect_profit,2),'roi':round(reg_amount/cost,4), 'new_follow_user':new_follow_user,
|
|
|
+ total_data={'cost':round(cost,2),'reg_amount':round(reg_amount,2),'profit':round(profit,2),'expect_profit':int(expect_profit),'roi':round(reg_amount/cost,4), 'new_follow_user':new_follow_user,
|
|
|
'new_follow_per_cost':round(new_follow_per_cost/count,2),'order_user':order_user,'order_count':order_count,
|
|
|
'order_user_per_cost':round(order_user_per_cost/count,2),'channel':'-','date':'总计','book':'-'
|
|
|
}
|