no message
This commit is contained in:
parent
3e8dba7d4b
commit
fb44b267bd
BIN
src/assets/img/detail/icon_quote_e.gif
Normal file
BIN
src/assets/img/detail/icon_quote_e.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 287 B |
BIN
src/assets/img/detail/icon_quote_s.gif
Normal file
BIN
src/assets/img/detail/icon_quote_s.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 298 B |
BIN
src/assets/img/detail/quotation-left.png
Normal file
BIN
src/assets/img/detail/quotation-left.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 434 B |
BIN
src/assets/img/detail/quotation-right.png
Normal file
BIN
src/assets/img/detail/quotation-right.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 437 B |
@ -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)" />
|
@input="inputCommentContent($event)" v-focus />
|
||||||
<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,16 +33,15 @@
|
|||||||
<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" type="text" maxlength="500" :value="commentContent"
|
<textarea class="discussion-multi-textarea flex1" v-focus type="text" maxlength="500"
|
||||||
:placeholder="twoCommentData ? '写回复…' : '想问啥,大胆问…'" @input="inputCommentContent($event)"></textarea>
|
:value="commentContent" :placeholder="twoCommentData ? '写回复…' : '想问啥,大胆问…'"
|
||||||
|
@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 class="discussion-multi-btn flexcenter" @click.stop="postComment()">发布</div>
|
||||||
发布
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -64,7 +63,6 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
|
|
||||||
// 提交回复
|
// 提交回复
|
||||||
postComment() {
|
postComment() {
|
||||||
this.$parent.postComment()
|
this.$parent.postComment()
|
||||||
|
@ -97,4 +97,6 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
</style>
|
</style>
|
11
src/main.js
11
src/main.js
@ -50,8 +50,17 @@ Vue.use(Pagination);
|
|||||||
Vue.use(VueSanitize);
|
Vue.use(VueSanitize);
|
||||||
|
|
||||||
|
|
||||||
|
Vue.directive('focus', {
|
||||||
|
// 当绑定元素插入到 DOM 中。
|
||||||
|
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')
|
||||||
|
@ -11,7 +11,8 @@ 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",
|
||||||
|
|
||||||
|
@ -18,7 +18,6 @@
|
|||||||
{{ 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">
|
||||||
@ -146,7 +145,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="handleIsmyself(item)">
|
<div class="edit-box flexcenter" v-if="item.ismyself == 1" @click.stop="openEditPop(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> -->
|
||||||
@ -169,8 +168,7 @@
|
|||||||
<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>
|
</div> 之前申请永久居民,参考了不少寄托的帖子和经验,现在回馈给大家,积攒RP。
|
||||||
之前申请永久居民,参考了不少寄托的帖子和经验,现在回馈给大家,积攒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">
|
||||||
@ -337,6 +335,7 @@ 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: {
|
||||||
@ -493,18 +492,13 @@ export default {
|
|||||||
return match.replace(/width="[^"]*"/g, '').replace(/height="[^"]*"/g, '');
|
return match.replace(/width="[^"]*"/g, '').replace(/height="[^"]*"/g, '');
|
||||||
})
|
})
|
||||||
|
|
||||||
info["messageList"] = []
|
|
||||||
|
|
||||||
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>`)
|
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>`)
|
||||||
|
|
||||||
// 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'] : "" : ""
|
||||||
|
|
||||||
@ -531,7 +525,8 @@ export default {
|
|||||||
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)
|
||||||
@ -629,6 +624,7 @@ export default {
|
|||||||
// tid: 2322145,
|
// tid: 2322145,
|
||||||
// uniqid: "--G1tS2SCTOQyoOMiedlLKxTnFvHWjBwQezsJjvVJFwgqOtOFeYr4_LAAG5RV37ETvMl2Zd4tSCc-_dqeKpERxXsx-tPfXrUs0kUysTGLzgxYzU~",
|
// uniqid: "--G1tS2SCTOQyoOMiedlLKxTnFvHWjBwQezsJjvVJFwgqOtOFeYr4_LAAG5RV37ETvMl2Zd4tSCc-_dqeKpERxXsx-tPfXrUs0kUysTGLzgxYzU~",
|
||||||
// token: "5e3c42209eebfbab66e6f0d6c70a53c7",
|
// token: "5e3c42209eebfbab66e6f0d6c70a53c7",
|
||||||
|
tid: this.tid,
|
||||||
token: this.token
|
token: this.token
|
||||||
}, "tenement").then(res => {
|
}, "tenement").then(res => {
|
||||||
// console.log(res);
|
// console.log(res);
|
||||||
@ -654,25 +650,52 @@ 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) {
|
||||||
this.$http.post("/api/operation/reply", {
|
let url = ""
|
||||||
|
|
||||||
|
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)
|
||||||
@ -714,7 +737,6 @@ 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
|
||||||
@ -903,7 +925,6 @@ export default {
|
|||||||
|
|
||||||
.edit-icom {
|
.edit-icom {
|
||||||
width: .4rem;
|
width: .4rem;
|
||||||
// height: .4rem;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -921,18 +942,29 @@ export default {
|
|||||||
width: 100% !important;
|
width: 100% !important;
|
||||||
height: auto !important;
|
height: auto !important;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.quotation {
|
.quote {
|
||||||
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);
|
background: rgb(246, 246, 246) url(@/assets/img/detail/quotation-left.png) no-repeat .4rem .2666rem;
|
||||||
padding: .36rem .24rem;
|
|
||||||
|
padding: .1333rem .1333rem .1333rem 1rem;
|
||||||
|
|
||||||
|
// padding: .36rem .24rem;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
margin-bottom: .48rem;
|
margin-bottom: .48rem;
|
||||||
|
|
||||||
|
blockquote {
|
||||||
|
margin: 0;
|
||||||
|
padding: 0 .8667rem .0667rem 0;
|
||||||
|
background: url(@/assets/img/detail/quotation-right.png) no-repeat 100% 100%;
|
||||||
|
line-height: 1.6;
|
||||||
|
zoom: 1;
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
|
||||||
.quotation-wenzi {
|
.quotation-wenzi {
|
||||||
line-height: .52rem;
|
line-height: .52rem;
|
||||||
}
|
}
|
||||||
@ -958,7 +990,6 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/deep/ {
|
|
||||||
.content-unlock {
|
.content-unlock {
|
||||||
&.content-unlock-no {
|
&.content-unlock-no {
|
||||||
height: 3.2rem;
|
height: 3.2rem;
|
||||||
@ -1000,6 +1031,8 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -100,7 +100,6 @@ 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) => {
|
||||||
@ -119,10 +118,6 @@ export default {
|
|||||||
|
|
||||||
})
|
})
|
||||||
|
|
||||||
console.log(this.allActive, "allActive");
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
this.handQuery()
|
this.handQuery()
|
||||||
@ -196,8 +191,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
|
||||||
},
|
},
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user