This commit is contained in:
yumoqing 2026-06-02 13:56:23 +08:00
parent d4c079d11e
commit cab7843f95

View File

@ -1,11 +1,13 @@
lt = params_kw.catelogid or 't2v' lt = params_kw.catelogid or 't2v'
async with get_sor_context(request._run_ns, 'llmage') as sor: debug(f'{lt=}')
try:
async with get_sor_context(request._run_ns, 'llmage') as sor:
sql = '''select distinct a.*, e.input_fields from llm a sql = '''select distinct a.*, e.input_fields from llm a
join llm_api_map m on a.id = m.llmid join llm_api_map m on a.id = m.llmid
join llmcatelog b on m.llmcatelogid = b.id join llmcatelog b on m.llmcatelogid = b.id
join uapi d on d.upappid = a.upappid and a.apiname = d.name join uapi d on d.upappid = a.upappid and a.apiname = d.name
join uapiio e on d.ioid = e.id join uapiio e on d.ioid = e.id
where (b.id=${lt}$ OR b.name=${lt}$) where (b.id=${lt}$ OR b.name=${lt}$)
and a.enabled_date <= ${biz_date}$ and a.enabled_date <= ${biz_date}$
and ${biz_date}$ < a.expired_date and ${biz_date}$ < a.expired_date
and a.status = 'published' and a.status = 'published'
@ -21,13 +23,14 @@ where (b.id=${lt}$ OR b.name=${lt}$)
'status': 'ok', 'status': 'ok',
'data': recs 'data': recs
} }
return { return {
'status': 'error', 'status': 'error',
'data':{ 'data':{
'message': 'server error' 'message': 'server error'
} }
} }
except Exception as e:
debug(f'{lt=},{e},{format_exc()}')