Minor changes and updates.
This commit is contained in:
@@ -248,6 +248,7 @@ async def get_obj_li(
|
||||
|
||||
jp_obj = None
|
||||
if jp:
|
||||
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
|
||||
log.debug( urllib.parse.unquote(jp) )
|
||||
try:
|
||||
jp_obj = json.loads(urllib.parse.unquote(jp))
|
||||
@@ -266,6 +267,8 @@ async def get_obj_li(
|
||||
if jp_obj.get('and_in_li'): # NOTE: This is for the additional AND IN clauses in the WHERE statement
|
||||
and_in_dict_li_obj = jp_obj['and_in_li']
|
||||
|
||||
log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
|
||||
|
||||
|
||||
if order_by_li:
|
||||
order_by_li = json.loads(order_by_li)
|
||||
@@ -336,8 +339,10 @@ async def get_obj_li(
|
||||
|
||||
if for_obj_type and for_obj_id:
|
||||
for_obj_id = redis_lookup_id_random(record_id_random=for_obj_id, table_name=for_obj_type)
|
||||
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
|
||||
log.debug(f'for_obj_type: {for_obj_type}')
|
||||
log.debug(f'for_obj_id: {for_obj_id}')
|
||||
# log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
|
||||
|
||||
field_name = f'{for_obj_type}_id'
|
||||
|
||||
@@ -363,20 +368,20 @@ async def get_obj_li(
|
||||
# NOTE: The enabled and hidden parameters are new to this endpoint and the sql_select function! -2023-07-06
|
||||
# NOTE: This call (without field_name, field_value, limit, offset) may need more testing.
|
||||
sql_result = sql_select(
|
||||
table_name = table_name,
|
||||
enabled = commons.enabled,
|
||||
hidden = hidden,
|
||||
fulltext_qry_dict = fulltext_qry_dict_obj,
|
||||
and_qry_dict = and_qry_dict_obj,
|
||||
and_in_dict_li = and_in_dict_li_obj,
|
||||
# fulltext_qry_field_li = fulltext_qry_field_li,
|
||||
# fulltext_qry_str = fulltext_qry_str,
|
||||
order_by_li = order_by_li,
|
||||
limit = commons.limit,
|
||||
offset = commons.offset,
|
||||
as_list = True,
|
||||
# log_lvl = logging.DEBUG
|
||||
)
|
||||
table_name = table_name,
|
||||
enabled = commons.enabled,
|
||||
hidden = hidden,
|
||||
fulltext_qry_dict = fulltext_qry_dict_obj,
|
||||
and_qry_dict = and_qry_dict_obj,
|
||||
and_in_dict_li = and_in_dict_li_obj,
|
||||
# fulltext_qry_field_li = fulltext_qry_field_li,
|
||||
# fulltext_qry_str = fulltext_qry_str,
|
||||
order_by_li = order_by_li,
|
||||
limit = commons.limit,
|
||||
offset = commons.offset,
|
||||
as_list = True,
|
||||
# log_lvl = logging.DEBUG
|
||||
)
|
||||
|
||||
# log.setLevel(logging.WARNING) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
|
||||
log.debug(sql_result)
|
||||
|
||||
Reference in New Issue
Block a user