You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by ju...@apache.org on 2020/09/06 15:18:13 UTC
[apisix-dashboard] branch master updated: feat(Consumer): update
auth plugin check policy (#446)
This is an automated email from the ASF dual-hosted git repository.
juzhiyuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-dashboard.git
The following commit(s) were added to refs/heads/master by this push:
new bd3f384 feat(Consumer): update auth plugin check policy (#446)
bd3f384 is described below
commit bd3f38458fc48518f47e9003139ed7c8544fccd3
Author: 琚致远 <ju...@apache.org>
AuthorDate: Sun Sep 6 23:18:04 2020 +0800
feat(Consumer): update auth plugin check policy (#446)
---
package.json | 2 +-
src/pages/Consumer/Create.tsx | 7 ++-----
src/pages/Route/Create.tsx | 2 +-
src/pages/Upstream/Create.tsx | 2 +-
4 files changed, 5 insertions(+), 8 deletions(-)
diff --git a/package.json b/package.json
index 87b7116..7f3f1bb 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
{
"name": "apisix-dashboard",
- "version": "1.5.2",
+ "version": "1.5.3",
"private": true,
"description": "Dashboard for Apache APISIX",
"scripts": {
diff --git a/src/pages/Consumer/Create.tsx b/src/pages/Consumer/Create.tsx
index 83da1ee..7e918de 100644
--- a/src/pages/Consumer/Create.tsx
+++ b/src/pages/Consumer/Create.tsx
@@ -18,7 +18,7 @@ import React, { useState, useEffect } from 'react';
import { PageContainer } from '@ant-design/pro-layout';
import { Card, Steps, notification, Form } from 'antd';
import { history, useIntl } from 'umi';
-import { PluginPage, PLUGIN_MAPPER_SOURCE, PluginPageType } from '@api7-dashboard/plugin';
+import { PluginPage, PluginPageType } from '@api7-dashboard/plugin';
import ActionBar from '@/components/ActionBar';
@@ -68,10 +68,7 @@ const Page: React.FC = (props) => {
setStep(nextStep);
});
} else if (nextStep === 3) {
- const authPluginNames = Object.entries(PLUGIN_MAPPER_SOURCE)
- .filter(([name, value]) => name.includes('auth') && value.category === 'Security')
- .map((item) => item[0]);
- const isValid = Object.keys(plugins).some((name) => authPluginNames.includes(name));
+ const isValid = Object.keys(plugins).some((name) => name.includes('auth'));
if (!isValid) {
notification.warning({
message: formatMessage({ id: 'consumer.create.enable.authentication.plugin' }),
diff --git a/src/pages/Route/Create.tsx b/src/pages/Route/Create.tsx
index 8beba5b..37819aa 100644
--- a/src/pages/Route/Create.tsx
+++ b/src/pages/Route/Create.tsx
@@ -18,9 +18,9 @@ import React, { useState, useEffect } from 'react';
import { Card, Steps, Form } from 'antd';
import { PageHeaderWrapper } from '@ant-design/pro-layout';
import { history, useIntl } from 'umi';
+import { transformer as chartTransformer } from '@api7-dashboard/pluginchart';
import ActionBar from '@/components/ActionBar';
-import { transformer as chartTransformer } from '@api7-dashboard/pluginchart';
import {
create,
diff --git a/src/pages/Upstream/Create.tsx b/src/pages/Upstream/Create.tsx
index dc824c4..405ecb9 100644
--- a/src/pages/Upstream/Create.tsx
+++ b/src/pages/Upstream/Create.tsx
@@ -17,9 +17,9 @@
import React, { useState, useEffect } from 'react';
import { PageContainer } from '@ant-design/pro-layout';
import { Card, Steps, notification, Form } from 'antd';
+import { history, useIntl } from 'umi';
import ActionBar from '@/components/ActionBar';
-import { history, useIntl } from 'umi';
import Step1 from './components/Step1';
import Preview from './components/Preview';