You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
52 lines
2.5 KiB
52 lines
2.5 KiB
FROM_SELL_ADD_GET_SHOW_SQL = ''' |
|
SELECT csa.cinema_sell_add_showid AS show_id, |
|
cms.cinema_movie_name AS name, |
|
cms.cinema_movie_show_start_time AS start_time, |
|
chi.cinema_hall_name AS hall_name |
|
FROM cinema_sell_add csa |
|
LEFT JOIN cinema_hall_info chi ON csa.cinema_sell_add_hall = chi.cinema_hall_id |
|
LEFT JOIN cinema_movie_show cms ON csa.cinema_sell_add_showid = cms.cinema_movie_show_id |
|
GROUP BY csa.cinema_sell_add_showid ORDER BY cms.cinema_movie_show_start_time DESC; |
|
''' |
|
|
|
FROM_REFUND_GET_SHOW_SQL = ''' |
|
SELECT csl.cinema_movie_show_id AS show_id, |
|
csl.cinema_movie_name AS name, |
|
csl.cinema_movie_show_start_time AS start_time, |
|
chi.cinema_hall_name AS hall_name |
|
FROM cinema_sell_log csl |
|
LEFT JOIN cinema_hall_info chi ON csl.cinema_hall_id = chi.cinema_hall_id |
|
WHERE csl.cinema_sell_id IN (SELECT cinema_sell_id FROM cinema_refund_order_detail) |
|
GROUP BY cinema_movie_id ORDER BY csl.cinema_movie_show_start_time DESC; |
|
''' |
|
|
|
UPDATE_ZZ_PLATFORM_HOST_SQL = ''' |
|
UPDATE cine.cinema_common_info |
|
SET cinema_common_info_val = %s WHERE cinema_common_info_key = 'zz_platform_host'; |
|
''' |
|
|
|
|
|
GET_ZZ_PLATFORM_HOST_SQL = ''' |
|
SELECT * FROM cine.cinema_common_info WHERE cinema_common_info_key = 'zz_platform_host'; |
|
''' |
|
|
|
GET_OVERTIME_SELL_TICKET_SQL = """ |
|
SELECT csad.id, |
|
csad.ticket_no AS ticket_no, |
|
csa.cinema_sell_add_status AS add_status, |
|
csa.zz_audit_status AS audit_status, |
|
csa.cinema_sell_add_showid AS show_id |
|
FROM cinema_sell_add_detail csad |
|
LEFT JOIN cinema_sell_add csa ON csad.cinema_sell_add_id = csa.cinema_sell_add_id |
|
WHERE csad.ticket_no <> '' |
|
AND csa.cinema_sell_add_showid = %s |
|
ORDER BY csad.id DESC; |
|
""" |
|
|
|
GET_OVERTIME_REFUND_TICKET_SQL = """ |
|
SELECT crod.id, crod.cinema_sell_id, crod.refund_status, cslei.ticket_no |
|
FROM cinema_refund_order_detail crod |
|
LEFT JOIN cinema_sell_log_ext_info cslei ON crod.cinema_sell_id = cslei.cinema_sell_id |
|
WHERE refund_order_id IN (SELECT cinema_refund_order.refund_order_id FROM cinema_refund_order WHERE show_id = %s) |
|
ORDER BY id DESC; |
|
""" |