1 line
3.4 KiB
PHP
1 line
3.4 KiB
PHP
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-47a9ae4d"],{"6e0f":function(t,e,i){"use strict";i.r(e);i("7f7f");var n=function(){var t=this,e=t._self._c;return e("div",{staticClass:"inviteFromLink",staticStyle:{height:"100%"}},[e("div",{staticClass:"content"},[e("a-spin",{attrs:{spinning:t.loading}},[t.inviteLink?e("a-card",{attrs:{title:"来自 ".concat(t.inviteLink.member.name," 的邀请")}},[e("div",{staticClass:"header"},[e("span",[t._v("\n "+t._s(t.inviteLink.member.name)+" 邀请你\n "),"project"==t.inviteLink.invite_type?e("span",[t._v("加入项目「"+t._s(t.inviteLink.sourceDetail.name)+"」")]):t._e(),"organization"==t.inviteLink.invite_type?e("span",[t._v("加入组织「"+t._s(t.inviteLink.sourceDetail.name)+"」")]):t._e()])]),e("div",{staticClass:"member-info"},[e("div",{staticClass:"avatar"},[e("a-avatar",{attrs:{size:"large",src:t.inviteLink.member.avatar}})],1),e("div",{staticClass:"info"},[e("p",[t._v(t._s(t.inviteLink.member.name))]),e("p",{staticClass:"muted"},[t._v(t._s(t.inviteLink.member.email))])])]),e("a-button",{staticClass:"middle-btn",attrs:{type:"primary",block:"",size:"large"},on:{click:t.acceptInvite}},["project"==t.inviteLink.invite_type?e("span",[t._v("加入项目")]):t._e(),"organization"==t.inviteLink.invite_type?e("span",[t._v("加入组织")]):t._e()])],1):t._e()],1)],1)])},a=[],r=(i("8e6e"),i("ac6a"),i("456d"),i("a481"),i("ade3")),s=i("2f62"),o=i("2f14"),c=i("82f8"),u=i("9f5d"),v=i("c24f");function p(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),i.push.apply(i,n)}return i}function d(t){for(var e=1;e<arguments.length;e++){var i=null!=arguments[e]?arguments[e]:{};e%2?p(Object(i),!0).forEach((function(e){Object(r["a"])(t,e,i[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):p(Object(i)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(i,e))}))}return t}var f={data:function(){return{loading:!1,inviteLink:void 0}},computed:d({},Object(s["c"])({userInfo:function(t){return t.userInfo}})),created:function(){this.getInviteInfo()},methods:{getInviteInfo:function(){var t=this;this.loading=!0,Object(c["d"])(this.$route.params.code).then((function(e){t.inviteLink=e.data,t.loading=!1}))},acceptInvite:function(){var t=this,e=this;"project"==this.inviteLink.invite_type?Object(u["a"])(this.$route.params.code).then((function(i){var n=Object(o["a"])(i);if(!n)return!1;t.$store.dispatch("setOrganizationList",i.data.organizationList),t.$store.dispatch("setCurrentOrganization",i.data.currentOrganization),setTimeout((function(){e.$router.replace({name:"task",params:{code:e.inviteLink.source_code}})}),500)})):"organization"==this.inviteLink.invite_type&&Object(v["i"])(this.$route.params.code).then((function(i){Object(o["a"])(i)&&(t.$store.dispatch("setOrganizationList",i.data.organizationList),t.$store.dispatch("setCurrentOrganization",i.data.currentOrganization),t.$notice({title:"你已成功加入组织",msg:"你可以在右上方切换当前组织"},"notice","success"),setTimeout((function(){e.$router.replace("/")}),500))}))}}},l=f,m=(i("a02a"),i("2877")),b=Object(m["a"])(l,n,a,!1,null,null,null);e["default"]=b.exports},a02a:function(t,e,i){"use strict";i("dd18")},dd18:function(t,e,i){}}]); |