refactor: 国家列表接口添加按名称搜索

This commit is contained in:
2025-03-25 16:50:58 +08:00
parent 5eff994559
commit 68d31fc9b1
2 changed files with 9 additions and 1 deletions

View File

@@ -18,6 +18,9 @@ class Country
'name',
'en_name',
])
->withSearch(['name'], [
'name' => request()->param('name') ?? null
])
->order(['sort' => 'asc', 'id' => 'asc'])
->select();