Commit 9d449fec by 匡雅琴

调整

1 parent 2022ba44
...@@ -45,12 +45,11 @@ Page({ ...@@ -45,12 +45,11 @@ Page({
customerType: 0, customerType: 0,
// 是否授权昵称 // 是否授权昵称
hasUserInfo: false, hasUserInfo: false,
<<<<<<< HEAD
// 是否授权手机号 // 是否授权手机号
hasPhoneNumber: false hasPhoneNumber: false,
======= curTab: [trackData.COMPANY, trackData.CUBE],
curTab: [trackData.COMPANY, trackData.CUBE] // 员工名片信息
>>>>>>> 8d35ac732b4e690c36b92f97d7f3262c98e54c4a cardInfo: []
}, },
introduce(e) { introduce(e) {
const curTabIndex = e.currentTarget.dataset.index; const curTabIndex = e.currentTarget.dataset.index;
...@@ -87,15 +86,21 @@ Page({ ...@@ -87,15 +86,21 @@ Page({
*/ */
onLoad(options) { onLoad(options) {
console.log(this.data.hasUserInfo); console.log(this.data.hasUserInfo);
// 获取员工名片信息 getApp().login().then(({data}) => {
const sessionId = util.getSessionId(); console.log(data);
let params = {}; if (data) {
params.cardId = 21; this.setData({
params.sessionId = sessionId; hasUserInfo: true
console.log(params, "+++"); })
// entmicroApi.getCardDetail(params).then((res) => { }
// console.log(res); if (data.phone) {
// }); this.setData({
hasPhoneNumber: true
})
} else {
this.getCardDetail()
}
})
}, },
/** /**
...@@ -292,5 +297,20 @@ Page({ ...@@ -292,5 +297,20 @@ Page({
}) })
} }
}) })
},
// 获取员工名片信息
getCardDetail() {
const sessionId = util.getSessionId();
let params = {};
params.cardId = 21;
params.sessionId = sessionId;
console.log(params, "+++");
entmicroApi.getCardDetail(params).then((res) => {
console.log(res);
if (res.data) {
} }
});
}
}) })
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<import src="../../template/equity/equity" /> <import src="../../template/equity/equity" />
<import src="../../template/clue/clue" /> --> <import src="../../template/clue/clue" /> -->
<view class="main-box"> <view class="main-box">
<user-info></user-info> <user-info data="{{cardInfo}}"></user-info>
<view class="main-bottom"> <view class="main-bottom">
<!-- 面向渠道 --> <!-- 面向渠道 -->
<template is="channel"></template> <template is="channel"></template>
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!