Skip to content

Wf setup - #24

Merged
davidbenge merged 3 commits into
mainfrom
wf-setup
Nov 29, 2025
Merged

Wf setup#24
davidbenge merged 3 commits into
mainfrom
wf-setup

Conversation

@davidbenge

Copy link
Copy Markdown
Owner

Lost work related to workfront endpoint registration and company and group selection

- Add WorkfrontClient service for API communication
- Implement Workfront event registry for event subscription management
- Add configure-workfront service to save Workfront config for brands
- Add list-workfront-companies and list-workfront-groups services
- Add manage-workfront-subscriptions service for event management
- Update Brand class with Workfront configuration fields
- Add WorkfrontConfigModal UI component for configuration
- Implement token caching utility for API authentication
- Update app.config.yaml with new Workfront service actions

This enables agencies to configure Workfront integration settings
for each brand, including server URL, company, and group selection.
- Fix Workfront data persistence in DemoBrandManager
  - Add Workfront fields to getBrandFromJson() method
  - Add Workfront fields to createBrand() method
  - Ensures data persists after save and shows in list view

- Improve Brand form layout and user experience
  - Change layout from maxWidth size-5000 to size-6000 with better padding
  - Add full-width background (gray-50) aligned with header bar
  - Remove centering (marginX auto) for left-aligned content layout
  - Fix gap between header and content area with explicit margin/padding

- Enhance Workfront integration section
  - Stack all Workfront fields vertically with Flex column layout
  - Add consistent size-200 gap between fields
  - Set width 100% on all fields for proper container spanning
  - Auto-load companies/groups when opening edit form with existing data
  - Add dynamic required indicators (Company/Group required when URL provided)
  - Implement validation error display with auto-clear on selection
  - Clear validation errors when Workfront URL is removed

- Fix logo upload DropZone styling
  - Remove width 100% that caused overflow
  - Use minHeight instead of fixed height
  - Add proper border, padding, and centering with UNSAFE_style
  - Contained within Well component boundaries

- Improve brand metadata display in view mode
  - Change from horizontal jumble to vertical stack using Flex
  - Add bold labels for better readability
  - Add consistent spacing with gap size-100
  - Fix date handling with proper new Date() wrapping

- Add comprehensive documentation
  - Create WORKFRONT_DATA_PERSISTENCE_FIX.md with detailed explanation
  - Document root cause, fixes, and expected behavior
  - Include verification steps and testing guidelines
}

// Parse runtime info
const runtimeInfo = new ApplicationRuntimeInfo(

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable runtimeInfo.

Copilot Autofix

AI 10 months ago

The best way to fix this issue is to remove the unused variable runtimeInfo entirely from the function. Specifically, eliminate the statement on line 62 where runtimeInfo is initialized. If there are no side-effects from creating the ApplicationRuntimeInfo object, removing this line will not alter the program's functional behavior or performance besides a minor improvement. Only line 62 (and, if applicable, line 63 which feeds into this initialization) should be deleted, with no other code changes required.


Suggested changeset 1
src/actions/services/workfront/configure-workfront/index.ts

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/src/actions/services/workfront/configure-workfront/index.ts b/src/actions/services/workfront/configure-workfront/index.ts
--- a/src/actions/services/workfront/configure-workfront/index.ts
+++ b/src/actions/services/workfront/configure-workfront/index.ts
@@ -59,9 +59,6 @@
         }
 
         // Parse runtime info
-        const runtimeInfo = new ApplicationRuntimeInfo(
-            JSON.parse(params.APPLICATION_RUNTIME_INFO)
-        );
 
         // Initialize Brand Manager
         const brandManager = new BrandManager(params.LOG_LEVEL || 'info');
EOF
@@ -59,9 +59,6 @@
}

// Parse runtime info
const runtimeInfo = new ApplicationRuntimeInfo(
JSON.parse(params.APPLICATION_RUNTIME_INFO)
);

