Skip to content

Conversation

@sapayth
Copy link
Member

@sapayth sapayth commented Jan 15, 2026

fix #275
related enhancement #279

Issue description:
After creating labels and assigning them to the tasks, they are not visible from the task list.

Steps to reproduce:
Navigate to Project Manager >> Projects >> Task lists >> Task >> add labels.
Aside task list, labels are not visible

Summary by CodeRabbit

Bug Fixes

  • Fixed an issue where project settings were not being saved correctly when updating existing projects
  • Corrected DOM structure and layout in the completed tasks view to ensure proper display and user interactions
  • Resolved template markup and structure errors in the incomplete tasks view for improved application stability and correct rendering of task information

✏️ Tip: You can customize this high-level summary in your review settings.

@sapayth sapayth added the Needs Testing This issue/PR needs further testing label Jan 15, 2026
@coderabbitai
Copy link

coderabbitai bot commented Jan 15, 2026

Walkthrough

The pull request adds Node.js version pinning, updates settings controller to properly include project IDs in data persistence, and fixes DOM structure inconsistencies in Vue task list components by relocating action elements and correcting template syntax.

Changes

Cohort / File(s) Summary
Configuration
.nvmrc
Added Node.js version specification (18) for development environment consistency.
Backend Logic
src/Settings/Controllers/Settings_Controller.php
Modified save_settings method to explicitly set $data['project_id'] before calling update_model() in the existing project_id branch.
Frontend Components
views/assets/src/components/project-task-lists/completed-tasks.vue, incompleted-tasks.vue
Restructured Vue template DOM: moved pm-do-action element into div wrapper in completed-tasks; fixed unclosed/mismatched anchor and comment tags in incompleted-tasks. Fixed JavaScript syntax in computed properties.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

🐰 A version pinned, settings flow true,
DOM neatly wrapped in divs anew,
Project IDs find their rightful place,
Task lists dancing with proper grace!

🚥 Pre-merge checks | ✅ 2 | ❌ 3
❌ Failed checks (2 warnings, 1 inconclusive)
Check name Status Explanation Resolution
Out of Scope Changes check ⚠️ Warning The .nvmrc file addition appears unrelated to fixing label visibility in tasks. The Settings_Controller and Vue component changes address label display, but the Node version file seems extraneous to the stated objectives. Remove the .nvmrc file change unless it's necessary for the label fix, or clarify its purpose in the PR description.
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
Linked Issues check ❓ Inconclusive The linked issue #275 concerns removal of Add/Delete options from project overview, unrelated to label visibility fixes. The PR objectives reference issue #275 but the actual code changes address label visibility without clear connection to the linked issue requirements. Clarify the relationship between the label visibility fix and issue #275, or link the correct issue(s) that define the label visibility requirements being addressed.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title 'Fix/labels not showing in tasks list' directly aligns with the primary objective to fix label visibility in task lists, clearly summarizing the main change.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In `@views/assets/src/components/project-task-lists/completed-tasks.vue`:
- Around line 36-39: The template in completed-tasks.vue is using the
globally-registered <pm-do-action> while the sibling incompleted-tasks.vue uses
a locally imported <do-action>; make them consistent by replacing <pm-do-action
:hook="'completed-task_inline'" :actionData="doActionData"> with the
locally-registered <do-action> and add the same local import and components
registration used in incompleted-tasks.vue (e.g., import DoAction from
'.../do-action.vue' and include DoAction in the components object), preserving
the existing props (doActionData and hook) so the prop names and usage remain
identical to incompleted-tasks.vue.
📜 Review details

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 71b6da4 and 55ed1a5.

⛔ Files ignored due to path filters (2)
  • package-lock.json is excluded by !**/package-lock.json
  • views/assets/vendor/vue-fullscreen/vue-fullscreen.min.js is excluded by !**/*.min.js
📒 Files selected for processing (4)
  • .nvmrc
  • src/Settings/Controllers/Settings_Controller.php
  • views/assets/src/components/project-task-lists/completed-tasks.vue
  • views/assets/src/components/project-task-lists/incompleted-tasks.vue
🔇 Additional comments (5)
.nvmrc (1)

1-1: LGTM!

Pinning Node.js to version 18 (LTS) ensures consistent development environments across the team.

views/assets/src/components/project-task-lists/completed-tasks.vue (1)

88-93: LGTM!

The doActionData computed property correctly provides the task and list context needed for the action hook to render labels.

src/Settings/Controllers/Settings_Controller.php (1)

100-106: Good fix for data integrity.

This ensures project_id is included in the data passed to update_model(), which is essential for correctly persisting project-scoped settings like labels. Without this, the project_id association could be lost during updates.

views/assets/src/components/project-task-lists/incompleted-tasks.vue (2)

40-46: LGTM!

The DOM structure is correct with the do-action component properly nested inside div.task-activity. The commented-out anchor block is cleanly terminated.


223-228: LGTM!

The doActionData computed property correctly provides the task and list context. The added semicolon improves code consistency.

✏️ Tip: You can disable this entire section by setting review_details to false in your review settings.

Comment on lines +36 to +39
</a> -->
<div class="task-activity">
<pm-do-action :hook="'completed-task_inline'" :actionData="doActionData"></pm-do-action>
</div>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

echo "=== Searching for pm-do-action usage ==="
rg -n "pm-do-action" -A 2 -B 2 --type vue --type js

echo -e "\n=== Searching for do-action usage in Vue files ==="
rg -n "<do-action" -A 2 -B 2 --type vue

echo -e "\n=== Checking completed-tasks.vue for component imports/usage ==="
fd "completed-tasks.vue" --type f

echo -e "\n=== Checking incompleted-tasks.vue for component imports/usage ==="
fd "incompleted-tasks.vue" --type f

Repository: weDevsOfficial/wp-project-manager

Length of output: 581


🏁 Script executed:

echo "=== Searching for pm-do-action ==="
rg "pm-do-action"

echo -e "\n=== Searching for <do-action ==="
rg "<do-action"

echo -e "\n=== Reading completed-tasks.vue (around the specified lines) ==="
sed -n '30,50p' views/assets/src/components/project-task-lists/completed-tasks.vue

echo -e "\n=== Reading incompleted-tasks.vue to check do-action usage ==="
rg -B 2 -A 2 "do-action" views/assets/src/components/project-task-lists/incompleted-tasks.vue

Repository: weDevsOfficial/wp-project-manager

Length of output: 6698


Component inconsistency needs resolution.

This file uses the globally registered <pm-do-action> component while the sibling incompleted-tasks.vue in the same directory uses the locally imported <do-action> component. Since both files handle similar task display logic (completed vs incompleted tasks), they should use the same component. Update one file to match the other for consistency.

🤖 Prompt for AI Agents
In `@views/assets/src/components/project-task-lists/completed-tasks.vue` around
lines 36 - 39, The template in completed-tasks.vue is using the
globally-registered <pm-do-action> while the sibling incompleted-tasks.vue uses
a locally imported <do-action>; make them consistent by replacing <pm-do-action
:hook="'completed-task_inline'" :actionData="doActionData"> with the
locally-registered <do-action> and add the same local import and components
registration used in incompleted-tasks.vue (e.g., import DoAction from
'.../do-action.vue' and include DoAction in the components object), preserving
the existing props (doActionData and hook) so the prop names and usage remain
identical to incompleted-tasks.vue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Needs Testing This issue/PR needs further testing

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant