diff --git a/src/store/modules/dashboard.ts b/src/store/modules/dashboard.ts index eee2b376..52dc62c2 100644 --- a/src/store/modules/dashboard.ts +++ b/src/store/modules/dashboard.ts @@ -423,13 +423,15 @@ export const dashboardStore = defineStore({ res = await graphql.query("addNewTemplate").params({ setting: { configuration: JSON.stringify(c) } }); json = res.data.data.addTemplate; + if (!json.status) { + ElMessage.error(json.message); + } } if (res.data.errors || res.errors) { ElMessage.error(res.data.errors); return res.data; } if (!json.status) { - ElMessage.error(json.message); return json; } if (!this.currentDashboard.id) {