|
|
@ -23,9 +23,9 @@ async def classtic_add(classtic:Classtic): |
|
|
|
return response_success(data=classtic,message="classtic create success") |
|
|
|
|
|
|
|
# 单条数据查询 |
|
|
|
@router.get("/search") |
|
|
|
@router.get("/list/search") |
|
|
|
async def classtic_search(header:str=Query(description="语录标题")): |
|
|
|
select_query="SELECT header FROM classtics WHERE 1=1 " |
|
|
|
select_query="SELECT id,header,text,descr FROM classtics WHERE 1=1 " |
|
|
|
params=[] |
|
|
|
if header: |
|
|
|
select_query+="AND header LIKE %s" |
|
|
|