|
@@ -2,13 +2,14 @@
|
|
|
<view class="">
|
|
<view class="">
|
|
|
<view class="index_personal bg-rgba-255 r-20 bor-f1 row-justify-sb center p-40">
|
|
<view class="index_personal bg-rgba-255 r-20 bor-f1 row-justify-sb center p-40">
|
|
|
<view class="center">
|
|
<view class="center">
|
|
|
- <image class="wh-100 r-circle" src="/static/img/index/index-avatar.png" mode="">
|
|
|
|
|
|
|
+ <image class="wh-100 r-circle" v-if="memberData.head_img" src="/static/img/index/index-avatar.png" mode="aspectFill">
|
|
|
|
|
+ <image class="wh-100 r-circle" v-else :src="memberData.head_img" mode="aspectFill">
|
|
|
</image>
|
|
</image>
|
|
|
<view class="m-l20">
|
|
<view class="m-l20">
|
|
|
- <text class="text-color-fff">HI,李亮</text>
|
|
|
|
|
|
|
+ <text class="text-color-fff">HI,{{ memberData.name ? memberData.name : memberData.nickname }}</text>
|
|
|
<view class="text-color-fff size-24 text-center r-20 line-30 p-tb6 p-lr20 m-t10 "
|
|
<view class="text-color-fff size-24 text-center r-20 line-30 p-tb6 p-lr20 m-t10 "
|
|
|
style="background-color: rgba(0, 0, 0, 0.2);opacity: 0.6;">
|
|
style="background-color: rgba(0, 0, 0, 0.2);opacity: 0.6;">
|
|
|
- {{is_admin?'管理员':'业务员'}}
|
|
|
|
|
|
|
+ {{memberData.position_name?memberData.position_name:'无'}}
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
|
</view>
|
|
</view>
|
|
@@ -17,13 +18,14 @@
|
|
|
</view>
|
|
</view>
|
|
|
<uni-popup background-color="#fff" ref="popup" type="left" border-radius="10px 10px 0 0"
|
|
<uni-popup background-color="#fff" ref="popup" type="left" border-radius="10px 10px 0 0"
|
|
|
@touchmove.stop.prevent="moveHandle">
|
|
@touchmove.stop.prevent="moveHandle">
|
|
|
- <SystemPopup ref="system" @onCloseSystem="onCloseSystem"></SystemPopup>
|
|
|
|
|
|
|
+ <SystemPopup ref="system" :member-data="memberData" ></SystemPopup>
|
|
|
</uni-popup>
|
|
</uni-popup>
|
|
|
</view>
|
|
</view>
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
import SystemPopup from "@/common/system_popup/system_popup.vue"
|
|
import SystemPopup from "@/common/system_popup/system_popup.vue"
|
|
|
|
|
+ import {getMemberInfo} from "@/api/user";
|
|
|
|
|
|
|
|
export default {
|
|
export default {
|
|
|
name: 'index_personal',
|
|
name: 'index_personal',
|
|
@@ -40,7 +42,45 @@
|
|
|
default: () => {}
|
|
default: () => {}
|
|
|
},
|
|
},
|
|
|
},
|
|
},
|
|
|
|
|
+ data(){
|
|
|
|
|
+ return{
|
|
|
|
|
+ memberData: {
|
|
|
|
|
+ position_name: "",
|
|
|
|
|
+ head_img: "",
|
|
|
|
|
+ id: 5,
|
|
|
|
|
+ name: "",
|
|
|
|
|
+ nickname: "",
|
|
|
|
|
+ phone: "",
|
|
|
|
|
+ status: 1,
|
|
|
|
|
+ user_type: 1,
|
|
|
|
|
+ accomplish_num: 0,
|
|
|
|
|
+ take_num: 0,
|
|
|
|
|
+ manage_num: 0,
|
|
|
|
|
+ use_num: 0,
|
|
|
|
|
+ end_num: 0,
|
|
|
|
|
+ grand_num: 0,
|
|
|
|
|
+ },
|
|
|
|
|
+ }
|
|
|
|
|
+ },
|
|
|
|
|
+ mounted() {
|
|
|
|
|
+ this.getMemberInfo();
|
|
|
|
|
+ uni.$on('updateMemberInfo', () => {
|
|
|
|
|
+ this.getMemberInfo();
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
methods: {
|
|
methods: {
|
|
|
|
|
+ getMemberInfo() {
|
|
|
|
|
+ getMemberInfo({
|
|
|
|
|
+ 'type': 1
|
|
|
|
|
+ }).then((res) => {
|
|
|
|
|
+ if (res.code === 1) {
|
|
|
|
|
+ this.memberData = res.data;
|
|
|
|
|
+ uni.setStorageSync('receivingType', res.data.receivingType)
|
|
|
|
|
+ uni.setStorageSync('enteringType', res.data.enteringType)
|
|
|
|
|
+ this.$emit('setMemberData',this.memberData)
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
+ },
|
|
|
onSystemShow() {
|
|
onSystemShow() {
|
|
|
this.$refs.popup.open('left')
|
|
this.$refs.popup.open('left')
|
|
|
},
|
|
},
|