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

Disable items by ids in datagrid #3879

Merged
merged 3 commits into from Apr 5, 2018

Conversation

danrot
Copy link
Contributor

@danrot danrot commented Mar 29, 2018

Q A
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Fixed tickets ---
Related issues/PRs #3855
License MIT
Documentation PR ---

What's in this PR?

This PR allows to disable certain items in the datagrid by passing the ids to disable in the disabledIds prop of the Datagrid.

Why?

Because in #3855 we introduced the internal links field type, but you can still select the page you are currently editing to itself, which the backend does not allow.

Example Usage

<Datagrid disabledIds={[1, 4]} />

To Do

  • Add disabledIds as property in the Assignment field type to avoid linking a page to itself

@danrot danrot added the Feature New functionality not yet included in Sulu label Mar 29, 2018
@danrot danrot added this to the Release 2.0 milestone Mar 29, 2018
@danrot
Copy link
Contributor Author

danrot commented Mar 29, 2018

Only the last two commit 2610ef8 and bc27792 are really in this PR, the rest comes from #3855.

@danrot danrot force-pushed the feature/disable-datagrid-items branch 3 times, most recently from 40340f5 to 0d8196e Compare April 5, 2018 07:31
@danrot danrot force-pushed the feature/disable-datagrid-items branch from 0d8196e to e08a578 Compare April 5, 2018 07:33
@danrot danrot force-pushed the feature/disable-datagrid-items branch from 3a528d5 to 63771af Compare April 5, 2018 11:19
@chirimoya chirimoya self-requested a review April 5, 2018 14:09
@chirimoya chirimoya merged commit 13df23e into sulu:develop Apr 5, 2018
@danrot danrot deleted the feature/disable-datagrid-items branch April 5, 2018 14:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New functionality not yet included in Sulu
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants