|
|
|
@ -226,12 +226,12 @@
|
|
|
|
|
v-loading="modifyDialog.loading"
|
|
|
|
|
style="height: 70vh;overflow: auto;padding-left:20px;padding-right:20px"
|
|
|
|
|
>
|
|
|
|
|
<ArticleDetail
|
|
|
|
|
<JournalDetail
|
|
|
|
|
v-if="modifyDialog.visible && modifyDialog.type === 2"
|
|
|
|
|
:data="modifyDialog.data"
|
|
|
|
|
:remoteTagList="queryForm.remoteData.superFilterTags"
|
|
|
|
|
:publisher="queryForm.remoteData.publisher"
|
|
|
|
|
></ArticleDetail>
|
|
|
|
|
></JournalDetail>
|
|
|
|
|
</div>
|
|
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
|
|
<el-button size="small" type="primary" @click="handleDialogCancel"
|
|
|
|
@ -305,13 +305,13 @@
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import articleApi from "@/api/article";
|
|
|
|
|
import journalApi from "@/api/journal";
|
|
|
|
|
import tagApi from "@/api/tag";
|
|
|
|
|
import SuperFilterTagDrawer from "./superFilterTagDrawer.vue";
|
|
|
|
|
import ArticleDetail from "./articleDetail.vue";
|
|
|
|
|
import JournalDetail from "./journalDetail.vue";
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
|
name: "Article",
|
|
|
|
|
name: "Journal",
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
// 标签分级 新建:0,已发布:1, 回收站:2
|
|
|
|
@ -360,7 +360,7 @@ export default {
|
|
|
|
|
};
|
|
|
|
|
},
|
|
|
|
|
components: {
|
|
|
|
|
ArticleDetail,
|
|
|
|
|
JournalDetail,
|
|
|
|
|
SuperFilterTagDrawer
|
|
|
|
|
},
|
|
|
|
|
filters: {},
|
|
|
|
@ -401,7 +401,7 @@ export default {
|
|
|
|
|
}
|
|
|
|
|
this.table.loading = true;
|
|
|
|
|
this.table.data = [];
|
|
|
|
|
articleApi
|
|
|
|
|
journalApi
|
|
|
|
|
.getList(queryParam, this.table.page.current, this.table.page.size)
|
|
|
|
|
.then(res => {
|
|
|
|
|
if (res.code === 200) {
|
|
|
|
@ -533,13 +533,13 @@ export default {
|
|
|
|
|
* 新建标签点击事件
|
|
|
|
|
*/
|
|
|
|
|
handleAddClick() {
|
|
|
|
|
this.$router.push(`/mainPage/article?type=add`);
|
|
|
|
|
this.$router.push(`/mainPage/journal?type=add`);
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 编辑标签点击事件
|
|
|
|
|
*/
|
|
|
|
|
handleModifyClick(row) {
|
|
|
|
|
this.$router.push(`/mainPage/article?id=${row.id}&type=modify`);
|
|
|
|
|
this.$router.push(`/mainPage/journal?id=${row.id}&type=modify`);
|
|
|
|
|
},
|
|
|
|
|
/**
|
|
|
|
|
* 发布点击事件
|
|
|
|
@ -556,7 +556,7 @@ export default {
|
|
|
|
|
handleDetailClick(row) {
|
|
|
|
|
this.modifyDialog.visible = true;
|
|
|
|
|
this.modifyDialog.loading = true;
|
|
|
|
|
articleApi.getDetail(row.id).then(res => {
|
|
|
|
|
journalApi.getDetail(row.id).then(res => {
|
|
|
|
|
if (res.code === 200) {
|
|
|
|
|
this.modifyDialog.data = JSON.parse(JSON.stringify(res.data));
|
|
|
|
|
this.modifyDialog.type = 2;
|
|
|
|
@ -573,7 +573,7 @@ export default {
|
|
|
|
|
* 表格内状态滑块切换事件
|
|
|
|
|
*/
|
|
|
|
|
handleTableRowStatusChange($event, row) {
|
|
|
|
|
articleApi.updateStatus(row.id, $event).then(res => {
|
|
|
|
|
journalApi.updateStatus(row.id, $event).then(res => {
|
|
|
|
|
if (res.code === 200) {
|
|
|
|
|
this.$message.success(res.message);
|
|
|
|
|
} else {
|
|
|
|
@ -599,7 +599,7 @@ export default {
|
|
|
|
|
* 发布弹窗确认按扭
|
|
|
|
|
*/
|
|
|
|
|
handlePublishDialogSubmit() {
|
|
|
|
|
articleApi
|
|
|
|
|
journalApi
|
|
|
|
|
.publish(
|
|
|
|
|
this.publishDialog.id,
|
|
|
|
|
this.publishDialog.type,
|