From ad0f99af27c776b0571f126155f200302d50bdf0 Mon Sep 17 00:00:00 2001 From: "CHIEFSOFT\\ameye" Date: Thu, 7 Dec 2023 12:06:21 -0500 Subject: [PATCH] jo.reminder_count < 4 --- wrenchboard/src/shared_tool/site_crons.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wrenchboard/src/shared_tool/site_crons.cc b/wrenchboard/src/shared_tool/site_crons.cc index f797534c..d63b022e 100644 --- a/wrenchboard/src/shared_tool/site_crons.cc +++ b/wrenchboard/src/shared_tool/site_crons.cc @@ -144,14 +144,14 @@ if ( mode == 200 ){ } if ( mode == 300 ){ - snprintf(extraQ, sizeof (extraQ), " WHERE jo.expire < now() +'6 hrs' AND jo.expire > now() AND jo.status = 1 AND jo.public_view =0 AND jo.reminder_count > 0 AND jo.reminder_date IS NOT NULL"); + snprintf(extraQ, sizeof (extraQ), " WHERE jo.expire < now() +'6 hrs' AND jo.expire > now() AND jo.status = 1 AND jo.public_view =0 AND jo.reminder_count = 2 AND jo.reminder_date IS NOT NULL"); } const PGresult *res = pgsql_query("SELECT jo.id AS offer_id,jo.added,j.title,jo.expire,to_char(jo.expire, 'Dy Mon dd, yyyy HH:MI AM') AS expire_formated, jo.email, jo.client_id, " "jo.job_id,jo.reminder_count,jo.reminder_date,jo.email AS firstname, jo.email AS rec_username " "FROM members_jobs_offer jo " "LEFT JOIN members_jobs j ON j.id = jo.job_id " - " %s LIMIT %lu ",extraQ, limit); + " %s AND jo.reminder_count < 4 LIMIT %lu ",extraQ, limit); if (res != NULL && pgsql_num_rows(res) > 0) { for (int i = 0, n = pgsql_num_rows(res); i < n; i++) {