(this.webpackJsonp=this.webpackJsonp||[]).push([[138],{IFDV:function(e,t,n){"use strict";n.r(t),t.default=n.p+"static/media/devops.39983f5b.png"},"cuo/":function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=n("cDcd"),r=c(a),o=n("spEH");n("y8uv");var l=c(n("IFDV")),u=(n("eO8H"),c(n("CnBM"))),i=c(n("HUFq")),d=c(n("vDqi"));function c(e){return e&&e.__esModule?e:{default:e}}(0,u.default)({loader:function(){return Promise.all([n.e(0),n.e(1),n.e(8),n.e(21),n.e(131)]).then(n.t.bind(null,"lRUx",7))},loading:i.default}),(0,u.default)({loader:function(){return Promise.all([n.e(12),n.e(118),n.e(90)]).then(n.t.bind(null,"JtPb",7))},loading:i.default}),(0,u.default)({loader:function(){return Promise.all([n.e(0),n.e(1),n.e(8),n.e(21)]).then(n.t.bind(null,"Jwem",7))},loading:i.default}),(0,u.default)({loader:function(){return Promise.all([n.e(0),n.e(1),n.e(8),n.e(73)]).then(n.t.bind(null,"t8ff",7))},loading:i.default}),(0,u.default)({loader:function(){return Promise.all([n.e(0),n.e(1),n.e(8),n.e(12),n.e(60)]).then(n.t.bind(null,"ZYHo",7))},loading:i.default}),(0,u.default)({loader:function(){return Promise.all([n.e(0),n.e(1),n.e(8),n.e(69)]).then(n.t.bind(null,"ZxKT",7))},loading:i.default}),t.default=function(e){var t=e.isManager,n=e.project,u=e.projectDetail,i=e.match.params,c=i.projectsId,f=i.owner,s=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],a=!0,r=!1,o=void 0;try{for(var l,u=e[Symbol.iterator]();!(a=(l=u.next()).done)&&(n.push(l.value),!t||n.length!==t);a=!0);}catch(e){r=!0,o=e}finally{try{!a&&u.return&&u.return()}finally{if(r)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")}((0,a.useState)(void 0),2),m=s[0],v=s[1];function h(e){if(e&&e.data&&"string"==typeof e.data){var t=JSON.parse(e.data);document.querySelector("#devopsIframe")&&(document.querySelector("#devopsIframe").height=t.height)}}return(0,a.useEffect)((function(){if(u){var e=u.author,t=u.name;document.title="引擎-"+e.name+"/"+t}}),[u]),(0,a.useEffect)((function(){var e="/"+f+"/"+c+"/simple.json";d.default.get(e).then((function(e){e&&e.data&&e.data.jianmu_devops&&v(encodeURIComponent(e.data.jianmu_devops))}))}),[]),(0,a.useEffect)((function(){return window.addEventListener("message",h,!1),function(){window.removeEventListener("message",h,!1)}})),r.default.createElement(o.WhiteBack,{className:"opsPanel "+(t?"main":"")},m&&n&&t&&r.default.createElement("iframe",{title:"devopsIframe",src:n.jianmu_devops_url+"/oauth2/authorize?code="+m,id:"devopsIframe",frameBorder:"0",name:"devopsIframe",width:"100%",onLoad:function(){try{var e=document.getElementById("devopsIframe");e.contentDocument&&(e.height=e.contentDocument.querySelector(".el-main").clientHeight+260)}catch(e){}},height:"auto"}),!t&&r.default.createElement("div",{className:"nullJurisdictionBox"},r.default.createElement("div",{className:"jurTil font-16"},"引擎配置"),r.default.createElement("div",{className:"jurCont mt25"},r.default.createElement("img",{src:l.default,alt:"",width:110}),r.default.createElement("div",{className:"font-18 mt30"},"暂无权限，仅仓库管理员可访问"))))}},y8uv:function(e,t,n){}}]);