tijiao
This commit is contained in:
@@ -1449,4 +1449,12 @@ wmath {
|
||||
.ML__keyboard {
|
||||
z-index: 99999 !important;
|
||||
position: fixed !important;
|
||||
}
|
||||
}
|
||||
.sticky-header {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 1000; /* 保证在上层 */
|
||||
background-color: transparent;
|
||||
/* padding: 10px; */
|
||||
box-shadow: 0 2px 2px rgba(221, 221, 221, 0.2);
|
||||
}
|
||||
@@ -7,6 +7,8 @@
|
||||
</el-breadcrumb-item>
|
||||
</el-breadcrumb>
|
||||
</div> -->
|
||||
|
||||
|
||||
<div class="tab_all">
|
||||
<!-- 正在处理 -->
|
||||
<p @click="tabIndex(1)" :class="activeIndex == 1 ? 'tab_Normal tab_Select' : 'tab_Normal'">Edit</p>
|
||||
@@ -25,6 +27,7 @@
|
||||
<!-- <p @click="tabIndex(4)" :class="activeIndex == 4 ? 'tab_Normal tab_Select' : 'tab_Normal'">Investigte and
|
||||
Retrace</p> -->
|
||||
<br clear="both" />
|
||||
|
||||
</div>
|
||||
<div class="container" style="padding: 20px 15px">
|
||||
|
||||
@@ -153,6 +156,7 @@ export default {
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
|
||||
.tab_all {
|
||||
border-bottom: 1px solid #ddd;
|
||||
}
|
||||
@@ -182,4 +186,7 @@ export default {
|
||||
|
||||
.tab_Select:hover {
|
||||
}
|
||||
.sticky-header{
|
||||
background-color: #fafafa;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -51,6 +51,7 @@
|
||||
<el-input v-model="query.sn" placeholder="SN" style="width: 250px; margin-right: 10px"></el-input>
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleSearch" style="margin: 0 0 10px 0">Search </el-button>
|
||||
</div>
|
||||
|
||||
<div v-if="!PreAcpVisible">
|
||||
<div v-for="(item, ikgn) in tableData">
|
||||
<p
|
||||
@@ -156,7 +157,7 @@
|
||||
<b @click="corrSpe(item)" class="btnCliArt" style="margin-left: 20px; white-space: nowrap">
|
||||
<i class="el-icon-paperclip"></i> Author's previous articles
|
||||
</b>
|
||||
<el-button
|
||||
<el-button
|
||||
:type="item.state == 0 ? 'primary' : 'info'"
|
||||
plain
|
||||
size="mini"
|
||||
@@ -953,7 +954,7 @@
|
||||
</el-form-item>
|
||||
<el-form-item label="Content :">
|
||||
<!-- <commonRemarkList :list="remark.contentList" @load="(e) => (this.remark.contentList = e)"></commonRemarkList> -->
|
||||
<el-input type="textarea" rows="5" v-model="remark.content" ></el-input>
|
||||
<el-input type="textarea" rows="5" v-model="remark.content"></el-input>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
@@ -1357,7 +1358,11 @@
|
||||
<el-button type="primary" @click="isShowAI = false">Close</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<el-dialog :title="majorMes.disabled ? 'Research areas' : 'Edit Research areas'" :visible.sync="majorBox" width="800px">
|
||||
<el-dialog
|
||||
:title="majorMes.disabled ? 'Article Research areas' : 'Edit Article Research areas'"
|
||||
:visible.sync="majorBox"
|
||||
width="800px"
|
||||
>
|
||||
<el-form ref="remark" :model="majorMes" label-width="120px">
|
||||
<el-form-item label="Title :">
|
||||
<p style="line-height: 20px">
|
||||
@@ -1444,9 +1449,7 @@ export default {
|
||||
// {
|
||||
// state: 7
|
||||
// },
|
||||
{
|
||||
state: 7
|
||||
},
|
||||
|
||||
{
|
||||
state: 6
|
||||
},
|
||||
@@ -1562,6 +1565,22 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
saveMajor() {
|
||||
this.$api
|
||||
.post('api/Reviewer/updateUserField', {
|
||||
article_id: this.majorMes.article_id,
|
||||
user_field: this.majorValueList.map((item) => item.selectedValue[item.selectedValue.length - 1]).toString(',')
|
||||
})
|
||||
.then((res) => {
|
||||
if (res.status == 1) {
|
||||
this.$message.success('Success');
|
||||
|
||||
this.fetchMajorData(this.majorMes.article_id);
|
||||
} else {
|
||||
this.$message.error(res.msg);
|
||||
}
|
||||
});
|
||||
},
|
||||
async fetchMajorData(article_id) {
|
||||
// if (!this.majorData[userId]) {
|
||||
// 判断是否已经加载过该用户的数据
|
||||
@@ -1573,8 +1592,8 @@ export default {
|
||||
// 修改标记
|
||||
async getMajorData(article_id) {
|
||||
try {
|
||||
const res = await this.$api.post('api/Article/getArticleDetail', { articleId: article_id, human: 'editor' });
|
||||
if (res.article&&res.article.majors.length>0) {
|
||||
const res = await this.$api.post('api/Article/getArticleDetail', { articleId: article_id, human: 'editor' });
|
||||
if (res.article && res.article.majors.length > 0) {
|
||||
return res.article.majors; // 返回数据
|
||||
} else {
|
||||
return []; // 如果没有数据,返回空数组
|
||||
@@ -1589,11 +1608,11 @@ export default {
|
||||
// this.majorMes.realname = e.realname;
|
||||
// this.majorMes.user_id = e.user_id;
|
||||
this.majorMes.title = e.title;
|
||||
this.majorMes.article_id = e.article_id;
|
||||
|
||||
this.$api
|
||||
.post('api/Article/getArticleDetail', {
|
||||
articleId: e.article_id,
|
||||
human: 'editor'
|
||||
.post('api/Article/getArticleField', {
|
||||
article_id: e.article_id
|
||||
})
|
||||
.then((res) => {
|
||||
if (this.majorMes.disabled) {
|
||||
@@ -2786,9 +2805,7 @@ export default {
|
||||
position: relative;
|
||||
}
|
||||
.mangu_list:hover {
|
||||
|
||||
border: 1px solid #0077b8e6;
|
||||
|
||||
}
|
||||
|
||||
.mangu_list:nth-child(2n + 1) {
|
||||
@@ -3099,6 +3116,6 @@ export default {
|
||||
border-top: none !important;
|
||||
}
|
||||
.mangu_list div.fi_new div > div:nth-child(1) {
|
||||
margin-top: 0px;
|
||||
margin-top: 0px;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
</div>
|
||||
<el-table
|
||||
:data="tableData"
|
||||
|
||||
stripe
|
||||
size="mini"
|
||||
class="table"
|
||||
@@ -61,7 +62,7 @@
|
||||
{{ scope.row.field }}
|
||||
</p>
|
||||
|
||||
<p class="tab_tie_col">
|
||||
<p class="tab_tie_col" v-if="scope.row.company">
|
||||
<span>Company: </span>
|
||||
{{ scope.row.company }}
|
||||
</p>
|
||||
@@ -138,7 +139,7 @@
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<span slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="AddSuggest = false">Cancel</el-button>
|
||||
<el-button @click="AddSuggest = false">Cancel</el-button>
|
||||
</span>
|
||||
</el-dialog>
|
||||
<el-dialog
|
||||
|
||||
@@ -23,13 +23,23 @@
|
||||
header-cell-class-name="table-header"
|
||||
empty-text="New messages (0)"
|
||||
>
|
||||
<el-table-column width="300" label="Base Information">
|
||||
<el-table-column width="360" label="Base Information">
|
||||
<template slot-scope="scope">
|
||||
<p class="tab_tie_col">
|
||||
<span>Realname: </span><b style="font-size: 14px">{{ scope.row.realname }}</b>
|
||||
<span>Realname: </span><b style="font-size: 14px">{{ scope.row.realname }}</b><el-button
|
||||
|
||||
size="mini"
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-tickets"
|
||||
@click="openDetail(scope.row)"
|
||||
style="margin-left: 10px;padding:4px;float: right;"
|
||||
>Detail</el-button
|
||||
>
|
||||
</p>
|
||||
<p class="tab_tie_col"><span>Account: </span>{{ scope.row.account }}</p>
|
||||
<p class="tab_tie_col"><span>Email: </span>{{ scope.row.email }}</p>
|
||||
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="Other Information">
|
||||
@@ -39,6 +49,16 @@
|
||||
<!-- <p class="tab_tie_col" v-if="scope.row.majorstr != ''"><span>Major: </span>{{ scope.row.majorstr }}</p> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="Research areas" width="300">
|
||||
<template slot-scope="scope">
|
||||
<commonMajorTableList
|
||||
:user_id="scope.row.user_id"
|
||||
:baseInfo="scope.row"
|
||||
:key="scope.row.user_id"
|
||||
:disabled="true"
|
||||
></commonMajorTableList>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="rs_num" label="Review Record" width="180">
|
||||
<template slot-scope="scope">
|
||||
Major review: {{ scope.row.major_times }} ({{ scope.row.major_rate }}%)
|
||||
@@ -48,7 +68,7 @@
|
||||
<!-- <font style="margin-left: 5px">(Reviewing:{{ scope.row.now }})</font> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="rs_num" label="Reviewed Times" width="160">
|
||||
<el-table-column prop="rs_num" label="Reviewed Times" width="140">
|
||||
<template slot-scope="scope">
|
||||
Total: {{ scope.row.rs_num }}
|
||||
<br />
|
||||
@@ -66,9 +86,9 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
<!-- <el-table-column prop="rd_num" label="Fail number" width="140"></el-table-column> -->
|
||||
<el-table-column label="" width="200" align="center">
|
||||
<el-table-column label="" width="120" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="success" plain icon="el-icon-tickets" @click="openDetail(scope.row)">Detail</el-button>
|
||||
<!-- <el-button size="mini" type="success" plain icon="el-icon-tickets" @click="openDetail(scope.row)">Detail</el-button> -->
|
||||
<el-button size="mini" type="primary" plain icon="el-icon-check" @click="openSelect(scope.row)"> Select</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
@@ -87,7 +107,12 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
export default {
|
||||
import commonMajorTableList from '../page/components/major/tableList.vue';
|
||||
|
||||
export default {components: {
|
||||
|
||||
commonMajorTableList
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
messform: {
|
||||
|
||||
@@ -1,24 +1,27 @@
|
||||
<template>
|
||||
<div>
|
||||
<div class="crumbs">
|
||||
<el-breadcrumb separator="/">
|
||||
<el-page-header @back="goBack" content="Add manuscript reviewer">
|
||||
</el-page-header>
|
||||
<!-- <el-breadcrumb separator="/">
|
||||
<el-breadcrumb-item> <i class="el-icon-lx-calendar"></i> Add manuscript reviewer</el-breadcrumb-item>
|
||||
</el-breadcrumb>
|
||||
</el-breadcrumb> -->
|
||||
</div>
|
||||
<div
|
||||
class="container"
|
||||
class="container" style="padding: 20px;"
|
||||
v-loading="loading"
|
||||
element-loading-text="Loading..."
|
||||
element-loading-spinner="el-icon-loading"
|
||||
element-loading-background="rgba(255, 255, 255, 0.8)"
|
||||
|
||||
>
|
||||
>
|
||||
<span
|
||||
style="float: right; display: flex; align-items: center; color: #6843ff; font-weight: bold"
|
||||
@click="isSelectAI = !isSelectAI"
|
||||
> <el-checkbox v-model="isSelectAI"></el-checkbox><img src="@/assets/img/ai.png" style="width: 30px; height: 30px; margin-left: 10px" /> </span
|
||||
>
|
||||
|
||||
<el-checkbox v-model="isSelectAI"></el-checkbox
|
||||
><img src="@/assets/img/ai.png" style="width: 30px; height: 30px; margin-left: 10px" />
|
||||
</span>
|
||||
|
||||
<!-- <el-select v-model="messform.major_a" placeholder="Please select major" @change="majorChange(1)"
|
||||
style="width: 200px;margin: 0 10px 0 0;">
|
||||
<el-option :key="0" label="All major" :value="0"></el-option>
|
||||
@@ -38,33 +41,32 @@
|
||||
<el-option v-for="item in majors_c" :key="item.major_id" :label="item.major_title"
|
||||
:value="item.major_id"></el-option>
|
||||
</el-select> -->
|
||||
|
||||
|
||||
|
||||
<div v-if="!isSelectAI"><span style="font-size: 14px; color: #606266; margin: 0 10px 0 0">Research direction :</span>
|
||||
<div v-if="!isSelectAI">
|
||||
<span style="font-size: 14px; color: #606266; margin: 0 10px 0 0">Research direction :</span>
|
||||
<el-cascader
|
||||
placeholder="Please select major"
|
||||
v-model="selectFileds"
|
||||
style="width: 300px; margin-right: 10px"
|
||||
@change="fieldChange"
|
||||
:options="allFileds"
|
||||
:props="fieldsProps"
|
||||
collapse-tags
|
||||
clearable
|
||||
></el-cascader>
|
||||
<el-input
|
||||
v-model="messform.email"
|
||||
clearable
|
||||
placeholder="Please enter email"
|
||||
style="width: 190px; display: inline-block; margin: 0 10px 20px 0"
|
||||
></el-input>
|
||||
<el-input
|
||||
v-model="messform.field"
|
||||
clearable
|
||||
placeholder="Please enter field"
|
||||
style="width: 190px; display: inline-block; margin: 0 10px 20px 0"
|
||||
></el-input>
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleSearch">Search</el-button>
|
||||
placeholder="Please select major"
|
||||
v-model="selectFileds"
|
||||
style="width: 300px; margin-right: 10px"
|
||||
@change="fieldChange"
|
||||
:options="allFileds"
|
||||
:props="fieldsProps"
|
||||
collapse-tags
|
||||
clearable
|
||||
></el-cascader>
|
||||
<el-input
|
||||
v-model="messform.email"
|
||||
clearable
|
||||
placeholder="Please enter email"
|
||||
style="width: 190px; display: inline-block; margin: 0 10px 20px 0"
|
||||
></el-input>
|
||||
<el-input
|
||||
v-model="messform.field"
|
||||
clearable
|
||||
placeholder="Please enter field"
|
||||
style="width: 190px; display: inline-block; margin: 0 10px 20px 0"
|
||||
></el-input>
|
||||
<el-button type="primary" icon="el-icon-search" @click="handleSearch">Search</el-button>
|
||||
<el-table
|
||||
:data="revTable"
|
||||
border
|
||||
@@ -74,10 +76,21 @@
|
||||
header-cell-class-name="table-header"
|
||||
empty-text="New messages (0)"
|
||||
>
|
||||
<el-table-column width="300" label="Base Information">
|
||||
<el-table-column width="360" label="Base Information">
|
||||
<template slot-scope="scope">
|
||||
<p class="tab_tie_col">
|
||||
<span>Realname: </span><b style="font-size: 14px">{{ scope.row.realname }}</b>
|
||||
|
||||
<el-button
|
||||
|
||||
size="mini"
|
||||
type="success"
|
||||
plain
|
||||
icon="el-icon-tickets"
|
||||
@click="openDetail(scope.row)"
|
||||
style="margin-left: 10px;padding:4px;float: right;"
|
||||
>Detail</el-button
|
||||
>
|
||||
</p>
|
||||
<p class="tab_tie_col"><span>Account: </span>{{ scope.row.account }}</p>
|
||||
<p class="tab_tie_col"><span>Email: </span>{{ scope.row.email }}</p>
|
||||
@@ -87,7 +100,17 @@
|
||||
<template slot-scope="scope">
|
||||
<p class="tab_tie_col" v-if="scope.row.company != ''"><span>Affiliation: </span>{{ scope.row.company }}</p>
|
||||
<p class="tab_tie_col" v-if="scope.row.field != ''"><span>Field: </span>{{ scope.row.field }}</p>
|
||||
<p class="tab_tie_col" v-if="scope.row.majorstr != ''"><span>Major: </span>{{ scope.row.majorstr }}</p>
|
||||
<!-- <p class="tab_tie_col" v-if="scope.row.majorstr != ''"><span>Major: </span>{{ scope.row.majorstr }}</p> -->
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="Research areas" width="300">
|
||||
<template slot-scope="scope">
|
||||
<commonMajorTableList
|
||||
:user_id="scope.row.reviewer_id"
|
||||
:baseInfo="scope.row"
|
||||
:key="scope.row.reviewer_id"
|
||||
:disabled="true"
|
||||
></commonMajorTableList>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="rs_num" label="Reviewed Times" width="160">
|
||||
@@ -96,15 +119,22 @@
|
||||
<font style="margin-left: 5px">(Reviewing:{{ scope.row.now }})</font>
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
<!-- <el-table-column prop="rd_num" label="Fail number" width="140"></el-table-column> -->
|
||||
<el-table-column label="" width="200" align="center">
|
||||
<el-table-column label="" width="120" align="center">
|
||||
<template slot-scope="scope">
|
||||
<el-button size="mini" type="success" plain icon="el-icon-tickets" @click="openDetail(scope.row)"
|
||||
>Detail</el-button
|
||||
>
|
||||
<el-button size="mini" type="primary" plain icon="el-icon-check" @click="openSelect(scope.row)">
|
||||
Select</el-button
|
||||
>
|
||||
<div style="display: flex; align-items: center; flex-wrap: wrap; flex-direction: column">
|
||||
<el-button
|
||||
style="margin-bottom: 10px"
|
||||
size="mini"
|
||||
type="primary"
|
||||
plain
|
||||
icon="el-icon-check"
|
||||
@click="openSelect(scope.row)"
|
||||
>Select</el-button
|
||||
>
|
||||
|
||||
</div>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -120,7 +150,7 @@
|
||||
</div>
|
||||
</div>
|
||||
<div v-if="isSelectAI">
|
||||
<commonAI @openSelect="openSelect" @openDetail="openDetail" @loading="(status)=>loading=status"></commonAI>
|
||||
<commonAI @openSelect="openSelect" @openDetail="openDetail" @loading="(status) => (loading = status)"></commonAI>
|
||||
</div>
|
||||
</div>
|
||||
<el-dialog
|
||||
@@ -145,8 +175,11 @@
|
||||
<el-form-item label="Affiliation :">
|
||||
<span>{{ mesOpen.company }}</span>
|
||||
</el-form-item>
|
||||
<el-form-item label="Major :">
|
||||
<span>{{ mesOpen.major_title }}</span>
|
||||
<el-form-item label="Research areas :">
|
||||
<p v-for="(v, i) in majorData" >
|
||||
<span style="font-weight: bold">{{ i + 1 }}.</span>
|
||||
{{ v.major_title.replace('Medicine >', '').trim() }}
|
||||
</p>
|
||||
</el-form-item>
|
||||
<el-form-item label="Field :">
|
||||
<span>{{ mesOpen.field }}</span>
|
||||
@@ -164,9 +197,11 @@
|
||||
|
||||
<script>
|
||||
import commonAI from './articleReviewerAIAdd.vue';
|
||||
import commonMajorTableList from '../page/components/major/tableList.vue';
|
||||
export default {
|
||||
components: {
|
||||
commonAI
|
||||
commonAI,
|
||||
commonMajorTableList
|
||||
},
|
||||
data() {
|
||||
return {
|
||||
@@ -208,6 +243,16 @@ export default {
|
||||
},
|
||||
computed: {},
|
||||
methods: {
|
||||
goBack() {
|
||||
this.$router.push({
|
||||
path: 'articleReviewer',
|
||||
query: {
|
||||
id: this.$route.query.id
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
},
|
||||
fieldChange(e) {
|
||||
this.messform.major_id = this.selectFileds[this.selectFileds.length - 1];
|
||||
},
|
||||
@@ -246,11 +291,35 @@ export default {
|
||||
// console.log(this.messform)
|
||||
this.getDate();
|
||||
},
|
||||
|
||||
async fetchMajorData(userId) {
|
||||
// if (!this.majorData[userId]) {
|
||||
// 判断是否已经加载过该用户的数据
|
||||
this.majorData = await this.getMajorData(userId);
|
||||
console.log('this.majorData at line 279:', this.majorData)
|
||||
this.$forceUpdate();
|
||||
// }
|
||||
},
|
||||
// 修改标记
|
||||
async getMajorData(userId) {
|
||||
try {
|
||||
const res = await this.$api.post('api/Reviewer/getUserField', { user_id: userId });
|
||||
this.loading = false; // 开始加载数据
|
||||
if (res.status === 1) {
|
||||
return res.data; // 返回数据
|
||||
} else {
|
||||
return []; // 如果没有数据,返回空数组
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('Error fetching data:', error);
|
||||
return []; // 如果发生错误,返回空数组
|
||||
}
|
||||
},
|
||||
// 审稿人详情
|
||||
openDetail(row) {
|
||||
this.mesOpen={}
|
||||
this.mesOpen = {};
|
||||
this.mesOpenVisble = true;
|
||||
this.majorData=[]
|
||||
|
||||
this.$api
|
||||
.post('api/Article/getReviewerdetail', {
|
||||
uid: row.user_id
|
||||
@@ -260,7 +329,7 @@ export default {
|
||||
})
|
||||
.catch((err) => {
|
||||
console.log(err);
|
||||
});
|
||||
});this.fetchMajorData(row.user_id);
|
||||
},
|
||||
// 保存添加操作
|
||||
openSelect(row) {
|
||||
@@ -381,4 +450,8 @@ export default {
|
||||
margin: 0 5px 0 0;
|
||||
font-size: 13px;
|
||||
}
|
||||
::v-deep .el-page-header__left, ::v-deep .el-page-header__content{
|
||||
font-size:14px !important ;
|
||||
color:#606266 !important ;
|
||||
}
|
||||
</style>
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
<template>
|
||||
<div>
|
||||
<div
|
||||
@click="disabled?'':BoxMajor()"
|
||||
@click="disabled ? '' : BoxMajor()"
|
||||
v-if="user_id"
|
||||
style="display: flex; align-items: center; justify-content: space-between;"
|
||||
style="display: flex; align-items: center; justify-content: space-between"
|
||||
:style="{ cursor: disabled ? '' : 'pointer' }"
|
||||
>
|
||||
<!-- 使用 user_id 来获取用户的 majorData -->
|
||||
@@ -51,14 +51,14 @@
|
||||
<script>
|
||||
export default {
|
||||
components: {},
|
||||
props: ['user_id','baseInfo','disabled'],
|
||||
props: ['user_id', 'baseInfo', 'disabled'],
|
||||
data() {
|
||||
return {
|
||||
majorValueList: [],
|
||||
majorData: [],
|
||||
majorMes: {},
|
||||
majorBox: false,
|
||||
loading: false,
|
||||
loading: false
|
||||
};
|
||||
},
|
||||
created() {
|
||||
@@ -83,11 +83,10 @@ export default {
|
||||
}));
|
||||
},
|
||||
async fetchMajorData(userId) {
|
||||
|
||||
// if (!this.majorData[userId]) {
|
||||
// 判断是否已经加载过该用户的数据
|
||||
this.majorData = await this.getMajorData(userId);
|
||||
this.$forceUpdate()
|
||||
this.$forceUpdate();
|
||||
// }
|
||||
},
|
||||
// 修改标记
|
||||
@@ -97,15 +96,13 @@ this.$forceUpdate()
|
||||
this.loading = false; // 开始加载数据
|
||||
if (res.status === 1) {
|
||||
return res.data; // 返回数据
|
||||
} else {
|
||||
} else {
|
||||
return []; // 如果没有数据,返回空数组
|
||||
}
|
||||
|
||||
} catch (error) {
|
||||
console.error('Error fetching data:', error);
|
||||
return []; // 如果发生错误,返回空数组
|
||||
}
|
||||
|
||||
},
|
||||
saveMajor() {
|
||||
this.$api
|
||||
|
||||
Reference in New Issue
Block a user