obsidian-tasks-group / obsidian-tasks

Task management for the Obsidian knowledge base.
https://publish.obsidian.md/tasks/
MIT License
2.38k stars 225 forks source link

Edit Task modal: switching status to Done or Cancelled changes the existing Done or Cancelled date #3085

Open ilandikov opened 10 hours ago

ilandikov commented 10 hours ago

Please check that this issue hasn't been reported before.

Expected Behavior

If a Done date has been set, switching status from Todo to Done should not overwrite an already set Done date. Same thing for Cancelled date & status.

Current behaviour

If a Done date has been set, switching status from Todo to Done overwrites an already set Done date. Same thing for Cancelled date & status.

Steps to reproduce

  1. Open Edit Task modal on a task that is not Done status
  2. Set Done date to any value other than today's
  3. Change status to Done

Same thing for Cancelled date & status.

Which Operating Systems are you using?

Obsidian Version

1.7.1

Tasks Plugin Version

7.10.0

Checks

Possible solution

Setting status to Done or Cancelled should not overwrite an existing Done or Cancelled date but only set it if it was missing.

ilandikov commented 10 hours ago

@claremacrae please let me know if you consider this a bug =)

claremacrae commented 7 hours ago

@claremacrae please let me know if you consider this a bug =)

Hi Ilyas. Did you encounter this in real use?

I do agree it's a bug.

ilandikov commented 6 hours ago

Hi Ilyas. Did you encounter this in real use?

Oh yes, after opening the modal, my mouse was pretty low on the screen, so I edited the Done date first and afterwards switched the status and discovered the bug. Then tried the same with Cancelled date just to be sure.