Commit 5af94b96 authored by leiqingsong's avatar leiqingsong

修改

parent 0d41adf1
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
</template> </template>
<script> <script>
import { getAuthToken, showBottomBar } from "@/utils/bridgeToAppFun"; import { getAuthToken } from "@/utils/bridgeToAppFun";
import BaseNavBar from "./components/BaseNavBar.vue"; import BaseNavBar from "./components/BaseNavBar.vue";
export default { export default {
components: { components: {
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
</template> </template>
<script> <script>
// import { navigateBack } from "@/utils/bridgeToAppFun";
export default { export default {
name: "BaseNavBar", name: "BaseNavBar",
props: { props: {
...@@ -20,6 +21,13 @@ export default { ...@@ -20,6 +21,13 @@ export default {
}, },
methods: { methods: {
onClickLeft() { onClickLeft() {
// console.log(this.$router);
// const currentPage = this.$router.currentRoute;
// if (whiteList.indexof(currentPage) > -1) {
// navigateBack();
// } else {
// this.$router.go(-1);
// }
this.$router.go(-1); this.$router.go(-1);
}, },
onClickRight() { onClickRight() {
......
export function getUserId() { export function getUserId() {
let userInfo = localStorage.getItem("user"); let userInfo = localStorage.getItem("user");
if (userInfo) { if (userInfo) {
return JSON.parse(userInfo).userId || ""; return JSON.parse(userInfo).userId;
} else { } else {
return ""; return "";
} }
......
...@@ -72,11 +72,11 @@ export default { ...@@ -72,11 +72,11 @@ export default {
}; };
console.log('setting-userId', params); console.log('setting-userId', params);
getUserInfo2(params).then(res => { getUserInfo2(params).then(res => {
if (res.code == 0) { if (res.userId) {
localStorage.setItem("user", JSON.stringify(res.data)); localStorage.setItem("user", JSON.stringify(res));
this.$nextTick(() => { this.$nextTick(() => {
this.inviteeCode = res.data.inviteCode; this.inviteeCode = res.beInviteCode;
this.avatar = "http://8.131.244.76:81" + res.data.headImage; this.avatar = "http://8.131.244.76:81" + res.headImage;
}) })
} }
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment