18
This commit is contained in:
+4
-3
@@ -32,7 +32,7 @@ export const businessModify = (params) =>
|
|||||||
// 用户信息
|
// 用户信息
|
||||||
export const businessInfoUpdate = (params) =>
|
export const businessInfoUpdate = (params) =>
|
||||||
uni.$u?.http.post(
|
uni.$u?.http.post(
|
||||||
"/user/info",
|
"/user/profile",
|
||||||
JSON.stringify({...params}),
|
JSON.stringify({...params}),
|
||||||
{
|
{
|
||||||
header: {
|
header: {
|
||||||
@@ -80,9 +80,10 @@ export const businessSearchUser = (keyword,searchtype) =>
|
|||||||
},
|
},
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
export const getArticle = (id,type) => uni.$u?.http.post("/article/detail",JSON.stringify({id,type:(type? type : 'id')}));
|
export const getSpage = (name) => uni.$u?.http.get(`/article/singpage?name=${name}`);
|
||||||
|
export const getArticle = (id) => uni.$u?.http.get(`/article/detail?id=${id}`);
|
||||||
export const getFriendCircle = (page=1,limit=10) =>{
|
export const getFriendCircle = (page=1,limit=10) =>{
|
||||||
return uni.$u?.http.get("/friendcircle/list",JSON.stringify({limit:limit,page:page}));
|
return uni.$u?.http.get(`/friendcircle/list?limit=${limit}&page=${page}`);
|
||||||
}
|
}
|
||||||
export const getFriendCircleNewcount = () =>{
|
export const getFriendCircleNewcount = () =>{
|
||||||
return uni.$u?.http.get("/friendcircle/newcount");
|
return uni.$u?.http.get("/friendcircle/newcount");
|
||||||
|
|||||||
+2
-2
@@ -2,8 +2,8 @@
|
|||||||
"name" : "回声",
|
"name" : "回声",
|
||||||
"appid" : "__UNI__CA458BA",
|
"appid" : "__UNI__CA458BA",
|
||||||
"description" : "",
|
"description" : "",
|
||||||
"versionName" : "3.3.4",
|
"versionName" : "3.3.5",
|
||||||
"versionCode" : 334,
|
"versionCode" : 335,
|
||||||
"transformPx" : false,
|
"transformPx" : false,
|
||||||
"app-plus" : {
|
"app-plus" : {
|
||||||
"bounce" : "none",
|
"bounce" : "none",
|
||||||
|
|||||||
@@ -1,20 +1,38 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="n-ps-all-base">
|
<view class="n-ps-all-base">
|
||||||
<uv-parse v-if="content" :content="content"></uv-parse>
|
<uni-nav-bar
|
||||||
<view class="n-flex-row" v-if="showButton" :style="{marginTop:'100rpx'}">
|
left-icon="back"
|
||||||
<uv-button class="n-flex-1 n-ms-base" v-for="(item, idx) in buttonList" :key="idx" @click="switchButton(idx, item)" :text="item.title" :icon="'/static/image/' + item.value + '.png'" :plain="current==idx" :color="current==idx ? item.color:'#f8f8f8'" :customStyle="{height:'80rpx'}" :customTextStyle="{color:current==idx ? item.color:'#333333',marginLeft:'20rpx'}" shape="circle" color="#f8f8f8" throttleTime="1000"></uv-button>
|
@clickLeft="goto(1)"
|
||||||
|
fixed
|
||||||
|
statusBar
|
||||||
|
:title="title">
|
||||||
|
</uni-nav-bar>
|
||||||
|
<view class="u-content">
|
||||||
|
<u-parse
|
||||||
|
v-if="content"
|
||||||
|
:domain="config.website"
|
||||||
|
:previewImg="false"
|
||||||
|
:showImgMenu="false"
|
||||||
|
:content="content">
|
||||||
|
</u-parse>
|
||||||
</view>
|
</view>
|
||||||
<uv-empty :show="empty" icon="/static/image/empty.png" text="暂无数据~" width="200" marginTop="100"></uv-empty>
|
<view class="n-flex-row" v-if="showButton" :style="{marginTop:'100rpx'}">
|
||||||
|
<u-button class="n-flex-1 n-ms-base" v-for="(item, idx) in buttonList" :key="idx" @click="switchButton(idx, item)" :text="item.title" :icon="'/static/image/' + item.value + '.png'" :plain="current==idx" :color="current==idx ? item.color:'#f8f8f8'" :customStyle="{height:'80rpx'}" :customTextStyle="{color:current==idx ? item.color:'#333333',marginLeft:'20rpx'}" shape="circle" color="#f8f8f8" throttleTime="1000"></u-button>
|
||||||
|
</view>
|
||||||
|
<u-empty :show="empty" icon="/static/image/empty.png" text="暂无数据~" width="200" marginTop="100"></u-empty>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import {getArticle} from '@/api/login.js'
|
import {getSpage,getArticle} from '@/api/login.js'
|
||||||
|
import { mapGetters } from "vuex";
|
||||||
|
import util from "@/util"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
empty: false,
|
empty: false,
|
||||||
|
title:"",
|
||||||
content: '',
|
content: '',
|
||||||
current: null,
|
current: null,
|
||||||
questionId: 0,
|
questionId: 0,
|
||||||
@@ -28,9 +46,14 @@
|
|||||||
onLoad(evt) {
|
onLoad(evt) {
|
||||||
if(evt.type=='config') this.setConfig(evt)
|
if(evt.type=='config') this.setConfig(evt)
|
||||||
if(evt.type=='question') this.setQuestion(evt)
|
if(evt.type=='question') this.setQuestion(evt)
|
||||||
|
if(evt.type=='article') this.setArticle(evt)
|
||||||
|
if(evt.type=='spage') this.setSpage(evt)
|
||||||
|
this.title = evt.title;
|
||||||
uni.setNavigationBarTitle({title:evt.title})
|
uni.setNavigationBarTitle({title:evt.title})
|
||||||
},
|
},
|
||||||
|
computed:{
|
||||||
|
...mapGetters(["config"]),
|
||||||
|
},
|
||||||
methods: {
|
methods: {
|
||||||
// 设置配置内容
|
// 设置配置内容
|
||||||
setConfig(evt) {
|
setConfig(evt) {
|
||||||
@@ -47,15 +70,38 @@
|
|||||||
this.questionId = evt.id
|
this.questionId = evt.id
|
||||||
this.showButton = true
|
this.showButton = true
|
||||||
},
|
},
|
||||||
|
setArticle(evt) {
|
||||||
|
this.showButton = false;
|
||||||
|
getArticle(evt.id).then(res=>{
|
||||||
|
this.content = res.content
|
||||||
|
}).catch(e=>{
|
||||||
|
console.log(e);
|
||||||
|
})
|
||||||
|
},
|
||||||
|
setSpage(evt) {
|
||||||
|
this.showButton = false;
|
||||||
|
getSpage(evt.name).then(res=>{
|
||||||
|
this.content = res.content
|
||||||
|
}).catch(e=>{
|
||||||
|
console.log(e);
|
||||||
|
})
|
||||||
|
},
|
||||||
// 切换按钮
|
// 切换按钮
|
||||||
switchButton(idx, item) {
|
switchButton(idx, item) {
|
||||||
this.current = idx
|
this.current = idx
|
||||||
getArticle({id:this.questionId,type:item.value})
|
getArticle({id:this.questionId,type:item.value})
|
||||||
}
|
},
|
||||||
|
goto:util.goto
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style>
|
<style lang="scss" scoped>
|
||||||
|
|
||||||
|
.u-content {
|
||||||
|
padding: 24rpx;
|
||||||
|
font-size: 32rpx;
|
||||||
|
color: $u-content-color;
|
||||||
|
line-height: 1.6;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
+249
-276
@@ -1,309 +1,282 @@
|
|||||||
<template>
|
<template>
|
||||||
<view class="group_card_container">
|
<view class="group_card_container">
|
||||||
<custom-nav-bar title="" />
|
<custom-nav-bar title="" />
|
||||||
<u-toast ref="uToast"></u-toast>
|
<u-toast ref="uToast"></u-toast>
|
||||||
|
|
||||||
<view class="main">
|
<view class="main">
|
||||||
<view class="base_info">
|
<view class="base_info">
|
||||||
<my-avatar :src="sourceGroupInfo.faceURL" :isGroup="true" size="48" />
|
<my-avatar :src="sourceGroupInfo.faceURL" :isGroup="true" size="48" />
|
||||||
<view>
|
<view>
|
||||||
<view class="group_name">
|
<view class="group_name">
|
||||||
<text>{{ sourceGroupInfo.groupName }}</text>
|
<text>{{ sourceGroupInfo.groupName }}</text>
|
||||||
<text v-if="!!sourceGroupInfo.memberCount"
|
<text v-if="!!sourceGroupInfo.memberCount">({{ sourceGroupInfo.memberCount }})</text>
|
||||||
>({{ sourceGroupInfo.memberCount }})</text
|
</view>
|
||||||
>
|
<view class="create_time">
|
||||||
</view>
|
<u-icon name="clock" color="#999" size="14"></u-icon>
|
||||||
<view class="create_time">
|
<text>{{ getCreateTime }}</text>
|
||||||
<u-icon name="clock" color="#999" size="14"></u-icon>
|
</view>
|
||||||
<text>{{ getCreateTime }}</text>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view
|
<view v-if="!!sourceGroupInfo.memberCount" @click="toMemberList" class="member_row info_row">
|
||||||
v-if="!!sourceGroupInfo.memberCount"
|
<view class="member_desc">
|
||||||
@click="toMemberList"
|
<text>群成员</text>
|
||||||
class="member_row info_row"
|
<text class="member_count">{{
|
||||||
>
|
|
||||||
<view class="member_desc">
|
|
||||||
<text>群成员</text>
|
|
||||||
<text class="member_count">{{
|
|
||||||
`${sourceGroupInfo.memberCount}人`
|
`${sourceGroupInfo.memberCount}人`
|
||||||
}}</text>
|
}}</text>
|
||||||
<u-icon name="arrow-right" color="#999" size="18"></u-icon>
|
<u-icon name="arrow-right" color="#999" size="18"></u-icon>
|
||||||
</view>
|
</view>
|
||||||
<view class="member_list">
|
<view class="member_list">
|
||||||
<my-avatar
|
<my-avatar v-for="member in getRenderMemberList" :key="member.userID" class="member_item" size="42"
|
||||||
v-for="member in getRenderMemberList"
|
:src="member.faceURL" :desc="member.nickname"></my-avatar>
|
||||||
:key="member.userID"
|
<u-avatar bgColor="#5496EB" icon="more-dot-fill" shape="square" size="42"></u-avatar>
|
||||||
class="member_item"
|
</view>
|
||||||
size="42"
|
</view>
|
||||||
:src="member.faceURL"
|
|
||||||
:desc="member.nickname"
|
|
||||||
></my-avatar>
|
|
||||||
<u-avatar
|
|
||||||
bgColor="#5496EB"
|
|
||||||
icon="more-dot-fill"
|
|
||||||
shape="square"
|
|
||||||
size="42"
|
|
||||||
></u-avatar>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view class="info_row">
|
<view class="info_row">
|
||||||
<user-info-row-item lable="群ID号" :content="sourceGroupInfo.groupID" />
|
<user-info-row-item lable="群ID号" :content="sourceGroupInfo.groupID" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
<view class="action_row">
|
<view class="action_row">
|
||||||
<u-button type="primary" v-if="!isJoinedGroup" @click="joinGroup"
|
<u-button type="primary" v-if="!isJoinedGroup" @click="joinGroup">申请加入该群</u-button>
|
||||||
>申请加入该群</u-button
|
<u-button type="primary" v-else @click="chatingInGroup">发消息</u-button>
|
||||||
>
|
</view>
|
||||||
<u-button type="primary" v-else @click="chatingInGroup">发消息</u-button>
|
</view>
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { GroupMemberListTypes } from "@/constant";
|
import {GroupMemberListTypes} from "@/constant";
|
||||||
import { navigateToDesignatedConversation } from "@/util/imCommon";
|
import {navigateToDesignatedConversation} from "@/util/imCommon";
|
||||||
import IMSDK, {
|
import IMSDK, {GroupVerificationType,SessionType,} from "openim-uniapp-polyfill";
|
||||||
GroupVerificationType,
|
import dayjs from "dayjs";
|
||||||
SessionType,
|
import MyAvatar from "@/components/MyAvatar/index.vue";
|
||||||
} from "openim-uniapp-polyfill";
|
import CustomNavBar from "@/components/CustomNavBar/index.vue";
|
||||||
import dayjs from "dayjs";
|
import UserInfoRowItem from "../userCard/components/UserInfoRowItem.vue";
|
||||||
import MyAvatar from "@/components/MyAvatar/index.vue";
|
|
||||||
import CustomNavBar from "@/components/CustomNavBar/index.vue";
|
|
||||||
import UserInfoRowItem from "../userCard/components/UserInfoRowItem.vue";
|
|
||||||
|
|
||||||
import userIcon from "static/images/contact_my_friend.png";
|
import userIcon from "static/images/contact_my_friend.png";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {CustomNavBar,MyAvatar,UserInfoRowItem,},
|
||||||
CustomNavBar,
|
data() {
|
||||||
MyAvatar,
|
return {
|
||||||
UserInfoRowItem,
|
sourceID: "",
|
||||||
},
|
isScan: false,
|
||||||
data() {
|
sourceGroupInfo: {},
|
||||||
return {
|
groupMemberList: [],
|
||||||
sourceID: "",
|
};
|
||||||
isScan: false,
|
},
|
||||||
sourceGroupInfo: {},
|
computed: {
|
||||||
groupMemberList: [],
|
isJoinedGroup() {
|
||||||
};
|
return (this.$store.getters.storeGroupList.findIndex((group) => group.groupID === this.sourceID,) !== -1);
|
||||||
},
|
},
|
||||||
computed: {
|
getCreateTime() {
|
||||||
isJoinedGroup() {
|
return dayjs(this.sourceGroupInfo.createTime).format("YYYY-MM-DD");
|
||||||
return (
|
},
|
||||||
this.$store.getters.storeGroupList.findIndex(
|
getRenderMemberList() {
|
||||||
(group) => group.groupID === this.sourceID,
|
if (this.isJoinedGroup) {
|
||||||
) !== -1
|
this.groupMemberList;
|
||||||
);
|
return this.groupMemberList;
|
||||||
},
|
}
|
||||||
getCreateTime() {
|
const memberCount = this.sourceGroupInfo.memberCount ?? 0;
|
||||||
return dayjs(this.sourceGroupInfo.createTime).format("YYYY-MM-DD");
|
return new Array(memberCount >= 6 ? 6 : memberCount)
|
||||||
},
|
.fill(1)
|
||||||
getRenderMemberList() {
|
.map((item, idx) => ({
|
||||||
if (this.isJoinedGroup) {
|
userID: idx,
|
||||||
this.groupMemberList;
|
src: userIcon,
|
||||||
return this.groupMemberList;
|
}));
|
||||||
}
|
},
|
||||||
const memberCount = this.sourceGroupInfo.memberCount ?? 0;
|
},
|
||||||
return new Array(memberCount >= 6 ? 6 : memberCount)
|
onLoad(options) {
|
||||||
.fill(1)
|
const {sourceID,sourceInfo,isScan} = options;
|
||||||
.map((item, idx) => ({
|
this.isScan = !!isScan;
|
||||||
userID: idx,
|
if (sourceID) {
|
||||||
src: userIcon,
|
this.sourceID = sourceID;
|
||||||
}));
|
this.getSourceGroupInfo();
|
||||||
},
|
} else {
|
||||||
},
|
const info = JSON.parse(sourceInfo);
|
||||||
onLoad(options) {
|
this.sourceID = info.groupID;
|
||||||
const { sourceID, sourceInfo, isScan } = options;
|
this.sourceGroupInfo = {
|
||||||
this.isScan = !!isScan;
|
...info,
|
||||||
if (sourceID) {
|
};
|
||||||
this.sourceID = sourceID;
|
}
|
||||||
this.getSourceGroupInfo();
|
this.getGroupMemberList();
|
||||||
} else {
|
},
|
||||||
const info = JSON.parse(sourceInfo);
|
methods: {
|
||||||
this.sourceID = info.groupID;
|
toMemberList() {
|
||||||
this.sourceGroupInfo = {
|
if (this.isJoinedGroup) {
|
||||||
...info,
|
this.$store.dispatch("conversation/getCurrentGroup", this.sourceID);
|
||||||
};
|
this.$store.dispatch(
|
||||||
}
|
"conversation/getCurrentMemberInGroup",
|
||||||
this.getGroupMemberList();
|
this.sourceID,
|
||||||
},
|
);
|
||||||
methods: {
|
uni.navigateTo({
|
||||||
toMemberList() {
|
url: `/pages/conversation/groupMemberList/index?type=${GroupMemberListTypes.Preview}&groupID=${this.sourceID}`,
|
||||||
if (this.isJoinedGroup) {
|
});
|
||||||
this.$store.dispatch("conversation/getCurrentGroup", this.sourceID);
|
}
|
||||||
this.$store.dispatch(
|
},
|
||||||
"conversation/getCurrentMemberInGroup",
|
joinGroup() {
|
||||||
this.sourceID,
|
uni.$u.route("/pages/common/sendAddRequest/index", {
|
||||||
);
|
isGroup: true,
|
||||||
uni.navigateTo({
|
sourceID: this.sourceID,
|
||||||
url: `/pages/conversation/groupMemberList/index?type=${GroupMemberListTypes.Preview}&groupID=${this.sourceID}`,
|
isScan: this.isScan,
|
||||||
});
|
notNeedVerification: this.sourceGroupInfo.needVerification ===
|
||||||
}
|
GroupVerificationType.AllNot,
|
||||||
},
|
sessionType: SessionType.WorkingGroup,
|
||||||
joinGroup() {
|
});
|
||||||
uni.$u.route("/pages/common/sendAddRequest/index", {
|
},
|
||||||
isGroup: true,
|
chatingInGroup() {
|
||||||
sourceID: this.sourceID,
|
navigateToDesignatedConversation(
|
||||||
isScan: this.isScan,
|
this.sourceID,
|
||||||
notNeedVerification:
|
SessionType.WorkingGroup,
|
||||||
this.sourceGroupInfo.needVerification ===
|
).catch(() => this.showToast("获取会话信息失败"));
|
||||||
GroupVerificationType.AllNot,
|
},
|
||||||
sessionType: SessionType.WorkingGroup,
|
async getSourceGroupInfo() {
|
||||||
});
|
let info = null;
|
||||||
},
|
if (this.isJoinedGroup) {
|
||||||
chatingInGroup() {
|
info = this.$store.getters.storeGroupList.find(
|
||||||
navigateToDesignatedConversation(
|
(group) => group.groupID === this.sourceID,
|
||||||
this.sourceID,
|
);
|
||||||
SessionType.WorkingGroup,
|
} else {
|
||||||
).catch(() => this.showToast("获取会话信息失败"));
|
try {
|
||||||
},
|
const {
|
||||||
async getSourceGroupInfo() {
|
data
|
||||||
let info = null;
|
} = await IMSDK.asyncApi(
|
||||||
if (this.isJoinedGroup) {
|
IMSDK.IMMethods.GetSpecifiedGroupsInfo,
|
||||||
info = this.$store.getters.storeGroupList.find(
|
IMSDK.uuid(),
|
||||||
(group) => group.groupID === this.sourceID,
|
[this.sourceID],
|
||||||
);
|
);
|
||||||
} else {
|
info = data[0] ?? {};
|
||||||
try {
|
} catch (e) {
|
||||||
const { data } = await IMSDK.asyncApi(
|
info = {};
|
||||||
IMSDK.IMMethods.GetSpecifiedGroupsInfo,
|
}
|
||||||
IMSDK.uuid(),
|
}
|
||||||
[this.sourceID],
|
this.sourceGroupInfo = {
|
||||||
);
|
...info,
|
||||||
info = data[0] ?? {};
|
};
|
||||||
} catch (e) {
|
},
|
||||||
info = {};
|
getGroupMemberList() {
|
||||||
}
|
if (this.isJoinedGroup) {
|
||||||
}
|
IMSDK.asyncApi(IMSDK.IMMethods.GetGroupMemberList, IMSDK.uuid(), {
|
||||||
this.sourceGroupInfo = {
|
groupID: this.sourceID,
|
||||||
...info,
|
filter: 0,
|
||||||
};
|
offset: 0,
|
||||||
},
|
count: 6,
|
||||||
getGroupMemberList() {
|
}).then(({
|
||||||
if (this.isJoinedGroup) {
|
data
|
||||||
IMSDK.asyncApi(IMSDK.IMMethods.GetGroupMemberList, IMSDK.uuid(), {
|
}) => {
|
||||||
groupID: this.sourceID,
|
this.groupMemberList = [...data];
|
||||||
filter: 0,
|
});
|
||||||
offset: 0,
|
}
|
||||||
count: 6,
|
},
|
||||||
}).then(({ data }) => {
|
showToast(message) {
|
||||||
this.groupMemberList = [...data];
|
this.$refs.uToast.show({
|
||||||
});
|
message,
|
||||||
}
|
});
|
||||||
},
|
},
|
||||||
showToast(message) {
|
},
|
||||||
this.$refs.uToast.show({
|
};
|
||||||
message,
|
|
||||||
});
|
|
||||||
},
|
|
||||||
},
|
|
||||||
};
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
.group_card_container {
|
.group_card_container {
|
||||||
@include colBox(false);
|
@include colBox(false);
|
||||||
height: 100vh;
|
height: 100vh;
|
||||||
background-color: #f6f6f6;
|
background-color: #f6f6f6;
|
||||||
|
|
||||||
.main {
|
.main {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.base_info {
|
.base_info {
|
||||||
@include vCenterBox();
|
@include vCenterBox();
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
padding: 44rpx;
|
padding: 44rpx;
|
||||||
margin-bottom: 18rpx;
|
margin-bottom: 18rpx;
|
||||||
|
|
||||||
.u-avatar {
|
.u-avatar {
|
||||||
margin-right: 24rpx;
|
margin-right: 24rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.group_name {
|
.group_name {
|
||||||
display: flex;
|
display: flex;
|
||||||
margin-bottom: 12rpx;
|
margin-bottom: 12rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.create_time {
|
.create_time {
|
||||||
@include vCenterBox();
|
@include vCenterBox();
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
color: #adadad;
|
color: #adadad;
|
||||||
font-size: 26rpx;
|
font-size: 26rpx;
|
||||||
|
|
||||||
.u-icon {
|
.u-icon {
|
||||||
margin-right: 12rpx;
|
margin-right: 12rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.member_row {
|
.member_row {
|
||||||
padding: 24rpx 44rpx;
|
padding: 24rpx 44rpx;
|
||||||
|
|
||||||
.member_desc {
|
.member_desc {
|
||||||
margin-bottom: 24rpx;
|
margin-bottom: 24rpx;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|
||||||
.member_count {
|
.member_count {
|
||||||
font-size: 28rpx;
|
font-size: 28rpx;
|
||||||
color: #adadad;
|
color: #adadad;
|
||||||
margin-left: 24rpx;
|
margin-left: 24rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.u-icon {
|
.u-icon {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
right: 0;
|
right: 0;
|
||||||
top: 0;
|
top: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.member_list {
|
.member_list {
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|
||||||
.member_item {
|
.member_item {
|
||||||
margin-right: 12rpx;
|
margin-right: 12rpx;
|
||||||
|
|
||||||
&:nth-child(7) {
|
&:nth-child(7) {
|
||||||
margin-right: 0;
|
margin-right: 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.info_row {
|
.info_row {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
margin-bottom: 24rpx;
|
margin-bottom: 24rpx;
|
||||||
|
|
||||||
::v-deep .content {
|
::v-deep .content {
|
||||||
color: #adadad;
|
color: #adadad;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.action_row {
|
.action_row {
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
padding: 44rpx 44rpx;
|
padding: 44rpx 44rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.online_state {
|
.online_state {
|
||||||
@include vCenterBox();
|
@include vCenterBox();
|
||||||
margin-left: 24rpx;
|
margin-left: 24rpx;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
color: #999;
|
color: #999;
|
||||||
|
|
||||||
.dot {
|
.dot {
|
||||||
background-color: #10cc64;
|
background-color: #10cc64;
|
||||||
width: 12rpx;
|
width: 12rpx;
|
||||||
height: 12rpx;
|
height: 12rpx;
|
||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
margin-right: 12rpx;
|
margin-right: 12rpx;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -86,7 +86,6 @@
|
|||||||
);
|
);
|
||||||
info = data[0];
|
info = data[0];
|
||||||
}
|
}
|
||||||
console.log(info)
|
|
||||||
if (info) {
|
if (info) {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/common/groupCard/index?sourceInfo=${JSON.stringify(info,)}`,
|
url: `/pages/common/groupCard/index?sourceInfo=${JSON.stringify(info,)}`,
|
||||||
|
|||||||
@@ -14,11 +14,11 @@
|
|||||||
</uni-nav-bar>
|
</uni-nav-bar>
|
||||||
<view style="flex:1;display: flex;flex-direction: column;align-items: center;justify-content: center;">
|
<view style="flex:1;display: flex;flex-direction: column;align-items: center;justify-content: center;">
|
||||||
<view class="info_card">
|
<view class="info_card">
|
||||||
<my-avatar :src="userInfo.faceURL" :desc="userInfo.nickname" size="64" />
|
<my-avatar :src="source.faceURL" :desc="source.showName" size="64" />
|
||||||
<view class="id_row">
|
<view class="id_row">
|
||||||
<text class="nickname">{{ userInfo.nickname }}</text>
|
<text class="nickname">{{ source.showName }}</text>
|
||||||
<view class="id_row_copy" @click="copy">
|
<view class="id_row_copy" @click="copy(source.code)">
|
||||||
<text class="id">{{ userInfo.userID }}</text>
|
<text class="id">{{ source.code }}</text>
|
||||||
<image style="width: 32rpx; height: 32rpx" src="@/static/images/id_copy.png" mode="" />
|
<image style="width: 32rpx; height: 32rpx" src="@/static/images/id_copy.png" mode="" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@@ -29,7 +29,7 @@
|
|||||||
<view style="width: 80%;display: flex;align-items: center;justify-content: center;height: 20%;">
|
<view style="width: 80%;display: flex;align-items: center;justify-content: center;height: 20%;">
|
||||||
<u-button type="default" plain :hairline="false" iconColor="#9aa2b2" @click="scan">扫一扫</u-button>
|
<u-button type="default" plain :hairline="false" iconColor="#9aa2b2" @click="scan">扫一扫</u-button>
|
||||||
<u-button type="default" plain :hairline="false" iconColor="#9aa2b2">换个样式</u-button>
|
<u-button type="default" plain :hairline="false" iconColor="#9aa2b2">换个样式</u-button>
|
||||||
<u-button type="default" plain :hairline="false" iconColor="#9aa2b2">保存图片</u-button>
|
<u-button @click="save" type="default" plain :hairline="false" iconColor="#9aa2b2">保存图片</u-button>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
@@ -39,6 +39,8 @@
|
|||||||
import QRCode from "@/components/qrcode.js";
|
import QRCode from "@/components/qrcode.js";
|
||||||
import UserBase from '@/components/User.vue';
|
import UserBase from '@/components/User.vue';
|
||||||
import util from "@/util";
|
import util from "@/util";
|
||||||
|
import { mapGetters } from "vuex";
|
||||||
|
import md5 from "md5";
|
||||||
export default {
|
export default {
|
||||||
mixins:[UserBase],
|
mixins:[UserBase],
|
||||||
components: {
|
components: {
|
||||||
@@ -46,15 +48,54 @@
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
qrcodeUrl:"",
|
||||||
|
qrcode_src:"",
|
||||||
|
source:{
|
||||||
|
type:"user",
|
||||||
|
showName:"",
|
||||||
|
faceURL:"",
|
||||||
|
code:"",
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onLoad() {
|
computed:{
|
||||||
console.log(this.userInfo)
|
...mapGetters(["storeFriendList","storeGroupList","config"]),
|
||||||
|
},
|
||||||
|
onLoad(opt) {
|
||||||
|
if(opt.sourceInfo){
|
||||||
|
this.source = JSON.parse(opt.sourceInfo);
|
||||||
|
}else{
|
||||||
|
this.source = {
|
||||||
|
type:"user",
|
||||||
|
showName:"",
|
||||||
|
faceURL:"",
|
||||||
|
code:"",
|
||||||
|
};
|
||||||
|
}
|
||||||
|
console.log(this.config);
|
||||||
|
if(this.source.type == "user"){
|
||||||
|
this.qrcodeUrl = `${this.config.website}/u/${this.source.code}`;
|
||||||
|
}else{
|
||||||
|
this.qrcodeUrl = `${this.config.website}/g/${this.source.code}`;
|
||||||
|
}
|
||||||
|
console.log(this.qrcodeUrl);
|
||||||
this.createQrcode();
|
this.createQrcode();
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
...util,
|
...util,
|
||||||
|
save(){
|
||||||
|
const _this = this;
|
||||||
|
uni.saveImageToPhotosAlbum({
|
||||||
|
filePath:_this.qrcode_src,
|
||||||
|
success() {
|
||||||
|
util.success("保存成功");
|
||||||
|
},
|
||||||
|
fail(e) {
|
||||||
|
console.log(e);
|
||||||
|
util.error("保存失败");
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
createQrcode() {
|
createQrcode() {
|
||||||
const _this = this;
|
const _this = this;
|
||||||
return new Promise((resolve, reject) => {
|
return new Promise((resolve, reject) => {
|
||||||
@@ -64,7 +105,7 @@
|
|||||||
usingComponents: true, // 是否是自定义组件
|
usingComponents: true, // 是否是自定义组件
|
||||||
showLoading: false, // 是否显示loading
|
showLoading: false, // 是否显示loading
|
||||||
loadingText: "", // loading文字
|
loadingText: "", // loading文字
|
||||||
text: "/pages/common/invite_register?code=", // 生成内容
|
text: `${this.qrcodeUrl}`, // 生成内容
|
||||||
size: 320, // 二维码大小
|
size: 320, // 二维码大小
|
||||||
background: "#fff", // 背景色
|
background: "#fff", // 背景色
|
||||||
foreground: '#000000', // 前景色
|
foreground: '#000000', // 前景色
|
||||||
@@ -73,7 +114,7 @@
|
|||||||
image: "", // 二维码图标
|
image: "", // 二维码图标
|
||||||
imageSize: 40, // 二维码图标大小
|
imageSize: 40, // 二维码图标大小
|
||||||
cbResult: function(res) { // 生成二维码的回调
|
cbResult: function(res) { // 生成二维码的回调
|
||||||
//_this.qrcode_src = (res)
|
_this.qrcode_src = (res)
|
||||||
//resolve(res);
|
//resolve(res);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
@@ -84,48 +125,46 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
.info_card {
|
.info_card {
|
||||||
width: 600rpx;
|
width: 600rpx;
|
||||||
height: 196rpx;
|
border-radius: 6px;
|
||||||
border-radius: 6px;
|
background: #fff;
|
||||||
background: #fff;
|
margin: 0 auto 0 auto;
|
||||||
margin: 0 auto 0 auto;
|
padding: 40rpx 36rpx;
|
||||||
padding: 0 36rpx;
|
color: #0c1c33;
|
||||||
color: #0c1c33;
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
|
||||||
|
.id_row {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
margin-left: 16rpx;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: flex-start;
|
||||||
|
justify-content: space-around;
|
||||||
|
height: 100%;
|
||||||
|
flex: 1;
|
||||||
|
font-size: 28rpx;
|
||||||
|
|
||||||
.id_row {
|
&_copy {
|
||||||
@include vCenterBox();
|
@include vCenterBox();
|
||||||
display: flex;
|
|
||||||
//height: 46px;
|
|
||||||
margin-left: 16rpx;
|
|
||||||
flex-direction: column;
|
|
||||||
align-items: flex-start;
|
|
||||||
justify-content: space-between;
|
|
||||||
flex: 1;
|
|
||||||
font-size: 28rpx;
|
|
||||||
|
|
||||||
&_copy {
|
|
||||||
@include vCenterBox();
|
|
||||||
}
|
|
||||||
|
|
||||||
.nickname {
|
|
||||||
@include nomalEllipsis();
|
|
||||||
max-width: 400rpx;
|
|
||||||
font-weight: 500;
|
|
||||||
font-size: 34rpx;
|
|
||||||
}
|
|
||||||
|
|
||||||
.id {
|
|
||||||
color: #8e9ab0;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
img {
|
.nickname {
|
||||||
width: 18px;
|
@include nomalEllipsis();
|
||||||
height: 18px;
|
max-width: 400rpx;
|
||||||
|
font-weight: 500;
|
||||||
|
font-size: 34rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.id {
|
||||||
|
color: #8e9ab0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
img {
|
||||||
|
width: 18px;
|
||||||
|
height: 18px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
@@ -6,13 +6,11 @@
|
|||||||
<view id="scroll_wrap">
|
<view id="scroll_wrap">
|
||||||
<u-loadmore nomoreText="" :status="loadMoreStatus" />
|
<u-loadmore nomoreText="" :status="loadMoreStatus" />
|
||||||
<view class="msg_item" v-for="item in storeHistoryMessageList" :key="item.clientMsgID" @click="onUserMessageEvent({type:'selected'},item)">
|
<view class="msg_item" v-for="item in storeHistoryMessageList" :key="item.clientMsgID" @click="onUserMessageEvent({type:'selected'},item)">
|
||||||
<template v-if="selectFlag">
|
|
||||||
<uni-icons class="selectedIcon" size="30" color="#07c160" type="checkbox-filled" v-if="selectClientMsgIDItems.indexOf(item.clientMsgID)>-1"></uni-icons>
|
|
||||||
<uni-icons class="selectedIcon" size="30" color="#ccc" type="circle" v-else></uni-icons>
|
|
||||||
</template>
|
|
||||||
<MessageItemRender
|
<MessageItemRender
|
||||||
@userEvent="onUserMessageEvent"
|
@userEvent="onUserMessageEvent"
|
||||||
:source="item"
|
:source="item"
|
||||||
|
:selectItems="selectItems"
|
||||||
|
:selectFlag="selectFlag"
|
||||||
:conversationID="storeCurrentConversation.conversationID"
|
:conversationID="storeCurrentConversation.conversationID"
|
||||||
:isSender="item.sendID === storeCurrentUserID"
|
:isSender="item.sendID === storeCurrentUserID"
|
||||||
/>
|
/>
|
||||||
@@ -74,13 +72,6 @@
|
|||||||
return "nomore";
|
return "nomore";
|
||||||
}
|
}
|
||||||
return this.messageLoadState.loading ? "loading" : "loadmore";
|
return this.messageLoadState.loading ? "loading" : "loadmore";
|
||||||
},
|
|
||||||
selectClientMsgIDItems(){
|
|
||||||
let arr = [];
|
|
||||||
this.selectItems.forEach((v,k)=>{
|
|
||||||
arr.push(v.clientMsgID);
|
|
||||||
});
|
|
||||||
return arr;
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
|||||||
@@ -1,35 +1,39 @@
|
|||||||
<template>
|
<template>
|
||||||
<view v-if="!getNoticeContent" :id="`auchor${source.clientMsgID}`" class="message_item"
|
<view v-if="isNoticeMessage" class="notice_message_container" style="margin: 0 auto;" :id="`auchor${source.clientMsgID}`">
|
||||||
:class="{ message_item_self: isSender, message_item_active: isActive }">
|
<text>{{ getNoticeContent }}</text>
|
||||||
<my-avatar size="42" :desc="source.senderNickname" :src="source.senderFaceUrl" @click="viewDetail" />
|
</view>
|
||||||
<view class="message_container">
|
<view v-else class="message_wrapper">
|
||||||
<view class="message_sender" :style="{ 'flex-direction': !isSender ? 'row-reverse' : 'row' }">
|
<template v-if="selectFlag">
|
||||||
<text>{{ formattedMessageTime }}</text>
|
<uni-icons class="selectedIcon" size="30" color="#07c160" type="checkbox-filled" v-if="selectClientMsgIDItems.indexOf(source.clientMsgID)>-1"></uni-icons>
|
||||||
<text style="margin-left: 2rpx; margin-right: 2rpx">{{ "" }}</text>
|
<uni-icons class="selectedIcon" size="30" color="#ccc" type="circle" v-else></uni-icons>
|
||||||
<text v-if="!isSingle">{{ source.senderNickname }}</text>
|
</template>
|
||||||
</view>
|
<view :id="`auchor${source.clientMsgID}`" class="message_item"
|
||||||
<view class="message_send_state_box">
|
:class="{ message_item_self: isSender, message_item_active: isActive }">
|
||||||
<view style="height: 100%;display: flex;justify-items: center;align-items: center;">
|
<my-avatar size="42" :desc="source.senderNickname" :src="source.senderFaceUrl" @click="viewDetail" />
|
||||||
<view class="message_send_state">
|
<view class="message_container">
|
||||||
<u-loading-icon v-if="showSending && !isPreview" />
|
<view class="message_sender" :style="{ 'flex-direction': !isSender ? 'row-reverse' : 'row' }">
|
||||||
<image v-if="isFailedMessage && !isPreview" class="state_img" src="@/static/images/chating_message_failed.png" />
|
<text>{{ formattedMessageTime }}</text>
|
||||||
</view>
|
<text style="margin-left: 2rpx; margin-right: 2rpx">{{ "" }}</text>
|
||||||
|
<text v-if="!isSingle">{{ source.senderNickname }}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="message_content_wrap message_content_wrap_shadow" :id="`message_content_wrap_${source.clientMsgID}`" @longtap.stop.prevent="longtapEvent($event)">
|
<view class="message_send_state_box">
|
||||||
<component :is="component"
|
<view style="height: 100%;display: flex;justify-items: center;align-items: center;">
|
||||||
@messageEvent="onMessageEvent"
|
<view class="message_send_state">
|
||||||
:isSender="isSender"
|
<u-loading-icon v-if="showSending && !isPreview" />
|
||||||
:message="source"
|
<image v-if="isFailedMessage && !isPreview" class="state_img" src="@/static/images/chating_message_failed.png" />
|
||||||
:conversationID="conversationID"
|
</view>
|
||||||
></component>
|
</view>
|
||||||
|
<view class="message_content_wrap message_content_wrap_shadow" :id="`message_content_wrap_${source.clientMsgID}`" @longtap.stop.prevent="longtapEvent($event)">
|
||||||
|
<component :is="component"
|
||||||
|
@messageEvent="onMessageEvent"
|
||||||
|
:isSender="isSender"
|
||||||
|
:message="source"
|
||||||
|
:conversationID="conversationID"
|
||||||
|
></component>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<view v-else class="notice_message_container" style="margin: 0 auto;" :id="`auchor${source.clientMsgID}`">
|
|
||||||
<text>{{ getNoticeContent }}</text>
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -89,6 +93,16 @@
|
|||||||
conversationID:String,
|
conversationID:String,
|
||||||
isPreview: Boolean,
|
isPreview: Boolean,
|
||||||
isActive: Boolean,
|
isActive: Boolean,
|
||||||
|
selectFlag:{
|
||||||
|
type:Boolean,
|
||||||
|
default:false
|
||||||
|
},
|
||||||
|
selectItems:{
|
||||||
|
type:Array,
|
||||||
|
default(){
|
||||||
|
return [];
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -97,7 +111,7 @@
|
|||||||
toolTipFlag: false,
|
toolTipFlag: false,
|
||||||
popPostion:"default",
|
popPostion:"default",
|
||||||
toolTipData: [],
|
toolTipData: [],
|
||||||
component:"ErrorMessageRender",
|
component:"ErrorMessageRender"
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -113,16 +127,17 @@
|
|||||||
formattedMessageTime() {
|
formattedMessageTime() {
|
||||||
return formatMessageTime(this.source.sendTime);
|
return formatMessageTime(this.source.sendTime);
|
||||||
},
|
},
|
||||||
|
isNoticeMessage(){
|
||||||
|
return noticeMessageTypes.includes(this.source.contentType);
|
||||||
|
},
|
||||||
getNoticeContent() {
|
getNoticeContent() {
|
||||||
const isNoticeMessage = noticeMessageTypes.includes(
|
if(this.isNoticeMessage){
|
||||||
this.source.contentType
|
return tipMessaggeFormat(
|
||||||
);
|
|
||||||
return !isNoticeMessage ?
|
|
||||||
"" :
|
|
||||||
tipMessaggeFormat(
|
|
||||||
this.source,
|
this.source,
|
||||||
this.$store.getters.storeCurrentUserID
|
this.$store.getters.storeCurrentUserID
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
return "";
|
||||||
},
|
},
|
||||||
isSuccessMessage() {
|
isSuccessMessage() {
|
||||||
return this.source.status === MessageStatus.Succeed;
|
return this.source.status === MessageStatus.Succeed;
|
||||||
@@ -133,6 +148,13 @@
|
|||||||
showSending() {
|
showSending() {
|
||||||
return this.source.status === MessageStatus.Sending && !this.sendingDelay;
|
return this.source.status === MessageStatus.Sending && !this.sendingDelay;
|
||||||
},
|
},
|
||||||
|
selectClientMsgIDItems(){
|
||||||
|
let arr = [];
|
||||||
|
this.selectItems.forEach((v,k)=>{
|
||||||
|
arr.push(v.clientMsgID);
|
||||||
|
});
|
||||||
|
return arr;
|
||||||
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
const MsgType2Components = {
|
const MsgType2Components = {
|
||||||
@@ -174,7 +196,6 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
longtapEvent(e){
|
longtapEvent(e){
|
||||||
console.log('longtapEvent');
|
|
||||||
this.$emit('userEvent',{type:"longtapMsgContent"},this.source);
|
this.$emit('userEvent',{type:"longtapMsgContent"},this.source);
|
||||||
},
|
},
|
||||||
onMessageEvent(e){
|
onMessageEvent(e){
|
||||||
@@ -185,9 +206,16 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
|
.message_wrapper{
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: flex-start;
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
.message_item {
|
.message_item {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
|
flex:1;
|
||||||
padding: 16rpx 44rpx;
|
padding: 16rpx 44rpx;
|
||||||
// padding-top: 48rpx;
|
// padding-top: 48rpx;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
|||||||
@@ -19,7 +19,7 @@
|
|||||||
<script>
|
<script>
|
||||||
import {mapActions,mapGetters} from "vuex";
|
import {mapActions,mapGetters} from "vuex";
|
||||||
import {offlinePushInfo} from "@/util/imCommon";
|
import {offlinePushInfo} from "@/util/imCommon";
|
||||||
import {PageEvents,ContactChooseTypes } from "@/constant";
|
import {PageEvents,ContactChooseTypes,noticeMessageTypes} from "@/constant";
|
||||||
import ChatingHeader from "./components/ChatingHeader";
|
import ChatingHeader from "./components/ChatingHeader";
|
||||||
import ChatingFooter from "./components/ChatingFooter/index";
|
import ChatingFooter from "./components/ChatingFooter/index";
|
||||||
import ChatingList from "./components/ChatingList";
|
import ChatingList from "./components/ChatingList";
|
||||||
@@ -174,9 +174,6 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
sendMessage(message, user_id, group_id) {
|
sendMessage(message, user_id, group_id) {
|
||||||
//this.scrollToBottom();
|
|
||||||
//console.log(message);
|
|
||||||
//console.log(user_id,group_id);
|
|
||||||
IMSDK.asyncApi(IMSDK.IMMethods.SendMessage, IMSDK.uuid(), {
|
IMSDK.asyncApi(IMSDK.IMMethods.SendMessage, IMSDK.uuid(), {
|
||||||
recvID: user_id,
|
recvID: user_id,
|
||||||
groupID: group_id,
|
groupID: group_id,
|
||||||
@@ -184,8 +181,16 @@
|
|||||||
offlinePushInfo,
|
offlinePushInfo,
|
||||||
})
|
})
|
||||||
.then(({data}) => {
|
.then(({data}) => {
|
||||||
console.log(data);
|
if(user_id && this.storeCurrentConversation.userID == user_id){
|
||||||
this.pushNewMessage(message);
|
this.pushNewMessage(message);
|
||||||
|
this.scrollToBottom();
|
||||||
|
return ;
|
||||||
|
}
|
||||||
|
if(group_id && this.storeCurrentConversation.groupID == group_id){
|
||||||
|
this.pushNewMessage(message);
|
||||||
|
this.scrollToBottom();
|
||||||
|
return ;
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.catch((res = {data,errCode,errMsg}) => {
|
.catch((res = {data,errCode,errMsg}) => {
|
||||||
console.log(res);
|
console.log(res);
|
||||||
@@ -207,6 +212,9 @@
|
|||||||
}
|
}
|
||||||
if (e.type == 'selected') {
|
if (e.type == 'selected') {
|
||||||
if (this.selectFlag == true) {
|
if (this.selectFlag == true) {
|
||||||
|
if(noticeMessageTypes.includes(data.contentType)){
|
||||||
|
return ;
|
||||||
|
}
|
||||||
let founded = false;
|
let founded = false;
|
||||||
let arr = [];
|
let arr = [];
|
||||||
for (var index = 0; index < this.selectItems.length; index++) {
|
for (var index = 0; index < this.selectItems.length; index++) {
|
||||||
|
|||||||
@@ -75,9 +75,9 @@
|
|||||||
// uni.switchTab({
|
// uni.switchTab({
|
||||||
// url:"/pages/user/index/index"
|
// url:"/pages/user/index/index"
|
||||||
// })
|
// })
|
||||||
uni.navigateTo({
|
// uni.navigateTo({
|
||||||
url:"/pages/user/vip/vip"
|
// url:"/pages/user/vip/vip"
|
||||||
});
|
// });
|
||||||
//prepareConversationState(this.storeConversationList[2]);
|
//prepareConversationState(this.storeConversationList[2]);
|
||||||
},1000)
|
},1000)
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -25,13 +25,13 @@
|
|||||||
<uni-list>
|
<uni-list>
|
||||||
<uni-list-item title="群聊名称" :rightText="storeCurrentConversation.showName" @click="editGroupName" :clickable="isOwner || isAdmin" :showArrow="isOwner || isAdmin"></uni-list-item>
|
<uni-list-item title="群聊名称" :rightText="storeCurrentConversation.showName" @click="editGroupName" :clickable="isOwner || isAdmin" :showArrow="isOwner || isAdmin"></uni-list-item>
|
||||||
<uni-list-item title="群公告" to="/pages/conversation/groupSettings/announcement" clickable showArrow></uni-list-item>
|
<uni-list-item title="群公告" to="/pages/conversation/groupSettings/announcement" clickable showArrow></uni-list-item>
|
||||||
<uni-list-item title="群二维码" :to="'/pages/common/userOrGroupQrCode?groupID='+storeCurrentConversation.groupID" clickable showArrow></uni-list-item>
|
<uni-list-item title="群二维码" :to="getGroupQrcdeUrl" clickable showArrow></uni-list-item>
|
||||||
<uni-list-item v-if="isOwner || isAdmin" title="群管理" to="/pages/conversation/groupManage/index" clickable showArrow></uni-list-item>
|
<uni-list-item v-if="isOwner || isAdmin" title="群管理" to="/pages/conversation/groupManage/index" clickable showArrow></uni-list-item>
|
||||||
<uni-list-item v-if="1==2" title="备注" :rightText="storeCurrentConversation.showName" @click="editGroupName" :clickable="isOwner || isAdmin" :showArrow="isOwner || isAdmin"></uni-list-item>
|
<uni-list-item v-if="1==2" title="备注" :rightText="storeCurrentConversation.showName" @click="editGroupName" :clickable="isOwner || isAdmin" :showArrow="isOwner || isAdmin"></uni-list-item>
|
||||||
</uni-list>
|
</uni-list>
|
||||||
<u-gap></u-gap>
|
<u-gap></u-gap>
|
||||||
<uni-list>
|
<uni-list>
|
||||||
<uni-list-item title="查找聊天内容" to=""></uni-list-item>
|
<uni-list-item title="查找聊天内容" :to="'/pages/common/search/index?type=conversation&conversationID='+storeCurrentConversation.conversationID" showArrow></uni-list-item>
|
||||||
</uni-list>
|
</uni-list>
|
||||||
<u-gap></u-gap>
|
<u-gap></u-gap>
|
||||||
<uni-list>
|
<uni-list>
|
||||||
@@ -192,6 +192,15 @@
|
|||||||
isAdmin() {
|
isAdmin() {
|
||||||
return this.storeCurrentMemberInGroup.roleLevel === GroupMemberRole.Admin;
|
return this.storeCurrentMemberInGroup.roleLevel === GroupMemberRole.Admin;
|
||||||
},
|
},
|
||||||
|
getGroupQrcdeUrl(){
|
||||||
|
const info = {
|
||||||
|
code : this.storeCurrentConversation.groupID,
|
||||||
|
showName: `${this.storeCurrentConversation.showName}(${this.storeCurrentGroup.memberCount})`,
|
||||||
|
faceURL : this.storeCurrentConversation.faceURL,
|
||||||
|
type : "group",
|
||||||
|
};
|
||||||
|
return `/pages/common/userOrGroupQrCode?sourceInfo=${JSON.stringify(info,)}`;
|
||||||
|
},
|
||||||
getGroupVerStr() {
|
getGroupVerStr() {
|
||||||
if (
|
if (
|
||||||
this.storeCurrentGroup.needVerification ===
|
this.storeCurrentGroup.needVerification ===
|
||||||
|
|||||||
@@ -267,7 +267,7 @@
|
|||||||
itemList:['更换相册封面'],
|
itemList:['更换相册封面'],
|
||||||
success: function (res) {
|
success: function (res) {
|
||||||
if(res.tapIndex == 0){
|
if(res.tapIndex == 0){
|
||||||
_this.goto('/pages/workbench/friend-circle/chooseCircleBgImg');
|
_this.goto('/pages/find/friend-circle/chooseCircleBgImg');
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail: function (res) {
|
fail: function (res) {
|
||||||
@@ -471,7 +471,7 @@
|
|||||||
//点击自定义组件相机按钮
|
//点击自定义组件相机按钮
|
||||||
linkToRelease(params) {
|
linkToRelease(params) {
|
||||||
console.log(params);
|
console.log(params);
|
||||||
let url = "/pages/workbench/friend-circle/releaseFriendCircle?";
|
let url = "/pages/find/friend-circle/releaseFriendCircle?";
|
||||||
for(let key in params){
|
for(let key in params){
|
||||||
if(key!="tempFilePaths"){
|
if(key!="tempFilePaths"){
|
||||||
url+=key+"="+params[key]+"&";
|
url+=key+"="+params[key]+"&";
|
||||||
@@ -490,7 +490,7 @@
|
|||||||
//return videoSrc;
|
//return videoSrc;
|
||||||
},
|
},
|
||||||
leftClick(e){
|
leftClick(e){
|
||||||
this.goto('/pages/workbench/index/index',"2");
|
this.goto('/pages/find/index/index',"2");
|
||||||
},
|
},
|
||||||
onUserEvent(e){
|
onUserEvent(e){
|
||||||
switch(e.type){
|
switch(e.type){
|
||||||
|
|||||||
+21
-10
@@ -7,10 +7,10 @@
|
|||||||
background-color="transparent"></uni-nav-bar>
|
background-color="transparent"></uni-nav-bar>
|
||||||
<uni-list>
|
<uni-list>
|
||||||
<uni-list-item title="朋友圈"
|
<uni-list-item title="朋友圈"
|
||||||
thumb="/static/images/workbench/01.png"
|
thumb="/static/images/find/01.png"
|
||||||
:thumbSize="thumbSize"
|
:thumbSize="thumbSize"
|
||||||
showArrow
|
showArrow
|
||||||
to="/pages/workbench/friend-circle/friend-circle">
|
to="/pages/find/friend-circle/friend-circle">
|
||||||
<view slot="footer" v-if="last_unread_item&&last_unread_item.avatar.length>0">
|
<view slot="footer" v-if="last_unread_item&&last_unread_item.avatar.length>0">
|
||||||
<u-avatar :src="last_unread_item.avatar" mode="square" :size="70"></u-avatar>
|
<u-avatar :src="last_unread_item.avatar" mode="square" :size="70"></u-avatar>
|
||||||
<u-badge :is-dot="true" type="error" :offset="[20,60]"></u-badge>
|
<u-badge :is-dot="true" type="error" :offset="[20,60]"></u-badge>
|
||||||
@@ -19,17 +19,18 @@
|
|||||||
</uni-list>
|
</uni-list>
|
||||||
<u-gap :height="10"></u-gap>
|
<u-gap :height="10"></u-gap>
|
||||||
<uni-list>
|
<uni-list>
|
||||||
<uni-list-item title="扫一扫" thumb="/static/images/workbench/03.png" :thumbSize="thumbSize" @click="scan" clickable showArrow></uni-list-item>
|
<uni-list-item title="扫一扫" thumb="/static/images/find/03.png" :thumbSize="thumbSize" @click="scan" clickable showArrow></uni-list-item>
|
||||||
<uni-list-item title="摇一摇" thumb="/static/images/workbench/05.png" :thumbSize="thumbSize" to="/pages/workbench/friend-circle/friend-circle" showArrow></uni-list-item>
|
<uni-list-item v-if="1==2" title="摇一摇" thumb="/static/images/find/05.png" :thumbSize="thumbSize" to="/pages/find/friend-circle/friend-circle" showArrow></uni-list-item>
|
||||||
<uni-list-item title="看一看" thumb="/static/images/workbench/06.png" :thumbSize="thumbSize" to="/pages/workbench/friend-circle/friend-circle" showArrow></uni-list-item>
|
<uni-list-item v-if="1==2" title="看一看" thumb="/static/images/find/06.png" :thumbSize="thumbSize" to="/pages/find/friend-circle/friend-circle" showArrow></uni-list-item>
|
||||||
<uni-list-item title="听一听" thumb="/static/images/workbench/06.png" :thumbSize="thumbSize" to="/pages/workbench/friend-circle/friend-circle" showArrow></uni-list-item>
|
<uni-list-item v-if="1==2" title="听一听" thumb="/static/images/find/06.png" :thumbSize="thumbSize" to="/pages/find/friend-circle/friend-circle" showArrow></uni-list-item>
|
||||||
<uni-list-item title="附近" thumb="/static/images/workbench/08.png" :thumbSize="thumbSize" to="/pages/workbench/near/near" showArrow></uni-list-item>
|
<uni-list-item v-if="config.near_user_open == '1'" title="附近" thumb="/static/images/find/08.png" :thumbSize="thumbSize" to="/pages/find/near/near" showArrow></uni-list-item>
|
||||||
<uni-list-item title="购物" thumb="/static/images/workbench/09.png" :thumbSize="thumbSize" to="/pages/workbench/friend-circle/friend-circle" showArrow></uni-list-item>
|
<uni-list-item title="购物" thumb="/static/images/find/09.png" :thumbSize="thumbSize" :to="'/pages/common/webview?url='+encodeURI('http://pinduoduo.com')" showArrow></uni-list-item>
|
||||||
</uni-list>
|
</uni-list>
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
|
import { mapGetters } from "vuex";
|
||||||
export default {
|
export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@@ -37,6 +38,7 @@
|
|||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed:{
|
computed:{
|
||||||
|
...mapGetters(["config"]),
|
||||||
circleUnreadCount() {
|
circleUnreadCount() {
|
||||||
return this.$store.getters.storeCircleUnreadCount;
|
return this.$store.getters.storeCircleUnreadCount;
|
||||||
},
|
},
|
||||||
@@ -60,8 +62,17 @@
|
|||||||
//res.result;
|
//res.result;
|
||||||
return ;
|
return ;
|
||||||
}
|
}
|
||||||
if(res.result.startsWith("http")){
|
const user_prefix = `${this.config.website}/u/`;
|
||||||
return ;
|
if(res.result.startsWith(user_prefix)){
|
||||||
|
return uni.navigateTo({
|
||||||
|
url:"/pages/common/userCard/index?sourceID="+res.result.replace(user_prefix,'')
|
||||||
|
});
|
||||||
|
}
|
||||||
|
const group_prefix = `${this.config.website}/g/`;
|
||||||
|
if(res.result.startsWith(group_prefix)){
|
||||||
|
return uni.navigateTo({
|
||||||
|
url:"/pages/common/groupCard/index?sourceID="+res.result.replace(group_prefix,'')
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,14 +5,14 @@
|
|||||||
<image src="@/static/images/about_logo.png" mode=""></image>
|
<image src="@/static/images/about_logo.png" mode=""></image>
|
||||||
<view>{{ appversion }}</view>
|
<view>{{ appversion }}</view>
|
||||||
|
|
||||||
<info-item @click="checkUpdate" class="check" title="检测更新" content="" />
|
<info-item @click="checkUpdate" class="check" title="检测更新" />
|
||||||
<info-item @click="openurl('http://baidu.com')" class="check" title="官方网站" content="" />
|
<info-item @click="openurl(config.website)" class="check" title="官方网站" />
|
||||||
<info-item @click="goto('/pages/common/article?type=article&name=coom&title=商务合作')" class="check" title="商务合作" content="" />
|
<info-item @click="goto('/pages/common/article?type=spage&name=cooperation&title=商务合作')" class="check" title="商务合作" />
|
||||||
<info-item @click="goto('/pages/common/article?type=article&name=contract&title=用户协议')" class="check" title="用户协议" content="" />
|
<info-item @click="goto('/pages/common/article?type=spage&name=terms_of_service&title=用户协议')" class="check" title="用户协议" />
|
||||||
<info-item @click="goto('/pages/common/article?type=article&name=privacy&title=隐私政策')" class="check" title="隐私政策" content="" />
|
<info-item @click="goto('/pages/common/article?type=spage&name=privacy_policy&title=隐私政策')" class="check" title="隐私政策" />
|
||||||
<info-item @click="goto('/pages/common/article?type=article&name=aboutus&title=关于我们')" class="check" title="关于我们" content="" />
|
<info-item @click="goto('/pages/common/article?type=spage&name=aboutus&title=关于我们')" class="check" title="关于我们" />
|
||||||
<info-item @click="clearcache" class="check" title="清除缓存" content="" />
|
<info-item @click="clearcache" class="check" title="清除缓存" />
|
||||||
<info-item @click="show = true" class="check" title="上传调试日志" content="" />
|
<info-item @click="show = true" class="check" title="上传调试日志" />
|
||||||
|
|
||||||
<u-modal showCancelButton :show="show" title="上传日志" @confirm="uploadLog" @cancel="show = false">
|
<u-modal showCancelButton :show="show" title="上传日志" @confirm="uploadLog" @cancel="show = false">
|
||||||
<view class="slot-content">
|
<view class="slot-content">
|
||||||
@@ -30,6 +30,7 @@
|
|||||||
import {PageEvents } from "@/constant";
|
import {PageEvents } from "@/constant";
|
||||||
import InfoItem from "../selfInfo/InfoItem.vue";
|
import InfoItem from "../selfInfo/InfoItem.vue";
|
||||||
import {checkUpgrade} from "@/api/login.js"
|
import {checkUpgrade} from "@/api/login.js"
|
||||||
|
import { mapGetters } from "vuex";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
CustomNavBar,
|
CustomNavBar,
|
||||||
@@ -43,6 +44,9 @@
|
|||||||
loading: false,
|
loading: false,
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
computed:{
|
||||||
|
...mapGetters(["config"]),
|
||||||
|
},
|
||||||
onLoad() {
|
onLoad() {
|
||||||
this.getAppVersion();
|
this.getAppVersion();
|
||||||
},
|
},
|
||||||
|
|||||||
+53
-22
@@ -20,23 +20,23 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<!-- v-if="userinfo.role_id==2" -->
|
<!-- 会员 -->
|
||||||
<view class="vipbar" @click="goto('/pages/user/vip/vip')">
|
<template v-if="config.role_buy_open == '1'">
|
||||||
<img src="/static/images/user/member_crown.png" alt="" />
|
<view v-if="selfInfo.role_id==2" class="vipbar" @click="goto('/pages/user/vip/vip')">
|
||||||
<text>会员到期时间:{{userinfo.expire_at}}</text>
|
<image src="/static/images/user/member_crown.png" mode="widthFix" alt="" />
|
||||||
<u-button>我的权益</u-button>
|
<text>会员到期时间:{{selfInfo.expire_at}}</text>
|
||||||
</view>
|
<u-button>我的权益</u-button>
|
||||||
<view class="vipbar" @click="goto('/pages/user/vip/vip')">
|
</view>
|
||||||
<img src="/static/images/user/member_crown.png" alt="" />
|
<view v-else class="vipbar" @click="goto('/pages/user/vip/vip')">
|
||||||
<text>开通会员立享特权</text>
|
<image src="/static/images/user/member_crown.png" mode="widthFix" alt="" />
|
||||||
<u-button>开通</u-button>
|
<text>开通会员立享特权</text>
|
||||||
</view>
|
<u-button>开通</u-button>
|
||||||
<u-alert title="我的信息" type = "warning" :closable="closable" :description = "description"></u-alert>
|
</view>
|
||||||
|
</template>
|
||||||
<uni-list style="margin: 20rpx auto;width: 100%;">
|
<uni-list style="margin: 20rpx auto;width: 100%;">
|
||||||
<uni-list-item title="我的信息" thumb="/static/images/profile_menu_info.png" to="/pages/user/selfInfo/index" clickable showArrow ></uni-list-item>
|
<uni-list-item title="我的信息" thumb="/static/images/profile_menu_info.png" to="/pages/user/selfInfo/index" clickable showArrow ></uni-list-item>
|
||||||
<uni-list-item title="账号设置" thumb="/static/images/profile_menu_account.png" to="/pages/user/messageNotification/index" clickable showArrow ></uni-list-item>
|
<uni-list-item title="账号设置" thumb="/static/images/profile_menu_account.png" to="/pages/user/accountSetting/index" clickable showArrow ></uni-list-item>
|
||||||
<uni-list-item title="关于我们" thumb="/static/images/profile_menu_about.png" to="/pages/user/accountSetting/index" clickable showArrow ></uni-list-item>
|
<uni-list-item title="关于我们" thumb="/static/images/profile_menu_about.png" to="/pages/user/about/index" clickable showArrow ></uni-list-item>
|
||||||
</uni-list>
|
</uni-list>
|
||||||
<uni-list>
|
<uni-list>
|
||||||
<uni-list-item title="退出登录" thumb="/static/images/profile_menu_logout.png" @click="logout" clickable showArrow ></uni-list-item>
|
<uni-list-item title="退出登录" thumb="/static/images/profile_menu_logout.png" @click="logout" clickable showArrow ></uni-list-item>
|
||||||
@@ -50,10 +50,17 @@
|
|||||||
import IMSDK from "openim-uniapp-polyfill";
|
import IMSDK from "openim-uniapp-polyfill";
|
||||||
import MyAvatar from "@/components/MyAvatar/index.vue";
|
import MyAvatar from "@/components/MyAvatar/index.vue";
|
||||||
import util from "@/util";
|
import util from "@/util";
|
||||||
|
import { mapGetters } from "vuex";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
MyAvatar,
|
MyAvatar,
|
||||||
},
|
},
|
||||||
|
computed:{
|
||||||
|
...mapGetters(["config"]),
|
||||||
|
selfInfo() {
|
||||||
|
return this.$store.getters.storeSelfInfo || {expire_at:0};
|
||||||
|
},
|
||||||
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
profileMenus: [
|
profileMenus: [
|
||||||
@@ -65,15 +72,9 @@
|
|||||||
],
|
],
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
computed: {
|
|
||||||
selfInfo() {
|
|
||||||
return this.$store.getters.storeSelfInfo;
|
|
||||||
},
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
...util,
|
...util,
|
||||||
copy() {
|
copy() {
|
||||||
console.log(this.selfInfo)
|
|
||||||
uni.setClipboardData({
|
uni.setClipboardData({
|
||||||
showToast: false,
|
showToast: false,
|
||||||
data: this.selfInfo.userID,
|
data: this.selfInfo.userID,
|
||||||
@@ -115,8 +116,15 @@
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
toSelfQr() {
|
toSelfQr() {
|
||||||
|
const info = {
|
||||||
|
code : this.selfInfo.userID,
|
||||||
|
showName: `${this.selfInfo.nickname}`,
|
||||||
|
faceURL : this.selfInfo.faceURL,
|
||||||
|
type : "user",
|
||||||
|
};
|
||||||
|
const url = `/pages/common/userOrGroupQrCode?sourceInfo=${JSON.stringify(info,)}`;
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `/pages/common/userOrGroupQrCode`,
|
url: url,
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -131,6 +139,29 @@
|
|||||||
background: #0c1c33;
|
background: #0c1c33;
|
||||||
color: #FFF;
|
color: #FFF;
|
||||||
border-radius: 20rpx;
|
border-radius: 20rpx;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
margin: 20rpx 20rpx 0 20rpx;
|
||||||
|
padding: 20rpx 20rpx;
|
||||||
|
gap: 10rpx;
|
||||||
|
uni-image{
|
||||||
|
width: 50rpx;
|
||||||
|
height: 50rpx;
|
||||||
|
}
|
||||||
|
uni-text{
|
||||||
|
flex: 1;
|
||||||
|
color: #f00;
|
||||||
|
font-size: 36rpx;
|
||||||
|
}
|
||||||
|
.u-button{
|
||||||
|
font-size: 32rpx;
|
||||||
|
background-color: $uni-color-success;
|
||||||
|
border-color: $uni-color-success;
|
||||||
|
color: #FFF;
|
||||||
|
padding: 0;
|
||||||
|
height: 2em;
|
||||||
|
width: 6em;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.self_info_row {
|
.self_info_row {
|
||||||
|
|||||||
@@ -140,7 +140,6 @@
|
|||||||
},
|
},
|
||||||
async updateSelfInfo(data, key) {
|
async updateSelfInfo(data, key) {
|
||||||
try {
|
try {
|
||||||
console.log(data);
|
|
||||||
await businessInfoUpdate({
|
await businessInfoUpdate({
|
||||||
userID: this.selfInfo.userID,
|
userID: this.selfInfo.userID,
|
||||||
...data,
|
...data,
|
||||||
|
|||||||
+12
-34
@@ -6,7 +6,6 @@
|
|||||||
@clickLeft="goto(1)"
|
@clickLeft="goto(1)"
|
||||||
>
|
>
|
||||||
</uni-nav-bar>
|
</uni-nav-bar>
|
||||||
<view class="m-navbg"></view>
|
|
||||||
<view class="m-card n-ms-base n-ps-all-ll n-radius-base n-position-relative">
|
<view class="m-card n-ms-base n-ps-all-ll n-radius-base n-position-relative">
|
||||||
<view class="n-flex-row n-align-center">
|
<view class="n-flex-row n-align-center">
|
||||||
<image class="m-avatar" :src="userinfo.avatar"></image>
|
<image class="m-avatar" :src="userinfo.avatar"></image>
|
||||||
@@ -18,42 +17,21 @@
|
|||||||
<text class="m-card-text n-size-s" :style="{marginTop:'50rpx'}">会员到期时间:{{userinfo.role_id==2 ? userinfo.expire_at:'未开通'}}</text>
|
<text class="m-card-text n-size-s" :style="{marginTop:'50rpx'}">会员到期时间:{{userinfo.role_id==2 ? userinfo.expire_at:'未开通'}}</text>
|
||||||
<image class="m-card-crown n-position-absolute" src="/static/images/user/member_crown.png" mode="widthFix"></image>
|
<image class="m-card-crown n-position-absolute" src="/static/images/user/member_crown.png" mode="widthFix"></image>
|
||||||
</view>
|
</view>
|
||||||
<view class="n-ps-base n-ms-top-ll">
|
|
||||||
<text class="n-size-l n-weight-7">会员权益</text>
|
<swiper class="swiper" circular :indicator-dots="false" :autoplay="false">
|
||||||
<view class="n-flex-row n-wrap-wrap n-ms-top-ss">
|
<swiper-item>
|
||||||
<u-cell-group>
|
<view class="swiper-item uni-bg-red">A</view>
|
||||||
<u-cell :class="[idx%2==0 ? 'n-ms-right-s':'', 'n-bg-page', 'n-radius-s', 'n-ms-top-s', 'n-ps-tb-ss']"
|
</swiper-item>
|
||||||
v-for="(item, idx) in powerList" :key="idx"
|
<swiper-item>
|
||||||
:icon="item.image_text"
|
<view class="swiper-item uni-bg-green">B</view>
|
||||||
:title="item.title"
|
</swiper-item>
|
||||||
:label="item.content"
|
<swiper-item>
|
||||||
:border="false"
|
<view class="swiper-item uni-bg-blue">C</view>
|
||||||
:iconStyle="{width:'80rpx',height:'80rpx',borderRadius:'40rpx'}" >
|
</swiper-item>
|
||||||
</u-cell>
|
</swiper>
|
||||||
</u-cell-group>
|
|
||||||
</view>
|
|
||||||
</view>
|
|
||||||
|
|
||||||
<u-gap></u-gap>
|
<u-gap></u-gap>
|
||||||
<view class="n-ps-base">
|
<view class="n-ps-base">
|
||||||
<text class="n-size-l n-weight-7 n-ms-top-ss">会员套餐</text>
|
|
||||||
<scroll-view class="n-flex-row n-ms-top-ll n-wrap-nowrap" :scroll-x="true" :show-scrollbar="false">
|
|
||||||
<view :class="[idx==current ? 'm-thali-active':'m-thali', 'n-ps-all-ll', 'n-ms-right-l', 'n-flex-column', 'n-radius-base', 'n-align-center', 'n-position-relative']" v-for="(item, idx) in thaliList" :key="idx" @click="current=idx">
|
|
||||||
<text class="n-size-l n-ms-top-s n-weight-7">{{item.title}}</text>
|
|
||||||
<view class="n-flex-row n-align-end n-ms-top-base">
|
|
||||||
<text class="m-card-text n-size-s">¥</text>
|
|
||||||
<text class="m-card-text n-size-ll">{{item.price}}</text>
|
|
||||||
</view>
|
|
||||||
<text class="n-size-ss n-ms-top-ss n-color-forth n-text-decoration-through">¥{{item.orig_price}}</text>
|
|
||||||
<u-tag class="n-ms-bottom-s n-ms-top-base"
|
|
||||||
:text="'立省' + (item.orig_price - item.price) + '元'"
|
|
||||||
size="mini" shape="circle"
|
|
||||||
bgColor="#efcf95"
|
|
||||||
borderColor="#efcf95"></u-tag>
|
|
||||||
<!-- 标签 -->
|
|
||||||
<u-button class="n-position-absolute" v-if="item.label" :text="item.label" :style="{top:0,left:0}" size="mini" color="#fc393f"></u-button>
|
|
||||||
</view>
|
|
||||||
</scroll-view>
|
|
||||||
<view class="n-flex-row n-ms-top-l n-justify-center">
|
<view class="n-flex-row n-ms-top-l n-justify-center">
|
||||||
<view class="n-flex-row n-wrap-wrap n-align-start n-ms-top-base n-align-center">
|
<view class="n-flex-row n-wrap-wrap n-align-start n-ms-top-base n-align-center">
|
||||||
<view>
|
<view>
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 503 KiB After Width: | Height: | Size: 191 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 1.6 MiB |
@@ -41,6 +41,9 @@ const mutations = {
|
|||||||
|
|
||||||
const actions = {
|
const actions = {
|
||||||
async getFriendList({commit }) {
|
async getFriendList({commit }) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
let offset = 0;
|
let offset = 0;
|
||||||
let friendInfoList = [];
|
let friendInfoList = [];
|
||||||
let initialFetch = true;
|
let initialFetch = true;
|
||||||
@@ -63,6 +66,9 @@ const actions = {
|
|||||||
commit("SET_FRIEND_LIST", friendInfoList);
|
commit("SET_FRIEND_LIST", friendInfoList);
|
||||||
},
|
},
|
||||||
async getGrouplist({commit}) {
|
async getGrouplist({commit}) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
let offset = 0;
|
let offset = 0;
|
||||||
let groupList = [];
|
let groupList = [];
|
||||||
while (true) {
|
while (true) {
|
||||||
@@ -86,6 +92,9 @@ const actions = {
|
|||||||
commit("SET_GROUP_LIST", groupList);
|
commit("SET_GROUP_LIST", groupList);
|
||||||
},
|
},
|
||||||
getBlacklist({commit}) {
|
getBlacklist({commit}) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(IMSDK.IMMethods.GetBlackList, uuidv4()).then(({
|
IMSDK.asyncApi(IMSDK.IMMethods.GetBlackList, uuidv4()).then(({
|
||||||
data
|
data
|
||||||
}) => {
|
}) => {
|
||||||
@@ -93,6 +102,9 @@ const actions = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getRecvFriendApplications({commit}) {
|
getRecvFriendApplications({commit}) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(
|
IMSDK.asyncApi(
|
||||||
IMSDK.IMMethods.GetFriendApplicationListAsRecipient,
|
IMSDK.IMMethods.GetFriendApplicationListAsRecipient,
|
||||||
uuidv4(),
|
uuidv4(),
|
||||||
@@ -103,6 +115,9 @@ const actions = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getSentFriendApplications({ commit }) {
|
getSentFriendApplications({ commit }) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(
|
IMSDK.asyncApi(
|
||||||
IMSDK.IMMethods.GetFriendApplicationListAsApplicant,
|
IMSDK.IMMethods.GetFriendApplicationListAsApplicant,
|
||||||
uuidv4(),
|
uuidv4(),
|
||||||
@@ -113,6 +128,9 @@ const actions = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getRecvGroupApplications({ commit }) {
|
getRecvGroupApplications({ commit }) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(
|
IMSDK.asyncApi(
|
||||||
IMSDK.IMMethods.GetGroupApplicationListAsRecipient,
|
IMSDK.IMMethods.GetGroupApplicationListAsRecipient,
|
||||||
uuidv4(),
|
uuidv4(),
|
||||||
@@ -123,6 +141,9 @@ const actions = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getSentGroupApplications({ commit }) {
|
getSentGroupApplications({ commit }) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(
|
IMSDK.asyncApi(
|
||||||
IMSDK.IMMethods.GetGroupApplicationListAsApplicant,
|
IMSDK.IMMethods.GetGroupApplicationListAsApplicant,
|
||||||
uuidv4(),
|
uuidv4(),
|
||||||
|
|||||||
@@ -45,6 +45,9 @@ const mutations = {
|
|||||||
|
|
||||||
const actions = {
|
const actions = {
|
||||||
async getConversationList({state,commit}, isFirstPage = true) {
|
async getConversationList({state,commit}, isFirstPage = true) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
try {
|
try {
|
||||||
const {data} = await IMSDK.asyncApi(
|
const {data} = await IMSDK.asyncApi(
|
||||||
IMSDK.IMMethods.GetConversationListSplit,
|
IMSDK.IMMethods.GetConversationListSplit,
|
||||||
@@ -65,6 +68,9 @@ const actions = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
getCurrentGroup({commit}, groupID) {
|
getCurrentGroup({commit}, groupID) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(IMSDK.IMMethods.GetSpecifiedGroupsInfo, uuidv4(), [
|
IMSDK.asyncApi(IMSDK.IMMethods.GetSpecifiedGroupsInfo, uuidv4(), [
|
||||||
groupID,
|
groupID,
|
||||||
]).then(({
|
]).then(({
|
||||||
@@ -74,6 +80,9 @@ const actions = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getCurrentMemberInGroup({commit,rootState}, groupID) {
|
getCurrentMemberInGroup({commit,rootState}, groupID) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(IMSDK.IMMethods.GetSpecifiedGroupMembersInfo, uuidv4(), {
|
IMSDK.asyncApi(IMSDK.IMMethods.GetSpecifiedGroupMembersInfo, uuidv4(), {
|
||||||
groupID,
|
groupID,
|
||||||
userIDList: [rootState.user.selfInfo.userID],
|
userIDList: [rootState.user.selfInfo.userID],
|
||||||
@@ -84,6 +93,9 @@ const actions = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
getUnReadCount({commit}) {
|
getUnReadCount({commit}) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
IMSDK.asyncApi(IMSDK.IMMethods.GetTotalUnreadMsgCount, uuidv4()).then(
|
IMSDK.asyncApi(IMSDK.IMMethods.GetTotalUnreadMsgCount, uuidv4()).then(
|
||||||
(res) => {
|
(res) => {
|
||||||
//console.log(res);
|
//console.log(res);
|
||||||
|
|||||||
@@ -29,6 +29,9 @@ const actions = {
|
|||||||
commit("SET_CURRENT_MSG", message);
|
commit("SET_CURRENT_MSG", message);
|
||||||
},
|
},
|
||||||
async getHistoryMesageList({commit,state}, params) {
|
async getHistoryMesageList({commit,state}, params) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
let emptyFlag = true;
|
let emptyFlag = true;
|
||||||
try {
|
try {
|
||||||
//console.log(params);
|
//console.log(params);
|
||||||
|
|||||||
@@ -39,6 +39,9 @@ const mutations = {
|
|||||||
|
|
||||||
const actions = {
|
const actions = {
|
||||||
async getSelfInfo({ commit }) {
|
async getSelfInfo({ commit }) {
|
||||||
|
//#ifndef APP
|
||||||
|
return [];
|
||||||
|
//#endif
|
||||||
try {
|
try {
|
||||||
const result = await IMSDK.asyncApi(IMSDK.IMMethods.GetSelfUserInfo,uuidv4(),);
|
const result = await IMSDK.asyncApi(IMSDK.IMMethods.GetSelfUserInfo,uuidv4(),);
|
||||||
const res = await businessGetUserInfo(result.data.userID);
|
const res = await businessGetUserInfo(result.data.userID);
|
||||||
|
|||||||
@@ -362,7 +362,6 @@
|
|||||||
this._mapInstance.clearOverLays();
|
this._mapInstance.clearOverLays();
|
||||||
// 创建新注记
|
// 创建新注记
|
||||||
data.markers && data.markers.forEach(item => {
|
data.markers && data.markers.forEach(item => {
|
||||||
console.log(item)
|
|
||||||
const option = {};
|
const option = {};
|
||||||
if (item.icon) {
|
if (item.icon) {
|
||||||
option.icon = new T.Icon({
|
option.icon = new T.Icon({
|
||||||
|
|||||||
+1
-4
@@ -259,10 +259,7 @@ export default{
|
|||||||
v = v.replace(/\\/ig,"/").replace('/\/\/ig',"/");
|
v = v.replace(/\\/ig,"/").replace('/\/\/ig',"/");
|
||||||
//console.log(v);
|
//console.log(v);
|
||||||
if(isString(v)){
|
if(isString(v)){
|
||||||
if(v.startsWith('blob:')){
|
if(v.startsWith('blob:') || v.startsWith('file://') || v.startsWith('http')){
|
||||||
return v;
|
|
||||||
}
|
|
||||||
if(v.startsWith('file://')){
|
|
||||||
return v;
|
return v;
|
||||||
}
|
}
|
||||||
v= v.startsWith('/') ? v : '/'+v;
|
v= v.startsWith('/') ? v : '/'+v;
|
||||||
|
|||||||
+8
-8
@@ -1,12 +1,12 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
configureWebpack: {
|
// configureWebpack: {
|
||||||
// 开启缓存
|
// // 开启缓存
|
||||||
cache: true,
|
// cache: true,
|
||||||
// 并行构建
|
// // 并行构建
|
||||||
parallel: require('os').cpus().length > 1,
|
// parallel: true,
|
||||||
// 关闭sourcemap加速生产构建
|
// // 关闭sourcemap加速生产构建
|
||||||
productionSourceMap: false
|
// productionSourceMap: false
|
||||||
},
|
// },
|
||||||
// 关闭文件hash (开发环境)
|
// 关闭文件hash (开发环境)
|
||||||
filenameHashing: process.env.NODE_ENV !== 'production'
|
filenameHashing: process.env.NODE_ENV !== 'production'
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user