export default {
  state: {
    subscribeMessageTemplates: {},
    spaceCardInfo: {
      imgUrl: '',
      roomName: '',
      envData: {
        temperature: '',
        humidity: '',
        pm25: '',
        co2: '',
        hcho: '',
        tvoc: '',
        pmIndicator: '优'
      },

      spaceId: '',
      roomType: '' // private_room-房间，public_room-开发空间
    }
  },
  mutations: {
    setSubscribeMessageTemplates(state, subscribeMessageTemplates) {
      state.subscribeMessageTemplates = subscribeMessageTemplates
    },
    setspaceCardInfo(state, spaceCardInfo) {
      state.spaceCardInfo = {...spaceCardInfo}
    }
  },
  actions: {
    setSubscribeMessageTemplates({ commit }, data) {
      commit('setSubscribeMessageTemplates', data);
    },
    setspaceCardInfo({commit}, data) {
      commit('setspaceCardInfo', data);
    }
  }
}
