接口调用

main
syt 1 month ago
parent 70418ded46
commit 6f420c2833
  1. 101
      api/index.js
  2. 1622
      api/qrcode.js
  3. 17
      components/dashan.vue
  4. 13
      components/share.vue
  5. 2
      main.js
  6. 2
      pages.json
  7. 15
      pages/login/index.vue
  8. 3
      pages/login/password.vue
  9. 2
      pages/peiwan/detail.vue
  10. 15
      pages/peiwan/index.vue
  11. 123
      pages/user/index.vue
  12. 4
      pages/users/about/index.vue
  13. 95
      pages/users/chengshi/index.vue
  14. 40
      pages/users/dashan/index.vue
  15. 173
      pages/users/feedback/add.vue
  16. 34
      pages/users/feedback/detail.vue
  17. 50
      pages/users/feedback/list.vue
  18. 105
      pages/users/help/index.vue
  19. 61
      pages/users/notice/index.vue
  20. 46
      pages/users/qingshaonian/detail.vue
  21. 143
      pages/users/qingshaonian/index.vue
  22. 11
      pages/users/recharge/index.vue
  23. 157
      pages/users/site/index.vue
  24. 57
      pages/users/team/index.vue
  25. 25
      pages/users/xieyi/index.vue
  26. 42
      pages/users/yinsi/index.vue
  27. 83
      pages/users/zhuxiao/index.vue
  28. 4
      pages/xiaoxi/dashan.vue
  29. 25
      pages/xiaoxi/detail.vue
  30. 4
      pages/xiaoxi/fangke.vue
  31. 17
      pages/xiaoxi/heimingdan.vue
  32. 40
      pages/xiaoxi/index.vue
  33. 72
      pages/xiaoxi/xitong.vue