// Initialize Brand Manager
const brandManager = new BrandManager(params.LOG_LEVEL || 'info');
Copilot is powered by AI and may make mistakes. Always verify output.
}

// Parse runtime info
const runtimeInfo = new ApplicationRuntimeInfo(

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused variable runtimeInfo.

Copilot Autofix

AI 10 months ago

The best fix is to simply remove the declaration of the unused variable runtimeInfo (line 80-82), since it isn't used in the code shown. This entails deleting these lines from the function. No other code appears to depend on this variable, and thus, no other changes are needed. This action improves performance and clarity by not performing unnecessary computation.


Suggested changeset 1
src/actions/services/workfront/manage-workfront-subscriptions/index.ts

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/src/actions/services/workfront/manage-workfront-subscriptions/index.ts b/src/actions/services/workfront/manage-workfront-subscriptions/index.ts
--- a/src/actions/services/workfront/manage-workfront-subscriptions/index.ts
+++ b/src/actions/services/workfront/manage-workfront-subscriptions/index.ts
@@ -77,9 +77,6 @@
         }
 
         // Parse runtime info
-        const runtimeInfo = new ApplicationRuntimeInfo(
-            JSON.parse(params.APPLICATION_RUNTIME_INFO)
-        );
 
         // Initialize Brand Manager
         const brandManager = new BrandManager(params.LOG_LEVEL || 'info');
EOF
@@ -77,9 +77,6 @@
}

// Parse runtime info
const runtimeInfo = new ApplicationRuntimeInfo(
JSON.parse(params.APPLICATION_RUNTIME_INFO)
);

// Initialize Brand Manager
const brandManager = new BrandManager(params.LOG_LEVEL || 'info');
Copilot is powered by AI and may make mistakes. Always verify output.
import { v4 as uuidv4 } from 'uuid';
import { apiService } from '../../services/api';
import { Brand } from '../../classes/Brand';
import { ActionButton } from '@adobe/react-spectrum';

Check notice

Code scanning / CodeQL

Unused variable, import, function or class Note

Unused import ActionButton.

Copilot Autofix

AI 10 months ago

To fix the problem, the unused import { ActionButton } from @adobe/react-spectrum on line 35 of src/components/layout/BrandManagerView.tsx should be removed. This involves deleting only line 35, without affecting any other parts of the file (such as keeping all other imports intact). If ActionButton is genuinely not used elsewhere in the file, and only Button (from line 16) is used for all related components, this removal won't affect functionality.

Suggested changeset 1
src/dx-excshell-1/web-src/src/components/layout/BrandManagerView.tsx

Autofix patch

Autofix patch
Run the following command in your local git repository to apply this patch
cat << 'EOF' | git apply
diff --git a/src/dx-excshell-1/web-src/src/components/layout/BrandManagerView.tsx b/src/dx-excshell-1/web-src/src/components/layout/BrandManagerView.tsx
--- a/src/dx-excshell-1/web-src/src/components/layout/BrandManagerView.tsx
+++ b/src/dx-excshell-1/web-src/src/components/layout/BrandManagerView.tsx
@@ -32,7 +32,6 @@
 import { v4 as uuidv4 } from 'uuid';
 import { apiService } from '../../services/api';
 import { Brand } from '../../classes/Brand';
-import { ActionButton } from '@adobe/react-spectrum';
 
 type ViewMode = 'list' | 'add' | 'edit' | 'view';
 
EOF
@@ -32,7 +32,6 @@
import { v4 as uuidv4 } from 'uuid';
import { apiService } from '../../services/api';
import { Brand } from '../../classes/Brand';
import { ActionButton } from '@adobe/react-spectrum';

type ViewMode = 'list' | 'add' | 'edit' | 'view';

Copilot is powered by AI and may make mistakes. Always verify output.
@davidbenge
davidbenge merged commit c7425ce into main Nov 29, 2025
2 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants