Revize c478920d
Přidáno uživatelem Ondřej Fibich před asi 9 roky(ů)
application/models/member.php | ||
---|---|---|
// query
|
||
return $this->db->query("
|
||
SELECT id, id AS member_id, name AS member_name, registration, registrations,
|
||
surname, firstname,
|
||
name, street, street_number, town, quarter, variable_symbol, aid, balance,
|
||
a_comment, a_comments_thread_id, type, type_name, entrance_date, leaving_date,
|
||
redirect_type_id, GROUP_CONCAT(DISTINCT redirect_type SEPARATOR ', ') AS redirect,
|
||
GROUP_CONCAT(DISTINCT redirect_type_text SEPARATOR ', \n') AS redirect_text,
|
||
notification_by_redirection, notification_by_email, notification_by_sms,
|
||
applicant_connected_from, whitelisted, interrupt, 1 AS redirection,
|
||
1 AS email, 1 AS sms $select_cloud
|
||
whitelisted, interrupt, 1 AS redirection, 1 AS email, 1 AS sms $select_cloud
|
||
FROM
|
||
(
|
||
SELECT
|
||
m.id, m.registration, m.registrations, m.name,
|
||
u.surname, u.name AS firstname,
|
||
s.street, ap.street_number, t.town, t.quarter,
|
||
vs.variable_symbol, a.id AS aid,
|
||
a.balance, a_comment,
|
||
a.comments_thread_id AS a_comments_thread_id,
|
||
m.type, type_name, m.entrance_date, m.leaving_date,
|
||
m.applicant_connected_from, redirect_type,
|
||
m.type, IFNULL(f.translated_term, e.value) AS type_name,
|
||
m.entrance_date, m.leaving_date, redirect_type,
|
||
redirect_type_id, redirect_type_text, whitelisted,
|
||
m.notification_by_redirection, m.notification_by_email,
|
||
m.notification_by_sms, interrupt $select_cloud
|
||
... | ... | |
IF(m.registration = 1, ?, ?) AS registration,
|
||
m.registration AS registrations,
|
||
m.type,
|
||
IFNULL(t.translated_term, e.value) AS type_name,
|
||
IF(mi.id IS NOT NULL, 1, 0) AS membership_interrupt,
|
||
IF(mi.id IS NOT NULL, 1, 0) AS interrupt,
|
||
m.organization_identifier, m.vat_organization_identifier,
|
||
m.comment, m.entrance_date, m.leaving_date,
|
||
m.entrance_fee, m.speed_class_id, m.notification_by_redirection,
|
||
m.notification_by_email, m.notification_by_sms, applicant_connected_from
|
||
m.notification_by_email, m.notification_by_sms
|
||
FROM members m
|
||
LEFT JOIN enum_types e ON m.type = e.id
|
||
LEFT JOIN translations t ON e.value = t.original_term AND lang = ?
|
||
... | ... | |
IF(mi.id IS NOT NULL, 1, 0) AS membership_interrupt,
|
||
m.organization_identifier, m.vat_organization_identifier,
|
||
m.comment, m.entrance_date, m.leaving_date,
|
||
m.entrance_fee, m.speed_class_id, m.applicant_connected_from
|
||
m.entrance_fee, m.speed_class_id
|
||
FROM members m
|
||
LEFT JOIN enum_types e ON m.type = e.id
|
||
LEFT JOIN translations t ON e.value = t.original_term AND lang = ?
|
Také k dispozici: Unified diff
Undo my stupid mistake (I have pushed issue-957 to master instead of develop). Do I have copied files from GitHub master and push them back..