(window.webpackJsonp=window.webpackJsonp||[]).push([["chunk-2d2311ab"],{eeb7:function(e,t,a){"use strict";a.r(t);var s={props:{im:{type:Object,default:function(){return{}}},id:{type:String,default:""},width:{type:Number,default:250},sceneCp:{type:String,default:""},keyWord:{type:String,default:""},hasMore:{type:Boolean,default:!1},closeSearchBoxFlag:{type:Boolean,default:!1},searchKcodeList:{type:Array,default:function(){return[]}},searchedNumber:{type:Array,default:function(){return[]}},searchTeamList:{type:Array,default:function(){return[]}},historyRecord:{type:Array,default:function(){return[]}}},data:function(){return{tabs:[{value:"0",name:"全部",labelWidth:"44px"},{value:"1",name:"网点",labelWidth:"45px"},{value:"2",name:"我的组织",labelWidth:"44px"},{value:"3",name:"群聊",labelWidth:"45px"}],navSelctType:"0",currentnavSelctType:"",showHistoryReacdFlag:!1,contactLoading:!1,kcodeItems:[],kecodeflag:!1,kcodeKey:{},searchedDataTeam:{}}},components:{"im-search-history":()=>a.e("chunk-72e91eb7").then(a.bind(null,"f7f3")),"im-search-member":()=>a.e("chunk-efcfda94").then(a.bind(null,"1589")),"im-search-kcode":()=>a.e("chunk-14f271f4").then(a.bind(null,"db95")),"im-search-team":()=>a.e("chunk-e6d87164").then(a.bind(null,"8d29")),"im-history-record":()=>a.e("chunk-1024c42a").then(a.bind(null,"6032"))},created:function(){},mounted:function(){},computed:{},methods:{searchNetworkTeam(){let e=this;this.im.getTeam({teamId:e.keyWord,done:function(t,a){if(!t){for(var[s,r]of Object.entries(a))e.$set(e.searchedDataTeam,s,r);e.$set(e.searchedDataTeam,"isNetWorkSearch",!0)}}})},searchNetTeam(){this.navSelctType="3"},clearSearchHistoryState(){this.$emit("clearSearchHistoryState",!0)},changeTabState(){this.$emit("changeTabState",!0)},dragHistoryBox(e){this.$emit("dragHistoryBoxTo",e)},returnToKcode:function(e){this.navSelctType=e.currentnavSelctType,this.kcodeKey=e.item},enterChatRoom:function(e){this.$emit("enterChatRoom",e),this.closeHistoryRecord()},createSession:function(e){this.$emit("createSession",e),this.closeHistoryRecord()},closeHistoryRecord:function(){this.navSelctType="0",this.$emit("closeSearchDialog")},switchTab:function(e){1==e?this.$emit("searchtabNavchange","1"):2==e?this.$emit("searchtabNavchange","2"):3==e?this.$emit("searchtabNavchange","3"):this.$emit("searchtabNavchange","0"),this.navSelctType=e},searchNearestHistory:function(e){this.$emit("searchNearestHistory",e)}},watch:{navSelctType:function(){this.$emit("searchtabNavchange","0")},keyWord:function(e){e&&this.searchNetworkTeam()},closeSearchBoxFlag:function(e){e?this.closeHistoryRecord():this.searchedDataTeam={}}},beforeDestroy:function(){this.closeHistoryRecord()}},r=a("2877");r=Object(r.a)(s,(function(){var e=this,t=e._self._c;return t("div",{staticClass:"p-absolute top-51 left-0 bottom-0 w-100-p bg-white",staticStyle:{"padding-top":"39px"},attrs:{id:"search-value-box"}},[t("div",{staticClass:"p-absolute top-0 left-0 w-100-p h-39 b-b b-c-g-100"},[t("ul",{staticClass:"d-table w-100-p h-100-p"},e._l(e.tabs,(function(a){return t("li",{key:a.value,staticClass:"p-relative d-table-cell h-100-p t-a-center v-a-middle cursor-pointer cursor-pointer user-select-none c-blue-hover search-tab-element",class:{"c-blue":e.navSelctType===a.value},style:{width:100/e.tabs.length+"%"},on:{mousedown:function(t){return t.preventDefault(),e.changeTabState.apply(null,arguments)}}},[t("label",[e._v(e._s(a.name)),t("input",{directives:[{name:"model",rawName:"v-model",value:e.navSelctType,expression:"navSelctType"}],staticClass:"d-none",attrs:{type:"radio",name:"imNavTabRadio"},domProps:{value:a.value,checked:e._q(e.navSelctType,a.value)},on:{change:function(t){e.navSelctType=a.value}}})]),t("i",{staticClass:"d-none p-absolute left-0 right-0 m-auto h-2",class:{"d-block":e.navSelctType===a.value},staticStyle:{bottom:"-1px","background-color":"#653EB3"},style:{width:a.labelWidth}})])})),0)]),t("div",{directives:[{name:"show",rawName:"v-show",value:"0"===e.navSelctType,expression:"navSelctType==='0'"}],staticClass:"h-100-p o-auto left-personnel-box"},[t("im-search-history",{directives:[{name:"show",rawName:"v-show",value:!e.keyWord,expression:"!keyWord"}],on:{clearSearchHistoryState:e.clearSearchHistoryState,searchNearestHistory:e.searchNearestHistory}}),e.keyWord?[e.keyWord?t("im-history-record",{attrs:{width:e.width,im:e.im,hasMore:e.hasMore,historyRecord:e.historyRecord,keyWord:e.keyWord,navSelctType:e.navSelctType},on:{dragHistoryBox:e.dragHistoryBox,closeHistoryRecord:e.closeHistoryRecord,enterChatRoom:e.enterChatRoom,switchTab:e.switchTab}}):e._e(),e.keyWord&&e.searchKcodeList.length?t("im-search-kcode",{attrs:{width:e.width,im:e.im,keyWord:e.keyWord,kcodeItems:e.searchKcodeList,currentnavSelctType:"1",navSelctType:e.navSelctType},on:{returnToKcode:e.returnToKcode,switchTab:e.switchTab,createSession:e.createSession}}):e._e(),e.keyWord&&e.searchedNumber.length?t("im-search-member",{attrs:{width:e.width,im:e.im,keyWord:e.keyWord,searchedNumber:e.searchedNumber,currentnavSelctType:"2",navSelctType:e.navSelctType},on:{switchTab:e.switchTab,createSession:e.createSession}}):e._e(),e.keyWord&&(e.searchTeamList.length||e.searchedDataTeam.teamId)?t("im-search-team",{attrs:{width:e.width,im:e.im,keyWord:e.keyWord,searchTeamList:e.searchTeamList,searchedDataTeam:e.searchedDataTeam,currentnavSelctType:"3",navSelctType:e.navSelctType},on:{switchTab:e.switchTab,createSession:e.createSession}}):e._e(),e.searchKcodeList.length||!e.keyWord||e.searchedNumber.length||e.searchTeamList.length||e.historyRecord.length||e.searchedDataTeam.teamId?e._e():t("div",{staticClass:"t-a-center p-x-20 l-h-24 p-y-10"},[e._v("未搜索到 “"+e._s(e.keyWord)+"” 的相关内容")])]:e._e()],2),t("div",{directives:[{name:"show",rawName:"v-show",value:"1"===e.navSelctType,expression:"navSelctType==='1'"}],staticClass:"h-100-p o-auto left-personnel-box"},[t("im-search-kcode",{attrs:{width:e.width,kcodeKey:e.kcodeKey,im:e.im,keyWord:e.keyWord,kcodeItems:e.searchKcodeList,currentnavSelctType:e.navSelctType,navSelctType:e.navSelctType},on:{createSession:e.createSession}})],1),t("div",{directives:[{name:"show",rawName:"v-show",value:"2"===e.navSelctType,expression:"navSelctType==='2'"}],staticClass:"h-100-p o-auto left-personnel-box"},[t("im-search-member",{attrs:{width:e.width,im:e.im,keyWord:e.keyWord,searchedNumber:e.searchedNumber,currentnavSelctType:e.navSelctType,navSelctType:e.navSelctType},on:{createSession:e.createSession}})],1),t("div",{directives:[{name:"show",rawName:"v-show",value:"3"===e.navSelctType,expression:"navSelctType==='3'"}],staticClass:"h-100-p o-auto left-personnel-box"},[t("im-search-team",{attrs:{width:e.width,im:e.im,keyWord:e.keyWord,searchTeamList:e.searchTeamList,searchedDataTeam:e.searchedDataTeam,currentnavSelctType:e.navSelctType,navSelctType:e.navSelctType},on:{createSession:e.createSession}})],1)])}),[],!1,null,null,null);t.default=r.exports}}]);