feat: add project key support for Jira analytics
- Introduced `projectKey` and `ignoredProjects` fields in Jira configuration to enhance analytics capabilities. - Implemented project validation logic in `JiraConfigClient` and integrated it into the `JiraConfigForm` for user input. - Updated `IntegrationsSettingsPageClient` to display analytics dashboard link based on the configured project key. - Enhanced API routes to handle project key in Jira sync and user preferences. - Marked related tasks as complete in `TODO.md`.
This commit is contained in:
@@ -26,7 +26,7 @@ export async function GET() {
|
||||
export async function PUT(request: NextRequest) {
|
||||
try {
|
||||
const body = await request.json();
|
||||
const { baseUrl, email, apiToken, ignoredProjects } = body;
|
||||
const { baseUrl, email, apiToken, projectKey, ignoredProjects } = body;
|
||||
|
||||
// Validation des données requises
|
||||
if (!baseUrl || !email || !apiToken) {
|
||||
@@ -60,6 +60,7 @@ export async function PUT(request: NextRequest) {
|
||||
email: email.trim(),
|
||||
apiToken: apiToken.trim(),
|
||||
enabled: true,
|
||||
projectKey: projectKey ? projectKey.trim().toUpperCase() : undefined,
|
||||
ignoredProjects: Array.isArray(ignoredProjects)
|
||||
? ignoredProjects.map((p: string) => p.trim().toUpperCase()).filter((p: string) => p.length > 0)
|
||||
: []
|
||||
|
||||
Reference in New Issue
Block a user