Commit 581fa42f by chenwq

im全屏

1 parent 1015b135
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
<router-view v-if="!$route.meta.keepAlive"></router-view> <router-view v-if="!$route.meta.keepAlive"></router-view>
</transition> </transition>
</template> </template>
<action v-show="$route.meta.showAction"></action> <action v-show="$route.meta.showAction && !$store.state.app.isLiveFull"></action>
</div> </div>
</template> </template>
<script> <script>
......
...@@ -8,11 +8,13 @@ ...@@ -8,11 +8,13 @@
} }
} }
.layout { .layout {
padding-bottom: 100px; padding-bottom: 100px;
&.no-padding {
padding: 0;
}
.empty-page { .empty-page {
position: absolute; position: absolute;
top: 0; top: 0;
...@@ -47,7 +49,7 @@ ...@@ -47,7 +49,7 @@
border-radius: 100%; border-radius: 100%;
} }
.big-img { .big-img {
...@@ -470,5 +472,5 @@ ...@@ -470,5 +472,5 @@
} }
} }
} }
...@@ -8,7 +8,6 @@ body .app { ...@@ -8,7 +8,6 @@ body .app {
background-color: #f7f8fa; background-color: #f7f8fa;
-webkit-overflow-scrolling: touch; -webkit-overflow-scrolling: touch;
height: 100%; height: 100%;
// overflow: hidden;
--themeColor: #3975c6; --themeColor: #3975c6;
} }
......
...@@ -105,7 +105,7 @@ export default { ...@@ -105,7 +105,7 @@ export default {
updated() { updated() {
this.scrollToBottom() this.scrollToBottom()
}, },
mounted() {}, mounted() { },
beforeDestroy() { beforeDestroy() {
timObj.quit() timObj.quit()
}, },
...@@ -162,20 +162,23 @@ export default { ...@@ -162,20 +162,23 @@ export default {
let message = data.message let message = data.message
console.log('收到消息:', data) console.log('收到消息:', data)
// 根据消息类型判断,执行不同操作 data.forEach(item => {
if (message.type == 'TIMTextElem') { // 根据消息类型判断,执行不同操作
// 群成员发送消息 if (item.type == 'TIMTextElem') {
// let eleData = JSON.parse() // 群成员发送消息
let eleData = { // let eleData = JSON.parse()
userName: message.from, let eleData = {
content: message.payload.text userName: item.from,
content: item.payload.text
}
// 获取群聊消息,消息上屏
this.updateMessageList(eleData)
} }
// 获取群聊消息,消息上屏 })
this.updateMessageList(eleData)
} // if (message.payload.operationType == 5) {
if (message.payload.operationType == 5) { // // 群聊解散
// 群聊解散 // }
}
// tim.getGroupProfile({ // tim.getGroupProfile({
// groupID: this.groupId // groupID: this.groupId
// }).then(res => { // }).then(res => {
......
...@@ -16,7 +16,8 @@ const state = { ...@@ -16,7 +16,8 @@ const state = {
lastPath: '', lastPath: '',
activityInfo: {}, activityInfo: {},
updataCarInfo: Date.now(), updataCarInfo: Date.now(),
loginStatus: false loginStatus: false,
isLiveFull: false
} }
const mutations = { const mutations = {
SET_ACTIVITY_INFO(state, value) { SET_ACTIVITY_INFO(state, value) {
...@@ -44,6 +45,9 @@ const mutations = { ...@@ -44,6 +45,9 @@ const mutations = {
}, },
SET_LOGIN_STATUS(state, data) { SET_LOGIN_STATUS(state, data) {
state.loginStatus = data state.loginStatus = data
},
SET_LIVE_FULL(state, data) {
state.isLiveFull = data
} }
} }
const actions = { const actions = {
...@@ -63,6 +67,9 @@ const actions = { ...@@ -63,6 +67,9 @@ const actions = {
setLoginStatus({ commit }, value) { setLoginStatus({ commit }, value) {
commit('SET_LOGIN_STATUS', value) commit('SET_LOGIN_STATUS', value)
}, },
setIsLiveFull({ commit }, value) {
commit('SET_LIVE_FULL', value)
},
wxLogin({ dispatch }, { code, redirectUrl, appId }) { wxLogin({ dispatch }, { code, redirectUrl, appId }) {
ssoApi ssoApi
.login({ .login({
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!