Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

plugin(basic-auth): update the schema #2439

Closed
2 of 5 tasks
liuxiran opened this issue Sep 23, 2020 · 2 comments
Closed
2 of 5 tasks

plugin(basic-auth): update the schema #2439

liuxiran opened this issue Sep 23, 2020 · 2 comments
Labels

Comments

@liuxiran
Copy link
Contributor

Please answer these questions before submitting your issue.

  • Why do you submit this issue?
  • Question or discussion
  • Bug
  • Requirements
  • Feature or performance improvement
  • Other

Question

  • What do you want to know?

What is the purpose of SELECT item?
image


Bug

  • Which version of Apache APISIX Dashboard, OS, and Browser?

  • What happened?
    If possible, provide a way to reproduce the error.

  1. config basic-auth plugin for a route

  2. select work with consumer object, and then click [ok]button

  3. action failed , and got an validate error in the console
    image


Requirement or improvement

  • Please describe your requirements or improvement suggestions.
@liuxiran
Copy link
Contributor Author

liuxiran commented Oct 16, 2020

Part of #2082

Accoring to the basic-auth doc :
config basic-auth plugin only needs to config
username(required) and password(required)

current schema of basic-auth:(update apisix to latest master branch)

{
	"additionalProperties": false,
	"properties": {
		"disable": {
			"type": "boolean"
		}
	},
	"title": "work with route or service object",
	"type": "object"
}

with the plugin page looks:

2020-10-16 19-51-55屏幕截图


the expected schema should be:

{
  "type": "object",
  "required": [
    "username",
    "password"
  ],
  "properties": {
    "username": {
      "type": "string",
      "title": "Username"
    },
    "password": {
      "type": "string",
      "title": "Password"
    }
  }
}

with the plugin page looks:

2020-10-16 20-00-45屏幕截图

@liuxiran liuxiran transferred this issue from apache/apisix-dashboard Oct 16, 2020
@liuxiran liuxiran changed the title can not config basic-auth plugin with ‘work with consumer object’ option plugin(basic-auth): update the schema Oct 16, 2020
@liuxiran
Copy link
Contributor Author

The solution is the same with #2441, it has already worked well with the apisix master branch and dashboard v2.0 branch.

close is now :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant