プロジェクト

全般

プロフィール

Vote #80831

完了

Property changes tab does not show journals with both property changes and notes

Admin Redmine さんが3年以上前に追加. 3年以上前に更新.

ステータス:
Closed
優先度:
通常
担当者:
-
カテゴリ:
Issues_2
対象バージョン:
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
2
version_id:
162
issue_org_id:
33338
author_id:
142895
assigned_to_id:
332
comments:
15
status_id:
5
tracker_id:
1
plus1:
0
affected_version:
closed_on:
affected_version_id:
160
ステータス-->[Closed]

説明


     case 'properties':
      tab_content.find('.journal.has-notes').hide();

When you have a journal entry with both notes and property changes, this code in application.js hides it completely on the property changes tab.
OTOH, property changes won't be hidden on the notes tab for this entry.

Patch added to fix this issue.


journals

--------------------------------------------------------------------------------
Greg T wrote:
> When you have a journal entry with both _notes_ and _property changes_, this code in application.js hides it completely on the _property changes_ tab.

I agree that "Property changes" tab should not skip journals that have notes.

> OTOH, _property changes_ won't be hidden on the _notes_ tab for this entry.

But I prefer the current behavior. I want to just exclude journals without notes in "Notes" tab. Changes in fields such as status and assignee are important information even in "Notes" tab.

Hiding property changes completely in the notes tab is a big change, so I am concerned that many users (including me :)) may complain. How about changing only "Property changes" tab with the following patch for now?

<pre><code class="diff">
diff --git a/public/javascripts/application.js b/public/javascripts/application.js
index ac2d5f8b0..6ac145f00 100644
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -371,15 +371,18 @@ function showIssueHistory(journal, url) {

switch(journal) {
case 'notes':
+ tab_content.find('.journal').show();
tab_content.find('.journal:not(.has-notes)').hide();
- tab_content.find('.journal.has-notes').show();
+ tab_content.find('.journal .wiki').show();
break;
case 'properties':
- tab_content.find('.journal.has-notes').hide();
- tab_content.find('.journal:not(.has-notes)').show();
+ tab_content.find('.journal').show();
+ tab_content.find('.journal:not(.has-details)').hide();
+ tab_content.find('.journal .wiki').hide();
break;
default:
tab_content.find('.journal').show();
+ tab_content.find('.journal .wiki').show();
}

return false;
</code></pre>
--------------------------------------------------------------------------------
Go MAEDA wrote:
> Hiding property changes completely in the notes tab is a big change, so I am concerned that many users (including me :)) may complain. How about changing only "Property changes" tab with the following patch for now?

Do as you please. I'd still find that counter-intuitive, but I don't even need these tabs, so I could live with that.
--------------------------------------------------------------------------------
Setting the target version to 4.1.2.
--------------------------------------------------------------------------------
This is a tricky issue consisting of two independent but inter-related parts:
# journals with both notes and property changes are not shown on the property changes tab
# journals with both notes and property changes are shown on the notes tab with property changes

Regarding the first: I agree with Go MAEDA and Greg T that this is a true issue.
Regarding the second: I agree with Greg T that this might be counter-intuitive (from a consistency perspective), however, given the goal of the notes tab (and the other inconsistencies that are already present [eg. attachments and issue relations "being tracked" as file/relation _properties_, associated revisions/time entries "being tracked" as if they are journals, etc.]), I agree with Go MAEDA that, from a usability perspective, this inconsistency is (desirable and) acceptable.

Translating the above into a redefinition of what should be rendered in which tabs would look like:

|Tab: |What to render: |
|._Notes_ |journals with notes, *with* their property changes |
|._Property changes_|journals with property changes, *without* their notes |

Regarding the posted solutions, both of them have one or more side-effects that might need to be taken care of. There might be others too.

|Solution: |Side-effect(s): |
|.by Greg T (attachment:"history_tabs.patch") |thumbnails are rendered for journals on property changes tab[1] |
|/2.by Go MAEDA (#33338#note-2) |thumbnails are rendered for journals on property changes tab[1] |
|journal action buttons (which are in fact _journal note_ action buttons) are rendered for journals on property changes tab[2] |

Alternative patch incorporating solutions for both side-effects mentioned in the table above:

<pre><code class="diff">
public/javascripts/application.js | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)

