More Stats

This commit is contained in:
CHIEFSOFT\ameye
2024-07-20 13:01:33 -04:00
parent 286cf5f7df
commit 43524c2ccb
+5
View File
@@ -525,6 +525,11 @@ try {
if (load_db_record(out, "SELECT id as client_id FROM members WHERE uid::text = '%s' ", in["client_uid"].c_str())) {
load_db_record(out, "SELECT count(id) AS job_pending FROM members_jobs_offer WHERE client_id = %lu AND expire > now()", out["client_id"].Long()); //pending jobs
load_db_record(out, "SELECT count(id) job_active FROM members_jobs_contract WHERE client_id = %lu AND delivery_date> now() AND status = 1", out["client_id"].Long()); //job_active
load_db_record(out, "SELECT delivery_date AS job_last_date FROM members_jobs_contract WHERE client_id = %lu AND status =7 ORDER BY delivery_date DESC LIMIT 1", out["client_id"].Long()); //job_active