From 1ff49ca16dc4cd02b66304f50c280d7d21a0bb6f Mon Sep 17 00:00:00 2001 From: wangruidong <940853815@qq.com> Date: Mon, 17 Jun 2024 10:03:05 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=E7=B3=BB=E7=BB=9F=E8=AE=BE=E7=BD=AE-?= =?UTF-8?q?=E7=BB=84=E7=BB=87=E7=AE=A1=E7=90=86=EF=BC=9A=E6=9C=80=E6=96=B0?= =?UTF-8?q?=E5=88=9B=E5=BB=BA=E6=88=90=E5=8A=9F=E5=90=8E=E8=BF=94=E5=9B=9E?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E6=9C=AA=E6=8C=89=E5=88=9B=E5=BB=BA=E6=97=B6?= =?UTF-8?q?=E9=97=B4=E6=8E=92=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/settings/Org/OrganizationCreateUpdate.vue | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/views/settings/Org/OrganizationCreateUpdate.vue b/src/views/settings/Org/OrganizationCreateUpdate.vue index 8bb144668..3ca8eafbe 100644 --- a/src/views/settings/Org/OrganizationCreateUpdate.vue +++ b/src/views/settings/Org/OrganizationCreateUpdate.vue @@ -12,25 +12,24 @@ export default { data() { return { config: { - initial: { - }, + initial: {}, url: '/api/v1/orgs/orgs/', fields: [ ['', ['name', 'comment']] ], hasSaveContinue: false, - fieldsMeta: { - }, + fieldsMeta: {}, onPerformSuccess(res, method) { + const order_params = { params: { order: '-date_created' }} switch (method) { case 'post': this.$store.dispatch('users/addAdminOrg', { id: res.id, name: res.name }) this.$message.success(this.$tc('common.createSuccessMsg')) - return this.$router.push({ name: 'OrganizationList' }) + return this.$router.push({ name: 'OrganizationList', ...order_params }) case 'put': this.$store.dispatch('users/modifyOrg', { id: res.id, name: res.name }) this.$message.success(this.$tc('common.updateSuccessMsg')) - return this.$router.push({ name: 'OrganizationList' }) + return this.$router.push({ name: 'OrganizationList', ...order_params }) } } }