click subpath
This commit is contained in:
@@ -24,6 +24,7 @@ export async function GET(request: NextRequest) {
|
||||
const startTime = searchParams.get('startTime');
|
||||
const endTime = searchParams.get('endTime');
|
||||
const linkId = searchParams.get('linkId');
|
||||
const subpath = searchParams.get('subpath');
|
||||
|
||||
// 获取团队、项目和标签筛选参数
|
||||
const teamIds = searchParams.getAll('teamId');
|
||||
@@ -39,6 +40,7 @@ export async function GET(request: NextRequest) {
|
||||
startTime,
|
||||
endTime,
|
||||
linkId,
|
||||
subpath,
|
||||
teamIds,
|
||||
projectIds,
|
||||
tagIds,
|
||||
@@ -63,6 +65,11 @@ export async function GET(request: NextRequest) {
|
||||
conditions.push(`link_id = '${linkId}'`);
|
||||
}
|
||||
|
||||
// 添加子路径筛选
|
||||
if (subpath) {
|
||||
conditions.push(`positionCaseInsensitive(url, '/${subpath}') > 0`);
|
||||
}
|
||||
|
||||
// 添加团队筛选
|
||||
if (teamIds && teamIds.length > 0) {
|
||||
// 如果只有一个团队ID
|
||||
|
||||
Reference in New Issue
Block a user