[GH-ISSUE #5645] [Feature]: delete disabled inbounds in adding client #3932

Closed
opened 2026-10-31 20:35:59 +07:00 by bsakaguchi · 1 comment
Owner

Originally created by @Morteza820 on GitHub (Jun 28, 2026).
Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/5645

dear Sanaei,
i would be appreciated if you add feature which doesnt show disabled inbounds in add inbound list in add client section...
i mean when we want to add new client or edit , we wont see disabled inbounds in add or edit inbounds sector...
best regards,

Describe the solution you'd like

dear Sanaei,
i would be appreciated if you add feature which doesnt show disabled inbounds in add inbound list in add client section...
i mean when we want to add new client or edit , we wont see disabled inbounds in add or edit inbounds sector...
best regards,

Alternatives you've considered

No response

Concrete use case

No response

Mockups, screenshots, or examples

No response

Which parts of the panel would this affect?

No response

Are you willing to help?

  • I'd like to implement this feature myself and open a PR.
  • I can help test once a PR is open.

Before submitting

  • I searched existing issues and this feature has not been requested.
  • This feature request is written in English.
Originally created by @Morteza820 on GitHub (Jun 28, 2026). Original GitHub issue: https://github.com/MHSanaei/3x-ui/issues/5645 ### Is your feature request related to a problem? dear Sanaei, i would be appreciated if you add feature which doesnt show disabled inbounds in add inbound list in add client section... i mean when we want to add new client or edit , we wont see disabled inbounds in add or edit inbounds sector... best regards, ### Describe the solution you'd like dear Sanaei, i would be appreciated if you add feature which doesnt show disabled inbounds in add inbound list in add client section... i mean when we want to add new client or edit , we wont see disabled inbounds in add or edit inbounds sector... best regards, ### Alternatives you've considered _No response_ ### Concrete use case _No response_ ### Mockups, screenshots, or examples _No response_ ### Which parts of the panel would this affect? _No response_ ### Are you willing to help? - [ ] I'd like to implement this feature myself and open a PR. - [ ] I can help test once a PR is open. ### Before submitting - [x] I searched [existing issues](../issues?q=is%3Aissue) and this feature has not been requested. - [x] This feature request is written in English.
bsakaguchi 2026-10-31 20:35:59 +07:00
Author
Owner

@github-actions[bot] commented on GitHub (Jun 28, 2026):

This is a valid enhancement. The inbound selector shown when adding or editing a client currently includes disabled inbounds because the backend query that populates it does not filter on the enable column.

Confirmed in the source:

  • internal/web/service/inbound.go, GetInboundOptions() (line 318–322): The query selects id, remark, tag, protocol, port, stream_settings, settings, node_id and filters only by user_id. Neither the enable column is selected nor is a WHERE enable = true condition applied.
  • frontend/src/pages/clients/ClientFormModal.tsx, line 376–379: The frontend filters the returned list only by protocol type (MULTI_CLIENT_PROTOCOLS), not by enabled status.
  • The InboundOption struct and its corresponding frontend schema (src/schemas/client.ts) do not carry an enable field at all.

The minimal change needed to implement this would be:

  1. Add enable to the SELECT clause and add AND enable = 1 (or equivalent) to the WHERE clause in GetInboundOptions() in internal/web/service/inbound.go.
  2. No frontend change would be required if filtering is done entirely on the backend.

Alternatively, the enable field could be added to InboundOption and the existing frontend filter in ClientFormModal.tsx could be extended, but a backend-only fix is simpler and keeps disabled inbounds out of the API response entirely.

If you want to implement this yourself, the checkboxes in the "Are you willing to help?" section of the template are available — a PR against main following the conventions in CLAUDE.md and CONTRIBUTING.md would be welcome.


This reply was generated automatically; a maintainer may follow up.

<!-- gh-comment-id:4827417039 --> @github-actions[bot] commented on GitHub (Jun 28, 2026): This is a valid enhancement. The inbound selector shown when adding or editing a client currently includes disabled inbounds because the backend query that populates it does not filter on the `enable` column. Confirmed in the source: - **`internal/web/service/inbound.go`, `GetInboundOptions()` (line 318–322):** The query selects `id, remark, tag, protocol, port, stream_settings, settings, node_id` and filters only by `user_id`. Neither the `enable` column is selected nor is a `WHERE enable = true` condition applied. - **`frontend/src/pages/clients/ClientFormModal.tsx`, line 376–379:** The frontend filters the returned list only by protocol type (`MULTI_CLIENT_PROTOCOLS`), not by enabled status. - The `InboundOption` struct and its corresponding frontend schema (`src/schemas/client.ts`) do not carry an `enable` field at all. The minimal change needed to implement this would be: 1. Add `enable` to the `SELECT` clause and add `AND enable = 1` (or equivalent) to the `WHERE` clause in `GetInboundOptions()` in `internal/web/service/inbound.go`. 2. No frontend change would be required if filtering is done entirely on the backend. Alternatively, the `enable` field could be added to `InboundOption` and the existing frontend filter in `ClientFormModal.tsx` could be extended, but a backend-only fix is simpler and keeps disabled inbounds out of the API response entirely. If you want to implement this yourself, the checkboxes in the "Are you willing to help?" section of the template are available — a PR against `main` following the conventions in `CLAUDE.md` and `CONTRIBUTING.md` would be welcome. --- *This reply was generated automatically; a maintainer may follow up.*
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MHSanaei/3x-ui#3932
No description provided.