|
@@ -17,6 +17,7 @@
|
|
|
display: flex;
|
|
display: flex;
|
|
|
// flex-direction: column;
|
|
// flex-direction: column;
|
|
|
justify-content: space-between;
|
|
justify-content: space-between;
|
|
|
|
|
+ position: relative;
|
|
|
}
|
|
}
|
|
|
.journalItem .title {
|
|
.journalItem .title {
|
|
|
color: #ffffff;
|
|
color: #ffffff;
|
|
@@ -27,6 +28,9 @@
|
|
|
.add{
|
|
.add{
|
|
|
position:absolute;
|
|
position:absolute;
|
|
|
right: 0px;
|
|
right: 0px;
|
|
|
|
|
+ top:-35px;
|
|
|
|
|
+ background: #0f1f8c;
|
|
|
|
|
+ border:1px solid #0f1f8c;
|
|
|
}
|
|
}
|
|
|
.overActivity {
|
|
.overActivity {
|
|
|
}
|
|
}
|
|
@@ -79,15 +83,93 @@
|
|
|
<div class="title more">查看更多>></div>
|
|
<div class="title more">查看更多>></div>
|
|
|
<el-button type="primary" class="add" size="mini">发布活动回顾</el-button>
|
|
<el-button type="primary" class="add" size="mini">发布活动回顾</el-button>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <el-table
|
|
|
|
|
+ :data="oldActivityList"
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-table-column label="活动海报">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <img :src="scope.row.img" alt="" width="120" height="80" style="margin:10px;">
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ <el-table-column label="活动名称" prop="name"></el-table-column>
|
|
|
|
|
+ <el-table-column label="活动时间">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <p>{{scope.row.begin_time}}</p>
|
|
|
|
|
+ <p>{{scope.row.end_time}}</p>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ <el-table-column label="活动地址" prop="address"></el-table-column>
|
|
|
|
|
+ <el-table-column label="活动简介" prop="desc" width="500"></el-table-column>
|
|
|
|
|
+ <el-table-column label="活动人数" prop="assembly_number"></el-table-column>
|
|
|
|
|
+ <el-table-column label="操作">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-button class="edit" type="text" @click="edit(scope.row)"
|
|
|
|
|
+ >编辑</el-button
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-button class="del" @click="del" type="text">删除</el-button>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ </el-table>
|
|
|
|
|
+ </div>
|
|
|
<!-- 活动预告 -->
|
|
<!-- 活动预告 -->
|
|
|
<div class="journalItem preActivity">
|
|
<div class="journalItem preActivity">
|
|
|
<div class="title">活动预告</div>
|
|
<div class="title">活动预告</div>
|
|
|
<div class="title more">查看更多>></div>
|
|
<div class="title more">查看更多>></div>
|
|
|
|
|
+ <el-button type="primary" class="add" size="mini">发布活动预告</el-button>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <el-table
|
|
|
|
|
+ :data="newActivityList"
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-table-column label="活动海报">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <img :src="scope.row.img" alt="" width="120" height="80" style="margin:10px;">
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ <el-table-column label="活动名称" prop="name"></el-table-column>
|
|
|
|
|
+ <el-table-column label="活动时间">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <p>{{scope.row.begin_time}}</p>
|
|
|
|
|
+ <p>{{scope.row.end_time}}</p>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ <el-table-column label="活动地址" prop="address"></el-table-column>
|
|
|
|
|
+ <el-table-column label="活动简介" prop="desc" width="500"></el-table-column>
|
|
|
|
|
+ <el-table-column label="活动人数" prop="assembly_number"></el-table-column>
|
|
|
|
|
+ <el-table-column label="操作">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-button class="edit" type="text" @click="edit(scope.row)"
|
|
|
|
|
+ >编辑</el-button
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-button class="del" @click="del" type="text">删除</el-button>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ </el-table>
|
|
|
</div>
|
|
</div>
|
|
|
<!-- 精品文章 -->
|
|
<!-- 精品文章 -->
|
|
|
<div class="journalItem preActivity">
|
|
<div class="journalItem preActivity">
|
|
|
<div class="title">精品文章</div>
|
|
<div class="title">精品文章</div>
|
|
|
<div class="title more">查看更多>></div>
|
|
<div class="title more">查看更多>></div>
|
|
|
|
|
+ <el-button type="primary" class="add" size="mini">发布精品文章</el-button>
|
|
|
|
|
+ </div>
|
|
|
|
|
+ <div>
|
|
|
|
|
+ <el-table
|
|
|
|
|
+ :data="goodArticleList"
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-table-column label="文章名称" prop="name"></el-table-column>
|
|
|
|
|
+ <el-table-column label="作者" prop="author"></el-table-column>
|
|
|
|
|
+ <el-table-column label="发布时间" prop="ctime" width="500"></el-table-column>
|
|
|
|
|
+ <el-table-column label="出版时间" prop="publish_time"></el-table-column>
|
|
|
|
|
+ <el-table-column label="操作">
|
|
|
|
|
+ <template slot-scope="scope">
|
|
|
|
|
+ <el-button class="edit" type="text" @click="edit(scope.row)"
|
|
|
|
|
+ >编辑</el-button
|
|
|
|
|
+ >
|
|
|
|
|
+ <el-button class="del" @click="del" type="text">删除</el-button>
|
|
|
|
|
+ </template>
|
|
|
|
|
+ </el-table-column>
|
|
|
|
|
+ </el-table>
|
|
|
</div>
|
|
</div>
|
|
|
</div>
|
|
</div>
|
|
|
</section>
|
|
</section>
|
|
@@ -101,8 +183,10 @@ export default {
|
|
|
data() {
|
|
data() {
|
|
|
return {
|
|
return {
|
|
|
form: {},
|
|
form: {},
|
|
|
- subjectList: [],
|
|
|
|
|
|
|
+ oldActivityList: [],
|
|
|
|
|
+ newActivityList: [],
|
|
|
organizerList: [],
|
|
organizerList: [],
|
|
|
|
|
+ goodArticleList:[],
|
|
|
imageUrl: "",
|
|
imageUrl: "",
|
|
|
rules: {
|
|
rules: {
|
|
|
name: [{ required: true, message: "请输入标题", trigger: "blur" }],
|
|
name: [{ required: true, message: "请输入标题", trigger: "blur" }],
|
|
@@ -118,23 +202,6 @@ export default {
|
|
|
};
|
|
};
|
|
|
},
|
|
},
|
|
|
methods: {
|
|
methods: {
|
|
|
- //封面
|
|
|
|
|
- handleAvatarSuccess(res, file) {
|
|
|
|
|
- this.form.img = file.response.data;
|
|
|
|
|
- console.log(this.form.img);
|
|
|
|
|
- },
|
|
|
|
|
- //主讲人
|
|
|
|
|
- handleAvatarSuccess1(index, res, file) {
|
|
|
|
|
- var speaker = this.form.speaker[index];
|
|
|
|
|
- speaker.img = file.response.data;
|
|
|
|
|
- this.$set(this.form.speaker, index, speaker);
|
|
|
|
|
- // console.log(this.form.img)
|
|
|
|
|
- },
|
|
|
|
|
- beforeAvatarUpload() {},
|
|
|
|
|
- handleClick() {},
|
|
|
|
|
- addSpeaker() {
|
|
|
|
|
- this.form.speaker.push({ name: "", intruduce: "" });
|
|
|
|
|
- },
|
|
|
|
|
gopage(size) {
|
|
gopage(size) {
|
|
|
if (size) {
|
|
if (size) {
|
|
|
this.form.page_size = size;
|
|
this.form.page_size = size;
|
|
@@ -144,54 +211,18 @@ export default {
|
|
|
},
|
|
},
|
|
|
getData() {
|
|
getData() {
|
|
|
this.loading = true;
|
|
this.loading = true;
|
|
|
- this.$api.searchSubjectList().then((res) => {
|
|
|
|
|
- this.subjectList = res.data.data;
|
|
|
|
|
- });
|
|
|
|
|
- this.$api.searchOrganizerList().then((res) => {
|
|
|
|
|
- this.organizerList = res.data.data;
|
|
|
|
|
- });
|
|
|
|
|
// 期刊详情
|
|
// 期刊详情
|
|
|
let id = this.$route.query.id;
|
|
let id = this.$route.query.id;
|
|
|
if (id) {
|
|
if (id) {
|
|
|
- this.$api.getJournal({ id: id }).then((res) => {
|
|
|
|
|
|
|
+ this.$api.showJournal({ id: id }).then((res) => {
|
|
|
|
|
+ console.log(res)
|
|
|
this.form = res.data.data;
|
|
this.form = res.data.data;
|
|
|
|
|
+ this.oldActivityList = res.data.data.old_activity;
|
|
|
|
|
+ this.newActivityList = res.data.data.new_activity;
|
|
|
|
|
+ this.goodArticleList = res.data.data.good_article;
|
|
|
});
|
|
});
|
|
|
}
|
|
}
|
|
|
},
|
|
},
|
|
|
- save() {
|
|
|
|
|
- let id = this.$route.query.id;
|
|
|
|
|
- let parm = this.form;
|
|
|
|
|
- this.$refs["form"].validate((valid) => {
|
|
|
|
|
- if (valid) {
|
|
|
|
|
- if (id) {
|
|
|
|
|
- parm.id = id;
|
|
|
|
|
- this.$api.updateJournal(parm).then((res) => {
|
|
|
|
|
- if (res.data.code == 0) {
|
|
|
|
|
- this.$message({
|
|
|
|
|
- type: "success",
|
|
|
|
|
- message: "保存成功!",
|
|
|
|
|
- });
|
|
|
|
|
- } else {
|
|
|
|
|
- this.$message.error("保存失败!");
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- } else {
|
|
|
|
|
- this.$api.addJournal(parm).then((res) => {
|
|
|
|
|
- if (res.data.code == 0) {
|
|
|
|
|
- this.$message({
|
|
|
|
|
- type: "success",
|
|
|
|
|
- message: "保存成功!",
|
|
|
|
|
- });
|
|
|
|
|
- } else {
|
|
|
|
|
- this.$message.error("保存失败!");
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- }
|
|
|
|
|
- } else {
|
|
|
|
|
- this.$message.error("有必填项没有填!");
|
|
|
|
|
- }
|
|
|
|
|
- });
|
|
|
|
|
- },
|
|
|
|
|
del(id) {
|
|
del(id) {
|
|
|
this.$confirm("确定删除吗", "提示", {
|
|
this.$confirm("确定删除吗", "提示", {
|
|
|
type: "warning",
|
|
type: "warning",
|