From f451147ecec773c69582e7bf4f4e34bebfa0271f Mon Sep 17 00:00:00 2001 From: linfeng Date: Thu, 1 Jun 2023 15:08:30 +0800 Subject: [PATCH 1/4] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E6=A0=A1=E9=AA=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/views/modules/admin/link-add-or-update.vue | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue index 5d6ab65..aaa48d8 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue @@ -51,13 +51,7 @@ export default { dataRule: { title: [{ required: true, message: "标题不能为空", trigger: "blur" }], url: [{ required: true, message: "路径不能为空", trigger: "blur" }], - img: [{ required: true, message: "图片不能为空", trigger: "blur" }], - type: [ - { required: true, message: "3圈子页轮播图不能为空", trigger: "blur" }, - ], - createTime: [ - { required: true, message: "创建时间不能为空", trigger: "blur" }, - ], + img: [{ required: true, message: "图片不能为空", trigger: "blur" }] }, }; }, From 631cdf1ef0d712e3d510af17c74a9de0c4c1a217 Mon Sep 17 00:00:00 2001 From: linfeng Date: Thu, 1 Jun 2023 15:17:18 +0800 Subject: [PATCH 2/4] =?UTF-8?q?=E5=90=8E=E5=8F=B0=E5=89=8D=E7=AB=AF?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/admin/category-add-or-update.vue | 2 +- .../modules/admin/comment-add-or-update.vue | 18 ------------------ .../src/views/modules/admin/comment.vue | 14 -------------- 3 files changed, 1 insertion(+), 33 deletions(-) diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/category-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/category-add-or-update.vue index b5f5462..2c1ff5d 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/category-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/category-add-or-update.vue @@ -39,7 +39,7 @@ export default { ], coverImage: [ { required: true, message: "图片不能为空", trigger: "blur" }, - ], + ] }, }; }, diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue index 31f5f94..4d7b617 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue @@ -32,26 +32,8 @@ createTime: '' }, dataRule: { - pid: [ - { required: true, message: '父级id不能为空', trigger: 'blur' } - ], - uid: [ - { required: true, message: '评论作者ID不能为空', trigger: 'blur' } - ], - toUid: [ - { required: true, message: '被回复用户ID不能为空', trigger: 'blur' } - ], - postId: [ - { required: true, message: '评论帖子ID不能为空', trigger: 'blur' } - ], - content: [ - { required: true, message: '评论内容不能为空', trigger: 'blur' } - ], status: [ { required: true, message: '评论状态不能为空', trigger: 'blur' } - ], - createTime: [ - { required: true, message: '创建时间不能为空', trigger: 'blur' } ] } } diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment.vue index 580053a..bc0a38e 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment.vue @@ -36,13 +36,6 @@ label="id" > - - - - Date: Fri, 2 Jun 2023 16:19:56 +0800 Subject: [PATCH 3/4] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=90=8E=E5=8F=B0?= =?UTF-8?q?=E5=89=8D=E7=AB=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/admin/comment-add-or-update.vue | 27 ++---------- .../modules/admin/link-add-or-update.vue | 2 +- .../modules/admin/post-add-or-update.vue | 43 +------------------ .../src/views/modules/admin/post.vue | 15 +------ 4 files changed, 7 insertions(+), 80 deletions(-) diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue index 4d7b617..9c02c0c 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue @@ -22,18 +22,11 @@ visible: false, dataForm: { id: 0, - pid: '', - type: '', - uid: '', - toUid: '', - postId: '', - content: '', - status: '', - createTime: '' + content: '' }, dataRule: { status: [ - { required: true, message: '评论状态不能为空', trigger: 'blur' } + { required: true, message: '评论状态未选择', trigger: 'blur' } ] } } @@ -51,14 +44,7 @@ params: this.$http.adornParams() }).then(({data}) => { if (data && data.code === 0) { - this.dataForm.pid = data.comment.pid - this.dataForm.type = data.comment.type - this.dataForm.uid = data.comment.uid - this.dataForm.toUid = data.comment.toUid - this.dataForm.postId = data.comment.postId this.dataForm.content = data.comment.content - this.dataForm.status = data.comment.status - this.dataForm.createTime = data.comment.createTime } }) } @@ -73,14 +59,7 @@ method: 'post', data: this.$http.adornData({ 'id': this.dataForm.id || undefined, - 'pid': this.dataForm.pid, - 'type': this.dataForm.type, - 'uid': this.dataForm.uid, - 'toUid': this.dataForm.toUid, - 'postId': this.dataForm.postId, - 'content': this.dataForm.content, - 'status': this.dataForm.status, - 'createTime': this.dataForm.createTime + 'content': this.dataForm.content }) }).then(({data}) => { if (data && data.code === 0) { diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue index aaa48d8..42f913e 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/link-add-or-update.vue @@ -50,7 +50,7 @@ export default { }, dataRule: { title: [{ required: true, message: "标题不能为空", trigger: "blur" }], - url: [{ required: true, message: "路径不能为空", trigger: "blur" }], + url: [{ required: true, message: "跳转路径不能为空", trigger: "blur" }], img: [{ required: true, message: "图片不能为空", trigger: "blur" }] }, }; diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue index ca99e4b..d3c3806 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue @@ -34,21 +34,8 @@ export default { visible: false, dataForm: { id: 0, - uid: "", - topicId: "", - discussId: "", - voteId: "", - title: "", - content: "", - media: "", readCount: "", - postTop: "", - type: "", - address: "", - longitude: "", - latitude: "", - createTime: "", - status: "", + postTop: "" }, }; }, @@ -65,21 +52,8 @@ export default { params: this.$http.adornParams(), }).then(({ data }) => { if (data && data.code === 0) { - this.dataForm.uid = data.post.uid; - this.dataForm.topicId = data.post.topicId; - this.dataForm.discussId = data.post.discussId; - this.dataForm.voteId = data.post.voteId; - this.dataForm.title = data.post.title; - this.dataForm.content = data.post.content; - this.dataForm.media = data.post.media; this.dataForm.readCount = data.post.readCount; this.dataForm.postTop = data.post.postTop; - this.dataForm.type = data.post.type; - this.dataForm.address = data.post.address; - this.dataForm.longitude = data.post.longitude; - this.dataForm.latitude = data.post.latitude; - this.dataForm.createTime = data.post.createTime; - this.dataForm.status = data.post.status; } }); } @@ -96,21 +70,8 @@ export default { method: "post", data: this.$http.adornData({ id: this.dataForm.id || undefined, - uid: this.dataForm.uid, - topicId: this.dataForm.topicId, - discussId: this.dataForm.discussId, - voteId: this.dataForm.voteId, - title: this.dataForm.title, - content: this.dataForm.content, - media: this.dataForm.media, readCount: this.dataForm.readCount, - postTop: this.dataForm.postTop, - type: this.dataForm.type, - address: this.dataForm.address, - longitude: this.dataForm.longitude, - latitude: this.dataForm.latitude, - createTime: this.dataForm.createTime, - status: this.dataForm.status, + postTop: this.dataForm.postTop }), }).then(({ data }) => { if (data && data.code === 0) { diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post.vue index 41c0019..e9e2153 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post.vue @@ -76,13 +76,7 @@ /> - - + - - Date: Fri, 2 Jun 2023 16:28:23 +0800 Subject: [PATCH 4/4] =?UTF-8?q?=E6=9B=B4=E6=96=B0=E5=8A=9F=E8=83=BD?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../modules/admin/comment-add-or-update.vue | 25 ++++++++++- .../modules/admin/post-add-or-update.vue | 43 ++++++++++++++++++- 2 files changed, 64 insertions(+), 4 deletions(-) diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue index 9c02c0c..27589ee 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/comment-add-or-update.vue @@ -22,7 +22,14 @@ visible: false, dataForm: { id: 0, - content: '' + pid: '', + type: '', + uid: '', + toUid: '', + postId: '', + content: '', + status: '', + createTime: '' }, dataRule: { status: [ @@ -44,7 +51,14 @@ params: this.$http.adornParams() }).then(({data}) => { if (data && data.code === 0) { + this.dataForm.pid = data.comment.pid + this.dataForm.type = data.comment.type + this.dataForm.uid = data.comment.uid + this.dataForm.toUid = data.comment.toUid + this.dataForm.postId = data.comment.postId this.dataForm.content = data.comment.content + this.dataForm.status = data.comment.status + this.dataForm.createTime = data.comment.createTime } }) } @@ -59,7 +73,14 @@ method: 'post', data: this.$http.adornData({ 'id': this.dataForm.id || undefined, - 'content': this.dataForm.content + 'pid': this.dataForm.pid, + 'type': this.dataForm.type, + 'uid': this.dataForm.uid, + 'toUid': this.dataForm.toUid, + 'postId': this.dataForm.postId, + 'content': this.dataForm.content, + 'status': this.dataForm.status, + 'createTime': this.dataForm.createTime }) }).then(({data}) => { if (data && data.code === 0) { diff --git a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue index d3c3806..ca99e4b 100644 --- a/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue +++ b/src/main/resources/static/linfeng-community-vue/src/views/modules/admin/post-add-or-update.vue @@ -34,8 +34,21 @@ export default { visible: false, dataForm: { id: 0, + uid: "", + topicId: "", + discussId: "", + voteId: "", + title: "", + content: "", + media: "", readCount: "", - postTop: "" + postTop: "", + type: "", + address: "", + longitude: "", + latitude: "", + createTime: "", + status: "", }, }; }, @@ -52,8 +65,21 @@ export default { params: this.$http.adornParams(), }).then(({ data }) => { if (data && data.code === 0) { + this.dataForm.uid = data.post.uid; + this.dataForm.topicId = data.post.topicId; + this.dataForm.discussId = data.post.discussId; + this.dataForm.voteId = data.post.voteId; + this.dataForm.title = data.post.title; + this.dataForm.content = data.post.content; + this.dataForm.media = data.post.media; this.dataForm.readCount = data.post.readCount; this.dataForm.postTop = data.post.postTop; + this.dataForm.type = data.post.type; + this.dataForm.address = data.post.address; + this.dataForm.longitude = data.post.longitude; + this.dataForm.latitude = data.post.latitude; + this.dataForm.createTime = data.post.createTime; + this.dataForm.status = data.post.status; } }); } @@ -70,8 +96,21 @@ export default { method: "post", data: this.$http.adornData({ id: this.dataForm.id || undefined, + uid: this.dataForm.uid, + topicId: this.dataForm.topicId, + discussId: this.dataForm.discussId, + voteId: this.dataForm.voteId, + title: this.dataForm.title, + content: this.dataForm.content, + media: this.dataForm.media, readCount: this.dataForm.readCount, - postTop: this.dataForm.postTop + postTop: this.dataForm.postTop, + type: this.dataForm.type, + address: this.dataForm.address, + longitude: this.dataForm.longitude, + latitude: this.dataForm.latitude, + createTime: this.dataForm.createTime, + status: this.dataForm.status, }), }).then(({ data }) => { if (data && data.code === 0) {