Custom JavaScript to enable web chat in Jira Service Desk Customer Portal pages

お困りですか?

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

コミュニティに質問

The information in this page relates to customizations in Jira. Consequently, Atlassian Support cannot guarantee to provide any support for the steps described on this page as customizations are not covered under Atlassian Support Offerings. Please be aware that this material is provided for your information only and that you use it at your own risk.

また、ファイルの直接変更によって行われるカスタマイズは、アップグレード プロセスには含まれない点にご注意ください。このような変更は、アップグレード後のインスタンスで手動で再適用する必要があります。


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

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

要約

Integrate JIRA Service Management with a live chat application. The live chat application generates a code snippet to be pasted in the HTML pages so that chat widget will appear on the page.

環境

Applicable to almost all versions of Jira Service Management.

ソリューション

Below are steps to insert the code in a Jira Service Management customer facing portal page. In this example, the JSM version being customized is 4.13.13. This version number will vary depending on your Jira Service Management version. 

  1. Take a backup of jira-servicedesk-4.13.13-REL-00xx.jar under /shared-home/atlassian-jira-software-8.13.13-standalone/plugins/installed-plugins
  2. Extract the jar in a temp folder using below command under

    jar xvf jira-servicedesk-4.13.13-REL-00xx.jar
  3. Open soy/backend-cv.soy file and add as shown below. The script may be different based on the web-chat service provider.

    <script>
           {literal}
                /*! loading JS*/
                (function (g, e, n, es, ys) {
    g['_genesysJs'] = e;
    g[e] = g[e] || function (){ (g[e].q = g[e].q || []).push(arguments) };
    g[e].t = 1 * new Date();
    g[e].c = es;
    ys = document.createElement('script'); ys.async = 1; ys.src = n; ys.charset = 'utf-8'; document.head.appendChild(ys);
    })(window, 'Genesys', 'https://apps.mypurecloud.com/genesys-bootstrap/genesys.min.js',{ environment: 'use1', deploymentId: '2624xxxx-21xx-4279-9cef-fxxxx2a1994c' });
          {/literal}
    </script> 
  4. The example of injecting Javascript in soy template file is shown below.
  5. Rebuild the jar using below command:

    jar cvfm jira-servicedesk-4.13.13-REL-00xx.jar META-INF/MANIFEST.MF ./* 
  6. Remove the existing jar under temp directory before rebuilding.
  7. Jira を停止します。
  8. Replace the existing one with the newly built jar. You may want to create a backup copy of the original file in case you need to back out this change.
  9. Jira を起動します。
  10. Re-test the Customer Portal in incognito mode.


As a result, web chat would be added to customer portal.



最終更新日 2023 年 5 月 3 日

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

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