Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-55348

Display Pull Request Name instead of ID in the UI

    Details

    • Similar Issues:

      Description

      Currently, in the UI, the Pull Request (PR) ID is displayed as the job name (example: PR-3), and when you mouse hover over the PR ID then the PR name pops up in a tool-tip label. This should be reversed, the job name should be named after the Pull Request name, not the ID, and the tool-tip should pop up showing the PR ID. The PR name appearing in the UI is much more important than the PR ID, and showing the PR name as the Jenkins job name is much more valuable to the user. Alternatively, the UI can display "{PR-ID} - {PR-NAME}" as the job name.

      Note: The job ID itself can remain as the PR ID (what appears in the URL), it's just what appears in the UI to the user that's important, the "display name" for the job name should be the PR name, or at least have the PR name as part of the human-readable label.

        Attachments

          Activity

          Hide
          warden Radek Antoniuk added a comment -

          The Pull Request name can be really long and although less UX friendly, it's more UI friendly.

          Show
          warden Radek Antoniuk added a comment - The Pull Request name can be really long and although less UX friendly, it's more UI friendly.
          Hide
          alan_czajkowski Alan Czajkowski added a comment - - edited

          Radek Antoniuk If the Pull Request name is very long then there are very easy styling tricks to truncate the name on the UI. You can either use CSS to elegantly truncate the the long line or do a hard-truncate when passing the name to the UI and then adding ellipses (...) to the end of the name. Either way, almost nobody knows what their PR ID is, and they are looking for their PR name in the list – it actually takes some effort to find the PR ID on most Git UIs (GitHub, Bitbucket, etc.).

          Show
          alan_czajkowski Alan Czajkowski added a comment - - edited Radek Antoniuk If the Pull Request name is very long then there are very easy styling tricks to truncate the name on the UI. You can either use CSS to elegantly truncate the the long line or do a hard-truncate when passing the name to the UI and then adding ellipses (...) to the end of the name. Either way, almost nobody knows what their PR ID is, and they are looking for their PR name in the list – it actually takes some effort to find the PR ID on most Git UIs (GitHub, Bitbucket, etc.).
          Hide
          philip_abraham Philipp Abraham added a comment -

          We were injecting a custom CSS rule to achieve that:

          #projectstatus a[title]::after {
          	content: " (" attr(title) ") ";
          } 

          But we are still unhappy about the state as you can't find PR branches when you use the Jenkins search as this is just a visual fix

          Show
          philip_abraham Philipp Abraham added a comment - We were injecting a custom CSS rule to achieve that: #projectstatus a[title]::after { content: " (" attr(title) ") " ; } But we are still unhappy about the state as you can't find PR branches when you use the Jenkins search as this is just a visual fix
          Hide
          alan_czajkowski Alan Czajkowski added a comment -

          any ETA on this? it's a very easy fix, it's just a small UI change (the job name/id does not change)

          Show
          alan_czajkowski Alan Czajkowski added a comment - any ETA on this? it's a very easy fix, it's just a small UI change (the job name/id does not change)
          Hide
          paybas Pay Bas added a comment - - edited

          Just attached a screenshot to show how silly this problem is. It prohibits easy use of monitoring because most information is lost. Nobody knows what PR-1360 means and which branch or PR-name it refers to.

          Show
          paybas Pay Bas added a comment - - edited Just attached a screenshot to show how silly this problem is. It prohibits easy use of monitoring because most information is lost. Nobody knows what PR-1360 means and which branch or PR-name it refers to.
          Hide
          alan_czajkowski Alan Czajkowski added a comment - - edited

          Attaching another screenshot example:

          The Jenkins UI shows "PR-20" but nobody really knows what that is, showing the PR name is much more valuable. And the PR name is already available to the UI because when you hover your mouse over the hyperlink, the tooltip popup shows the PR name. The UI should flip that display experience, the hyperlink text should be the PR name, and when you hover the mouse over the text, the tooltip popup should show the PR ID.

          Show
          alan_czajkowski Alan Czajkowski added a comment - - edited Attaching another screenshot example: The Jenkins UI shows "PR-20" but nobody really knows what that is, showing the PR name is much more valuable. And the PR name is already available to the UI because when you hover your mouse over the hyperlink, the tooltip popup shows the PR name. The UI should flip that display experience, the hyperlink text should be the PR name, and when you hover the mouse over the text, the tooltip popup should show the PR ID.
          Hide
          paybas Pay Bas added a comment -

          Perhaps better than changing the current behavior, a new SCMSourceTrait could be added for "changing PR display names". Perhaps using something like the https://plugins.jenkins.io/token-macro behavior, so we could enter a string like:

          "PR-${pullRequestId}"  or  "PR-${pullRequestId} | ${branchName}"  or  "PR-${pullRequestId} = ${pullRequestName}"

          Show
          paybas Pay Bas added a comment - Perhaps better than changing the current behavior, a new SCMSourceTrait could be added for "changing PR display names". Perhaps using something like the https://plugins.jenkins.io/token-macro behavior, so we could enter a string like: "PR-${pullRequestId}"   or  "PR-${pullRequestId} | ${branchName}"   or  "PR-${pullRequestId} = ${pullRequestName}"
          Hide
          paybas Pay Bas added a comment -

          This is the Trait that I created. Working well. Going on holiday soon so a colleague of mine will probably finish it and create a PR.

           

           

          Show
          paybas Pay Bas added a comment - This is the Trait that I created. Working well. Going on holiday soon so a colleague of mine will probably finish it and create a PR.    

            People

            • Assignee:
              Unassigned
              Reporter:
              alan_czajkowski Alan Czajkowski
            • Votes:
              5 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

              • Created:
                Updated: