Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -70,6 +70,7 @@ export const user = {
|
|||||||
//checkType 1、登录认证 2、居民认证 3、党员认证
|
//checkType 1、登录认证 2、居民认证 3、党员认证
|
||||||
//判断是否需要校验认证信息
|
//判断是否需要校验认证信息
|
||||||
let {user: userInfo, token} = rootState
|
let {user: userInfo, token} = rootState
|
||||||
|
console.log();
|
||||||
if (!checkType) {
|
if (!checkType) {
|
||||||
//如果需要校验认证信息,必定要先验证是否登录
|
//如果需要校验认证信息,必定要先验证是否登录
|
||||||
uni.navigateTo({url: modulePath});
|
uni.navigateTo({url: modulePath});
|
||||||
@@ -94,6 +95,19 @@ export const user = {
|
|||||||
return uni.showToast({title: "您还不是党员,暂时无法使用该功能", icon: "none"});
|
return uni.showToast({title: "您还不是党员,暂时无法使用该功能", icon: "none"});
|
||||||
}
|
}
|
||||||
uni.navigateTo({url: modulePath});
|
uni.navigateTo({url: modulePath});
|
||||||
|
} else if (checkType == 4) {
|
||||||
|
if (!token) {
|
||||||
|
return dispatch('autoLogin').then(() => dispatch('authCheck', { checkType, modulePath }));
|
||||||
|
}
|
||||||
|
if (!userInfo.areaId) {
|
||||||
|
this.$dialog.confirm({
|
||||||
|
content: '您只有完成信息认证后,才可进行相关操作。',
|
||||||
|
confirmText: '去认证'
|
||||||
|
}).then(() => {
|
||||||
|
uni.switchTab({ url: '/pages/AppMine/userInfo' })
|
||||||
|
}).catch(() => {
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -53,6 +53,8 @@
|
|||||||
export default {
|
export default {
|
||||||
name: 'Add',
|
name: 'Add',
|
||||||
appName: '发新贴',
|
appName: '发新贴',
|
||||||
|
navigationBarBackgroundColor: '#ffffff',
|
||||||
|
navigationBarTextStyle: 'black',
|
||||||
|
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -96,6 +96,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
onReady () {
|
||||||
|
},
|
||||||
|
|
||||||
onLoad () {
|
onLoad () {
|
||||||
this.getTopicList()
|
this.getTopicList()
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
<template>
|
div<template>
|
||||||
<div class="Detail" v-if="pageShow">
|
<div class="Detail" v-if="pageShow">
|
||||||
<div class="top">
|
<div class="top">
|
||||||
<div class="item-top">
|
<div class="item-top">
|
||||||
@@ -41,7 +41,7 @@
|
|||||||
<p>{{ item.content }}</p>
|
<p>{{ item.content }}</p>
|
||||||
<div class="bottom">
|
<div class="bottom">
|
||||||
<span>{{ item.createTime }}</span>
|
<span>{{ item.createTime }}</span>
|
||||||
<div hover-class="text-hover" @click="commentId = item.id, replyName = item.createUserName, focus = true">回复</div>
|
<div hover-class="text-hover" @click="replay(item)">回复</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="replay-list" v-if="item.replyList.length">
|
<div class="replay-list" v-if="item.replyList.length">
|
||||||
<div class="replay-item" v-for="replay in item.replyList" :key="replay.id">
|
<div class="replay-item" v-for="replay in item.replyList" :key="replay.id">
|
||||||
@@ -64,9 +64,9 @@
|
|||||||
<AiEmpty v-if="!list.length"></AiEmpty>
|
<AiEmpty v-if="!list.length"></AiEmpty>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="footer">
|
<div class="footer" @click="showComment">
|
||||||
<input :placeholder="commentId ? '回复' + replyName : '请输入评论内容'" :focus="focus" v-model="content">
|
<span>请输入评论内容</span>
|
||||||
<div hover-class="hover-class" @click="send">发送</div>
|
<!-- <div hover-class="hover-class">发送</div> -->
|
||||||
</div>
|
</div>
|
||||||
<u-popup v-model="isShow" mode="bottom" hidden height="350rpx" border-radius="30">
|
<u-popup v-model="isShow" mode="bottom" hidden height="350rpx" border-radius="30">
|
||||||
<div class="popup">
|
<div class="popup">
|
||||||
@@ -90,7 +90,20 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</u-popup>
|
</u-popup>
|
||||||
<AiLogin ref="login"/>
|
<u-popup v-model="isShowComment" mode="bottom" hidden height="400rpx" border-radius="30" @close="focus = false">
|
||||||
|
<div class="popup">
|
||||||
|
<div class="popup-title">
|
||||||
|
<h2>评论</h2>
|
||||||
|
<image @click="isShowComment = false, focus = false" src="https://cdn.cunwuyun.cn/wxmp/fengdu/ic-guanbi.png" />
|
||||||
|
</div>
|
||||||
|
<div class="form">
|
||||||
|
<textarea :maxlength="100" :cursor-spacing="10" :placeholder="commentId ? '回复' + replyName : '请输入评论内容'" :focus="focus" v-model="content"></textarea>
|
||||||
|
<div>
|
||||||
|
<div class="send-btn" hover-class="hover-class" @click="send">发送</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</u-popup>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -99,6 +112,8 @@
|
|||||||
export default {
|
export default {
|
||||||
name: 'Detail',
|
name: 'Detail',
|
||||||
appName: '详情',
|
appName: '详情',
|
||||||
|
navigationBarBackgroundColor: '#ffffff',
|
||||||
|
navigationBarTextStyle: 'black',
|
||||||
|
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@@ -110,6 +125,7 @@
|
|||||||
isFrom: '',
|
isFrom: '',
|
||||||
list: [],
|
list: [],
|
||||||
isMore: false,
|
isMore: false,
|
||||||
|
isShowComment: false,
|
||||||
current: 1,
|
current: 1,
|
||||||
content: '',
|
content: '',
|
||||||
focus: false,
|
focus: false,
|
||||||
@@ -151,6 +167,31 @@
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
showComment () {
|
||||||
|
this.commentId = ''
|
||||||
|
this.replyName = ''
|
||||||
|
this.isShowComment = true
|
||||||
|
|
||||||
|
this.$nextTick(() => {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.focus = true
|
||||||
|
}, 500)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
|
replay (item) {
|
||||||
|
this.commentId = item.id
|
||||||
|
this.replyName = item.createUserName
|
||||||
|
|
||||||
|
this.isShowComment = true
|
||||||
|
|
||||||
|
this.$nextTick(() => {
|
||||||
|
setTimeout(() => {
|
||||||
|
this.focus = true
|
||||||
|
}, 500)
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
getInfo (id) {
|
getInfo (id) {
|
||||||
this.$instance.post(`/app/appneighborhoodassistance/queryDetailById?id=${id}`, null, {
|
this.$instance.post(`/app/appneighborhoodassistance/queryDetailById?id=${id}`, null, {
|
||||||
withoutToken: this.token ? false : true,
|
withoutToken: this.token ? false : true,
|
||||||
@@ -191,6 +232,7 @@
|
|||||||
}).then(res => {
|
}).then(res => {
|
||||||
uni.hideLoading()
|
uni.hideLoading()
|
||||||
if (res.code === 0) {
|
if (res.code === 0) {
|
||||||
|
this.isShowComment = false
|
||||||
this.$toast('提交成功')
|
this.$toast('提交成功')
|
||||||
this.content = ''
|
this.content = ''
|
||||||
this.replyName = ''
|
this.replyName = ''
|
||||||
@@ -289,7 +331,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.popup {
|
.popup {
|
||||||
height: 700px;
|
height: 400px;
|
||||||
border-radius: 20px 20px 0 0;
|
border-radius: 20px 20px 0 0;
|
||||||
|
|
||||||
.popup-title {
|
.popup-title {
|
||||||
@@ -339,6 +381,41 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.form {
|
||||||
|
padding: 0 32px;
|
||||||
|
|
||||||
|
textarea {
|
||||||
|
width: 100%;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
height: 200px;
|
||||||
|
line-height: 1.3;
|
||||||
|
padding: 20px;
|
||||||
|
font-size: 28px;
|
||||||
|
color: #333;
|
||||||
|
box-sizing: border-box;
|
||||||
|
background: #eeeeee;
|
||||||
|
}
|
||||||
|
|
||||||
|
& > div {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: flex-end;
|
||||||
|
}
|
||||||
|
|
||||||
|
.send-btn {
|
||||||
|
display: inline-block;
|
||||||
|
width: 100px;
|
||||||
|
height: 60px;
|
||||||
|
line-height: 60px;
|
||||||
|
text-align: right;
|
||||||
|
text-align: center;
|
||||||
|
font-size: 26px;
|
||||||
|
color: #fff;
|
||||||
|
border-radius: 30px;
|
||||||
|
background: #2d7dffff;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
.footer {
|
.footer {
|
||||||
display: flex;
|
display: flex;
|
||||||
@@ -351,16 +428,17 @@
|
|||||||
padding: 14px 32px;
|
padding: 14px 32px;
|
||||||
background: #fff;
|
background: #fff;
|
||||||
|
|
||||||
input {
|
span {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
height: 60px;
|
height: 60px;
|
||||||
margin-right: 16px;
|
line-height: 60px;
|
||||||
|
// margin-right: 16px;
|
||||||
padding: 0 24px;
|
padding: 0 24px;
|
||||||
border-radius: 30px;
|
border-radius: 30px;
|
||||||
font-size: 26px;
|
font-size: 26px;
|
||||||
color: #333;
|
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
background: #eeeeeeff;
|
background: #eeeeee;
|
||||||
|
color: #999;
|
||||||
}
|
}
|
||||||
|
|
||||||
div {
|
div {
|
||||||
|
|||||||
@@ -127,6 +127,8 @@
|
|||||||
export default {
|
export default {
|
||||||
name: 'MyPostList',
|
name: 'MyPostList',
|
||||||
appName: '我的帖子',
|
appName: '我的帖子',
|
||||||
|
navigationBarBackgroundColor: '#ffffff',
|
||||||
|
navigationBarTextStyle: 'black',
|
||||||
|
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -17,6 +17,8 @@
|
|||||||
export default {
|
export default {
|
||||||
name: 'Topic',
|
name: 'Topic',
|
||||||
appName: '更多话题',
|
appName: '更多话题',
|
||||||
|
navigationBarBackgroundColor: '#ffffff',
|
||||||
|
navigationBarTextStyle: 'black',
|
||||||
|
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -60,6 +60,8 @@
|
|||||||
export default {
|
export default {
|
||||||
name: 'TopicDetail',
|
name: 'TopicDetail',
|
||||||
appName: '话题详情',
|
appName: '话题详情',
|
||||||
|
navigationBarBackgroundColor: '#ffffff',
|
||||||
|
navigationBarTextStyle: 'black',
|
||||||
|
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
|
|||||||
@@ -118,38 +118,27 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
handleClick({type, appId, modulePath, url, checkType, corpId}) {
|
handleClick({type, appId, modulePath, url, checkType, corpId}) {
|
||||||
if(this.user.areaId) {
|
//先判读是不是系统应用
|
||||||
//先判读是不是系统应用
|
if (type != "0") {
|
||||||
if (type != "0") {
|
if (type == "1") {
|
||||||
if (type == "1") {
|
uni.navigateToMiniProgram({appId});
|
||||||
uni.navigateToMiniProgram({appId});
|
} else if (type == "2") {
|
||||||
} else if (type == "2") {
|
uni.navigateTo({url: "/subPages/h5/webview?link=" + url});
|
||||||
uni.navigateTo({url: "/subPages/h5/webview?link=" + url});
|
} else if (type == "3") {
|
||||||
} else if (type == "3") {
|
this.$linkTo(url);
|
||||||
this.$linkTo(url);
|
} else if (type == "4") {
|
||||||
} else if (type == "4") {
|
uni.openCustomerServiceChat({
|
||||||
uni.openCustomerServiceChat({
|
extInfo: {url: url},
|
||||||
extInfo: {url: url},
|
corpId: corpId,
|
||||||
corpId: corpId,
|
fail: () => {
|
||||||
fail: () => {
|
this.$u.toast('请使用普通微信打开小程序进行咨询');
|
||||||
this.$u.toast('请使用普通微信打开小程序进行咨询');
|
}
|
||||||
}
|
});
|
||||||
});
|
|
||||||
}
|
|
||||||
} else if (type && type == "0") {
|
|
||||||
uni.showLoading({title: '正在进入应用...'})
|
|
||||||
this.authCheck({checkType, modulePath}).finally(() => uni.hideLoading())
|
|
||||||
}
|
}
|
||||||
} else {
|
} else if (type && type == "0") {
|
||||||
this.$dialog.confirm({
|
uni.showLoading({title: '正在进入应用...'})
|
||||||
content: '您只有完成信息认证后,才可进行相关操作。',
|
this.authCheck({checkType, modulePath}).finally(() => uni.hideLoading())
|
||||||
confirmText: '去认证'
|
|
||||||
}).then(() => {
|
|
||||||
uni.switchTab({ url: '/pages/AppMine/userInfo' })
|
|
||||||
}).catch(() => {
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
handleBannerClick(index) {
|
handleBannerClick(index) {
|
||||||
if (!this.swiperList[index].linkUrl) return
|
if (!this.swiperList[index].linkUrl) return
|
||||||
|
|||||||
@@ -161,7 +161,7 @@ export default {
|
|||||||
},
|
},
|
||||||
getAuth() {
|
getAuth() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.token && this.getUserInfo()
|
this.token && this.getUserInfo('qujing')
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
onLogout() {
|
onLogout() {
|
||||||
|
|||||||
Reference in New Issue
Block a user