2016-11-14 18 views
1

作爲我們網絡報告工具的一部分,我們正在將一堆JIRA頁面提取到一個頁面中。要做到這一點,我們獲取的頁面到iframe如下:使用iframe提取Jira Scrum板

<div class='embed-container'><iframe src='http://jira.ourcompany.com/secure/RapidBoard.jspa?rapidView=6044&view=planning.nodetail' style='border:0;'></iframe></div> 

<style>body { margin: 0px; } .embed-container { position: relative; padding-bottom: 100%; height: 0; overflow: hidden; max-width: 100%; min-height: 100%; } .embed-container iframe, .embed-container object, .embed-container embed { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }</style> 

單獨的鏈接http://jira.ourcompany.com/secure/RapidBoard.jspa?rapidView=6044&view=planning.nodetail工作正常,我們得到的結果,但iframe中它返回一個例外

An error occurred 
Please try refreshing the page, or contact your administrator/Atlassian Support if the problem continues. 
Details 
Exception: Uncaught Error: No jira/ajs/select/single-select 
Resource: http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US 
Line: 6 
Column: 1882 
Exception: Uncaught TypeError: Cannot read property 'init' of undefined 
Resource: http://jira.ourcompany.com/secure/RapidBoard.jspa?rapidView=6044&projectKey=VSNFOUR&view=reporting&chart=releaseBurndown&version=78791 
Line: 148 
Column: 32 
Exception: Uncaught TypeError: Cannot read property 'trigger' of undefined 
Resource: http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US 
Line: 308 
Column: 517 
Exception: Uncaught Error: undefined missing jira/flag 
Resource: http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US 
Line: 6 
Column: 3661 
Exception: Uncaught Error: undefined missing jira/flag 
Resource: http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US 
Line: 6 
Column: 3661 
Exception: Uncaught Error: undefined missing jira/license-banner 
Resource: http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US 
Line: 6 
Column: 3661 
Environment 
Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36 
Stack trace 
Error: No jira/ajs/select/single-select 
at callDep (http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US:6:1888) 
at req (http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US:6:4223) 
at window.require (http://jira.ourcompany.com/s/323e93367fc956e3ac0c0e0c46249982-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/0c798f90b1a61deafa1d5193fc512be9/_/download/contextbatch/js/_super/batch.js?atlassian.aui.raphael.disabled=true&locale=en-US:9:258) 
at http://jira.ourcompany.com/s/0eece49457aceb5c9183460c268f6764-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/284fab080430022efdcdeab955978f67/_/download/contextbatch/js/greenhopper-rapid-non-gadget,atl.general,gh-rapid,jira.global,jira.project.sidebar,jira.general,-_super/batch.js?agile_global_admin_condition=true&is-server-instance=true&jag=true&jaguser=true&locale=en-US&nps-acknowledged=true&nps-not-opted-out=true:100:30 
at http://jira.ourcompany.com/s/0eece49457aceb5c9183460c268f6764-CDN/en_USahlg6s/71012/22d2be4a45e303262123c6f0c4c063aa/284fab080430022efdcdeab955978f67/_/download/contextbatch/js/greenhopper-rapid-non-gadget,atl.general,gh-rapid,jira.global,jira.project.sidebar,jira.general,-_super/batch.js?agile_global_admin_condition=true&is-server-instance=true&jag=true&jaguser=true&locale=en-US&nps-acknowledged=true&nps-not-opted-out=true:100:965 

有趣的部分是,當我們使用JQL像:

<div class='embed-container'><iframe src='http://jira.ourcompany.com/issues/?jql=project=VSNR AND type=Bug AND priority=P1 AND &quot;Responsible Organization&quot;=&quot;OurTeam&quot; AND status!=DONE AND status!=WITHDRAWN' style='border:0;'></iframe></div> 

網頁在iframe中正確顯示。

以前有沒有人使用過iframe和JIRA板?

感謝

回答