Remove header and footer from Excel export

お困りですか?

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

コミュニティに質問

背景

Certain programs that extract data from Excel require JIRA's Excel export to be trimmed to only include the table of issues. (The header and footer is not required)  

Example output:

 

ソリューション

  • Jira を停止します。
  • Go to the following folder location: $JIRA_INSTALL/atlassian-jira/WEB-INF/classes/templates/plugins/searchrequestviews

  • Open searchrequest-excel-header.vm, and comment out the following parts:

    <!--    
    <table border="1">
    <tr bgcolor="$topBgColour" height="$jiraLogoHeight">
            <td colspan="$colCount">
                <img src="$jiraLogo" width="$jiraLogoWidth" height="$jiraLogoHeight" border="0" alt="$title">
            </td>
        </tr>
        <tr>
            <td colspan="$colCount">
                <a href="$link">$title</a>
            </td>
        </tr> 
        <tr>
            <td colspan="$colCount">
                $resultsDescription
            </td>
        </tr>
    </table>  
    -->

    This removes the top header rows.

  • To remove the footer, open searchrequest-excel-footer.vm and comment out the following parts:

    <!--
    <table border="1" >
    <tr>
        <td bgcolor="#dddddd" colspan="$colCount"><font size="1">
            $generatedInfo
        </font></td>
    </tr>
    </table>
    -->

    (info) To "comment out" a part in the HTML code is to add <!-- and --> to enclose the code block, as per demonstrated above. This means that the interpreter will skip this part of the code. (Its the same thing as removing it directly)

     

  • Restart JIRA for the changes to take effect.

最終更新日: 2016 年 2 月 26 日

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

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