add: resend chat wa notif error user

This commit is contained in:
2025-12-31 15:11:34 +07:00
parent a704eb3235
commit 25ba80ab7e
5 changed files with 141 additions and 24 deletions

View File

@@ -55,8 +55,11 @@ const getAllNotificationErrorUserDb = async (searchParams = {}) => {
const getNotificationErrorUserByIdDb = async (id) => {
const queryText = `
SELECT
a.*
a.*,
b. is_active as contact_is_active
FROM notification_error_user a
LEFT JOIN contact b ON a.contact_phone = b.contact_phone
WHERE a.notification_error_user_id = $1 AND a.deleted_at IS NULL
`;
const result = await pool.query(queryText, [id]);