(this.webpackJsonpbitdeals=this.webpackJsonpbitdeals||[]).push([[27],{854:function(t,e,n){"use strict";n.d(e,"a",(function(){return r}));var s=n(921),a=(n(0),n(95)),i=n(26),c=n(1);function r(t){return Object(c.jsxs)(c.Fragment,{children:[Object(c.jsx)(a.a,{children:Object(c.jsx)("title",{children:t.title})}),Object(c.jsx)("h2",{className:"title gx-mb-4",children:Object(c.jsx)(i.a,{to:t.url,className:"gx-text-dark",children:Object(c.jsxs)(s.b,{children:[t.icon,t.title]})})})]})}},968:function(t,e,n){"use strict";n.r(e);var s=n(32),a=n(12),i=n(11),c=n(16),r=n(17),l=n(18),j=n.n(l),b=n(0),d=n.n(b),u=n(167),o=n(831),h=n(828),p=n(921),x=n(879),m=n(304),O=n(830),g=n(945),f=n(94),v=n(854),y=n(844),w=n(1),S=o.a.TextArea,k=h.a.TabPane,q=function(t){Object(c.a)(n,t);var e=Object(r.a)(n);function n(t){var i;return Object(a.a)(this,n),(i=e.call(this,t)).pendingStart=function(){i.setState({pending:!0})},i.pendingEnd=function(){i.setState({pending:!1})},i.m=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"admin.console.",n=i.props.intl;return n.formatMessage({id:e+t})},i.submit=Object(s.a)(j.a.mark((function t(){var e;return j.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i.pendingStart(),t.next=3,i.context.api.q(i.state.query,JSON.parse(i.state.params||"{}"));case 3:e=t.sent,i.pendingEnd(),i.setState({result:e});case 6:case"end":return t.stop()}}),t)}))),i.state={pending:!1,query:"",params:"",result:null},i}return Object(i.a)(n,[{key:"render",value:function(){var t=this;return Object(w.jsxs)(w.Fragment,{children:[Object(w.jsx)(v.a,{title:this.m("console"),url:"/admin/console",icon:Object(w.jsx)(y.a,{})}),Object(w.jsxs)(p.b,{direction:"vertical",style:{width:"100%"},children:[Object(w.jsx)(x.a,{style:{width:"100%"},className:"gx-mb-0",children:Object(w.jsxs)(p.b,{direction:"vertical",style:{width:"100%"},children:[Object(w.jsx)(o.a,{value:this.state.query,onChange:function(e){return t.setState({query:e.target.value})},placeholder:this.m("query"),onPressEnter:this.submit}),Object(w.jsx)(S,{rows:3,value:this.state.params,onChange:function(e){return t.setState({params:e.target.value})},placeholder:this.m("params")}),Object(w.jsx)(m.a,{loading:this.state.pending,onClick:this.submit,type:"primary",className:"gx-mb-0 gx-mt-2",children:this.m("submit")})]})}),Object(w.jsx)(x.a,{style:{width:"100%"},className:"inspector",children:Object(w.jsx)(O.a,{spinning:this.state.pending,children:Object(w.jsxs)(h.a,{defaultActiveKey:"object",children:[Object(w.jsx)(k,{tab:this.m("object"),children:Object(w.jsx)(g.a,{expandLevel:2,data:this.state.result})},"object"),Object(w.jsx)(k,{tab:this.m("table"),children:Object(w.jsx)(g.b,{data:this.state.result})},"table")]})})})]})]})}}]),n}(d.a.Component);q.contextType=f.a,e.default=Object(u.c)(q)}}]);