Compare commits
No commits in common. "d5ab2ca459bc688a70ec4fcecd78a1b91bcbb8ae" and "15b7c46e3567b53cf0de67779b280fe62e97e1e9" have entirely different histories.
d5ab2ca459
...
15b7c46e35
Before Width: | Height: | Size: 4.6 KiB |
Before Width: | Height: | Size: 1.3 KiB |
Before Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 2.1 KiB |
Before Width: | Height: | Size: 2.0 KiB |
Before Width: | Height: | Size: 1011 B |
Before Width: | Height: | Size: 1.4 KiB |
Before Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 1.6 KiB |
Before Width: | Height: | Size: 968 B |
Before Width: | Height: | Size: 1.7 KiB |
Before Width: | Height: | Size: 287 B |
Before Width: | Height: | Size: 298 B |
Before Width: | Height: | Size: 434 B |
Before Width: | Height: | Size: 437 B |
0
public/img/user/bindingthird-party.png → src/assets/img/user/bindingthird-party .png
Normal file → Executable file
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
Before Width: | Height: | Size: 1.2 KiB |
@ -13,7 +13,7 @@
|
|||||||
<div class="discussion-single-content flexacenter flex1">
|
<div class="discussion-single-content flexacenter flex1">
|
||||||
<input class="discussion-single-input flex1" cursor-spacing="5" type="text"
|
<input class="discussion-single-input flex1" cursor-spacing="5" type="text"
|
||||||
:placeholder="twoCommentData ? '写回复…' : '想问啥,大胆问…'" :value="commentContent"
|
:placeholder="twoCommentData ? '写回复…' : '想问啥,大胆问…'" :value="commentContent"
|
||||||
@input="inputCommentContent($event)" v-focus />
|
@input="inputCommentContent($event)" />
|
||||||
<img class="discussion-single-input-icom" @click.stop="setValue()"
|
<img class="discussion-single-input-icom" @click.stop="setValue()"
|
||||||
src="@/assets/img/detail/unfold.png" />
|
src="@/assets/img/detail/unfold.png" />
|
||||||
</div>
|
</div>
|
||||||
@ -33,15 +33,16 @@
|
|||||||
<div class="discussion-text one-line">{{ twoCommentData.content }}</div>
|
<div class="discussion-text one-line">{{ twoCommentData.content }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="discussion-multi-content flexflex flex1">
|
<div class="discussion-multi-content flexflex flex1">
|
||||||
<textarea class="discussion-multi-textarea flex1" v-focus type="text" maxlength="500"
|
<textarea class="discussion-multi-textarea flex1" type="text" maxlength="500" :value="commentContent"
|
||||||
:value="commentContent" :placeholder="twoCommentData ? '写回复…' : '想问啥,大胆问…'"
|
:placeholder="twoCommentData ? '写回复…' : '想问啥,大胆问…'" @input="inputCommentContent($event)"></textarea>
|
||||||
@input="inputCommentContent($event)"></textarea>
|
|
||||||
<img class="discussion-multi-icom" @click.stop="openDiscussionSingle()"
|
<img class="discussion-multi-icom" @click.stop="openDiscussionSingle()"
|
||||||
src="@/assets/img/detail/pack.png" />
|
src="@/assets/img/detail/pack.png" />
|
||||||
<div class="discussion-multi-sum">{{ 500 - commentContent.length }}</div>
|
<div class="discussion-multi-sum">{{ 500 - commentContent.length }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="discussion-multi-bottom flexflex flexacenter">
|
<div class="discussion-multi-bottom flexflex flexacenter">
|
||||||
<div class="discussion-multi-btn flexcenter" @click.stop="postComment()">发布</div>
|
<div class="discussion-multi-btn flexcenter" @click.stop="postComment()">
|
||||||
|
发布
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -63,6 +64,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
// 提交回复
|
// 提交回复
|
||||||
postComment() {
|
postComment() {
|
||||||
this.$parent.postComment()
|
this.$parent.postComment()
|
||||||
@ -72,9 +74,6 @@ export default {
|
|||||||
handlePopCancel() {
|
handlePopCancel() {
|
||||||
this.$parent.twoCommentData = null
|
this.$parent.twoCommentData = null
|
||||||
this.$parent.popState = ""
|
this.$parent.popState = ""
|
||||||
this.$parent.commentContent = ""
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
// 清空
|
// 清空
|
||||||
|
@ -13,7 +13,7 @@
|
|||||||
<search-box slot="search" :hot-searchkeywords="hotSearchkeywords" :issearch="issearch"></search-box>
|
<search-box slot="search" :hot-searchkeywords="hotSearchkeywords" :issearch="issearch"></search-box>
|
||||||
|
|
||||||
<div class="head-more flexcenter" @click="headMorePopState = !headMorePopState">
|
<div class="head-more flexcenter" @click="headMorePopState = !headMorePopState">
|
||||||
<div class="red-dot" v-if="userInfo && userInfo.messagenum"></div>
|
<div class="red-dot" v-if="false"></div>
|
||||||
<svg-icon icon-class="threeAcross" class-name="head-more-icon"></svg-icon>
|
<svg-icon icon-class="threeAcross" class-name="head-more-icon"></svg-icon>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -22,12 +22,9 @@
|
|||||||
<div class="head-more-pop" :class="{ animation: headMorePopState }">
|
<div class="head-more-pop" :class="{ animation: headMorePopState }">
|
||||||
<div class="head-more-userinfo flex1 flexacenter">
|
<div class="head-more-userinfo flex1 flexacenter">
|
||||||
<div class="head-more-left flexacenter">
|
<div class="head-more-left flexacenter">
|
||||||
<router-link to="/user">
|
<img class="head-more-userinfo-avatar" :src="userInfo.avatar" alt="" />
|
||||||
<img class="head-more-userinfo-avatar" :src="userInfo.avatar || './img/defaultAvatar.jpg'" />
|
|
||||||
</router-link>
|
|
||||||
|
|
||||||
<div class="head-more-userinfo-username">
|
<div class="head-more-userinfo-username">
|
||||||
{{ userInfo.nickname || '未登录' }}
|
{{ userInfo.nickname }}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="head-more-right">
|
<div class="head-more-right">
|
||||||
@ -44,7 +41,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="tab-list">
|
<div class="tab-list">
|
||||||
<a class="tab-item flexacenter" :href="item.url" target="_blank" :class="{ pitch: item.current == 1 }"
|
<a class="tab-item flexacenter" :href="item.url" target="_blank" :class="{ pitch: tab == item.name }"
|
||||||
v-for="(item, index) in menu" :key="index">{{ item.name }}</a>
|
v-for="(item, index) in menu" :key="index">{{ item.name }}</a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -76,6 +73,7 @@ export default {
|
|||||||
return {
|
return {
|
||||||
collapseShow: false, //显示折叠弹窗
|
collapseShow: false, //显示折叠弹窗
|
||||||
a: 0,
|
a: 0,
|
||||||
|
tab: "Offer榜",
|
||||||
headMorePopState: false, // 弹窗的状态
|
headMorePopState: false, // 弹窗的状态
|
||||||
islogin: false,
|
islogin: false,
|
||||||
userInfo: {}, // 注意 userInfo 写I 是否是大写 ,, 因为 user 已经改为全局,后面要删除传值的 user
|
userInfo: {}, // 注意 userInfo 写I 是否是大写 ,, 因为 user 已经改为全局,后面要删除传值的 user
|
||||||
@ -85,6 +83,18 @@ export default {
|
|||||||
},
|
},
|
||||||
props: ["issearch", "needgetuser", "userinfo"],
|
props: ["issearch", "needgetuser", "userinfo"],
|
||||||
watch: {
|
watch: {
|
||||||
|
// needgetuser: {
|
||||||
|
// handler(newValue, oldValue) {
|
||||||
|
// // if (newValue) this.getUserInfoData();
|
||||||
|
// },
|
||||||
|
// immediate: true,
|
||||||
|
// },
|
||||||
|
|
||||||
|
// userinfo(newValue, oldValue) {
|
||||||
|
// this.userInfo = newValue;
|
||||||
|
// this.islogin = newValue.uid > 0 ? true : false;
|
||||||
|
// },
|
||||||
|
|
||||||
headMorePopState(newValue, oldValue) {
|
headMorePopState(newValue, oldValue) {
|
||||||
if (newValue) this.$pageStop();
|
if (newValue) this.$pageStop();
|
||||||
else this.$pageMove();
|
else this.$pageMove();
|
||||||
@ -97,9 +107,10 @@ export default {
|
|||||||
this.userInfo = user
|
this.userInfo = user
|
||||||
this.islogin = user.uid > 0 ? true : false;
|
this.islogin = user.uid > 0 ? true : false;
|
||||||
this.hotSearchkeywords = this.$store.state.hotSearchkeywords
|
this.hotSearchkeywords = this.$store.state.hotSearchkeywords
|
||||||
this.menu = this.$store.state.menu
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// this.getMenu()
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -129,6 +140,16 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
getMenu() {
|
||||||
|
return
|
||||||
|
this.$http.get("/widget", {
|
||||||
|
type: "menu",
|
||||||
|
}).then((res) => {
|
||||||
|
if (res.code != 200) return;
|
||||||
|
this.menu = res.data.menu.data;
|
||||||
|
});
|
||||||
|
},
|
||||||
|
|
||||||
collapseClick() {
|
collapseClick() {
|
||||||
if (this.collapseShow == true) this.collapseShow = false;
|
if (this.collapseShow == true) this.collapseShow = false;
|
||||||
else this.collapseShow = true;
|
else this.collapseShow = true;
|
||||||
|
@ -53,6 +53,7 @@ export default {
|
|||||||
left: 0;
|
left: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
|
background: #7F7F7F;
|
||||||
}
|
}
|
||||||
|
|
||||||
.path-slash {
|
.path-slash {
|
||||||
@ -97,6 +98,4 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
</style>
|
</style>
|
@ -28,7 +28,7 @@
|
|||||||
投币解锁
|
投币解锁
|
||||||
</div>
|
</div>
|
||||||
<div class="unlockCoin-hint flexacenter" style="font-size: .36rem;">作者设置了阅读限制,解锁所有内容仅需 <div
|
<div class="unlockCoin-hint flexacenter" style="font-size: .36rem;">作者设置了阅读限制,解锁所有内容仅需 <div
|
||||||
class="unlockCoin-hint-sum">{{ info.price }}</div> 寄托币</div>
|
class="unlockCoin-hint-sum">{{ defaultcoinnum }}</div> 寄托币</div>
|
||||||
<div class="unlockCoin-btn flexcenter" @click="postCoin(defaultcoinnum)">立即解锁
|
<div class="unlockCoin-btn flexcenter" @click="postCoin(defaultcoinnum)">立即解锁
|
||||||
</div>
|
</div>
|
||||||
<div class="unlockCoin-hint flexcenter">你共有 {{ mybalance }} 个寄托币</div>
|
<div class="unlockCoin-hint flexcenter">你共有 {{ mybalance }} 个寄托币</div>
|
||||||
@ -41,7 +41,7 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: 'Coins',
|
name: 'Coins',
|
||||||
props: ["popState", "coinConfig", "info", "mybalance"],
|
props: ["popState", "coinConfig"],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
defaultcoinnum: 1
|
defaultcoinnum: 1
|
||||||
|
15
src/main.js
@ -4,7 +4,7 @@ import router from './router'
|
|||||||
import store from './store'
|
import store from './store'
|
||||||
import ElementUI, { Message, Pagination, loading } from 'element-ui';
|
import ElementUI, { Message, Pagination, loading } from 'element-ui';
|
||||||
import 'element-ui/lib/theme-chalk/index.css';
|
import 'element-ui/lib/theme-chalk/index.css';
|
||||||
import { skipUrl, pageStop, pageMove, goTologin, copy, startupUnderLoading, closeUnderLoading, formattedDate, updateURLSearchParams, clearCookies } from "@/utils/common.js"
|
import { skipUrl, pageStop, pageMove, goTologin, copy, startupUnderLoading, closeUnderLoading, formattedDate, updateURLSearchParams } from "@/utils/common.js"
|
||||||
import http from "@/utils/request"
|
import http from "@/utils/request"
|
||||||
import VueSanitize from 'vue-sanitize'
|
import VueSanitize from 'vue-sanitize'
|
||||||
|
|
||||||
@ -29,7 +29,6 @@ Vue.prototype.$startupUnderLoading = startupUnderLoading // 开启加载提示
|
|||||||
Vue.prototype.$closeUnderLoading = closeUnderLoading // 关闭加载提示 element的
|
Vue.prototype.$closeUnderLoading = closeUnderLoading // 关闭加载提示 element的
|
||||||
Vue.prototype.$formattedDate = formattedDate // 时间戳转格式
|
Vue.prototype.$formattedDate = formattedDate // 时间戳转格式
|
||||||
Vue.prototype.$updateURLSearchParams = updateURLSearchParams // 不刷新的情况下修改url
|
Vue.prototype.$updateURLSearchParams = updateURLSearchParams // 不刷新的情况下修改url
|
||||||
Vue.prototype.$clearCookies = clearCookies // 清空Cookies
|
|
||||||
|
|
||||||
//svg文件引入
|
//svg文件引入
|
||||||
import './icons'
|
import './icons'
|
||||||
@ -48,21 +47,11 @@ if (!Array.isArray) {
|
|||||||
Vue.use(ElementUI);
|
Vue.use(ElementUI);
|
||||||
Vue.use(Pagination);
|
Vue.use(Pagination);
|
||||||
|
|
||||||
// 不要的
|
|
||||||
Vue.use(VueSanitize);
|
Vue.use(VueSanitize);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// v-focus
|
|
||||||
Vue.directive('focus', {
|
|
||||||
inserted: function (el) {
|
|
||||||
el.focus()
|
|
||||||
}
|
|
||||||
})
|
|
||||||
|
|
||||||
new Vue({
|
new Vue({
|
||||||
router,
|
router,
|
||||||
store,
|
store,
|
||||||
render: h => h(App),
|
render: h => h(App)
|
||||||
|
|
||||||
}).$mount('#app')
|
}).$mount('#app')
|
||||||
|
@ -5,13 +5,12 @@ Vue.use(Vuex)
|
|||||||
|
|
||||||
export default new Vuex.Store({
|
export default new Vuex.Store({
|
||||||
state: {
|
state: {
|
||||||
historicalSearch: [], // 历史数据
|
historicalSearch: [],
|
||||||
allForumList: [], // 全部板块数据
|
allForumList: [], // 全部板块数据
|
||||||
homeRequestState: false, // 首页推荐和收藏接口的数据请求状态 这个是是否需要发送请求,因为用户点击收藏后需要重新获取
|
homeRequestState: false, // 首页推荐和收藏接口的数据请求状态 这个是是否需要发送请求,因为用户点击收藏后需要重新获取
|
||||||
getUserInfoState: false, // 这个是是否在请求状态
|
getUserInfoState: false, // 这个是是否在请求状态
|
||||||
favoriteList: [], // 收藏板块 数据
|
favoriteList: [],
|
||||||
recommendList: [], // 推荐板块数据
|
recommendList: [],
|
||||||
menu: [],
|
|
||||||
user: {}, // 用户信息
|
user: {}, // 用户信息
|
||||||
hotSearchkeywords: [], // 热门搜索
|
hotSearchkeywords: [], // 热门搜索
|
||||||
loading: null,
|
loading: null,
|
||||||
@ -57,10 +56,6 @@ export default new Vuex.Store({
|
|||||||
state.getUserInfoState = payload
|
state.getUserInfoState = payload
|
||||||
},
|
},
|
||||||
|
|
||||||
setMenu(state, payload) {
|
|
||||||
state.menu = payload
|
|
||||||
}
|
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
actions: {
|
actions: {
|
||||||
@ -95,20 +90,18 @@ export default new Vuex.Store({
|
|||||||
that.$http.post("/api/home").then(res => {
|
that.$http.post("/api/home").then(res => {
|
||||||
if (res.code != 200) return;
|
if (res.code != 200) return;
|
||||||
let data = res.data
|
let data = res.data
|
||||||
let { config, favorite, hotSearchkeywords, recommend, user, menu } = data
|
let { config, favorite, hotSearchkeywords, recommend, user } = data
|
||||||
|
|
||||||
commit('setHomeRequestState', true)
|
commit('setHomeRequestState', true)
|
||||||
commit('setUser', user)
|
commit('setUser', user)
|
||||||
commit('setFavoriteList', favorite)
|
commit('setFavoriteList', favorite)
|
||||||
commit('setRecommendList', recommend)
|
commit('setRecommendList', recommend)
|
||||||
commit('setHotSearchkeywords', hotSearchkeywords)
|
commit('setHotSearchkeywords', hotSearchkeywords)
|
||||||
commit('setMenu', menu)
|
|
||||||
|
|
||||||
if (that.userInfo) { // 这个是顶部用户数据的 这样不用监听是否请求成功
|
if (that.userInfo) { // 这个是顶部用户数据的 这样不用监听是否请求成功
|
||||||
that.userInfo = user
|
that.userInfo = user
|
||||||
that.islogin = user.uid > 0 ? true : false;
|
that.islogin = user.uid > 0 ? true : false;
|
||||||
that.hotSearchkeywords = hotSearchkeywords
|
that.hotSearchkeywords = hotSearchkeywords
|
||||||
that.menu = menu
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}).catch(err => {
|
}).catch(err => {
|
||||||
|
@ -85,14 +85,4 @@ function updateURLSearchParams(obj = {}) {
|
|||||||
window.history.pushState({}, '', newUrl);
|
window.history.pushState({}, '', newUrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
export { skipUrl, pageStop, pageMove, goTologin, copy, startupUnderLoading, closeUnderLoading, formattedDate, updateURLSearchParams }
|
||||||
// 清除所有cookies
|
|
||||||
function clearCookies() {
|
|
||||||
let cookies = document.cookie.split("; ");
|
|
||||||
for (let c of cookies) {
|
|
||||||
let [name, _] = c.split("=");
|
|
||||||
document.cookie = name + "=; expires=Thu, 01 Jan 1970 00:00:00 UTC; path=/;";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
export { skipUrl, pageStop, pageMove, goTologin, copy, startupUnderLoading, closeUnderLoading, formattedDate, updateURLSearchParams, clearCookies }
|
|
@ -11,12 +11,10 @@ axios.defaults.withCredentials = true
|
|||||||
axios.defaults.emulateJSON = true
|
axios.defaults.emulateJSON = true
|
||||||
|
|
||||||
baseURL = {
|
baseURL = {
|
||||||
// forum: "https://forum.gter.net",
|
forum: "https://forum.gter.net",
|
||||||
forum: "https://app.gter.net/forum",
|
|
||||||
offer: "https://offer.gter.net",
|
offer: "https://offer.gter.net",
|
||||||
tenement: "https://app.gter.net",
|
tenement: "https://app.gter.net",
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const service = axios.create({
|
const service = axios.create({
|
||||||
@ -28,6 +26,7 @@ const service = axios.create({
|
|||||||
service.interceptors.request.use(config => {
|
service.interceptors.request.use(config => {
|
||||||
//发请求前做的一些处理,数据转化,配置请求头,设置token,设置loading等,根据需求去添加
|
//发请求前做的一些处理,数据转化,配置请求头,设置token,设置loading等,根据需求去添加
|
||||||
//注意使用token的时候需要引入cookie方法或者用本地localStorage等方法,推荐js-cookie
|
//注意使用token的时候需要引入cookie方法或者用本地localStorage等方法,推荐js-cookie
|
||||||
|
// config['baseURL'] = "https://offer.gter.net"
|
||||||
config['headers']['authorization'] = "qj2q1qk1on0curclipghjtv5ja1g9eq2"
|
config['headers']['authorization'] = "qj2q1qk1on0curclipghjtv5ja1g9eq2"
|
||||||
return config
|
return config
|
||||||
}, error => {
|
}, error => {
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
{{ info.subject }}
|
{{ info.subject }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
<!-- -->
|
<!-- -->
|
||||||
<div class="card flexcenter">
|
<div class="card flexcenter">
|
||||||
<div class="card-item shadow" v-if="postList.page == 1">
|
<div class="card-item shadow" v-if="postList.page == 1">
|
||||||
@ -145,7 +146,7 @@
|
|||||||
index + 2}楼` }}</div>
|
index + 2}楼` }}</div>
|
||||||
<div class="card-head-fool" v-else>{{ `${(postList.page - 1) * postList.limit + index + 1}楼` }}
|
<div class="card-head-fool" v-else>{{ `${(postList.page - 1) * postList.limit + index + 1}楼` }}
|
||||||
</div>
|
</div>
|
||||||
<div class="edit-box flexcenter" v-if="item.ismyself == 1" @click.stop="openEditPop(item)">
|
<div class="edit-box flexcenter" v-if="item.ismyself == 1" @click.stop="handleIsmyself(item)">
|
||||||
<img class="edit-icom" src="@/assets/img/detail/edit.png" />
|
<img class="edit-icom" src="@/assets/img/detail/edit.png" />
|
||||||
</div>
|
</div>
|
||||||
<!-- <div class="card-head-fool">{{ index == 0 ? '楼主' : `${index}楼` }}</div> -->
|
<!-- <div class="card-head-fool">{{ index == 0 ? '楼主' : `${index}楼` }}</div> -->
|
||||||
@ -168,7 +169,8 @@
|
|||||||
<svg-icon icon-class="quotation-right" class-name="quotation-icon"></svg-icon>
|
<svg-icon icon-class="quotation-right" class-name="quotation-icon"></svg-icon>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div> 之前申请永久居民,参考了不少寄托的帖子和经验,现在回馈给大家,积攒RP。
|
</div>
|
||||||
|
之前申请永久居民,参考了不少寄托的帖子和经验,现在回馈给大家,积攒RP。
|
||||||
<!-- 未解锁区域 -->
|
<!-- 未解锁区域 -->
|
||||||
<div class="flexcenter content-unlock content-unlock-no" v-if="index == 3 || index == 4">
|
<div class="flexcenter content-unlock content-unlock-no" v-if="index == 3 || index == 4">
|
||||||
<img class="unlock-icom" src="@/assets/img/detail/unlock.png">
|
<img class="unlock-icom" src="@/assets/img/detail/unlock.png">
|
||||||
@ -310,6 +312,7 @@
|
|||||||
<div class="bottom-operation-item flex1 flexcolumn flexcenter" @click="transmit()">
|
<div class="bottom-operation-item flex1 flexcolumn flexcenter" @click="transmit()">
|
||||||
<img class="bottom-operation-icom bottom-transmit-icom" src="@/assets/img/detail/share.png" />
|
<img class="bottom-operation-icom bottom-transmit-icom" src="@/assets/img/detail/share.png" />
|
||||||
<div class="bottom-operation-text">转发</div>
|
<div class="bottom-operation-text">转发</div>
|
||||||
|
<button class="bottom-operation-button flexcolumn flexcenter" open-type="share"></button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -318,7 +321,7 @@
|
|||||||
<detail-reply :two-comment-data="twoCommentData" :comment-content="commentContent"
|
<detail-reply :two-comment-data="twoCommentData" :comment-content="commentContent"
|
||||||
:pop-state="popState"></detail-reply>
|
:pop-state="popState"></detail-reply>
|
||||||
|
|
||||||
<coins :coin-config="coinConfig" :mybalance="mybalance" :pop-state="popState" :info="info"></coins>
|
<coins :coin-config="coinConfig" :pop-state="popState"></coins>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -334,7 +337,6 @@ export default {
|
|||||||
// avatar: "https://oss.gter.net/avatar/97KwEWANd_4DHWiY6VbnSUFSCKroYWFjYQ~~/middle",
|
// avatar: "https://oss.gter.net/avatar/97KwEWANd_4DHWiY6VbnSUFSCKroYWFjYQ~~/middle",
|
||||||
// content: "评论回复",
|
// content: "评论回复",
|
||||||
// },
|
// },
|
||||||
editCommentPid: null,
|
|
||||||
popState: "", // discussionSingle discussionMulti
|
popState: "", // discussionSingle discussionMulti
|
||||||
coinConfig: {
|
coinConfig: {
|
||||||
strategy: {
|
strategy: {
|
||||||
@ -462,8 +464,6 @@ export default {
|
|||||||
commentContent: "", // 评论的文本
|
commentContent: "", // 评论的文本
|
||||||
operateState: false, // 操作请求的状态
|
operateState: false, // 操作请求的状态
|
||||||
|
|
||||||
mybalance: 0, // 一共有多个寄托币
|
|
||||||
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@ -487,57 +487,24 @@ export default {
|
|||||||
let data = res.data
|
let data = res.data
|
||||||
let info = data.info
|
let info = data.info
|
||||||
|
|
||||||
|
|
||||||
info['message'] = info['message'].trim()
|
|
||||||
|
|
||||||
const reg = new RegExp("\r\n", "g")
|
const reg = new RegExp("\r\n", "g")
|
||||||
info['message'] = info['message'].replaceAll(reg, '<br/>')
|
info['message'] = info['message'].replaceAll(reg, '<br/>')
|
||||||
info['message'] = info['message'].replace(/<img[^>]*>/g, (match) => {
|
info['message'] = info['message'].replace(/<img[^>]*>/g, (match) => {
|
||||||
return match.replace(/width="[^"]*"/g, '').replace(/height="[^"]*"/g, '');
|
return match.replace(/width="[^"]*"/g, '').replace(/height="[^"]*"/g, '');
|
||||||
})
|
})
|
||||||
|
|
||||||
|
info["messageList"] = []
|
||||||
|
|
||||||
let ispost = data.info.ispost
|
info['message'] = info['message'].replaceAll("[hide]作者设置了回复可见[/hide]", `<div class="flexcenter content-unlock content-unlock-no replyVisible" @click="aa()"><img class="unlock-icom" src="./img/unlock.png"/>作者设置了回复可见</div>`)
|
||||||
let price = data.info.price
|
|
||||||
|
|
||||||
|
|
||||||
if (price > 0) {
|
|
||||||
let message = info['message']
|
|
||||||
|
|
||||||
if (message.indexOf("[free]") != -1) {
|
|
||||||
info['message'] = ""
|
|
||||||
const regex = /\[free\]([^[]+)\[\/free\]/g;
|
|
||||||
let result = message.match(regex);
|
|
||||||
for (let i = 0; i < result.length; i++) {
|
|
||||||
result[i] = result[i].replace("[free]", "")
|
|
||||||
result[i] = result[i].replace("[/free]", "")
|
|
||||||
|
|
||||||
info['message'] += result[i]
|
|
||||||
}
|
|
||||||
info['message'] += `<div class="flexcenter content-unlock content-unlock-no coinVisible" @click="aa()"><img class="unlock-icom" src="./img/unlock.png"/>作者设置了投币可见</div>`
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (info['message'].indexOf("[hide]") != -1) {
|
|
||||||
if (ispost == 0) info['message'] = info['message'].replaceAll("[hide]作者设置了回复可见[/hide]", `<div class="flexcenter content-unlock content-unlock-no replyVisible" @click="setValue('popState', 'discussionSingle')"><img class="unlock-icom" src="./img/unlock.png"/>作者设置了回复可见</div>`)
|
|
||||||
if (ispost == 1) {
|
|
||||||
info['message'] = info['message'].replaceAll("[hide]", `<div class="content-unlock content-already"><div class="content-already-header flexflex">- 本内容回复可见 -</div><div class="content-unlock-wenzi">`)
|
|
||||||
info['message'] = info['message'].replaceAll("[/hide]", `</div></div>`)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// if (ispost == 1) info['message'] = info['message'].replaceAll("[hide]作者设置了回复可见[/hide]", "")
|
|
||||||
// if (info.message.indexOf("[hide]作者设置了回复可见[/hide]")) {
|
// if (info.message.indexOf("[hide]作者设置了回复可见[/hide]")) {
|
||||||
// `<div class="flexcenter content-unlock content-unlock-no"><img class="unlock-icom" src="@/assets/img/detail/unlock.png">作者设置了回复可见</div>`
|
// `<div class="flexcenter content-unlock content-unlock-no"><img class="unlock-icom" src="@/assets/img/detail/unlock.png">作者设置了回复可见</div>`
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
// console.log(info['message']);
|
||||||
|
|
||||||
// info['message'] = this.$sanitize(info['message'])
|
// info['message'] = this.$sanitize(info['message'])
|
||||||
|
// console.log(info['message']);
|
||||||
|
|
||||||
data.type == 0 ? this.$refs['vHtmlMessage'] ? this.$refs.vHtmlMessage.innerHTML = info['message'] : "" : ""
|
data.type == 0 ? this.$refs['vHtmlMessage'] ? this.$refs.vHtmlMessage.innerHTML = info['message'] : "" : ""
|
||||||
|
|
||||||
@ -553,34 +520,18 @@ export default {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
let coinVisibleList = document.getElementsByClassName("coinVisible")
|
|
||||||
if (!Array.isArray(coinVisibleList)) {
|
|
||||||
for (let i = 0; i < coinVisibleList.length; i++) {
|
|
||||||
coinVisibleList[i].addEventListener('click', () => {
|
|
||||||
this.$emit("coinVisibleClick")
|
|
||||||
})
|
|
||||||
}
|
|
||||||
this.$on('coinVisibleClick', () => {
|
|
||||||
// coinNo coindisplayuser
|
|
||||||
this.popState = data.mybalance > price ? "coindisplayuser" : "coinNo"
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// console.log(info, "offerinfo", data.type);
|
// console.log(info, "offerinfo", data.type);
|
||||||
|
|
||||||
this.info = info
|
this.info = info
|
||||||
this.type = data.type
|
this.type = data.type
|
||||||
this.token = data.token
|
this.token = data.token
|
||||||
this.mybalance = data.mybalance
|
|
||||||
|
|
||||||
if (this.type == 6) this.getOfferDetail()
|
if (this.type == 6) this.getOfferDetail()
|
||||||
else if (this.type == 5) this.getsummaryDetails()
|
else if (this.type == 5) this.getsummaryDetails()
|
||||||
else if (this.type == 3) this.getTenementDetails()
|
else if (this.type == 3) this.getTenementDetails()
|
||||||
else if (this.type == 2) this.getInterviewDetails()
|
else if (this.type == 2) this.getInterviewDetails()
|
||||||
|
|
||||||
// info['ispost'] != 0 ? this.getPostList() : ''
|
info['ispost'] != 0 ? this.getPostList() : ''
|
||||||
this.getPostList()
|
|
||||||
|
|
||||||
}).finally(() => {
|
}).finally(() => {
|
||||||
this.$closeUnderLoading(this)
|
this.$closeUnderLoading(this)
|
||||||
@ -673,7 +624,11 @@ export default {
|
|||||||
getInterviewDetails() {
|
getInterviewDetails() {
|
||||||
|
|
||||||
this.$http.post("/InterviewExperience/thread", {
|
this.$http.post("/InterviewExperience/thread", {
|
||||||
tid: this.tid,
|
// token: this.token,
|
||||||
|
// tid: this.tid
|
||||||
|
// tid: 2322145,
|
||||||
|
// uniqid: "--G1tS2SCTOQyoOMiedlLKxTnFvHWjBwQezsJjvVJFwgqOtOFeYr4_LAAG5RV37ETvMl2Zd4tSCc-_dqeKpERxXsx-tPfXrUs0kUysTGLzgxYzU~",
|
||||||
|
// token: "5e3c42209eebfbab66e6f0d6c70a53c7",
|
||||||
token: this.token
|
token: this.token
|
||||||
}, "tenement").then(res => {
|
}, "tenement").then(res => {
|
||||||
// console.log(res);
|
// console.log(res);
|
||||||
@ -699,51 +654,25 @@ export default {
|
|||||||
this.postList.count = data.count
|
this.postList.count = data.count
|
||||||
})
|
})
|
||||||
|
|
||||||
},
|
|
||||||
|
|
||||||
// 打开编辑评论
|
|
||||||
openEditPop(item) {
|
|
||||||
console.log(item);
|
|
||||||
let message = item.message
|
|
||||||
message = message.replace(/<div[^>]*>[\s\S]*?<\/div>/gi, ''); // 清除掉引有的结构
|
|
||||||
message = message.trim()
|
|
||||||
this.commentContent = message
|
|
||||||
this.editCommentPid = item.pid
|
|
||||||
|
|
||||||
this.popState = "discussionMulti"
|
|
||||||
},
|
},
|
||||||
|
|
||||||
// 处理回复点击弹出弹窗
|
// 处理回复点击弹出弹窗
|
||||||
handleReplyPop(item) {
|
handleReplyPop(item) {
|
||||||
this.twoCommentData = {
|
|
||||||
avatar: item.avatar,
|
|
||||||
content: item.message,
|
|
||||||
pid: item.pid
|
|
||||||
}
|
|
||||||
this.popState = "discussionSingle"
|
this.popState = "discussionSingle"
|
||||||
},
|
},
|
||||||
|
|
||||||
// 集中处理回复帖子
|
// 集中处理回复帖子
|
||||||
postComment(message) {
|
postComment(message) {
|
||||||
let url = ""
|
this.$http.post("/api/operation/reply", {
|
||||||
|
|
||||||
if (this.editCommentPid) url = "/api/operation/redactPost" // 回复评论或者评论
|
|
||||||
else url = "/api/operation/reply" // 编辑评论
|
|
||||||
|
|
||||||
this.$http.post(url, {
|
|
||||||
token: this.token,
|
token: this.token,
|
||||||
message: this.commentContent,
|
message: this.commentContent
|
||||||
pid: this.editCommentPid || (this.twoCommentData && this.twoCommentData.pid)
|
|
||||||
}).then(res => {
|
}).then(res => {
|
||||||
if (res.code != 200) return
|
if (res.code != 200) return
|
||||||
|
// let data = res.data
|
||||||
|
// console.log(data);
|
||||||
this.popState = ""
|
this.popState = ""
|
||||||
this.twoCommentData = null
|
|
||||||
if (this.editCommentPid) this.$router.go(0)
|
|
||||||
|
|
||||||
this.editCommentPid = null
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
let { count, limit } = this.postList
|
let { count, limit } = this.postList
|
||||||
|
|
||||||
let page = Math.ceil((count + 1) / limit)
|
let page = Math.ceil((count + 1) / limit)
|
||||||
@ -785,6 +714,7 @@ export default {
|
|||||||
else if (key == "uncollect") url = "/api/operation/threadunFav"
|
else if (key == "uncollect") url = "/api/operation/threadunFav"
|
||||||
|
|
||||||
this.$http.post(url, { tid: this.tid }).then(res => {
|
this.$http.post(url, { tid: this.tid }).then(res => {
|
||||||
|
console.log(res);
|
||||||
if (res.code != 200) return
|
if (res.code != 200) return
|
||||||
if (key == "like") this.info.islike = 1
|
if (key == "like") this.info.islike = 1
|
||||||
if (key == "collect") this.info.isfav = 1
|
if (key == "collect") this.info.isfav = 1
|
||||||
@ -833,6 +763,10 @@ export default {
|
|||||||
margin-top: 1.3rem;
|
margin-top: 1.3rem;
|
||||||
padding-bottom: 2.8rem;
|
padding-bottom: 2.8rem;
|
||||||
|
|
||||||
|
.aaa {
|
||||||
|
color: red;
|
||||||
|
}
|
||||||
|
|
||||||
.detail-head {
|
.detail-head {
|
||||||
color: #7F7F7F;
|
color: #7F7F7F;
|
||||||
padding: .191rem 0.2933rem 0;
|
padding: .191rem 0.2933rem 0;
|
||||||
@ -969,6 +903,7 @@ export default {
|
|||||||
|
|
||||||
.edit-icom {
|
.edit-icom {
|
||||||
width: .4rem;
|
width: .4rem;
|
||||||
|
// height: .4rem;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -986,54 +921,44 @@ export default {
|
|||||||
width: 100% !important;
|
width: 100% !important;
|
||||||
height: auto !important;
|
height: auto !important;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.quote {
|
.quotation {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
color: #333;
|
color: #333;
|
||||||
font-size: .32rem;
|
font-size: .32rem;
|
||||||
border-radius: .16rem;
|
border-radius: .16rem;
|
||||||
background: rgb(246, 246, 246) url(@/assets/img/detail/quotation-left.png) no-repeat .4rem .2666rem;
|
background: rgb(246, 246, 246);
|
||||||
|
padding: .36rem .24rem;
|
||||||
|
box-sizing: border-box;
|
||||||
|
margin-bottom: .48rem;
|
||||||
|
|
||||||
padding: .1333rem .1333rem .1333rem 1rem;
|
.quotation-wenzi {
|
||||||
|
line-height: .52rem;
|
||||||
|
}
|
||||||
|
|
||||||
// padding: .36rem .24rem;
|
.quotation-icon {
|
||||||
box-sizing: border-box;
|
width: .32rem;
|
||||||
margin-bottom: .48rem;
|
height: .26rem;
|
||||||
|
}
|
||||||
|
|
||||||
blockquote {
|
.quotation-right {
|
||||||
margin: 0;
|
flex-direction: column;
|
||||||
padding: 0 .8667rem .0667rem 0;
|
margin-left: .28rem;
|
||||||
background: url(@/assets/img/detail/quotation-right.png) no-repeat 100% 100%;
|
|
||||||
line-height: 1.6;
|
|
||||||
zoom: 1;
|
|
||||||
display: inline;
|
|
||||||
}
|
|
||||||
|
|
||||||
.quotation-wenzi {
|
.quotation-bottom {
|
||||||
line-height: .52rem;
|
color: #7F7F7F;
|
||||||
}
|
font-size: .28rem;
|
||||||
|
margin-top: .258rem;
|
||||||
|
|
||||||
.quotation-icon {
|
.quotation-icon {
|
||||||
width: .32rem;
|
margin-left: .2rem;
|
||||||
height: .26rem;
|
|
||||||
}
|
|
||||||
|
|
||||||
.quotation-right {
|
|
||||||
flex-direction: column;
|
|
||||||
margin-left: .28rem;
|
|
||||||
|
|
||||||
.quotation-bottom {
|
|
||||||
color: #7F7F7F;
|
|
||||||
font-size: .28rem;
|
|
||||||
margin-top: .258rem;
|
|
||||||
|
|
||||||
.quotation-icon {
|
|
||||||
margin-left: .2rem;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/deep/ {
|
||||||
.content-unlock {
|
.content-unlock {
|
||||||
&.content-unlock-no {
|
&.content-unlock-no {
|
||||||
height: 3.2rem;
|
height: 3.2rem;
|
||||||
@ -1075,8 +1000,6 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1359,6 +1282,23 @@ export default {
|
|||||||
padding: 0 0.4rem;
|
padding: 0 0.4rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.bottom-operation-button {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
background-color: transparent;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
border: none;
|
||||||
|
outline: none;
|
||||||
|
|
||||||
|
&::after {
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.bottom-transmit-icom {
|
.bottom-transmit-icom {
|
||||||
width: 0.4rem;
|
width: 0.4rem;
|
||||||
height: 0.4rem;
|
height: 0.4rem;
|
||||||
|
@ -100,6 +100,7 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
// 处理 query 的参数
|
// 处理 query 的参数
|
||||||
handQuery() {
|
handQuery() {
|
||||||
|
console.log(this.list);
|
||||||
if (this.list.length >= 2) {
|
if (this.list.length >= 2) {
|
||||||
let list = this.list
|
let list = this.list
|
||||||
list.forEach((el, index) => {
|
list.forEach((el, index) => {
|
||||||
@ -118,6 +119,10 @@ export default {
|
|||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
|
console.log(this.allActive, "allActive");
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.handQuery()
|
this.handQuery()
|
||||||
@ -191,8 +196,8 @@ export default {
|
|||||||
this.$router.push({ path: `/allSections`, query: { fid: this.fid, invitationPage: this.invitationPage } })
|
this.$router.push({ path: `/allSections`, query: { fid: this.fid, invitationPage: this.invitationPage } })
|
||||||
},
|
},
|
||||||
|
|
||||||
// 点击回归板块列表
|
|
||||||
flybackAll() {
|
flybackAll() {
|
||||||
|
console.log("jkldfgjklfggfdjklgfjkl");
|
||||||
this.isPlateListState = true
|
this.isPlateListState = true
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@
|
|||||||
@click="hotLabelClick(item.fid)">{{ item.name }}</div>
|
@click="hotLabelClick(item.fid)">{{ item.name }}</div>
|
||||||
</div>
|
</div>
|
||||||
<!-- 路径 -->
|
<!-- 路径 -->
|
||||||
<plate-navigation isskip="true" v-if="fid != 0" :stairname="plate.stairname"
|
<plate-navigation :isskip="isskip" v-if="fid != 0" :stairname="plate.stairname"
|
||||||
:subsectionsname="plate.subsectionsname"></plate-navigation>
|
:subsectionsname="plate.subsectionsname"></plate-navigation>
|
||||||
<section>
|
<section>
|
||||||
<template v-if="list.length != 0 || loading">
|
<template v-if="list.length != 0 || loading">
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="operation-box shadow">
|
<div class="operation-box shadow">
|
||||||
<a class="operation-item flexacenter" href="https://www.gter.net/bbs/user/pm.html?mobile=yes">
|
<div class="operation-item flexacenter">
|
||||||
<div class="operation-left flexacenter">
|
<div class="operation-left flexacenter">
|
||||||
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/information.png">消息
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/information.png">消息
|
||||||
</div>
|
</div>
|
||||||
@ -33,29 +33,103 @@
|
|||||||
<div v-else class="unread-info flexcenter">{{ user.messagenum }}</div>
|
<div v-else class="unread-info flexcenter">{{ user.messagenum }}</div>
|
||||||
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</div>
|
||||||
|
|
||||||
<a class="operation-item flexacenter" v-for="(item, index) in operateList" :key="index" :href="item.url">
|
<div class="operation-item flexacenter">
|
||||||
<div class="operation-left flexacenter">
|
<div class="operation-left flexacenter">
|
||||||
<img class="operation-icom" mode="widthFix" :src="`./img/user/${item.icon}`">{{ item.name }}
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/collect.png">收藏
|
||||||
</div>
|
</div>
|
||||||
<div class="operation-right flexacenter">
|
<div class="operation-right flexacenter">
|
||||||
<div class="operation-data flexcenter">{{ count[item.key] }}</div>
|
<div class="operation-data flexcenter">{{ count.fav }}</div>
|
||||||
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" src="@/assets/img/user/postmessage.png" />发帖
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<div class="operation-data flexcenter">{{ count.post }}</div>
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/replymessage.png" />回帖
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<div class="operation-data flexcenter">{{ count.reply }}</div>
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="operation-box shadow">
|
<div class="operation-box shadow">
|
||||||
<a v-for="(item, index) in setList" :key="index" class="operation-item flexacenter" :href="item.url">
|
<div class="operation-item flexacenter">
|
||||||
<div class="operation-left flexacenter">
|
<div class="operation-left flexacenter">
|
||||||
<img class="operation-icom" mode="widthFix" :src="`./img/user/${item.icon}`">{{ item.name }}
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/personaldata.png">个人资料
|
||||||
</div>
|
</div>
|
||||||
<div class="operation-right flexacenter">
|
<div class="operation-right flexacenter">
|
||||||
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
</div>
|
</div>
|
||||||
</a>
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" src="@/assets/img/user/avatarsetting.png" />设置头像
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/mystatus.png" />我的状态
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/changepassword.png" />修改密码
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/bindemail.png" />绑定邮箱
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/bindmobile.png" />绑定手机
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/bindingthird-party .png" />绑定第三方账号
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="operation-item flexacenter">
|
||||||
|
<div class="operation-left flexacenter">
|
||||||
|
<img class="operation-icom" mode="widthFix" src="@/assets/img/user/visithomepage.png" />浏览个人主页
|
||||||
|
</div>
|
||||||
|
<div class="operation-right flexacenter">
|
||||||
|
<svg-icon icon-class="arrowsLeft" class-name="operation-right-icom"></svg-icon>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@ -77,68 +151,6 @@ export default {
|
|||||||
},
|
},
|
||||||
count: {},
|
count: {},
|
||||||
|
|
||||||
operateList: [{
|
|
||||||
name: "收藏",
|
|
||||||
url: "https://www.gter.net/bbs/user/collection.html",
|
|
||||||
icon: "collect.png",
|
|
||||||
type: "collect",
|
|
||||||
key: "fav"
|
|
||||||
}, {
|
|
||||||
name: "发帖",
|
|
||||||
url: "https://www.gter.net/bbs/user/threads.html",
|
|
||||||
icon: "postmessage.png",
|
|
||||||
type: "collect",
|
|
||||||
key: "post"
|
|
||||||
}, {
|
|
||||||
name: "回帖",
|
|
||||||
url: "https://www.gter.net/bbs/user/post.html",
|
|
||||||
icon: "replymessage.png",
|
|
||||||
type: "post",
|
|
||||||
key: "reply"
|
|
||||||
},],
|
|
||||||
|
|
||||||
setList: [{ // 设置列表
|
|
||||||
name: "个人资料",
|
|
||||||
url: "https://member.gter.net/index/modify.html",
|
|
||||||
icon: "personaldata.png",
|
|
||||||
type: "modify"
|
|
||||||
}, {
|
|
||||||
name: "设置头像",
|
|
||||||
url: "https://member.gter.net/index/avatar.html",
|
|
||||||
icon: "avatarsetting.png",
|
|
||||||
type: "avatar"
|
|
||||||
}, {
|
|
||||||
name: "我的状态",
|
|
||||||
url: "https://member.gter.net/index/status.html",
|
|
||||||
icon: "mystatus.png",
|
|
||||||
type: "status"
|
|
||||||
}, {
|
|
||||||
name: "修改密码",
|
|
||||||
url: "https://member.gter.net/reset/password.html",
|
|
||||||
icon: "changepassword.png",
|
|
||||||
type: "password"
|
|
||||||
}, {
|
|
||||||
name: "绑定邮箱",
|
|
||||||
url: "https://member.gter.net/reset/email.html",
|
|
||||||
icon: "bindemail.png",
|
|
||||||
type: "email"
|
|
||||||
}, {
|
|
||||||
name: "绑定手机",
|
|
||||||
url: "https://member.gter.net/reset/mobile.html",
|
|
||||||
icon: "bindmobile.png",
|
|
||||||
type: "mobile"
|
|
||||||
}, {
|
|
||||||
name: "绑定第三方账号",
|
|
||||||
url: "https://member.gter.net/bind",
|
|
||||||
icon: "bindingthird-party.png",
|
|
||||||
type: "bind"
|
|
||||||
}, {
|
|
||||||
name: "浏览个人主页",
|
|
||||||
url: "",
|
|
||||||
icon: "visithomepage.png",
|
|
||||||
type: "space"
|
|
||||||
}]
|
|
||||||
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -149,40 +161,18 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
init() {
|
init() {
|
||||||
this.$http.post("/api/user", "").then(res => {
|
this.$http.post("/api/user", "").then(res => {
|
||||||
|
console.log(res, "res");
|
||||||
let data = res.data
|
let data = res.data
|
||||||
this.count = data.count
|
this.count = data.count
|
||||||
this.user = data.user
|
this.user = data.user
|
||||||
|
|
||||||
let user = data.user
|
console.log(this.count);
|
||||||
let setList = this.setList
|
|
||||||
setList.forEach(el => {
|
|
||||||
if (el.type == "space") el['url'] = `https://bbs.gter.net/space-uid-${user.uin}.html`
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
// 点击退出登录
|
// 点击退出登录
|
||||||
logOut() {
|
logOut() {
|
||||||
console.log("点击退出登录");
|
console.log("点击退出登录");
|
||||||
|
|
||||||
this.user = {
|
|
||||||
avatar: "",
|
|
||||||
nickname: "",
|
|
||||||
messagenum: 0
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
this.$store.commit('setUser', {})
|
|
||||||
this.$store.commit('setFavoriteList', [])
|
|
||||||
this.$store.commit('setHomeRequestState', false)
|
|
||||||
|
|
||||||
this.$clearCookies();
|
|
||||||
|
|
||||||
this.$router.push("/")
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|