diff --git a/public/javascripts/application.js b/public/javascripts/application.js
index e4e902d..66b254a 100644
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -371,15 +371,24 @@ function showIssueHistory(journal, url) {

switch(journal) {
case 'notes':
+ tab_content.find('.journal').show();
tab_content.find('.journal:not(.has-notes)').hide();
- tab_content.find('.journal.has-notes').show();
+ tab_content.find('.journal .wiki').show();
+ tab_content.find('.journal .thumbnails').show();
+ tab_content.find('.journal .contextual .journal-actions').show();
break;
case 'properties':
- tab_content.find('.journal.has-notes').hide();
- tab_content.find('.journal:not(.has-notes)').show();
+ tab_content.find('.journal').show();
+ tab_content.find('.journal:not(.has-details)').hide();
+ tab_content.find('.journal .wiki').hide();
+ tab_content.find('.journal .thumbnails').hide();
+ tab_content.find('.journal .contextual .journal-actions').hide();
break;
default:
tab_content.find('.journal').show();
+ tab_content.find('.journal .wiki').show();
+ tab_content.find('.journal .thumbnails').show();
+ tab_content.find('.journal .contextual .journal-actions').show();
}

return false;

</code></pre>

fn1. thumbnails shouldn't be rendered in this tab IMHO

fn2. the buttons make the journal appear as if the property changes can be altered, while these buttons affect/relate to the journal notes only (leading to all kinds of weird behavior)

--------------------------------------------------------------------------------
Thank you all for the feedback on this. The solution proposed by Mischa sounds good to me (I didn't test the patch yet).

Mischa The Evil wrote:

> [...], however, given the goal of the notes tab (and the other inconsistencies that are already present [eg. attachments and issue relations "being tracked" as file/relation _properties_, associated revisions/time entries "being tracked" as if they are journals, etc.]), [...]

Mischa, how do you see a better implementation of this feature? Maybe we can improve it in the following releases.
--------------------------------------------------------------------------------
In top of the changes proposed by Mischa, I think we should apply the following:

<pre><code class="diff">

diff --git a/public/javascripts/application.js b/public/javascripts/application.js
index b322efc1e..726410bae 100644
--- a/public/javascripts/application.js
+++ b/public/javascripts/application.js
@@ -367,11 +367,17 @@ function showIssueHistory(journal, url) {
tab_content.find('.journal').show();
tab_content.find('.journal:not(.has-notes)').hide();
tab_content.find('.journal .wiki').show();
- tab_content.find('.journal .thumbnails').show();
tab_content.find('.journal .contextual .journal-actions').show();
+
+ var thumbnails = tab_content.find('.journal .thumbnails');
+ // show thumbnails for journals with notes
+ thumbnails.show();
+ // show thumbnails for journals without notes, but hide details
+ thumbnails.parents('.journal').show().find('.details').hide();
break;
case 'properties':
tab_content.find('.journal').show();
+ tab_content.find('.journal .details').show();
tab_content.find('.journal:not(.has-details)').hide();
tab_content.find('.journal .wiki').hide();
tab_content.find('.journal .thumbnails').hide();
@@ -381,6 +387,7 @@ function showIssueHistory(journal, url) {
tab_content.find('.journal').show();
tab_content.find('.journal .wiki').show();
tab_content.find('.journal .thumbnails').show();
+ tab_content.find('.journal .details').show();
tab_content.find('.journal .contextual .journal-actions').show();
}
</code></pre>
which always show the thumbnails in the notes tab regardless the type of journal (with or without notes).

To be honest, I think the current implementation become too complicated and we need an improved solution. Any ideas are welcome.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
I've applied the patches and got following results.

On the history tab notes with thumbnails also show the property changes.
On the notes tab these property changes are hidden for journal entries with thumbnails.

Is this the desired behavior? It was quite confusing for me.

|_.history|_.notes|
| !history-tab.png!| !notes-tab.png!|
--------------------------------------------------------------------------------
Thanks Bernhard for testing the patch. I agree with you, it's awkward. I've updated the second patch to display the journals with thumbnails in the same way as journal with notes.
--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------

--------------------------------------------------------------------------------
Committed the fix. Thank you.
--------------------------------------------------------------------------------


related_issues

relates,Closed,3058,Show issue history using tabs

Admin Redmine さんが3年以上前に更新

  • カテゴリIssues_2 にセット
  • 対象バージョン4.1.2_162 にセット

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0