import { panelStatus } from '@/utils/common'
const getters = {
    chatlist (state) {
      return state.user.chatlist
    },
    searchChatlist (state) {
      return state.user.searchChatlist
    },
    chartings(state){
      return state.user.chartings
    },
    selectedChat (state) {
      let temp = state.user.chartings.find(session => session.id === state.user.selectId);
      return temp
    },
    selectId(state){
      return state.user.selectId
    },
    selectedSearchChat(state){
      let temp = state.user.searchChatlist.find(session => session.id === state.user.selectId);
      return temp
    },
    messages (state) {
      let session = state.user.chartings.find(session => session.id === state.user.selectId);
      return session&&session.messages
    },
    userInfo(state){
      return state.user.userInfo
    },
    isSelectMore(state){
      return state.user.isSelectMore
    },
    witchPanel(state){
      return state.baozheng.witchPanel
    },
    sendContent(state){
      return state.baozheng.sendContent
    },
    customerInfo(state){
      return state.baozheng.customerInfo
    },
}
export default getters