mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/student-h5.git
synced 2025-12-06 17:36:45 +08:00
feat:增加讨论发帖点赞等
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-13 11:42:48
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-02-19 18:05:07
|
||||
* @LastEditTime: 2023-02-20 17:57:40
|
||||
* @FilePath: /stu_h5/src/api/api.js
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
*/
|
||||
@@ -54,8 +54,18 @@ export const VOTE_DETAIL_SUBMIT = `/voteSubmit/vote/commit post`
|
||||
// 讨论模块
|
||||
// -- 根据讨论的Id查询讨论发表的帖子
|
||||
export const QueryDiscussSubmitDetailByDiscussId = '/discussSubmit/queryDiscussSubmitDetailByDiscussId post'
|
||||
export const COMMENT_PRAISE = '/comment/praise post'
|
||||
export const COMMENT_COLLECTION = '/comment/collection post'
|
||||
// 查询讨论下的帖子
|
||||
export const PostList = `/statement/list`
|
||||
// 发表帖子
|
||||
export const PostAdd = `/statement/add post`
|
||||
// 贴子点赞
|
||||
export const PostPraise = `/statement/praise`
|
||||
// 帖子详情查询
|
||||
export const PostDetails = `/statement/info`
|
||||
|
||||
export const COMMENT_LIST = '/comment/list'
|
||||
export const COMMENT_PRAISE = '/comment/praise'
|
||||
|
||||
// 外部考试详情接口
|
||||
export const EXTERNALEXAM = `/external/exam/queryExternalExam`
|
||||
|
||||
@@ -157,7 +157,7 @@ const httpupload = axios.create({
|
||||
headers: { "Content-Type": "multipart/form-data" },
|
||||
});
|
||||
|
||||
export const fileUp = (data) => httpupload.post("/file/img", data, {
|
||||
export const fileUp = (data) => httpupload.post("/file/upload", data, {
|
||||
headers: { "Content-Type": "multipart/form-data" },
|
||||
});
|
||||
export const videoUp = (data) => httpupload.post("/file/uploadunlimit", data, {
|
||||
|
||||
BIN
src/assets/image/discuss/elsedianzan1.png
Normal file
BIN
src/assets/image/discuss/elsedianzan1.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 678 B |
BIN
src/assets/image/uploadImg2.png
Normal file
BIN
src/assets/image/uploadImg2.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.3 KiB |
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-16 17:26:39
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-02-18 15:16:34
|
||||
* @LastEditTime: 2023-02-20 11:56:39
|
||||
* @FilePath: /stu_h5/src/components/ReturnHead.vue
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
-->
|
||||
@@ -72,6 +72,14 @@ export default {
|
||||
type: Number,
|
||||
default: null,
|
||||
},
|
||||
discussId: {
|
||||
type: Number,
|
||||
default: null,
|
||||
},
|
||||
postAdd: {
|
||||
type: Function,
|
||||
default: null,
|
||||
},
|
||||
},
|
||||
setup(props, ctx) {
|
||||
const router = useRouter();
|
||||
@@ -79,7 +87,12 @@ export default {
|
||||
router.back();
|
||||
};
|
||||
const publishClick = () => {
|
||||
props.publishWork && props.publishWork();
|
||||
if (props.postAdd) {
|
||||
props.postAdd && props.postAdd();
|
||||
}
|
||||
if (props.publishWork) {
|
||||
props.publishWork && props.publishWork();
|
||||
}
|
||||
};
|
||||
const goFileStorage = () => {
|
||||
router.push({
|
||||
@@ -93,9 +106,9 @@ export default {
|
||||
const goPublish = () => {
|
||||
router.push({
|
||||
path: "/discussupload",
|
||||
// query: {
|
||||
// courseId: props.courseId,
|
||||
// },
|
||||
query: {
|
||||
discussId: props.discussId,
|
||||
},
|
||||
});
|
||||
};
|
||||
return {
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
<div class="tithead">
|
||||
<div class="headin">
|
||||
<div class="vaa">
|
||||
<img class="vaaimg" src="../../assets/image/discuss/px.jpg" />
|
||||
<img class="vaaimg" :src="disDetail?.userAvatar" />
|
||||
</div>
|
||||
<div class="vaainfo">
|
||||
<div class="vaana">付欣晴</div>
|
||||
<div class="vaana">{{ disDetail?.userName }}</div>
|
||||
<div class="vaanato">认识事物的本质。</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -19,16 +19,14 @@
|
||||
<div class="previewmani">
|
||||
<div class="alltalkcontainer">
|
||||
<div class="inne">
|
||||
<div class="takltitle">从营销角度分析:我的团队需要这些能力</div>
|
||||
<div class="taklcon">
|
||||
所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说,不仅要有个人能力,更需要有在不同的位置上各尽所能、与其他成员协调合作的能力。
|
||||
</div>
|
||||
<div class="takltitle">{{ disDetail?.title }}</div>
|
||||
<div class="taklcon" v-html="disDetail?.content"></div>
|
||||
<div class="tt clearfix">
|
||||
<div class="ttin">
|
||||
请基于公司战略方向和你所负责的组织业务发展,识别3个你和你的团队在未来3年的新的能力与技能要求
|
||||
{{ discussInfo ? discussInfo : "-" }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="botime">2022-08-15 22:28</div>
|
||||
<div class="botime">{{ disDetail?.createTime }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -39,65 +37,106 @@
|
||||
<div class="reshead">
|
||||
<div class="headn">
|
||||
<div class="pl">评论</div>
|
||||
<div class="ts">1992条</div>
|
||||
<div class="ts">{{ hfPage?.total }}条</div>
|
||||
</div>
|
||||
<div class="reply" :style="{ opacity: reply1Show ? 0 : 1 }">
|
||||
<img
|
||||
style="width: 28px; height: 28px; margin-right: 5px"
|
||||
src="../../assets/image/uploadImg2.png"
|
||||
/>
|
||||
<el-input
|
||||
type="text"
|
||||
v-model="disComment.content"
|
||||
resize="none"
|
||||
maxlength="100"
|
||||
placeholder="写评论~"
|
||||
style="width: calc(100% - 40px)"
|
||||
/>
|
||||
</div>
|
||||
<div class="reply" :style="{ opacity: reply1Show ? 1 : 0 }">
|
||||
<el-input
|
||||
type="text"
|
||||
v-model="replayComment.content"
|
||||
resize="none"
|
||||
maxlength="100"
|
||||
:placeholder="replayComment.placeholder"
|
||||
style="width: calc(100% - 40px)"
|
||||
@blur="reply1Blur"
|
||||
class="replyInp"
|
||||
/>
|
||||
<img
|
||||
style="width: 28px; height: 28px; margin-left: 5px"
|
||||
src="../../assets/image/uploadImg2.png"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="linee"></div>
|
||||
<!-- <div class="linee"></div> -->
|
||||
|
||||
<div class="restorebox">
|
||||
<div class="restorebox" v-for="(item, index) in commontList" :key="index">
|
||||
<div class="restoremani">
|
||||
<div
|
||||
class="rescon clearfix"
|
||||
v-for="(item, index) in restore"
|
||||
:key="index"
|
||||
>
|
||||
<div class="rescon clearfix">
|
||||
<div class="head">
|
||||
<div>
|
||||
<img class="headavator" :src="item.head" />
|
||||
<img class="headavator" :src="item.studentAvatar" />
|
||||
</div>
|
||||
<div class="namehead">
|
||||
{{ item.name }}
|
||||
{{ item.createName }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="inner">
|
||||
<div class="recon">{{ item.re }}</div>
|
||||
<div class="recon">{{ item.content }}</div>
|
||||
<div class="botto">
|
||||
<div class="time">{{ item.time }}</div>
|
||||
<div class="re">回复</div>
|
||||
<div class="right">
|
||||
<div class="time">{{ item.createTime }}</div>
|
||||
<div class="re" @click="commentComment(item)">回复</div>
|
||||
<div class="right" @click="commentLike(item)">
|
||||
<div class="good">
|
||||
<img src="../../assets/image/discuss/elsedianzan.png" />
|
||||
<img
|
||||
v-if="item.praised"
|
||||
src="../../assets/image/discuss/elsedianzan1.png"
|
||||
/>
|
||||
<img
|
||||
v-else
|
||||
src="../../assets/image/discuss/elsedianzan.png"
|
||||
/>
|
||||
</div>
|
||||
<div class="gocount">67</div>
|
||||
<div class="gocount">{{ item.praiseNum || 0 }}</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="newre">
|
||||
<div class="newre" v-if="item.children.length !== 0">
|
||||
<div class="tri"></div>
|
||||
<div class="reccon">
|
||||
<div class="rec clearfix">
|
||||
<div
|
||||
class="it"
|
||||
v-for="(itemc, index) in newrestore"
|
||||
:key="index"
|
||||
v-for="(itemc, key) in item.children"
|
||||
:key="key"
|
||||
>
|
||||
<div class="ava">
|
||||
<img class="avainner" :src="itemc.head" />
|
||||
<img class="avainner" :src="itemc.studentAvatar" />
|
||||
</div>
|
||||
<div class="redetail">
|
||||
<div class="rename">{{ itemc.name }}</div>
|
||||
<div class="rein">{{ itemc.re }}</div>
|
||||
<div class="rename">{{ itemc.createName }}</div>
|
||||
<div class="rein">{{ itemc.content }}</div>
|
||||
<div class="detre">
|
||||
<div class="day">{{ itemc.time }}</div>
|
||||
<div class="huifu">回复</div>
|
||||
<div class="good">
|
||||
<div class="day">{{ itemc.createTime }}</div>
|
||||
<div class="huifu" @click="commentComment(itemc)">
|
||||
回复
|
||||
</div>
|
||||
<div class="good" @click="commentLike(itemc)">
|
||||
<img
|
||||
v-if="itemc.praised"
|
||||
class="gimg"
|
||||
src="../../assets/image/discuss/elsedianzan1.png"
|
||||
/>
|
||||
<img
|
||||
v-else
|
||||
class="gimg"
|
||||
src="../../assets/image/discuss/elsedianzan.png"
|
||||
/>
|
||||
<div class="gcou">0</div>
|
||||
<div class="gcou">{{ itemc.praiseNum || 0 }}</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- <div class="line"></div> -->
|
||||
@@ -115,86 +154,281 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 重复上述 -->
|
||||
<div class="linee"></div>
|
||||
<div class="restorebox">
|
||||
<div class="restoremani">
|
||||
<div
|
||||
class="rescon clearfix"
|
||||
style="margin-bottom: 20px"
|
||||
v-for="(item, index) in restore"
|
||||
:key="index"
|
||||
>
|
||||
<div class="head">
|
||||
<div>
|
||||
<img class="headavator" :src="item.head" />
|
||||
</div>
|
||||
<div class="namehead">
|
||||
{{ item.name }}
|
||||
</div>
|
||||
</div>
|
||||
<div class="inner">
|
||||
<div class="recon">{{ item.re }}</div>
|
||||
<div class="botto">
|
||||
<div class="time">{{ item.time }}</div>
|
||||
<div class="re">回复</div>
|
||||
<div class="right">
|
||||
<div class="good">
|
||||
<img src="../../assets/image/discuss/elsedianzan.png" />
|
||||
</div>
|
||||
<div class="gocount">67</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 回复框 -->
|
||||
<!-- <div class="reply1" v-if="reply1Show">
|
||||
<el-input
|
||||
type="text"
|
||||
v-model="replayComment.content"
|
||||
resize="none"
|
||||
maxlength="100"
|
||||
:placeholder="replayComment.placeholder"
|
||||
style="width: calc(100% - 40px)"
|
||||
@blur="reply1Blur"
|
||||
:autofocus="autofocus"
|
||||
/>
|
||||
<img
|
||||
style="width: 28px; height: 28px; margin-left: 5px"
|
||||
src="../../assets/image/uploadImg2.png"
|
||||
/>
|
||||
</div> -->
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import { reactive, toRefs } from "vue";
|
||||
<script setup>
|
||||
import { reactive, ref } from "vue";
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import px from "@/assets/image/discuss/px.jpg";
|
||||
export default {
|
||||
name: "DiscussDetail",
|
||||
components: {
|
||||
ReturnHead,
|
||||
import { request, useRequest } from "@/api/request";
|
||||
import {
|
||||
PostDetails,
|
||||
COMMENT_LIST,
|
||||
DISCUSS_LIST,
|
||||
COMMENT_PRAISE,
|
||||
} from "@/api/api";
|
||||
import { useRoute, useRouter } from "vue-router/dist/vue-router";
|
||||
const {
|
||||
query: { id, type, postID, targetId },
|
||||
} = useRoute();
|
||||
const restore = ref([
|
||||
{
|
||||
name: "罗宗梅",
|
||||
time: "2022-09-01",
|
||||
re: "教师基本功扎实,知识讲解准确,教学设计合理,始终以学生为主体,自主学习,小组交流讨论,上台交流展示等形式,师生配合默契,取得了较好的学习效果。",
|
||||
head: px,
|
||||
reimg: px,
|
||||
},
|
||||
setup() {
|
||||
const state = reactive({
|
||||
restore: [
|
||||
{
|
||||
name: "罗宗梅",
|
||||
time: "2022-09-01",
|
||||
re: "教师基本功扎实,知识讲解准确,教学设计合理,始终以学生为主体,自主学习,小组交流讨论,上台交流展示等形式,师生配合默契,取得了较好的学习效果。",
|
||||
head: px,
|
||||
reimg: px,
|
||||
},
|
||||
],
|
||||
]);
|
||||
const newrestore = ref([
|
||||
{
|
||||
name: "赵雪梨",
|
||||
time: "3天前",
|
||||
re: "教学重难点突出,板书条理清晰。教学步骤设计合理由浅入深,循序渐进。",
|
||||
head: px,
|
||||
},
|
||||
]);
|
||||
const disDetail = ref({});
|
||||
const commontList = ref([]);
|
||||
const spreadReply = ref(-1);
|
||||
const hfPage = ref({
|
||||
currentPage: 1,
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
total: 0,
|
||||
});
|
||||
//获取讨论详情
|
||||
const discussInfo = ref("");
|
||||
request(DISCUSS_LIST, {
|
||||
type: type == 1 ? 2 : 1,
|
||||
id: targetId,
|
||||
})
|
||||
.then((e) => {
|
||||
console.log("讨论详情", e);
|
||||
discussInfo.value = e.data.discussDtoList[0].discussExplain;
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
|
||||
newrestore: [
|
||||
{
|
||||
name: "赵雪梨",
|
||||
time: "3天前",
|
||||
re: "教学重难点突出,板书条理清晰。教学步骤设计合理由浅入深,循序渐进。",
|
||||
head: px,
|
||||
},
|
||||
// {
|
||||
// name: "赵雪梨",
|
||||
// time: "三天前",
|
||||
// re: "教学重难点突出,板书条理清晰。教学步骤设计合理由浅入深,循序渐进。",
|
||||
// head: require("../../assets/image/discuss/px.jpg"),
|
||||
// },
|
||||
],
|
||||
// 获取数据
|
||||
const getData = () => {
|
||||
useRequest(PostDetails, { id: postID }, (e) => {
|
||||
console.log("disDetail", e);
|
||||
disDetail.value = e.data;
|
||||
console.log("查询帖子下的评论参数", {
|
||||
statementId: e.data.discussId,
|
||||
pageNo: 10,
|
||||
pageSize: 1,
|
||||
});
|
||||
|
||||
return {
|
||||
...toRefs(state),
|
||||
};
|
||||
},
|
||||
// 获取帖子下的评论
|
||||
request(COMMENT_LIST, {
|
||||
id: e.data.id,
|
||||
type: 1,
|
||||
pageNo: hfPage.value.currentPage,
|
||||
pageSize: 10,
|
||||
})
|
||||
.then((res) => {
|
||||
console.log("我是获取当前帖子的评论", res);
|
||||
commontList.value = res.data.records;
|
||||
hfPage.value.total = Number(res.data.total);
|
||||
clearText();
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
});
|
||||
};
|
||||
getData();
|
||||
|
||||
// 查看更多-展开回复列表
|
||||
function lookMore(i) {
|
||||
i == spreadReply.value ? (spreadReply.value = -1) : (spreadReply.value = i);
|
||||
}
|
||||
// 清空回复及评论输入框
|
||||
const clearText = () => {
|
||||
disComment.value.content = "";
|
||||
fileListComment.value = [];
|
||||
fileListCommentRelpay.value = [];
|
||||
replayComment.value.content = "";
|
||||
};
|
||||
|
||||
// 回复分页
|
||||
function handleCurrentChange(e, k) {
|
||||
console.log("分页打印", e, k);
|
||||
hfPage.value.currentPage = e;
|
||||
hfPage.value.pageNo = e;
|
||||
getData();
|
||||
}
|
||||
const commentSubmitFileList = ref([]);
|
||||
|
||||
const disComment = ref({
|
||||
content: "",
|
||||
});
|
||||
const replayComment = ref({
|
||||
placeholder: "",
|
||||
content: "",
|
||||
pid: "",
|
||||
});
|
||||
|
||||
// 评论图片展示数组
|
||||
const fileListComment = ref([]);
|
||||
// 回复图片展示数组
|
||||
const fileListCommentRelpay = ref([]);
|
||||
|
||||
// 上传图片成功返回的URL
|
||||
const uploadBack = (e) => {
|
||||
console.log("--------->", e);
|
||||
fileListComment.value.push(e);
|
||||
};
|
||||
|
||||
const uploadReplyBack = (e) => {
|
||||
console.log("--------->", e);
|
||||
fileListCommentRelpay.value.push(e);
|
||||
};
|
||||
|
||||
function removeImg(i) {
|
||||
fileListCommentRelpay.value.splice(i, 1);
|
||||
}
|
||||
|
||||
function removeCommentImg(i) {
|
||||
fileListComment.value.splice(i, 1);
|
||||
}
|
||||
|
||||
function like() {
|
||||
console.log(disDetail.value);
|
||||
disDetail.value.praised
|
||||
? (disDetail.value.praiseNum = Number(disDetail.value.praiseNum) - 1)
|
||||
: (disDetail.value.praiseNum = Number(disDetail.value.praiseNum) + 1);
|
||||
disDetail.value.praised = !disDetail.value.praised;
|
||||
request(PostPraise, { targetId: disDetail.value.id, type: 3 });
|
||||
}
|
||||
|
||||
function collection() {
|
||||
disDetail.value.collected
|
||||
? (disDetail.value.collectionNum =
|
||||
Number(disDetail.value.collectionNum) - 1)
|
||||
: (disDetail.value.collectionNum =
|
||||
Number(disDetail.value.collectionNum) + 1);
|
||||
disDetail.value.collected = !disDetail.value.collected;
|
||||
request(PostPraise, { targetId: disDetail.value.id, type: 4 });
|
||||
}
|
||||
|
||||
function commentLike(obj) {
|
||||
obj.praised
|
||||
? (obj.praiseNum = Number(obj.praiseNum) - 1)
|
||||
: (obj.praiseNum = Number(obj.praiseNum) + 1);
|
||||
obj.praised = !obj.praised;
|
||||
request(COMMENT_PRAISE, { targetId: obj.id, type: 1 });
|
||||
}
|
||||
|
||||
const reply1Show = ref(false);
|
||||
const autofocus = ref(false);
|
||||
function commentComment(obj) {
|
||||
reply1Show.value = true;
|
||||
// autofocus.value = true;
|
||||
replayComment.value.placeholder = "@ " + obj.createName;
|
||||
replayComment.value.pid = obj.id;
|
||||
if (document.getElementsByClassName("replyInp")[0]) {
|
||||
document
|
||||
.getElementsByClassName("replyInp")[0]
|
||||
.querySelector("input")
|
||||
.focus();
|
||||
}
|
||||
|
||||
console.log("获得焦点", document.getElementsByClassName("replyInp")[0]);
|
||||
}
|
||||
function reply1Blur() {
|
||||
reply1Show.value = false;
|
||||
// autofocus.value = false;
|
||||
console.log("失去焦点");
|
||||
// document.getElementsByClassName("replyInp")[0].querySelector("input").blur();
|
||||
}
|
||||
// function reply1Focus() {
|
||||
// reply1Show.value = true;
|
||||
// autofocus.value = true;
|
||||
// }
|
||||
|
||||
// 提交评论
|
||||
function submitComment() {
|
||||
console.log(disDetail.value, fileListComment.value);
|
||||
let imgFileUrl = [];
|
||||
for (let i = 0; i < fileListComment.value.length; i++) {
|
||||
imgFileUrl.push(fileListComment.value[i].url);
|
||||
}
|
||||
console.table("帖子评论参数", {
|
||||
id: disDetail.value.id,
|
||||
targetId: disDetail.value.id,
|
||||
content: disComment.value.content,
|
||||
type: 1,
|
||||
img: imgFileUrl.length !== 0 ? imgFileUrl.toString() : "",
|
||||
});
|
||||
|
||||
request(COMMENT_ADD, {
|
||||
targetId: disDetail.value.id,
|
||||
content: disComment.value.content,
|
||||
type: 1,
|
||||
img: imgFileUrl.length !== 0 ? imgFileUrl.toString() : "",
|
||||
})
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
getData();
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
}
|
||||
|
||||
// 回复评论
|
||||
function submitReplayComment() {
|
||||
let imgFileUrl = [];
|
||||
for (let i = 0; i < fileListCommentRelpay.value.length; i++) {
|
||||
imgFileUrl.push(fileListCommentRelpay.value[i].url);
|
||||
}
|
||||
|
||||
console.table("帖子回复评论参数", {
|
||||
id: disDetail.value.id,
|
||||
targetId: disDetail.value.id,
|
||||
content: replayComment.value.content,
|
||||
type: 1,
|
||||
pid: replayComment.value.pid,
|
||||
img: imgFileUrl.length !== 0 ? imgFileUrl.toString() : "",
|
||||
});
|
||||
|
||||
request(COMMENT_ADD, {
|
||||
targetId: disDetail.value.id,
|
||||
content: replayComment.value.content,
|
||||
type: 1,
|
||||
pid: replayComment.value.pid,
|
||||
img: imgFileUrl.length !== 0 ? imgFileUrl.toString() : "",
|
||||
})
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
getData();
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<!-- Add "scoped" attribute to limit CSS to this component only -->
|
||||
@@ -355,8 +589,10 @@ export default {
|
||||
.reshead {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
height: 50px;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
position: relative;
|
||||
height: 100px;
|
||||
.headn {
|
||||
width: 90%;
|
||||
display: flex;
|
||||
@@ -372,6 +608,13 @@ export default {
|
||||
line-height: 50px;
|
||||
}
|
||||
}
|
||||
.reply {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 90%;
|
||||
position: absolute;
|
||||
bottom: 15px;
|
||||
}
|
||||
}
|
||||
.linee {
|
||||
height: 0;
|
||||
@@ -381,7 +624,7 @@ export default {
|
||||
.restorebox {
|
||||
width: 100%;
|
||||
// height: 200px;
|
||||
|
||||
border-top: 1px solid #f1f2f3;
|
||||
border-radius: 4px;
|
||||
position: relative;
|
||||
display: flex;
|
||||
@@ -484,6 +727,7 @@ export default {
|
||||
}
|
||||
}
|
||||
.redetail {
|
||||
width: 100%;
|
||||
margin-left: 12.5px;
|
||||
.rename {
|
||||
color: #02172a;
|
||||
@@ -554,5 +798,13 @@ export default {
|
||||
}
|
||||
}
|
||||
}
|
||||
.reply1 {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 90%;
|
||||
margin-left: 5%;
|
||||
position: absolute;
|
||||
bottom: 100px;
|
||||
}
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,18 +1,22 @@
|
||||
<template>
|
||||
<div class="discusspage">
|
||||
<ReturnHead text="讨论详情" :ispublish="true"></ReturnHead>
|
||||
<ReturnHead
|
||||
text="讨论详情"
|
||||
:ispublish="true"
|
||||
:discussId="discussId"
|
||||
></ReturnHead>
|
||||
<div class="head clearfix">
|
||||
<div class="title">
|
||||
{{
|
||||
data && data.discussDtoList && data.discussDtoList.length !== 0
|
||||
? data?.discussDtoList[0].discussName
|
||||
info && info.discussDtoList && info.discussDtoList.length !== 0
|
||||
? info?.discussDtoList[0].discussName
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
<div class="title" style="margin-top: 0px">
|
||||
{{
|
||||
data && data.discussDtoList && data.discussDtoList.length !== 0
|
||||
? data?.discussDtoList[0].discussExplain
|
||||
info && info.discussDtoList && info.discussDtoList.length !== 0
|
||||
? info?.discussDtoList[0].discussExplain
|
||||
: "-"
|
||||
}}
|
||||
</div>
|
||||
@@ -24,15 +28,15 @@
|
||||
<div class="firstbtncontainer">
|
||||
<div class="inbtn">
|
||||
<button
|
||||
@click="changee"
|
||||
:class="onfo ? 'new samebtn' : 'samebtn hot'"
|
||||
@click="nowPost(info.discussDtoList[0].id)"
|
||||
:class="searchType === 1 ? 'new samebtn' : 'samebtn hot'"
|
||||
>
|
||||
最新
|
||||
</button>
|
||||
<div class="dd"></div>
|
||||
<button
|
||||
@click="changeee"
|
||||
:class="onfo ? 'samebtn hot' : 'new samebtn'"
|
||||
@click="hotPost(state.info.discussDtoList[0].id)"
|
||||
:class="searchType === 2 ? 'new samebtn' : 'samebtn hot'"
|
||||
>
|
||||
最热
|
||||
</button>
|
||||
@@ -40,53 +44,61 @@
|
||||
</div>
|
||||
|
||||
<div class="discusscontainer clearfix">
|
||||
<div class="item" v-for="(item, index) in discuss" :key="index">
|
||||
<div class="item" v-for="(item, index) in postList" :key="index">
|
||||
<div class="thinline"></div>
|
||||
<div class="coni">
|
||||
<div class="coni" @click="goDetails(item)">
|
||||
<div class="conin">
|
||||
<div class="tit">{{ item.title }}</div>
|
||||
<div class="inn">{{ item.contain }}</div>
|
||||
<div class="inn" v-html="item.content"></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="thinline"></div>
|
||||
<div class="bott">
|
||||
<div class="dicon">
|
||||
<div class="imgcont" @click="goDetails">
|
||||
<div class="imgcont" @click="goDetails(item)">
|
||||
<img
|
||||
class="imgs"
|
||||
src="../../assets/image/discuss/pinglun.png"
|
||||
/>
|
||||
<div class="samei" style="margin-top: 2px">
|
||||
{{ item.pinglun }}
|
||||
{{ item.commentNum || 0 }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="imgcont">
|
||||
<div class="imgcont" @click="like(item)">
|
||||
<img
|
||||
v-if="item.isGood"
|
||||
@click="getId(item)"
|
||||
v-if="item.praised"
|
||||
style="margin-left: 56px"
|
||||
class="imgs"
|
||||
src="../../assets/image/discuss/dianzan2.png"
|
||||
/>
|
||||
<img
|
||||
v-else
|
||||
@click="getId(item)"
|
||||
style="margin-left: 56px"
|
||||
class="imgs"
|
||||
src="../../assets/image/discuss/dianzan.png"
|
||||
/>
|
||||
<div
|
||||
:class="item.isGood ? 'sameii' : 'samei'"
|
||||
:class="item.praised ? 'sameii' : 'samei'"
|
||||
style="margin-top: 2px"
|
||||
>
|
||||
{{ item.dianzan }}
|
||||
{{ item.praiseNum || 0 }}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clickMoreBox" v-if="!noMore && total > 10">
|
||||
<div class="clickMore" @click="handleCurrentChange">
|
||||
点击加载更多~
|
||||
</div>
|
||||
</div>
|
||||
<div class="clickMoreBox" v-if="noMore">
|
||||
<div class="clickMore" style="color: rgba(95, 109, 117, 1)">
|
||||
已经到底啦~
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -106,124 +118,75 @@ import {
|
||||
COMMENT_PRAISE,
|
||||
DISCUSS_LIST,
|
||||
QueryDiscussSubmitDetailByDiscussId,
|
||||
PostList,
|
||||
PostPraise,
|
||||
} from "@/api/api";
|
||||
const router = useRouter();
|
||||
const state = reactive({
|
||||
onfo: true,
|
||||
discuss: [
|
||||
// {
|
||||
// id: 1,
|
||||
// title: "从营销角度分析:我的团队需要这些能力",
|
||||
// contain:
|
||||
// "所谓团队协作能力,是指建立在团队的基础之上,发挥团队精神、互补互助以达到团队最大工作效率的能力。对于团队的成员来说...",
|
||||
// pinglun: 317,
|
||||
// dianzan: 103,
|
||||
// isGood: false,
|
||||
// },
|
||||
],
|
||||
info: {},
|
||||
pageNo: 1,
|
||||
pageSize: 10,
|
||||
searchType: 1,
|
||||
postList: [], //帖子列表
|
||||
total: 0, // 帖子总条数
|
||||
currentPage: 1,
|
||||
content: 1,
|
||||
discussId: null,
|
||||
noMore: false,
|
||||
});
|
||||
const { onfo, discuss } = toRefs(state);
|
||||
const changee = () => {
|
||||
if (state.onfo !== true) {
|
||||
state.onfo = !state.onfo;
|
||||
}
|
||||
};
|
||||
const changeee = () => {
|
||||
if (state.onfo == true) {
|
||||
state.onfo = !state.onfo;
|
||||
}
|
||||
};
|
||||
const getId = (it) => {
|
||||
it.isGood = !it.isGood;
|
||||
if (it.isGood) {
|
||||
it.dianzan++;
|
||||
} else {
|
||||
it.dianzan--;
|
||||
}
|
||||
// console.log(it.isGood);
|
||||
};
|
||||
const {
|
||||
onfo,
|
||||
discuss,
|
||||
info,
|
||||
pageNo,
|
||||
pageSize,
|
||||
searchType,
|
||||
postList, //帖子列表
|
||||
total, // 帖子总条数
|
||||
currentPage,
|
||||
content,
|
||||
discussId,
|
||||
noMore,
|
||||
} = toRefs(state);
|
||||
|
||||
//获取讨论详情
|
||||
const {
|
||||
query: { id, type },
|
||||
} = useRoute();
|
||||
const { data } = useRequest(DISCUSS_LIST, { id, type });
|
||||
console.log("获取讨论", data);
|
||||
request(DISCUSS_LIST, {
|
||||
type: type == 1 ? 2 : 1,
|
||||
id,
|
||||
})
|
||||
.then((e) => {
|
||||
state.info = e.data;
|
||||
console.log("讨论详情", state.info);
|
||||
state.discussId = e.data.discussDtoList[0].id;
|
||||
getPostList(e.data.discussDtoList[0].id);
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
// 获取帖子
|
||||
function getPostList(discussId) {
|
||||
console.log({
|
||||
discussId: discussId,
|
||||
pageNo: state.pageNo,
|
||||
pageSize: state.pageSize,
|
||||
searchType: state.searchType,
|
||||
console.log("获取帖子参数", {
|
||||
pid: discussId,
|
||||
current: state.pageNo,
|
||||
order: 1,
|
||||
});
|
||||
|
||||
request(QueryDiscussSubmitDetailByDiscussId, {
|
||||
discussId: discussId,
|
||||
pageNo: state.pageNo,
|
||||
pageSize: state.pageSize,
|
||||
searchType: state.searchType,
|
||||
request(PostList, {
|
||||
pid: discussId,
|
||||
current: state.pageNo,
|
||||
order: state.content,
|
||||
})
|
||||
.then((e) => {
|
||||
console.log("我是当前讨论下的帖子", e);
|
||||
state.postList = e.data.rows;
|
||||
state.total = e.data.total;
|
||||
|
||||
// 添加一条假的数据 供测试使用
|
||||
state.postList = [
|
||||
{
|
||||
createTime: "",
|
||||
createUser: 0,
|
||||
discussCollectionCount: "234",
|
||||
discussId: "",
|
||||
discussLikeCount: "3576",
|
||||
discussReviewCount: "12353",
|
||||
discussSubmitContent:
|
||||
"帖子的内容----帖子的内容帖子的内容帖子的内容帖子的内容帖子的内容帖子的内容帖子的内容帖子的内容帖子的内容",
|
||||
discussSubmitId: "",
|
||||
discussSubmitPictureAddress: "",
|
||||
discussSubmitTitle: "我是一个用来测试的帖子标题",
|
||||
stuId: "",
|
||||
stuName: "",
|
||||
updateTime: "",
|
||||
updateUser: 0,
|
||||
|
||||
submitReviewVoList: [
|
||||
{
|
||||
createTime: "",
|
||||
createUser: 0,
|
||||
discussLikeCount: "",
|
||||
discussReviewContent: "",
|
||||
discussReviewFlag: "",
|
||||
discussReviewId: "",
|
||||
discussReviewPictureAddress: "",
|
||||
discussSubmitId: "",
|
||||
stuId: "",
|
||||
stuName: "",
|
||||
submitReplyVoList: [
|
||||
{
|
||||
createTime: "",
|
||||
createUser: 0,
|
||||
discussReplyId: 0,
|
||||
discussReviewId: "",
|
||||
replyContent: "",
|
||||
replyFlag: "",
|
||||
replyPictureAddress: "",
|
||||
reviewStuId: "",
|
||||
reviewStuName: "",
|
||||
stuId: "",
|
||||
stuName: "",
|
||||
updateTime: "",
|
||||
updateUser: 0,
|
||||
},
|
||||
],
|
||||
updateTime: "",
|
||||
updateUser: 0,
|
||||
},
|
||||
],
|
||||
},
|
||||
];
|
||||
state.total = 100;
|
||||
state.postList = state.postList.concat(e.data.records);
|
||||
state.total = Number(e.data.total);
|
||||
if (e.data.records.length === 0) {
|
||||
state.noMore = true;
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
@@ -232,28 +195,63 @@ function getPostList(discussId) {
|
||||
|
||||
// 最新
|
||||
function nowPost(discussId) {
|
||||
state.content = 1;
|
||||
state.searchType = 1;
|
||||
state.pageNo = 1;
|
||||
state.currentPage = 1;
|
||||
state.postList = [];
|
||||
state.noMore = false;
|
||||
getPostList(discussId);
|
||||
}
|
||||
// 最热
|
||||
function hotPost(discussId) {
|
||||
state.content = 2;
|
||||
state.searchType = 2;
|
||||
state.pageNo = 1;
|
||||
state.currentPage = 1;
|
||||
state.postList = [];
|
||||
state.noMore = false;
|
||||
getPostList(discussId);
|
||||
}
|
||||
|
||||
//跳转到讨论详情
|
||||
const goDetails = () => {
|
||||
const goDetails = (item) => {
|
||||
console.log("item", item);
|
||||
router.push({
|
||||
path: "/discussdetail",
|
||||
// query: {
|
||||
// courseId: props.courseId,
|
||||
// },
|
||||
query: {
|
||||
targetId: id,
|
||||
id: item.discussId,
|
||||
type,
|
||||
postID: item.id,
|
||||
postName: state.info.discussDtoList[0].discussName,
|
||||
},
|
||||
});
|
||||
};
|
||||
// 帖子点赞
|
||||
function like(d) {
|
||||
console.log("点击参数", d);
|
||||
d.praised
|
||||
? (d.praiseNum = Number(d.praiseNum) - 1)
|
||||
: (d.praiseNum = Number(d.praiseNum) + 1);
|
||||
d.praised = !d.praised;
|
||||
console.log("我是点赞传递的参数", { targetId: d.id, type: 2 });
|
||||
request(PostPraise, { targetId: d.id, type: 3 })
|
||||
.then((res) => {
|
||||
console.log("我是点赞的操作", res);
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
}
|
||||
|
||||
// 分页
|
||||
function handleCurrentChange(e, k) {
|
||||
console.log("分页打印", e, k);
|
||||
state.currentPage = state.currentPage + 1;
|
||||
state.pageNo = state.pageNo + 1;
|
||||
getPostList(state.info.discussDtoList[0].id);
|
||||
}
|
||||
</script>
|
||||
|
||||
<!-- Add "scoped" attribute to limit CSS to this component only -->
|
||||
@@ -298,7 +296,7 @@ const goDetails = () => {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
.previewmani {
|
||||
// width: 90%;
|
||||
width: 100%;
|
||||
margin-top: 17px;
|
||||
.firstbtncontainer {
|
||||
width: 100%;
|
||||
@@ -374,7 +372,7 @@ const goDetails = () => {
|
||||
width: 100%;
|
||||
|
||||
.item {
|
||||
// width: 90%;
|
||||
width: 90%;
|
||||
// position:relative;
|
||||
|
||||
.thinline {
|
||||
@@ -443,6 +441,16 @@ const goDetails = () => {
|
||||
}
|
||||
}
|
||||
}
|
||||
.clickMoreBox {
|
||||
width: 100%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 14px;
|
||||
font-weight: 400;
|
||||
color: #2478ff;
|
||||
padding-bottom: 20px;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
text="发讨论"
|
||||
:showpublish="true"
|
||||
:publishWork="publishWork"
|
||||
v-model:postAdd="postAdd"
|
||||
></ReturnHead>
|
||||
<div
|
||||
class="discussupload"
|
||||
@@ -17,7 +18,7 @@
|
||||
type="text"
|
||||
id="input_title"
|
||||
placeholder="请输入标题"
|
||||
v-model:value="disTitle"
|
||||
v-model="titleName"
|
||||
/>
|
||||
</div>
|
||||
<div class="discusscontent">
|
||||
@@ -59,18 +60,35 @@
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { reactive, ref, toRefs, shallowRef, onBeforeUnmount } from "vue";
|
||||
import {
|
||||
reactive,
|
||||
ref,
|
||||
toRefs,
|
||||
shallowRef,
|
||||
onBeforeUnmount,
|
||||
computed,
|
||||
} from "vue";
|
||||
import { request, useRequest } from "@/api/request";
|
||||
import ReturnHead from "@/components/ReturnHead.vue";
|
||||
import "@wangeditor/editor/dist/css/style.css";
|
||||
import { Editor, Toolbar } from "@wangeditor/editor-for-vue";
|
||||
import { fileUp, videoUp } from "../../api/request";
|
||||
import { PostAdd } from "@/api/api";
|
||||
import { ElLoading } from "element-plus";
|
||||
import { useRouter, useRoute } from "vue-router";
|
||||
import store from "@/store";
|
||||
import { ElMessage } from "element-plus";
|
||||
const router = useRouter();
|
||||
const {
|
||||
query: { discussId },
|
||||
} = useRoute();
|
||||
const state = reactive({
|
||||
text: "",
|
||||
textarea: "",
|
||||
screenHeight: document.body.clientHeight, // 屏幕高度
|
||||
disTitle: null,
|
||||
});
|
||||
const userInfo = computed(() => store.state.userInfo);
|
||||
// 使用
|
||||
const loading = ref(false); // loading
|
||||
const openLoading = () => {
|
||||
@@ -93,7 +111,7 @@ const editorRef = shallowRef();
|
||||
|
||||
// 内容 HTML
|
||||
const valueHtml = ref("");
|
||||
|
||||
const titleName = ref("");
|
||||
const toolbarConfig = {
|
||||
excludeKeys: ["insertVideo", "uploadVideo", "insertImage", "group-video"],
|
||||
};
|
||||
@@ -142,6 +160,41 @@ onBeforeUnmount(() => {
|
||||
if (editor == null) return;
|
||||
editor.destroy();
|
||||
});
|
||||
|
||||
// 发表帖子发布操作
|
||||
const postAdd = () => {
|
||||
console.log("用户信息", userInfo.value);
|
||||
let obj = {
|
||||
collectionNum: 0,
|
||||
commentNum: 0,
|
||||
content: valueHtml.value,
|
||||
ctime: "",
|
||||
discussId: discussId,
|
||||
id: 0,
|
||||
mtime: "",
|
||||
praiseNum: 0,
|
||||
status: 0,
|
||||
title: titleName.value,
|
||||
userAvatar: userInfo.value.avatar,
|
||||
userId: userInfo.value.id,
|
||||
userJobName: userInfo.value.jobName,
|
||||
userName: userInfo.value.realName,
|
||||
userOrgName: userInfo.value.orgName,
|
||||
};
|
||||
console.log("发表帖子传递的参数", obj);
|
||||
request(PostAdd, obj)
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
if (res.code == 200) {
|
||||
ElMessage.success("发帖成功");
|
||||
titleName.value = "";
|
||||
valueHtml.value = "";
|
||||
}
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss">
|
||||
|
||||
@@ -81,14 +81,13 @@ console.log("外链信息", data);
|
||||
const userInfo = computed(() => store.state.userInfo);
|
||||
const goOuterChain = () => {
|
||||
console.log("userInfo", userInfo);
|
||||
status != 1 &&
|
||||
request(STUDY_RECORD, {
|
||||
studentId: userInfo.value.id,
|
||||
targetId: infoId,
|
||||
logo: type,
|
||||
stageOrChapterId: chapterOrStageId,
|
||||
taskId: taskId,
|
||||
});
|
||||
request(STUDY_RECORD, {
|
||||
studentId: userInfo.value.id,
|
||||
targetId: infoId,
|
||||
logo: type,
|
||||
stageOrChapterId: chapterOrStageId,
|
||||
taskId: taskId,
|
||||
});
|
||||
|
||||
window.open(data.value.linkAddress, "_top");
|
||||
};
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-19 11:28:11
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-02-19 21:02:52
|
||||
* @LastEditTime: 2023-02-20 10:45:25
|
||||
* @FilePath: /stu_h5/src/views/projectdetails/ProjectPath.vue
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
-->
|
||||
@@ -181,7 +181,7 @@ const handleClick = (tab, event) => {
|
||||
const goDetails = () => {
|
||||
router.push({
|
||||
path: "/pathdetails",
|
||||
query: { routerId: 397 },
|
||||
query: { routerId: 404 },
|
||||
});
|
||||
// router.push({
|
||||
// path: "/projectdetails",
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* @Author: lixg lixg@dongwu-inc.com
|
||||
* @Date: 2023-01-13 11:42:48
|
||||
* @LastEditors: lixg lixg@dongwu-inc.com
|
||||
* @LastEditTime: 2023-02-19 12:16:34
|
||||
* @LastEditTime: 2023-02-20 11:20:13
|
||||
* @FilePath: /stu_h5/vite.config.js
|
||||
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
|
||||
*/
|
||||
@@ -113,6 +113,50 @@ export default defineConfig(({ command, mode }) =>
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
},
|
||||
'/statement/add': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/collection': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/delete': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/praise': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/update': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/list': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/stu/externalExam/submitExternalExam': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/comment/list': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/comment/add': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/comment/praise': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/comment/collection': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/info': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/getComments': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
}, '/statement/getMoreComments': {
|
||||
target: loadEnv(mode, process.cwd()).VITE_PROXY_URL,
|
||||
changeOrigin: true,
|
||||
},
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user