Commit aaf17831 authored by 罗林杰's avatar 罗林杰

修改互要微信

parent 2d052ddf
......@@ -12,17 +12,17 @@
<view style="margin-top: 5px">
<u-tabbar-item text="互要微信" icon="weixin-fill" @click="tabbarClick"/>
<view style="margin-top: -35px;margin-left: 60px">
<u-badge :isDot="true" type="error"></u-badge>
<u-badge :isDot="wxTask.type == '1'" type="error"></u-badge>
</view>
</view>
<u-tabbar-item text="互要联系方式" icon="phone-fill" @click="tabbarClick"/>
</u-tabbar>
</view>
<z-paging ref="paging" v-model="dataList" @query="getMessageList" :fixed="true" :auto-show-back-to-top="true" :back-to-top-with-animate="false">
<z-paging ref="paging" v-model="dataList" @query="getMessageList" use-chat-record-mode>
<view class="page-layout">
<view class="page-body" id="x_chat">
<view v-for="(item, index) in dataList" :key="index">
<view class="chat-item-body">
<view class="chat-item-body" style="transform: scaleY(-1);">
<view class="chat-item-time">{{item.createDate}}</view>
<view v-if="item.createBy == targetId" class="chat-item-layout chat-left">
<view class="chat-inner-layout">
......@@ -45,11 +45,13 @@
</view>
</view>
</view>
</view>
<template #bottom>
<view class="submit-layout">
<input class="submit-input" placeholder="点击输入,开始聊天吧" v-model="inputTemp" @input="bindKeyInput"/>
<view class="submit-submit" type="submit" size="mini" @tap="submitTo">发送</view>
</view>
</view>
</template>
</z-paging>
<u-popup
:show="showApply"
......@@ -163,7 +165,7 @@ export default {
if (e === 1){
//要微信
//发送请求
if (this.wxTask.type == '0'){
if (this.wxTask == null || this.wxTask == ''){
this.wantWxC()
} else if (this.wxTask.type == '1'){
if (this.wxTask.targetId == this.targetId){
......@@ -175,6 +177,16 @@ export default {
}
} else if (this.wxTask.type == '2' && this.wxTask.status == '1'){
this.open()
} else if (this.wxTask.type == '2' && this.wxTask.status == '2'){
if (this.wxTask.targetId == this.targetId){
this.tipMsg = "已拒绝对方请求";
this.isConfirm = true;
this.$refs.elm.showDialog();
} else {
this.tipMsg = "对方已拒绝请求";
this.isConfirm = true;
this.$refs.elm.showDialog();
}
}
}
},
......@@ -346,6 +358,7 @@ export default {
}
wantWeChatTask(form).then(res=>{
if (res.data.code == 200){
this.getWxTask()
uni.showToast({
title: '已发送请求',
icon: 'none'
......@@ -387,6 +400,7 @@ export default {
}
wantWeChatTask(form).then(res=>{
if (res.data.code == 200){
this.getWxTask()
uni.showToast({
title: '已接受请求',
icon: 'none'
......@@ -418,6 +432,7 @@ export default {
}
wantWeChatTask(form).then(res=>{
if (res.data.code == 200){
this.getWxTask()
uni.showToast({
title: '已拒绝请求',
icon: 'none'
......
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