mirror of
https://github.com/lingble/chatwoot.git
synced 2025-10-30 18:47:51 +00:00
fix: Draft, Articles, Archived are counted wrong in help-center (#7761)
This commit is contained in:
@@ -189,6 +189,7 @@ export default {
|
|||||||
articleId: this.articleSlug,
|
articleId: this.articleSlug,
|
||||||
status: status,
|
status: status,
|
||||||
});
|
});
|
||||||
|
this.$emit('update-meta');
|
||||||
this.statusUpdateSuccessMessage(status);
|
this.statusUpdateSuccessMessage(status);
|
||||||
this.closeActionsDropdown();
|
this.closeActionsDropdown();
|
||||||
if (status === this.ARTICLE_STATUS_TYPES.ARCHIVE) {
|
if (status === this.ARTICLE_STATUS_TYPES.ARCHIVE) {
|
||||||
|
|||||||
@@ -209,15 +209,21 @@ export default {
|
|||||||
},
|
},
|
||||||
onClickAssignAuthor({ id }) {
|
onClickAssignAuthor({ id }) {
|
||||||
this.$emit('save-article', { author_id: id });
|
this.$emit('save-article', { author_id: id });
|
||||||
|
this.updateMeta();
|
||||||
},
|
},
|
||||||
onChangeMetaInput() {
|
onChangeMetaInput() {
|
||||||
this.saveArticle();
|
this.saveArticle();
|
||||||
},
|
},
|
||||||
onClickArchiveArticle() {
|
onClickArchiveArticle() {
|
||||||
this.$emit('archive-article');
|
this.$emit('archive-article');
|
||||||
|
this.updateMeta();
|
||||||
},
|
},
|
||||||
onClickDeleteArticle() {
|
onClickDeleteArticle() {
|
||||||
this.$emit('delete-article');
|
this.$emit('delete-article');
|
||||||
|
this.updateMeta();
|
||||||
|
},
|
||||||
|
updateMeta() {
|
||||||
|
this.$emit('update-meta');
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
@open="openArticleSettings"
|
@open="openArticleSettings"
|
||||||
@close="closeArticleSettings"
|
@close="closeArticleSettings"
|
||||||
@show="showArticleInPortal"
|
@show="showArticleInPortal"
|
||||||
|
@update-meta="updateMeta"
|
||||||
/>
|
/>
|
||||||
<div v-if="isFetching" class="text-center p-normal fs-default h-full">
|
<div v-if="isFetching" class="text-center p-normal fs-default h-full">
|
||||||
<spinner size="" />
|
<spinner size="" />
|
||||||
@@ -31,6 +32,7 @@
|
|||||||
@save-article="saveArticle"
|
@save-article="saveArticle"
|
||||||
@delete-article="openDeletePopup"
|
@delete-article="openDeletePopup"
|
||||||
@archive-article="archiveArticle"
|
@archive-article="archiveArticle"
|
||||||
|
@update-meta="updateMeta"
|
||||||
/>
|
/>
|
||||||
<woot-delete-modal
|
<woot-delete-modal
|
||||||
:show.sync="showDeleteConfirmationPopup"
|
:show.sync="showDeleteConfirmationPopup"
|
||||||
@@ -87,6 +89,9 @@ export default {
|
|||||||
selectedPortalSlug() {
|
selectedPortalSlug() {
|
||||||
return this.$route.params.portalSlug;
|
return this.$route.params.portalSlug;
|
||||||
},
|
},
|
||||||
|
selectedLocale() {
|
||||||
|
return this.$route.params.locale;
|
||||||
|
},
|
||||||
portalLink() {
|
portalLink() {
|
||||||
const slug = this.$route.params.portalSlug;
|
const slug = this.$route.params.portalSlug;
|
||||||
return buildPortalArticleURL(
|
return buildPortalArticleURL(
|
||||||
@@ -183,6 +188,13 @@ export default {
|
|||||||
this.showAlert(this.alertMessage);
|
this.showAlert(this.alertMessage);
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
updateMeta() {
|
||||||
|
const selectedPortalParam = {
|
||||||
|
portalSlug: this.selectedPortalSlug,
|
||||||
|
locale: this.selectedLocale,
|
||||||
|
};
|
||||||
|
return this.$store.dispatch('portals/show', selectedPortalParam);
|
||||||
|
},
|
||||||
openArticleSettings() {
|
openArticleSettings() {
|
||||||
this.showArticleSettings = true;
|
this.showArticleSettings = true;
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user