@ -1,5 +1,102 @@
import { request } from './request'
const api = {
const api = {
//获取当前用户得聊天好友列表
findFrindList(data) {
return request({
url: 'api/user/findFrindList',
method: 'post',
data
})
},
//系统消息列表
systemNoticeList(data) {
return request({
url: 'api/systemNoticeList',
method: 'post',
data
})
},
//新增城市合作
urbanCooperation(data) {
return request({
url: 'api/user/urbanCooperation',
method: 'post',
data
})
},
//新增意见反馈
feedback(data) {
return request({
url: 'api/user/feedback',
method: 'post',
data
})
},
//意见反馈列表
feedbackList(data) {
return request({
url: 'api/user/feedbackList',
method: 'post',
data
})
},
//帮助中心
helpCenter(data) {
return request({
url: 'api/helpCenter',
method: 'get',
data
})
},
//关闭青少年
async closeTeenageMode(data) {
return request({
url: 'api/user/closeTeenageMode',
method: 'post',
data
})
},
//开启青少年
async openTeenageMode(data) {
return request({
url: 'api/user/openTeenageMode',
method: 'post',
data
})
},
//注销
async cancelAccount(data) {
return request({
url: 'api/user/cancelAccount',
method: 'post',
data
})
},
//隐私&消息通知
async privacyConfig(data) {
return request({
url: 'api/user/privacyConfig',
method: 'post',
data
})
},
//新增与移除黑名单
async addOrRemoveBlacklist(data) {
return request({
url: 'api/user/addOrRemoveBlacklist',
method: 'post',
data
})
},
//我的团队
async myTeam(data) {
return request({
url: 'api/user/myTeam',
method: 'post',
data
})
},
//任务列表
async taskList(data) {
return request({
@ -52,7 +149,7 @@ const api = {
mealsetList(data){
return request({
url: 'api/mealsetList',
method: 'get',
method: 'post',
data
})
},

File diff suppressed because it is too large Load Diff

@ -13,7 +13,7 @@
<view class="b">
<view class="txt">系统推荐</view>
<view class="list" v-if="list && list.length>0">
<view class="item" v-for="(a,i) in list" :class="tabIndex == i?'item-on':''" >
<view class="item" v-for="(a,i) in list" :key="i" :class="tabIndex == i?'item-on':''" >
<view class="text" @click="tabItem(1,i)">{{a.content}}</view>
<view class="anniu anniu-on" v-if="a.isDefault == 1">默认</view>
<view class="anniu" v-else @click="tabItem(2,i)">设为默认</view>
@ -115,7 +115,7 @@
const { code, data } = await this.$api.chat({
userId: uni.getStorageSync("userInfo").id,
sellerId: this.info.userid,
type: 3,
type: 6,
message: this.content
})
if(code == 200){
@ -162,12 +162,14 @@
<style scoped lang="scss">
.dashan{
width: 670rpx;
min-height: 270rpx;
min-height: 270rpx;
overflow: hidden;
background: #FFFFFF;
border-radius: 20rpx;
padding-bottom: 50rpx;
.fd{
margin-top: 50rpx;
margin-bottom: 50rpx;
margin-top: 50rpx;
overflow: hidden;
.btn{
width: 300rpx;
text-align: center;
@ -219,7 +221,10 @@
}
}
}
.list{
.list{
max-height: 500rpx;
overflow-x: hidden;
overflow-y: auto;
.item{
margin-top: 20rpx;
display: flex;

@ -89,9 +89,10 @@
}
})
return ;
}else if(scene == 'src'){
}
if(scene == 'src'){
uni.setClipboardData({
data: this.$articleShareUrl+this.info.id,
data: this.$userShareUrl+this.info.invitationCode,
success: function () {
uni.getClipboardData({
success: function (res) {
@ -104,7 +105,13 @@
}
})
return ;
}
}
if(scene == 'hb'){
uni.$emit("closeSharePopup",false)
uni.$emit("openHaibaoPopup",true)
return;
}
uni.showLoading({
title: '加载中',
mask: true

@ -20,7 +20,7 @@ Vue.config.productionTip = false
import api from '@/api/index.js'
Vue.prototype.$api = api
Vue.prototype.$articleShareUrl = "https://api.lyiyuan.cn/profile/upload/web/index.html#/pages/dongtai/detail?type=web&id="
Vue.prototype.$userShareUrl = "https://api.lyiyuan.cn/profile/upload/web/index.html#/pages/login/res?id="
Vue.prototype.$userShareUrl = "https://api.lyiyuan.cn/profile/upload/web/index.html#/pages/login/reg?id="
App.mpType = 'app'
const app = new Vue({

@ -352,7 +352,7 @@
"path" : "pages/users/xieyi/index",
"style" :
{
"navigationBarTitleText" : "协议规则"
"navigationBarTitleText" : ""
}
},
{

@ -21,7 +21,7 @@
<image src="@/static/wx.png" @click="wxLogin()"></image>
</view>
<view class="c">
<image @click="clickCheck()" v-if="isCheck" src="@/static/icon-select.png"></image><image @click="clickCheck()" v-else src="@/static/icon-select-on.png"></image>我已阅读并同意<text>APP用户协议</text><text>APP隐私条款</text>
<image @click="clickCheck()" v-if="isCheck" src="@/static/icon-select.png"></image><image @click="clickCheck()" v-else src="@/static/icon-select-on.png"></image>我已阅读并同意<text @click="openPages(1)">《APP用户协议》</text><text@click="openPages(2)">APP隐私条款</text>
</view>
</view>
</view>
@ -55,7 +55,18 @@
this.isShow1 = true
}
},
methods: {
methods: {
openPages(index) {
if(index == 1){
uni.navigateTo({
url: "/pages/users/about/index?type=CONFIG_USER_AGREEMENT"
})
}else{
uni.navigateTo({
url: "/pages/users/about/index?type=CONFIG_PRIVACY_POLICY"
})
}
},
// App
wxLogin() {
const that = this;

@ -159,7 +159,8 @@
this.phone = ""
this.code = ""
this.apassword = ""
this.password = ""
this.password = ""
uni.removeStorageSync("userInfo")
uni.showToast({
title: "修改成功"
})

@ -13,7 +13,7 @@
<view class="vip" v-if="userInfo.memberflag>=1">VIP{{userInfo.memberflag}}</view>
<image class="sex" v-if="userInfo.sex ==2" src="@/static/peiwan-nv.png"></image>
<image class="sex" v-else src="@/static/peiwan-nan.png"></image>
<view class="city" v-if="userInfo.province"><image class="location" src="@/static/dingwei2.png"></image>{{userInfo.province+"-"+userInfo.city}}</view>
<view class="city" v-if="userInfo.province && userInfo.cityHide != 1"><image class="location" src="@/static/dingwei2.png"></image>{{userInfo.province+"-"+userInfo.city}}</view>
</view>
<view class="b">
<view class="tag" v-if="userInfo.age">{{userInfo.age}}</view>

@ -291,7 +291,20 @@
</script>
<style scoped lang="scss">
.home{
.home{
.empty{
padding: 150rpx 0;
text-align: center;
font-weight: 500;
font-size: 28rpx;
color: #222222;
image{
display: block;
width: 460rpx;
height: 400rpx;
margin: 0 auto;
}
}
&-navbar{
width: 100%;
overflow: hidden;

@ -154,17 +154,17 @@
<view class="invite" v-if="show">
<view class="body">
<view class="content">
<image class="avatar" :src="userInfo.img"></image>
<view class="name">{{userInfo.id}}</view>
<image class="avatar" :src="userInfo.faceImage?userInfo.faceImage:userInfo.img"></image>
<view class="name">{{userInfo.nickname}}</view>
<image class="txt" src="@/static/txt.png"></image>
<image class="code" src="@/static/code.png"></image>
<image class="code" :src="qrcode" show-menu-by-longpress="true"></image>
<view class="txt1">-长按识别图中二维码-</view>
<view class="id">邀请码{{userInfo.invitationCode}}</view>
<image class="zw" src="@/static/zw.png"></image>
</view>
<view class="btns">
<view class="cancle">取消</view>
<view class="sure">保存</view>
<view class="cancle" @click="toCancle()">取消</view>
<view class="sure" @click="toSave()">保存</view>
</view>
</view>
</view>
@ -173,7 +173,8 @@
</view>
</template>
<script>
<script>
import { createQrCodeImg } from '@/api/qrcode'
export default {
data() {
return {
@ -189,7 +190,8 @@
},
userInfo: {},
baseUrl: "",
info: {}
info: {},
qrcode: ""
}
},
onLoad() {
@ -198,12 +200,66 @@
that.isPopup = false;
that.isShare = false;
that.baseUrl = that.$baseUrl;
})
uni.$on("openHaibaoPopup",res=>{
that.show = true;
})
},
onShow() {
this.getUserInfo();
},
methods: {
methods: {
toCancle() {
this.show = false;
},
toSave() {
uni.showLoading({
title: "正在保存"
})
uni.downloadFile({
url:"https://shejiao.njlvguo.com/uploads/erweima.jpg",
complete:(res)=>{
uni.hideLoading();
uni.saveImageToPhotosAlbum({
filePath:res.tempFilePath,
success: function() {
uni.showToast({
title: "保存成功",
icon: "none"
});
},
fail: function() {
uni.showToast({
title: "保存失败",
icon: "none"
});
}
})
}
})
this.show = false;
},
//
async getConfigData() {
const that = this;
let res1 = await that.$api.getConfigData({dictType: 'CONFIG_CUSTOMER_SERVICE_USERID'});
if(res1.data.content){
that.toChat(res1.data.content)
}
},
//
async toChat(sellerId) {
const { code, data } = await this.$api.findZegoToken({
userId: uni.getStorageSync("userInfo").id,
sellerId
})
if(code == 200){
uni.setStorageSync("chatToken",data.token);
uni.navigateTo({
url: "/pages/users/chat?id="+sellerId+"&roomId="+data.roomId
})
}
},
openPage(index,id){
if(index == 1){
uni.navigateTo({
@ -243,7 +299,12 @@
uni.navigateTo({
url: "/pages/users/wallet/index"
})
}else if(index == 10){
}else if(index == 10){
if(this.userInfo.realnameFlag == 0){
this.isPopup = true
return ;
}
uni.navigateTo({
url: "/pages/users/recharge/index"
})
@ -287,9 +348,46 @@
if(this.userInfo.realnameFlag == 0){
this.isPopup = true
return ;
}
}
this.info.id = this.userInfo.id
this.info.invitationCode = this.userInfo.invitationCode
this.isShare = true;
}
}else if(index == 18){
uni.navigateTo({
url: "/pages/users/team/index"
})
}else if(index == 19){
uni.navigateTo({
url: "/pages/users/site/index"
})
}else if(index == 20){
uni.navigateTo({
url: "/pages/users/help/index"
})
}else if(index == 21){
if(this.userInfo.realnameFlag == 0){
this.isPopup = true
return ;
}
uni.navigateTo({
url: "/pages/users/chengshi/index"
})
}else if(index == 22){
if(this.userInfo.realnameFlag == 0){
this.isPopup = true
return ;
}
uni.navigateTo({
url: "/pages/users/feedback/add"
})
}else if(index == 23){
if(this.userInfo.realnameFlag == 0){
this.isPopup = true
return ;
}
this.getConfigData();
}
},
//
async toSign() {
@ -313,7 +411,8 @@
async getUserInfo() {
const { code, data , msg } = await this.$api.findUserInfo({userId: uni.getStorageSync("userInfo").id});
if(code == 200){
this.userInfo = data;
this.userInfo = data;
this.qrcode = createQrCodeImg(this.$userShareUrl+this.userInfo.invitationCode, { 'size': 500 });
uni.setStorageSync("userInfo",data);
}else{
uni.showToast({

@ -20,7 +20,9 @@
async getInfo() {
const { code,data } = await this.$api.getConfigData({dictType: this.type});
if(code == 200){
this.content = data.content;
this.content = data.content.replace(/style=""/g, '')
.replace(/<img " src=/g, '<img src=')
.replace(/<img src=/g, '<img style="width: 100%; height:100%; display:block" src=');
uni.setNavigationBarTitle({
title: data.title
})

@ -1,10 +1,8 @@
<template>
<view class="qingshaonian">
<view class="bd">
</view>
<view class="bd" v-html="content"></view>
<view class="fd">
<view class="btn">申请合作</view>
<view class="btn" @click="show = true">申请合作</view>
</view>
<u-popup v-model="show" mode="center" border-radius="20" :mask-close-able="true" zIndex="21">
<view class="hezuo">
@ -13,45 +11,110 @@
<view class="item">
<view class="a"><text>*</text>姓名</view>
<view class="b">
<input type="text" placeholder="请输入" />
<input v-model="name" type="text" placeholder="请输入" />
</view>
</view>
<view class="item">
<view class="a"><text>*</text>手机号</view>
<view class="b">
<input type="number" placeholder="请输入" />
<input v-model="phone" type="number" placeholder="请输入" />
</view>
</view>
<view class="item">
<view class="a">所在区域</view>
<view class="b">
<picker mode="region">
<view class="picker picker-on">请输入</view>
</picker>
<view class="picker picker-on" @click="show1 = true">{{province?(province+"-"+city+"-"+district):'请选择'}}</view>
</view>
</view>
<view class="item">
<view class="a">公司名称</view>
<view class="b">
<input type="text" placeholder="请输入" />
<input v-model="companyname" type="text" placeholder="请输入" />
</view>
</view>
</view>
<view class="btns">提交</view>
<view class="btns" @click="toReg()">提交</view>
</view>
</u-popup>
</u-popup>
<u-picker mode="region" v-model="show1" :defaultRegion="defaultRegion" @cancel="cancel" @confirm="confirm" ></u-picker>
</view>
</template>
<script>
export default {
data() {
return {
show: true
return {
show1: false,
content: "",
show: false,
defaultRegion: [],
phone: "",
name: "",
companyname: "",
province: "",
city: "",
district: ""
}
},
onLoad() {
this.getInfo();
},
methods: {
methods: {
cancel() {
this.show1 = false;
},
confirm(e) {
this.show1 = false;
this.defaultRegion = [e.province.name,e.city.name,e.area.name]
this.province = e.province.name;
this.city = e.city.name;
this.district = e.area.name;
},
async toReg() {
if(!this.name){
uni.showToast({
icon: "none",
position: "bottom",
title: "姓名不能为空!"
})
return ;
}
if(!this.phone){
uni.showToast({
icon: "none",
position: "bottom",
title: "手机号不能为空!"
})
return ;
}
const {code, data, msg} = await this.$api.urbanCooperation({
userId: uni.getStorageSync("userInfo").id,
name: this.name,
phone: this.phone,
quyu: this.defaultRegion.join(","),
companyname: this.companyname,
})
if(code == 200){
uni.showToast({
title: "提交成功"
})
this.show = false
}else{
uni.showToast({
icon: "none",
position: "bottom",
title: msg
})
}
},
async getInfo() {
const { code,data } = await this.$api.getConfigData({dictType: 'CONFIG_URBAN_COOPERATION'});
if(code == 200){
this.content = data.content.replace(/style=""/g, '')
.replace(/<img " src=/g, '<img src=')
.replace(/<img src=/g, '<img style="width: 100%; height:100%; display:block" src=');
}
},
}
}
</script>

@ -2,9 +2,10 @@
<view class="qingshaonian">
<view class="title">设置搭讪语后无需选择直接发送</view>
<view class="bd">
<view class="item" v-for="i in 10" :key="i" @click="tabItem(i)">
<view class="txt">哈喽很高兴认识你一起嗨皮吧~</view>
<view class="btn" :class="tabIndex == i?'btn-on':''">{{tabIndex == i?'默认':'设为默认'}}</view>
<view class="item"v-for="(a,i) in list" :key="i">
<view class="txt">{{a.content}}</view>
<view class="btn btn-on" v-if="a.isDefault == 1">默认</view>
<view class="btn" v-else @click="toSet(i)">设为默认</view>
</view>
</view>
</view>
@ -14,13 +15,36 @@
export default {
data() {
return {
tabIndex: 1,
tabIndex: 1,
list: []
}
},
onLoad() {
this.getList();
},
methods: {
tabItem(i){
this.tabIndex = i;
}
methods: {
//
async getList() {
const { code, data } = await this.$api.findAccost({
userId: uni.getStorageSync("userInfo").id
})
if(code == 200){
this.list = data;
}
},
//
async toSet(index) {
const { code, data } = await this.$api.setAccostDefault({
userId: uni.getStorageSync("userInfo").id,
id: this.list[index].id
})
if(code == 200){
uni.showToast({
title: "设置成功"
})
this.getList();
}
},
}
}
</script>

@ -1,8 +1,8 @@
<template>
<view class="add">
<view class="add-hd">如需尽快解决问题可直接联系在线客服<image src="@/static/jiantou1.png"></image></view>
<view class="add-hd" @click="getConfigData()">如需尽快解决问题可直接联系在线客服<image src="@/static/jiantou1.png"></image></view>
<view class="add-content">
<view class="content">
<!-- <view class="content">
<view class="title"><text class="red">*</text>反馈类型</view>
<view class="tab">
<view class="li" :class="tabIndex == 1?'li-on':''" @click="tabItem(1)">界面</view>
@ -13,24 +13,24 @@
<view class="picker picker-on">请选择</view>
</picker>
</view>
</view>
</view> -->
<view class="content">
<view class="title"><text class="red">*</text>反馈内容</view>
<view class="box">
<textarea maxlength="200" placeholder="如有必要,请详细描述(200字以内)~"></textarea>
<view class="tips">0/200</view>
<textarea v-model="content" maxlength="200" placeholder="如有必要,请详细描述(200字以内)~"></textarea>
<view class="tips">{{content.length}}/200</view>
</view>
</view>
<view class="content">
<view class="title"><text class="red">*</text>图片上传<text class="hs">(上传聊天截图或与问题描述相关的图片)</text></view>
<view class="list">
<view class="item">
<image class="pic" src="@/static/1.png"></image>
<image class="del" src="@/static/fabu-cha.png"></image>
</view>
<view class="upload">
<image class="pic" src="@/static/fankui-tianjia.png"></image>
<view class="txt">上传图片</view>
<view class="item" v-for="(a,i) in imgurl" :key="i">
<image class="pic" :src="a"></image>
<image class="del" @click="toDel(i)" src="@/static/fabu-cha.png"></image>
</view>
<view class="upload" @click="uploadImg()">
<image class="pic" src="@/static/fankui-tianjia.png"></image>
<view class="txt">上传图片</view>
</view>
</view>
</view>
@ -38,23 +38,23 @@
<view class="title"><text class="red">*</text>联系方式</view>
<view class="list">
<view class="dd">
<input type="text" placeholder="请填写您的姓名"/>
<input v-model="name" type="text" placeholder="请填写您的姓名"/>
</view>
<view class="dd">
<input type="text" placeholder="请填写您的电话或邮箱"/>
<input v-model="phone" type="text" placeholder="请填写您的电话"/>
</view>
</view>
</view>
</view>
<view class="add-fd">
<view class="btn">提交反馈</view>
<view class="history">反馈记录 ></view>
<view class="btn" @click="toReg()">提交反馈</view>
<view class="history" @click="toPage()">反馈记录 ></view>
</view>
<u-popup v-model="show" mode="center" border-radius="20" :mask-close-able="true">
<view class="feed">
<image src="@/static/feed-01.png"></image>
<view class="title">反馈提交成功</view>
<view class="btn">我知道了</view>
<view class="btn" @click="show = false">我知道了</view>
</view>
</u-popup>
</view>
@ -64,14 +64,141 @@
export default {
data() {
return {
show: false,
tabIndex: 1
show: false,
imgurl: [],
content: "",
tabIndex: 1,
name: "",
phone: ""
};
},
methods: {
tabItem(index) {
this.tabIndex = index;
}
methods: {
toPage() {
uni.navigateTo({
url: "/pages/users/feedback/list"
})
},
//
async getConfigData() {
const that = this;
let res1 = await that.$api.getConfigData({dictType: 'CONFIG_CUSTOMER_SERVICE_USERID'});
if(res1.data.content){
that.toChat(res1.data.content)
}
},
//
async toChat(sellerId) {
const { code, data } = await this.$api.findZegoToken({
userId: uni.getStorageSync("userInfo").id,
sellerId
})
if(code == 200){
uni.setStorageSync("chatToken",data.token);
uni.navigateTo({
url: "/pages/users/chat?id="+sellerId+"&roomId="+data.roomId
})
}
},
//
uploadImg() {
const that = this
uni.chooseImage({
count: 9-that.imgurl.length,
sizeType: ["original"], //
sourceType: ["album", "camera"],
success: (res1) => {
console.log(res1)
for(var i = 0; i<res1.tempFilePaths.length;i++){
uni.uploadFile({
name: 'file',
url: that.$baseUrl+'/prod-api/common/upload',
filePath: res1.tempFilePaths[i],
success: (res) => {
const {code, fileName, url, msg} = JSON.parse(res.data);
if(code == 200){
uni.showToast({
title: "上传成功"
})
that.imgurl.push(url)
}else{
uni.showToast({
icon: "error",
title: "上传失败"
})
}
},
fail: (err) => {
console.log(err)
}
});
}
},
fail(err){
console.log("fail",err)
}
});
},
async toReg() {
const that = this;
if(!that.content){
uni.showToast({
icon: "none",
position: "bottom",
title: "反馈内容不能为空!"
})
return ;
}
if(that.imgurl.length == 0){
uni.showToast({
icon: "none",
position: "bottom",
title: "请上传图片"
})
return ;
}
if(!that.name){
uni.showToast({
icon: "none",
position: "bottom",
title: "姓名不能为空!"
})
return ;
}
if(!that.phone){
uni.showToast({
icon: "none",
position: "bottom",
title: "电话不能为空!"
})
return ;
}
const { code, data, msg } = await that.$api.feedback({
userId: uni.getStorageSync("userInfo").id,
content: that.content,
imgurl: that.imgurl.join(","),
name: that.name,
phone: that.phone
})
if(code == 200){
that.imgurl = [];
that.content = "";
that.name = "";
that.phone = "";
that.show = true;
}else{
uni.showToast({
icon: "none",
position: "bottom",
title: msg
})
}
},
tabItem(index) {
this.tabIndex = index;
},
toDel(i) {
this.imgurl.splice(i,1)
},
}
}
</script>

@ -1,26 +1,18 @@
<template>
<view class="feed">
<view class="content">
<view class="item">
<view class="fl">反馈类型</view>
<view class="fr">界面</view>
</view>
<view class="item">
<view class="fl">问题分类</view>
<view class="fr">体验不好</view>
</view>
<view class="item">
<view class="fl">姓名</view>
<view class="fr"></view>
<view class="fr">{{info.name}}</view>
</view>
<view class="item">
<view class="fl">电话/邮箱</view>
<view class="fr">13078980980</view>
<view class="fl">电话</view>
<view class="fr">{{info.phone}}</view>
</view>
<view class="items">
<view class="fl">体验不好</view>
<view class="fl">{{info.content}}</view>
<view class="fr">
<image v-for="i in 4" :key="i" src="@/static/pic.jpg"></image>
<image v-for="(a,i) in info.imgurls" mode="aspectFill" :key="i" :src="a" @click="perviewimage(i)"></image>
</view>
</view>
</view>
@ -31,8 +23,22 @@
export default {
data() {
return {
info: {}
};
},
onLoad() {
this.info=uni.getStorageSync("pcontent");
if(this.info.imgurl && this.info){
this.info.imgurls = this.info.imgurl.split(",")
}
},
methods: {
perviewimage(index) {
uni.previewImage({
urls: this.info.imgurls,
current: index
})
}
}
}
</script>

@ -1,13 +1,17 @@
<template>
<view class="feed">
<view class="item">
<view class="item" v-for="(a,i) in list" :key="i" @click="toPage(a)">
<view class="fl">
<view class="title">体验不好 测试以下</view>
<view class="desc">2024-03-03 23:22:22</view>
<view class="title">{{a.content}}</view>
<view class="desc">{{a.createTime}}</view>
</view>
<view class="fr">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="empty" v-if="isShow">
<image src="@/static/empty.png"></image>
<view class="txt">暂无数据</view>
</view>
</view>
</template>
@ -16,16 +20,50 @@
export default {
data() {
return {
list: [],
isShow: false
};
}
},
onLoad() {
this.getList();
},
methods: {
toPage(a) {
uni.setStorageSync("pcontent",a);
uni.navigateTo({
url: "/pages/users/feedback/detail"
})
},
async getList() {
const {code,data} = await this.$api.feedbackList({
userId: uni.getStorageSync("userInfo").id
})
if(code == 200){
this.isShow = data.length == 0?true:false;
this.list = data;
}
}
},
}
</script>
<style scoped lang="scss">
.feed{
padding: 0 25rpx 25rpx;
overflow: hidden;
overflow: hidden;
.empty{
padding: 150rpx 0;
text-align: center;
font-weight: 500;
font-size: 28rpx;
color: #222222;
image{
display: block;
width: 460rpx;
height: 400rpx;
margin: 0 auto;
}
}
.item{
height: 150rpx;
background: #FFFFFF;

@ -1,83 +1,23 @@
<template>
<view class="help">
<view class="help-dl" :class="tabIndex == 1?'help-dl-on':''" @click="tabItem(1)">
<view class="help-dl" v-for="(a,i) in list" :key="i" :class="a.isClick?'help-dl-on':''" @click="tabItem(i)">
<view class="dt">
<image class="icon" src="@/static/icon-help-01.png"></image>
<image class="icon" :src="a.icon"></image>
<view class="info">
<view class="fl">账号问题<text>账号注册绑定密码修改等</text></view>
<view class="fl">{{a.title}}<text>{{a.content}}</text></view>
<view class="fr">
<image class="img2" src="@/static/icon-help-up.png"></image>
<image class="img1" src="@/static/icon-help-down.png"></image>
<image class="img2" v-if="a.isClick" src="@/static/icon-help-up.png"></image>
<image class="img1" v-else src="@/static/icon-help-down.png"></image>
</view>
</view>
</view>
<view class="dd">
<view class="item">
绑定手机<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
绑定微信<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
注销账号<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
是否支持多设备登录<image src="@/static/icon-help-right.png"></image>
</view>
</view>
</view>
<view class="help-dl" :class="tabIndex == 2?'help-dl-on':''" @click="tabItem(2)">
<view class="dt">
<image class="icon" src="@/static/icon-help-02.png"></image>
<view class="info">
<view class="fl">购买问题<text>墨刀会员购买充值续费等</text></view>
<view class="fr">
<image class="img2" src="@/static/icon-help-up.png"></image>
<image class="img1" src="@/static/icon-help-down.png"></image>
</view>
</view>
</view>
<view class="dd">
<view class="item">
绑定手机<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
绑定微信<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
注销账号<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
是否支持多设备登录<image src="@/static/icon-help-right.png"></image>
</view>
</view>
</view>
<view class="help-dl" :class="tabIndex == 3?'help-dl-on':''" @click="tabItem(3)">
<view class="dt">
<image class="icon" src="@/static/icon-help-03.png"></image>
<view class="info">
<view class="fl">发票问题<text>发票信息开票进度等</text></view>
<view class="fr">
<image class="img2" src="@/static/icon-help-up.png"></image>
<image class="img1" src="@/static/icon-help-down.png"></image>
</view>
</view>
</view>
<view class="dd">
<view class="item">
绑定手机<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
绑定微信<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
注销账号<image src="@/static/icon-help-right.png"></image>
</view>
<view class="item">
是否支持多设备登录<image src="@/static/icon-help-right.png"></image>
<view class="item" v-for="(b,idx) in a.contentList" :key="idx" @click="toPage(a)">
{{b.title}}<image src="@/static/icon-help-right.png"></image>
</view>
</view>
</view>
</view>
</template>
@ -85,13 +25,34 @@
export default {
data() {
return {
tabIndex: 1
tabIndex: 0,
list: [],
};
},
onLoad() {
this.getList();
},
methods: {
methods: {
toPage(a) {
uni.setStorageSync("pcontent",a)
uni.navigateTo({
url: "/pages/users/xieyi/index"
})
},
tabItem (index) {
this.tabIndex = index;
}
this.list[index].isClick = !this.list[index].isClick;
},
async getList() {
let { code, data } = await this.$api.helpCenter({});
if(code == 200){
if(data && data.length > 0){
data.map(a=>{
a.isClick = false
})
}
this.list = data
}
},
}
}
</script>

@ -3,11 +3,11 @@
<view class="content">
<view class="item">
<view class="a">新消息提示音</view>
<u-switch active-color="#000000" v-model="checked"></u-switch>
<u-switch active-color="#000000" v-model="checked" @change="changeChecked()"></u-switch>
</view>
<view class="item">
<view class="a">新消息震动</view>
<u-switch active-color="#000000" v-model="checked"></u-switch>
<u-switch active-color="#000000" v-model="checked1" @change="changeChecked1()"></u-switch>
</view>
</view>
</view>
@ -17,8 +17,63 @@
export default {
data() {
return {
checked: true
checked: false,
checked1: false
};
},
onLoad() {
this.getUserInfo();
},
methods: {
//
async getUserInfo() {
const { code, data , msg } = await this.$api.findUserInfo({userId: uni.getStorageSync("userInfo").id});
if(code == 200){
this.checked = (data.msgVoice == 1?true:false)
this.checked1 = (data.msgShock == 1?true:false)
uni.setStorageSync("userInfo",data);
}else{
uni.showToast({
title: mgs,
position: "bottom",
icon: "none",
})
}
},
async changeChecked(e) {
const { code, data, msg } = await this.$api.privacyConfig({
"userId": uni.getStorageSync("userInfo").id,
"msgVoice": this.checked?1:0 //01
});
if(code == 200){
uni.showToast({
title: "修改成功"
})
}else{
uni.showToast({
icon: "none",
position: "bottom",
title: msg
})
}
},
async changeChecked1(e) {
const { code, data, msg } = await this.$api.privacyConfig({
"userId": uni.getStorageSync("userInfo").id,
"msgShock": this.checked1?1:0 //01
});
if(code == 200){
uni.showToast({
title: "修改成功"
})
}else{
uni.showToast({
icon: "none",
position: "bottom",
title: msg
})
}
}
}
}
</script>

@ -4,15 +4,15 @@
<view class="bd">
<view class="item">
<image src="@/static/qingshaonian-lock.png"></image>
<input type="password" placeholder="输入密码" />
<input v-model="teenagePsw" type="password" placeholder="输入密码" />
</view>
<view class="item">
<image src="@/static/qingshaonian-lock.png"></image>
<input type="password" placeholder="输入密码" />
<input v-model="teenagePsw1" type="password" placeholder="确认密码" />
</view>
</view>
<view class="fd">
<view class="btn">确定开启</view>
<view class="btn" @click="openTeenageMode()">确定开启</view>
</view>
</view>
</template>
@ -21,11 +21,47 @@
export default {
data() {
return {
teenagePsw: "",
teenagePsw1: ""
}
},
methods: {
//
async openTeenageMode() {
if(!this.teenagePsw){
uni.showToast({
title: "密码不能为空!",
position: "bottom",
icon: "none",
})
return ;
}
if(this.teenagePsw != this.teenagePsw1){
uni.showToast({
title: "密码不一致!",
position: "bottom",
icon: "none",
})
return ;
}
const { code, data , msg } = await this.$api.openTeenageMode({teenagePsw: this.teenagePsw,userId: uni.getStorageSync("userInfo").id});
if(code == 200){
uni.showToast({
title: "提交成功",
})
setTimeout(()=>{
uni.navigateBack({
delta: 2
})
},2000)
}else{
uni.showToast({
title: mgs,
position: "bottom",
icon: "none",
})
}
},
}
}
</script>

@ -2,44 +2,151 @@
<view class="qingshaonian">
<view class="bd">
<image src="@/static/qingshaonian-san.png"></image>
<!-- <view class="title">青少年模式已开启</view> -->
<view class="title">青少年模式未开启</view>
<!-- <view class="desc">关闭后所有行为将不受限制</view> -->
<view class="desc">开启时以下行为会收到限制</view>
<view class="item">
<view class="title" v-if="userInfo.teenageMode == 1">青少年模式已开启</view>
<view class="title" v-else>青少年模式未开启</view>
<view class="desc" v-if="userInfo.teenageMode == 1">关闭后所有行为将不受限制</view>
<view class="desc" v-else>开启时以下行为会收到限制</view>
<view class="item" v-if="userInfo.teenageMode == 0">
<image src="@/static/qingshaonian-yuan.png"></image>无法进行充值
</view>
<view class="item">
<view class="item" v-if="userInfo.teenageMode == 0">
<image src="@/static/qingshaonian-yuan.png"></image>部分功能无法使用
</view>
</view>
<view class="fd">
<!-- <view class="btn">关闭</view> -->
<view class="btn">开启青少年模式</view>
</view>
<view class="btn" @click="openPage()" v-if="userInfo.teenageMode == 0">开启青少年模式</view>
<view class="btn" @click="isPopup = true" v-else>关闭</view>
</view>
<u-popup v-model="isPopup" mode="center" border-radius="20" :mask-close-able="false">
<view class="qingshaonians">
<view class="titles">输入密码<image @click="isPopup = false" src="@/static/cha.png"></image></view>
<view class="contents">
<view class="p">解除青少年模式密码</view>
<view class="box">
<u-icon name="lock-fill"></u-icon>
<input v-model="teenagePsw" type="password" placeholder="输入密码" />
</view>
</view>
<view class="fds">
<view class="btns" @click="toReg">确定关闭</view>
</view>
</view>
</u-popup>
</view>
</template>
<script>
export default {
data() {
return {
return {
isPopup: false,
userInfo: {},
teenagePsw: ""
}
},
onShow() {
this.userInfo = uni.getStorageSync("userInfo")
},
methods: {
methods: {
async toReg() {
if(!this.teenagePsw){
uni.showToast({
title: "密码不能为空!",
position: "bottom",
icon: "none",
})
return ;
}
this.isPopup = false
const { code, data , msg } = await this.$api.closeTeenageMode({teenagePsw: this.teenagePsw,userId: uni.getStorageSync("userInfo").id});
if(code == 200){
uni.showToast({
title: "提交成功",
})
setTimeout(()=>{
uni.navigateBack({
delta: 1
})
},2000)
}else{
uni.showToast({
title: mgs,
position: "bottom",
icon: "none",
})
}
},
openPage() {
uni.navigateTo({
url: "/pages/users/qingshaonian/detail"
})
},
}
}
</script>
<style scoped lang="scss">
page{
background-color: #fff;
}
.qingshaonian{
.qingshaonian{
background-color: #fff;
min-height: 100vh;
padding: 0 25rpx;
overflow: hidden;
overflow: hidden;
.qingshaonians{
overflow: hidden;
width: 670rpx;
height: 520rpx;
background: #FFFFFF;
box-sizing: border-box;
.titles{
text-align: center;
font-weight: 500;
font-size: 36rpx;
color: #222222;
padding: 40rpx 0;
border-bottom: 1px solid #EAEAEA;
image{
width: 45rpx;
height: 45rpx;
float: right;
margin-right: 20rpx;
}
}
.contents{
padding: 30rpx;
.p{
font-weight: 500;
font-size: 30rpx;
color: #222222;
}
.box{
font-weight: 500;
display: flex;
padding: 30rpx 0;
align-items: center;
border-bottom: 1px solid #EAEAEA;
margin-top: 20rpx;
input{
flex: 1;
margin-left: 30rpx;
font-size: 30rpx;
color: #222222;
}
}
}
.btns{
width: 400rpx;
line-height: 80rpx;
background: linear-gradient(0deg, #000000, #3D3B38);
box-shadow: 0px 4rpx 18rpx 0px rgba(42,41,39,0.34);
border-radius: 80rpx;
text-align: center;
font-weight: 500;
font-size: 26rpx;
color: #FFFFFF;
margin: 0 auto;
margin-top: 50rpx;
}
}
.fd{
width: 100%;
position: fixed;

@ -76,7 +76,14 @@
},
//
async toCreate() {
const that = this;
const that = this;
if(this.userInfo.teenageMode == 1){
uni.showModal({
title: "温馨提示",
content: "已开启青少年模式,该功能已关闭"
})
return ;
}
if(!this.payType){
uni.showToast({
icon: "none",
@ -142,7 +149,7 @@
async getList() {
const { code, data } = await this.$api.mealsetList({page: 1,limit: 9999});
if(code == 200){
this.list = data;
this.list = data.list;
}
},
//

@ -1,31 +1,31 @@
<template>
<view class="site">
<view class="site-hd">
<view class="item">
<view class="item" @click="openPage('/pages/users/yinsi/index')">
<view class="a">隐私设置</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/users/notice/index')">
<view class="a">新消息通知</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/users/qingshaonian/index')">
<view class="a">青少年模式</view>
<view class="b">未开启
<view class="b">{{userInfo.teenageMode == 0?'未开启':'已开启'}}
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/login/password')">
<view class="a">修改密码</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/users/dashan/index')">
<view class="a">搭讪语设置</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
@ -33,7 +33,7 @@
</view>
</view>
<view class="site-hd">
<view class="item">
<view class="item" @click="openPage('/pages/xiaoxi/heimingdan')">
<view class="a">黑名单</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
@ -41,25 +41,25 @@
</view>
</view>
<view class="site-hd">
<view class="item">
<view class="item" @click="openPage('/pages/users/about/index?type=CONFIG_ABOUT_AS')">
<view class="a">关于我们</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/users/about/index?type=CONFIG_PRIVACY_POLICY')">
<view class="a">隐私协议</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/users/about/index?type=CONFIG_USER_AGREEMENT')">
<view class="a">用户协议</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/users/zhuxiao/index')">
<view class="a">注销账号</view>
<view class="b">
<image src="@/static/icon-arrow.png"></image>
@ -67,23 +67,9 @@
</view>
</view>
<view class="site-fd">
<view class="btn" @click="openPage(1)">退出登录</view>
<view class="btn" @click="toLoginOut()">退出登录</view>
</view>
<u-popup v-model="isPopup" mode="center" border-radius="20" :mask-close-able="false">
<view class="qingshaonian">
<view class="title">输入密码<image src="@/static/cha.png"></image></view>
<view class="content">
<view class="p">解除青少年模式密码</view>
<view class="box">
<u-icon name="lock-fill"></u-icon>
<input type="password" placeholder="输入密码" />
</view>
</view>
<view class="fd">
<view class="btn">确定关闭</view>
</view>
</view>
</u-popup>
</view>
</template>
@ -91,25 +77,54 @@
export default {
data() {
return {
isPopup: false
isPopup: false,
userInfo: {},
};
},
onShow() {
this.getUserInfo();
},
methods: {
openPage(index) {
if(index == 1){
uni.showModal({
title: "温馨提示",
content: "是否确认推出登录?",
success(res){
if(res.confirm){
uni.navigateBack({
delta: 1
})
}
methods: {
//
async getUserInfo() {
const { code, data , msg } = await this.$api.findUserInfo({userId: uni.getStorageSync("userInfo").id});
if(code == 200){
this.userInfo = data;
uni.setStorageSync("userInfo",data);
}else{
uni.showToast({
title: mgs,
position: "bottom",
icon: "none",
})
}
},
openPage(url){
uni.navigateTo({
url
})
},
toLoginOut() {
const that = this;
uni.showModal({
title: "温馨提示",
content: "是否确认退出登录?",
confirmColor: "#000",
success(res){
if(res.confirm){
uni.clearStorageSync();
uni.showToast({
title: "退出成功"
})
setTimeout(()=>{
uni.reLaunch({
url: "/pages/login/index"
})
},2000)
}
})
}
}
}
})
},
}
}
</script>
@ -119,61 +134,7 @@
padding: 0 25rpx;
overflow: hidden;
padding-bottom: 110rpx;
.qingshaonian{
overflow: hidden;
width: 670rpx;
height: 520rpx;
background: #FFFFFF;
box-sizing: border-box;
.title{
text-align: center;
font-weight: 500;
font-size: 36rpx;
color: #222222;
padding: 40rpx 0;
border-bottom: 1px solid #EAEAEA;
image{
width: 45rpx;
height: 45rpx;
float: right;
margin-right: 20rpx;
}
}
.content{
padding: 30rpx;
.p{
font-weight: 500;
font-size: 30rpx;
color: #222222;
}
.box{
font-weight: 500;
display: flex;
padding: 30rpx 0;
align-items: center;
border-bottom: 1px solid #EAEAEA;
margin-top: 20rpx;
input{
margin-left: 30rpx;
font-size: 30rpx;
color: #222222;
}
}
}
.btn{
width: 400rpx;
line-height: 80rpx;
background: linear-gradient(0deg, #000000, #3D3B38);
box-shadow: 0px 4rpx 18rpx 0px rgba(42,41,39,0.34);
border-radius: 80rpx;
text-align: center;
font-weight: 500;
font-size: 26rpx;
color: #FFFFFF;
margin: 0 auto;
margin-top: 50rpx;
}
}
&-hd{
width: 100%;
background: #FFFFFF;

@ -1,23 +1,26 @@
<template>
<view class="dashan">
<view class="hd">
<view class="a"><text>10</text></view>
<view class="a"><text>{{list.length}}</text></view>
<view class="a">我的团队人数</view>
</view>
<view class="list">
<view class="item" v-for="i in 5" :key="i">
<view class="item" v-for="(a,i) in list" :key="i">
<view class="pic">
<!-- 只有会员才可以看到 -->
<image src="@/static/avatar.png"></image>
<image :src="a.faceImage?a.faceImage:a.img"></image>
</view>
<view class="content">
<view class="info">
<view class="name">李同学</view>
<view class="desc">ID1568935688</view>
<view class="name">{{a.nickname}}</view>
<view class="desc">ID{{a.id}}</view>
</view>
<view class="btns">2023-09-23</view>
<view class="btns">{{a.createTime}}</view>
</view>
</view>
</view>
<view class="empty" v-if="isShow">
<image src="@/static/empty.png"></image>
<view class="txt">暂无数据</view>
</view>
</view>
</template>
@ -25,11 +28,25 @@
<script>
export default {
data() {
return {
return {
isShow: false,
list: []
};
},
onLoad() {
this.getList();
},
methods: {
methods: {
//
async getList() {
const { code, data } = await this.$api.myTeam({
userId: uni.getStorageSync("userInfo").id
});
if(code == 200){
this.isShow = (data.length >0?false:true);
this.list = data;
}
},
openSheet() {
uni.showActionSheet({
itemList: ["删除会话"],
@ -43,12 +60,24 @@
</script>
<style scoped lang="scss">
page{
.dashan{
min-height: 100vh;
background-color: #fff;
}
.dashan{
padding: 0 25rpx;
overflow: hidden;
overflow: hidden;
.empty{
padding: 150rpx 0;
text-align: center;
font-weight: 500;
font-size: 28rpx;
color: #222222;
image{
display: block;
width: 460rpx;
height: 400rpx;
margin: 0 auto;
}
}
.hd{
width: 702rpx;
height: 190rpx;

@ -1,5 +1,5 @@
<template>
<view>
<view class="content" v-html="content">
</view>
</template>
@ -8,12 +8,29 @@
export default {
data() {
return {
content: ""
};
},
onLoad() {
this.content=uni.getStorageSync("pcontent").content.replace(/style=""/g, '')
.replace(/<img " src=/g, '<img src=')
.replace(/<img src=/g, '<img style="width: 100%; height:100%; display:block" src=');
uni.setNavigationBarTitle({
title: uni.getStorageSync("pcontent").title
})
},
destroyed() {
uni.removeStorageSync("pcontent")
}
}
</script>
<style lang="scss">
<style scoped lang="scss">
.content{
padding: 25rpx;
overflow: hidden;
font-size: 28rpx;
color: #333;
}
</style>

@ -3,7 +3,7 @@
<view class="content">
<view class="item">
<view class="a">隐藏我的城市</view>
<u-switch active-color="#000000" v-model="checked"></u-switch>
<u-switch active-color="#000000" v-model="checked" @change="changeChecked"></u-switch>
</view>
</view>
</view>
@ -13,8 +13,46 @@
export default {
data() {
return {
checked: true
checked: false
};
},
onLoad() {
this.getUserInfo();
},
methods: {
//
async getUserInfo() {
const { code, data , msg } = await this.$api.findUserInfo({userId: uni.getStorageSync("userInfo").id});
if(code == 200){
this.city_hide = (data.cityHide == 0?true:false)
uni.setStorageSync("userInfo",data);
}else{
uni.showToast({
title: mgs,
position: "bottom",
icon: "none",
})
}
},
async changeChecked(e) {
this.checked = e;
console.log(e)
const { code, data, msg } = await this.$api.privacyConfig({
"userId": uni.getStorageSync("userInfo").id,
"cityHide": this.checked?1:0 //01
});
if(code == 200){
uni.showToast({
title: "修改成功"
})
}else{
uni.showToast({
icon: "none",
position: "bottom",
title: msg
})
}
}
}
}
</script>

@ -1,19 +1,17 @@
<template>
<view class="zhuxiao">
<view class="title">注销后你账号将</view>
<view class="content">
<text>
1账号相关信息将被移除你的好友无法再与你取得联系(包括好友关注粉丝等);\n2账户剩余金币积分魅力值财富值VIP等收益相关数据在注销成功后将清空如产生利益损失由账号注销发起者承担;\n3绑定手机好或第三方账号将会解绑解绑后可再次注册账号;\n4你的实名信息会解绑解绑后可以再次绑定其他账号;\n5账号将会被系统收回并对平台其他用户开放申请;\n提示:一旦注销将无法撤销账号将自动清除15天后方可从新注册请慎重!!!
</text>
<view class="content" v-html="content">
</view>
<view class="fd">
<view class="xieyi" @click="toToggle()">
<image v-if="isCheck" src="@/static/icon-select.png"></image>
<image v-if="isCheck ==false" src="@/static/icon-select.png"></image>
<image v-else src="@/static/icon-select-on.png"></image>我已认真阅读且同意注销账号需要注意的内容
</view>
<view class="btns">
<view class="cancle">取消</view>
<view class="sure">确定</view>
<view class="cancle" @click="toCancle">取消</view>
<view class="sure" @click="toClick">确定</view>
</view>
</view>
@ -24,19 +22,78 @@
export default {
data() {
return {
isCheck: false
isCheck: false,
content: ""
};
},
onLoad() {
this.getInfo()
},
methods: {
toToggle() {
this.isCheck = !this.isCheck
},
toClick() {
const that = this;
if(this.isCheck == false){
uni.showToast({
icon: "none",
position: "bottom",
title: "请选择注销内容协议"
})
return ;
}
uni.showModal({
title: "温馨提示",
content: "是否要注销当前账号?",
async success( res) {
const { code, data, msg } = await this.$api.cancelAccount({userId: uni.getStorageSync("userInfo").id});
if(code == 200){
uni.showToast({
title: "注销成功",
})
uni.clearStorageSync();
setTimeout(()=>{
uni.reLaunch({
url: "/pages/login/index"
})
},2000)
}else{
uni.showToast({
icon: "none",
position: "bottom",
title: msg
})
}
}
})
},
toCancle() {
uni.navigateBack({
delta: 1
})
},
async getInfo() {
const { code,data } = await this.$api.getConfigData({dictType: 'CONFIG_CANCEL_ACCOUNT'});
if(code == 200){
this.content = data.content.replace(/style=""/g, '')
.replace(/<img " src=/g, '<img src=')
.replace(/<img src=/g, '<img style="width: 100%; height:100%; display:block" src=');
}
},
}
}
</script>
<style scoped lang="scss">
page{
.zhuxiao{
min-height: 100vh;
background-color: #fff;
}
.zhuxiao{
padding: 30rpx;
overflow: hidden;
padding: 30rpx 30rpx 400rpx;
overflow: hidden;
box-sizing: border-box;
.title{
font-weight: 500;
font-size: 36rpx;

@ -9,6 +9,10 @@
<view class="name">李同学<text>晚上9:50</text></view>
<view class="desc">[搭讪]你好在吗</view>
</view>
</view>
<view class="empty" v-if="isShow">
<image src="@/static/empty.png"></image>
<view class="txt">暂无数据</view>
</view>
</view>
</view>

@ -1,5 +1,5 @@
<template>
<view>
<view class="content" v-html="content">
</view>
</template>
@ -8,12 +8,29 @@
export default {
data() {
return {
content: ""
};
},
onLoad() {
this.content=uni.getStorageSync("pcontent").noticeContent.replace(/style=""/g, '')
.replace(/<img " src=/g, '<img src=')
.replace(/<img src=/g, '<img style="width: 100%; height:100%; display:block" src=');
uni.setNavigationBarTitle({
title: uni.getStorageSync("pcontent").noticeTitle
})
},
destroyed() {
uni.removeStorageSync("pcontent")
}
}
</script>
<style lang="scss">
<style scoped lang="scss">
.content{
padding: 25rpx;
overflow: hidden;
font-size: 28rpx;
color: #333;
}
</style>

@ -14,6 +14,10 @@
</view>
<view class="btn" @click.stop="toDash(a.userid)">搭讪</view>
</view>
</view>
<view class="empty" v-if="isShow">
<image src="@/static/empty.png"></image>
<view class="txt">暂无数据</view>
</view>
</view>
<unverified :isPopup="isPopup" />

@ -10,7 +10,7 @@
<view class="name">{{a.nickname}}</view>
<view class="desc">{{a.declaration}}</view>
</view>
<view class="btn">已关注</view>
<view class="btn" @click.stop="toYichu(a.userid)">移除</view>
</view>
</view>
<view class="empty" v-if="isShow">
@ -48,6 +48,21 @@
this.list = data;
this.isShow = data.length == 0?true:false
}
},
async toYichu(sellerId) {
const { code, data } = await this.$api.addOrRemoveBlacklist({
userId: uni.getStorageSync("userInfo").id,
sellerId,
type: 2
})
if(code == 200){
uni.showToast({
title: "移除成功"
})
setTimeout(()=>{
this.getList();
},2000)
}
},
toUser(id) {
if(uni.getStorageSync("userInfo").realnameFlag == 0){

@ -22,32 +22,36 @@
</view>
</view>
<view class="xiaoxi-list">
<view class="item" v-if="current == 0">
<view class="item" v-if="current == 0" @click="openPage('/pages/xiaoxi/dashan')">
<view class="pic"><image src="@/static/dashan.png"></image></view>
<view class="info">
<view class="name">搭讪消息<text>晚上9:50</text></view>
<view class="desc">上学和工作哪个更快来呢上学的...</view>
</view>
</view>
<view class="item" v-if="current == 0">
<view class="item" v-if="current == 0" @click="openPage('/pages/xiaoxi/xitong')">
<view class="pic"><image src="@/static/xitong.png"></image></view>
<view class="info">
<view class="name">系统消息<text>晚上9:50</text></view>
<view class="desc">明天再见喽</view>
</view>
</view>
<view class="item">
<view class="item" @click="openPage('/pages/xiaoxi/fangke')">
<view class="pic"><image src="@/static/kan.png"></image></view>
<view class="info">
<view class="name">谁看过我<text>晚上9:50</text></view>
<view class="desc">对你感兴趣的人一直默默关注你</view>
</view>
</view>
<view class="item">
<view class="pic"><image src="@/static/nan.png"></image><view class="num">30</view></view>
<view class="item" v-for="(a,i) in frindList" :key="i">
<view class="pic"><image :src="a.faceImage"></image><view class="num" v-if="a.noReadCount">{{a.noReadCount}}</view></view>
<view class="info">
<view class="name">李同学<text>晚上9:50</text></view>
<view class="desc">在么</view>
<view class="name">{{a.nickname}}<text>{{a.createTime}}</text></view>
<view class="desc" v-if="a.type==3">{{a.message}}</view>
<view class="desc" v-if="a.type==1">你有一条新的语音</view>
<view class="desc" v-if="a.type==2">你有一条新的视频</view>
<view class="desc" v-if="a.type==4">你有一张新的图片</view>
<view class="desc" v-if="a.type==5">你有一个新的礼物</view>
</view>
</view>
</view>
@ -61,13 +65,27 @@
tabIndex: 0,
current: 0,
list:[{'name': '消息'},{'name': '好友'}],
activeStyle:{'fontSize': '35rpx'}
activeStyle:{'fontSize': '35rpx'},
frindList: [],
}
},
onLoad() {
onShow() {
this.getList();
},
methods: {
methods: {
async getList() {
const { code, data } = await this.$api.findFrindList({
userId: uni.getStorageSync("userInfo").id
})
if(code == 200){
this.frindList = data
}
},
openPage(url) {
uni.navigateTo({
url
})
},
clearInfo() {
uni.showModal({
title: "提示",

@ -1,12 +1,16 @@
<template>
<view class="xitong">
<view class="item" v-for="i in 5" :key="i" @click="openPage(1)">
<view class="date">2023-01-02</view>
<view class="item" v-for="(a,i) in list" :key="i" @click="toPage(a)">
<view class="date">{{a.createTime}}</view>
<view class="content">
<view class="title">系统消息系统消息系统消息</view>
<view class="desc">系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息系统消息</view>
<image mode="widthFix" v-if="i == 5" src="@/static/pic.jpg"></image>
<view class="title">{{a.noticeTitle}}</view>
<view class="desc">{{a.noticeContent}}</view>
<!-- <image mode="widthFix" v-if="i == 5" src="@/static/pic.jpg"></image> -->
</view>
</view>
<view class="empty" v-if="total == 0">
<image src="@/static/empty.png"></image>
<view class="txt">暂无数据</view>
</view>
</view>
</template>
@ -15,16 +19,58 @@
export default {
data() {
return {
list: [],
total: 1,
page: 1
};
},
onLoad() {
this.getList();
},
onReachBottom() {
const that = this;
uni.showLoading({
title: "加载中"
})
if(that.list.length <= that.total){
that.page ++;
setTimeout(function() {
that.getList(1);
}, 1000);
}
},
methods: {
toPage(a) {
uni.setStorageSync("pcontent",a);
uni.navigateTo({
url: "/pages/xiaoxi/detail"
})
},
//
arrayUnique (arr, name) {
var hash = {};
return arr.reduce(function (item, next) {
hash[next[name]]
? ""
: (hash[next[name]] = true && item.push(next));
return item;
}, []);
},
async getList(type) {
const {code,data} = await this.$api.systemNoticeList({
userId: uni.getStorageSync("userInfo").id,
limit: 20,
page: this.page
})
if(type == 1){
uni.hideLoading()
}
if(code == 200){
this.isShow = data.total == 0?true:false;
this.list = this.arrayUnique([...this.list,...data.list],"id");
}
}
},
methods: {
openPage(id){
uni.navigateTo({
url: "/pages/xiaoxi/detail?id="+id
})
}
}
}
</script>

Loading…
Cancel
Save