Workflow transition button missing from the issue view page in Jira server

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

プラットフォームについて: Server と Data Center のみ - この記事は、サーバーおよびデータセンター プラットフォームのアトラシアン製品にのみ適用されます。

問題

The workflow transition button is no longer available on the issue view page although the issue is not in a closed status.

診断

Run the following query against the JIRA database (in this example, the issue key is "TTWO-4"; table name 'os_wfentry' is case sensitive and is 'OS_WFENTRY' in MySQL)

select * from os_wfentry 
where id = (select workflow_id from jiraissue where issuenum = 4 and project = (select id from project where pkey = 'TTWO'));
  id   | name | initialized | state
-------+------+-------------+-------
 10100 | test |             |     3
(1 row) 

We may also be hitting into a problem when the issue is not associated with a valid workflow step. You can confirm that if the query below returns any of your issues.

select concat(concat(P.pkey,'-'),I.issuenum)
from jiraissue I
join project P on P.id = I.project
left join os_currentstep C on C.entry_id = I.workflow_id
where C.id is null

原因

考えられる原因: 

  1. The workflow applied (value of the "name" column) on this issue is no longer associated with the project;
  2. The issue state is not active. (The value for the "state" column: 0 for Inactive, 1 for Active, 3 for Killed, 4 for Complete);
  3. The issue is not associated with an existing current step;
  4. Missing add-ons used by the workflow - Refer to JIRA doesn't display any transitions for issues in the issue view page;
  5. Not enough Permission:
    1. The user does not have permission to do the transition (Permission Scheme);
    2. There is a permission restriction added to the workflow;
    3. The user does not have permission to edit an Epic Link JSWSERVER-20770 - Getting issue details... STATUS   JRASERVER-71884 - Getting issue details... STATUS .

回避策

データベースの変更を行う場合は必ず事前にバックアップを取得してください。可能な場合は、まずステージング サーバーで SQL コマンドの変更、挿入、更新、または削除を行うようにします。

Causes 1 - 3, 5c:

  • Please run the integrity checker to fix the issue.

  • In case the integrity checker is not able to fix the issue:

    • Workflow inconsistency 1: Copy the workflow and replace it on the project's workflow scheme. It'll trigger a workflow remap. You may reassign the original workflow back if you want right after.
    • Workflow inconsistency 2: Please move the issue to another Issue Type or Project then move it back to force JIRA to trigger a workflow remap.
    • Issue state inconsistency "Killed", not captured by the Integrity Checker ( JRA-26454 - Getting issue details... STATUS ):

      • Please run the following query against the database. For the sample below, considering an issue called 'TTWO-4':

        update os_wfentry set state = 1 where id = (select workflow_id from jiraissue where issuenum = 4 and project = (select id from project where pkey = 'TTWO'));
    • Issue state inconsistency "Inactive" if the Integrity Checker was not executed. Reference SQL equivalents for Jira server's workflow integrity checks Skip to end of metadata
      • Find all issues using an inactive state: 

        SELECT jiraissue.id issue_id,
               jiraissue.workflow_id,
               os_wfentry.*
        FROM   jiraissue
        JOIN   os_wfentry
        ON     jiraissue.workflow_id = os_wfentry.id
        WHERE  os_wfentry.state IS NULL
        OR     os_wfentry.state = 0;
      • Update all broken states:  

        UPDATE os_wfentry
        SET state = 1
        WHERE id IN (SELECT os_wfentry.id
                     FROM jiraissue
                              JOIN os_wfentry
                                   ON jiraissue.workflow_id = os_wfentry.id
                     WHERE os_wfentry.state IS NULL
                        OR os_wfentry.state = 0);
    • Workaround for cause 3: Run the following SQL query to generate the inserts for all issues missing the valid workflow step entry

      select concat(concat('insert into os_currentstep values ((select max(id)+1 from os_currentstep),',workflow_id),',1,0,'''',now(),null,null,''open'',null)') 
      from jiraissue where workflow_id not in (select entry_id from os_currentstep)


      • Copy all results and run the inserts to add the missing rows.

Cause 5a, 5b:

  • Not enough Permission to do the transition: 
    • Check the Permission defined at the Project Permission Scheme;
    • Check the actual workflow transition if there is any validation created restricting who is able to do the transition. 
      The user has permission to work on the issue (Project Permission Scheme) but for that transition, only another user/group can do the transition. For instance, adding a condition like "Only the assignee of the issue can execute this transition": The transition button would not appear when a user other than the assignee edits the issue.

説明The workflow transition button is no longer available on the issue view page although the issue is not in a closed status.
製品Jira
プラットフォームサーバー
最終更新日 2021 年 9 月 2 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.