This commit is contained in:
zmj 2024-04-29 23:05:49 +08:00
parent 0aed25b996
commit 448733a1c8
3 changed files with 135 additions and 118 deletions

33
App.vue
View File

@ -1,6 +1,6 @@
<script>
// +----------------------------------------------------------------------
// | CRMEB [ CRMEB ]
// | CRMEB [ CRMEB ]
// +----------------------------------------------------------------------
// | Copyright (c) 2016~2021 https://www.crmeb.com All rights reserved.
// +----------------------------------------------------------------------
@ -16,7 +16,9 @@
checkLogin
} from "./libs/login";
import {
getUserInfo
} from '@/api/user.js';
import {
parseToken
@ -89,6 +91,16 @@
//
console.log('消息成功' + JSON.stringify(option));
});
uni.onHostEventReceive((event, data) => {
if (event == 'tocustomlist') {
uni.switchTab({
url: '/pages/chat/customer_list/index'
});
}
});
// #endif
this.globalData.statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 'px';
@ -120,6 +132,10 @@
if (option?.referrerInfo?.extraData?.uniMP) {
uni.setStorageSync('uniMP', option.referrerInfo?.extraData?.uniMP);
// this.$store.commit("LOGIN", {
// 'token': option.referrerInfo?.extraData?.token,
// 'time': 604800
// });
parseToken({
token: option.referrerInfo?.extraData?.token
}).then((res) => {
@ -133,6 +149,7 @@
'token': option.referrerInfo?.extraData?.token,
'time': 604800
});
console.log('TOKEN解析错误:', err);
this.$isResolve()
})
} else {
@ -405,8 +422,7 @@
//console.log('App Hide')
},
watch: {
// https://lihai001.oss-cn-chengdu.aliyuncs.com/attach/40390202404250914319725.mp4
// H5?spm=a2c4e.11153940.blogcont573781.6.c1032027sQ46VG&x-oss-process=video/snapshot,t_1000,m_fast
// H5
$route(n) {
if (this.$store.state.app.token) {
//
@ -428,21 +444,10 @@
@import 'static/css/style.scss';
//
* {
scrollbar-color: #e5e5e500 #f7f7f9 !important;
}
view {
box-sizing: border-box;
}
.c_active {
&:active {
opacity: .8;
}
}
.custom_style {
color: #fff;
display: flex;

View File

@ -12,7 +12,8 @@
<view class="con line1" v-if="item.last && item.last.msn_type == 2">[表情]</view>
<view class="con line1" v-if="item.last && item.last.msn_type == 3">[图片]</view>
<view class="con line1" v-if="item.last && item.last.msn_type == 4">[商品]</view>
<view class="con line1" v-if="item.last && (item.last.msn_type == 5 || item.last.msn_type == 6)">[订单]</view>
<view class="con line1"
v-if="item.last && (item.last.msn_type == 5 || item.last.msn_type == 6)">[订单]</view>
</view>
<view class="right-box">
<view class="time">{{item.last && item.last.create_time.split(' ')[1] || ''}}</view>
@ -23,15 +24,18 @@
<block v-if="type == 1 && list.length>0" v-for="(item,index) in list" :key="index">
<div class="item acea-row" @click="goPage(item)">
<view class="logo">
<image :src="(item.user && item.user.avatar) ? item.user.avatar : '/static/images/f.png'" mode=""></image>
<image :src="(item.user && item.user.avatar) ? item.user.avatar : '/static/images/f.png'"
mode=""></image>
</view>
<view class="info">
<view class="name">{{item.user && item.user.nickname}}</view>
<view class="con line1" v-if="item.last && item.last.msn_type == 1">{{item.last.msn}}</view>
<view class="con line1" v-if="item.last && item.last.msn_type == 2">[表情]</view>
<view class="con line1" v-if="item.last && item.last.msn_type == 3">[图片]</view>
<view class="con line1" v-if="item.last && (item.last.msn_type == 4 || item.last.msn_type == 7)">[商品]</view>
<view class="con line1" v-if="item.last && (item.last.msn_type == 5 || item.last.msn_type == 6)">[订单]</view>
<view class="con line1"
v-if="item.last && (item.last.msn_type == 4 || item.last.msn_type == 7)">[商品]</view>
<view class="con line1"
v-if="item.last && (item.last.msn_type == 5 || item.last.msn_type == 6)">[订单]</view>
</view>
<view class="right-box">
<view class="time">{{item.last && item.last.create_time.split(' ')[1]}}</view>
@ -65,7 +69,9 @@
import {
getUserInfo
} from '@/api/user.js';
import { mapGetters } from "vuex";
import {
mapGetters
} from "vuex";
export default {
name: "CustomerList",
components: {
@ -91,7 +97,6 @@
computed: mapGetters(['isLogin', 'viewColor']),
onLoad(optios) {
this.type = optios.type || 1;
this.getindex()
},
onShow(option) {
if (this.isLogin) {
@ -100,6 +105,7 @@
this.isAuto = true;
this.isShowAuth = true
}
this.getindex()
},
onHide() {
if (this.timer) {
@ -248,6 +254,7 @@
transform: rotate(180deg);
font-size: 36rpx;
}
.popupn {
position: fixed;
width: 100%;
@ -258,17 +265,20 @@
height: 90rpx;
line-height: 90rpx;
z-index: 100;
.title {
max-width: 560rpx;
margin: 0 auto;
position: relative;
}
.iconfont {
display: inline-block;
position: relative;
top: 4rpx;
right: 0;
}
.mer_logo {
width: 34rpx;
height: 34rpx;
@ -276,36 +286,44 @@
top: 6rpx;
right: 10px;
}
.mer_name {
display: inline-block;
max-width: 650rpx;
}
.invoice-content {
background-color: #ffffff;
}
}
.list_count {
margin-top: 104rpx;
}
.item {
align-items: center;
border-bottom: 1px solid #eee;
padding: 20rpx 30rpx;
background-color: #fff;
.logo image {
width: 88rpx;
height: 88rpx;
border-radius: 50%;
}
.info {
width: 334rpx;
margin-left: 20rpx;
.con {
margin-top: 10rpx;
color: #999999;
font-size: 24rpx;
}
}
.right-box {
flex: 1;
display: flex;
@ -313,9 +331,11 @@
align-items: flex-end;
font-size: 20rpx;
color: #BBBBBB;
.time {
margin-bottom: 10rpx;
}
.num {
min-width: 6px;
background-color: var(--view-theme);

View File

@ -17,10 +17,8 @@
</u-form-item>
<view class="card" style="min-height: 150rpx;margin-bottom: 0;padding: 0;">
<view class="" style="display: flex;flex-wrap: wrap;">
<view v-for="(item,index) in formData.imageList"
style="margin-right: 20rpx;margin-bottom: 20rpx;">
<view class="video_list" v-if='vidioTypeList.includes(getSuffix(item))'>
<view class="video_list_item photo" style="position: relative;">
<view class="jiao">
@ -46,8 +44,6 @@
</view>
</view>
</view>
<view class="" style="position: relative;" v-else>
<view class="jiao" @click="formData.imageList.splice(index,1)">
<image src="@/static/images/gban.png" mode="widthFix"></image>
@ -57,10 +53,7 @@
</view>
</view>
<view class='uploadimg' @click="show=true,isDetail=false">
<!-- <view class='uploadimg'> -->
<u-icon name="plus" color="#777777"></u-icon>
<view class="" style="color: #777777;font-size: 20rpx;">
上传图片/视频
@ -823,7 +816,6 @@
align-items: center;
box-sizing: border-box;
padding: 20rpx 0;
/* margin-left: 20rpx; */
overflow: hidden;
}