| | |
| | | |
| | | <view style="height:205rpx;"></view> |
| | | <view class="tab" style="position: fixed;top: 0;width: 100%;height: 205rpx;z-index: 100;"> |
| | | <u-navbar style="position: relative;left: -20rpx;" :is-fixed="false" :border-bottom="false" :is-back="false" title="好友" |
| | | :background="{ background: '#0BB9C8' }" title-color="#fff"> |
| | | <u-navbar style="position: relative;left: -20rpx;" :is-fixed="false" :border-bottom="false" :is-back="false" |
| | | title="好友" :background="{ background: '#0BB9C8' }" title-color="#fff"> |
| | | <image slot="right" src="/static/images/home/message.png" class="message-icon" mode="widthFix"></image> |
| | | </u-navbar> |
| | | <u-tabs :list="list" :is-scroll="false" :current="current" active-color="#14B9C8" inactive-color="#595959" |
| | |
| | | <div class="m-main"> |
| | | <!-- <view class="inTitle">{{Task}}</view> --> |
| | | <view class="inTmain"> |
| | | <contacts v-for="(item,index) in dataListQZ" :key="index" :Pdata="item" :fromW="indexs" |
| | | <contacts v-for="(item,index) in dataListTXL" :key="index" :Pdata="item" :fromW="indexs" |
| | | @refreshTask="refreshTask"></contacts> |
| | | </view> |
| | | </div> |
| | |
| | | <div class="m-main"> |
| | | <!-- <view class="inTitle">{{Task}}</view> --> |
| | | <view class="inTmain"> |
| | | <contacts v-for="(item,index) in dataListTXL" :key="index" :Pdata="item" :fromW="indexs" |
| | | <contacts v-for="(item,index) in dataListQZ" :key="index" :Pdata="item" :fromW="indexs" |
| | | @refreshTask="refreshTask"></contacts> |
| | | </view> |
| | | </div> |
| | |
| | | import navBarTop from '../../components/nav-bar-top/nav-bar-top.vue'; |
| | | export default{ |
| | | components: { |
| | | navBarTop,contacts |
| | | navBarTop, |
| | | contacts |
| | | }, |
| | | data() { |
| | | return { |
| | |
| | | name: '正在聊天' |
| | | }, |
| | | { |
| | | name: '群组' |
| | | name: '好友' |
| | | }, |
| | | { |
| | | name: '好友' |
| | | name: '群组' |
| | | } |
| | | ], |
| | | swiperHeight: 0, |
| | |
| | | }); |
| | | }else if(this.current == 1){ |
| | | uni.request({ |
| | | url:"http://223.82.109.183:2080/api/chatgroup/selectList", |
| | | method:"POST", |
| | | data:{ |
| | | senderId: WxStorage.get("ids") |
| | | }, |
| | | success:(res)=> { |
| | | var resdata = res.data.data; |
| | | for (var i = 0; i < resdata.length; i++) { |
| | | if(resdata[i].avatar == null || resdata[i].avatar == ""){ |
| | | resdata[i].avatar = "http://s16s652780.51mypc.cn/img/bg/qunz.png"; |
| | | } |
| | | } |
| | | that.dataListQZ = resdata; |
| | | that.swiperHeight = resdata.length * 85; |
| | | } |
| | | }) |
| | | }else if(this.current == 2){ |
| | | uni.request({ |
| | | url:"http://223.82.109.183:2080/api/blade-user/page?current=1&size=9999", |
| | | method:"get", |
| | | data:{ |
| | |
| | | } |
| | | } |
| | | that.dataListTXL = resdata; |
| | | that.swiperHeight = resdata.length * 85; |
| | | } |
| | | }) |
| | | } else if (this.current == 2) { |
| | | |
| | | uni.request({ |
| | | url: "http://223.82.109.183:2080/api/chatgroup/selectList", |
| | | method: "POST", |
| | | data: { |
| | | senderId: WxStorage.get("ids") |
| | | }, |
| | | success: (res) => { |
| | | var resdata = res.data.data; |
| | | for (var i = 0; i < resdata.length; i++) { |
| | | if (resdata[i].avatar == null || resdata[i].avatar == "") { |
| | | resdata[i].avatar = "http://s16s652780.51mypc.cn/img/bg/qunz.png"; |
| | | } |
| | | } |
| | | that.dataListQZ = resdata; |
| | | that.swiperHeight = resdata.length * 85; |
| | | } |
| | | }) |
| | |
| | | } |
| | | } |
| | | } |
| | | |
| | | .message-icon { |
| | | width: 32rpx; |
| | | height: auto; |
| | | margin-right: 27rpx; |
| | | } |
| | | |
| | | </style> |