contract uid

This commit is contained in:
CHIEFSOFT\ameye
2023-06-12 20:52:09 -04:00
parent ecf8d29a20
commit a14bc7cacb
4 changed files with 13 additions and 3 deletions
+3 -1
View File
@@ -193,7 +193,9 @@ long MemberCouponList( CVars in, CVars &out ){
out["total_record"] = "0";
const PGresult *res;
res = pgsql_query("SELECT id AS coupon_id, ca.code, ca.amount, ca.added::date,ca.status FROM coupons_allocation ca WHERE ca.member_id = %lu AND %s ORDER BY ca.id DESC", in["member_id"].Long(),in["active_q"].c_str());
res = pgsql_query(" SELECT id AS coupon_id, ca.code, ca.amount, ca.added::date,ca.status "
" FROM coupons_allocation ca WHERE ca.member_id = %lu "
" AND %s ORDER BY ca.id DESC", in["member_id"].Long(),in["active_q"].c_str());
if (res != NULL && pgsql_num_rows(res) > 0) {
out["total_record"] = pgsql_num_rows(res);