Reactadmin - edit user roles Announcing the arrival of Valued Associate #679: Cesar Manara Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern) The Ask Question Wizard is Live! Data science time! April 2019 and salary with experienceReact – the right way to pass form element state to sibling/parent elements?React: How do I update state.item[1] on setState? (with JSFiddle)How to update store state in react-redux?Passing a function from an object to the component to edit the stateReact-Admin: Cannot change the style of <Filter>react-admin saving a resource is sending parts of the wrong resourceGrouping & Aligning Items in <SimpleShowLayout> with react-adminSupport for resource nestingHow to connect to nested paths in React-admin? (e.g. http://my.api.to/users/active)react-admin exclude “record” from the redux-form
How to market an anarchic city as a tourism spot to people living in civilized areas?
Using "nakedly" instead of "with nothing on"
Simulating Exploding Dice
How are presidential pardons supposed to be used?
The following signatures were invalid: EXPKEYSIG 1397BC53640DB551
Need a suitable toxic chemical for a murder plot in my novel
Stopping real property loss from eroding embankment
How can players take actions together that are impossible otherwise?
Is drag coefficient lowest at zero angle of attack?
When is phishing education going too far?
How many things? AとBがふたつ
New Order #5: where Fibonacci and Beatty meet at Wythoff
Single author papers against my advisor's will?
Cauchy Sequence Characterized only By Directly Neighbouring Sequence Members
Can a non-EU citizen traveling with me come with me through the EU passport line?
How is simplicity better than precision and clarity in prose?
How do I automatically answer y in bash script?
How to say 'striped' in Latin
I'm having difficulty getting my players to do stuff in a sandbox campaign
Did the new image of black hole confirm the general theory of relativity?
What do I do if technical issues prevent me from filing my return on time?
Autumning in love
How does modal jazz use chord progressions?
When communicating altitude with a '9' in it, should it be pronounced "nine hundred" or "niner hundred"?
Reactadmin - edit user roles
Announcing the arrival of Valued Associate #679: Cesar Manara
Planned maintenance scheduled April 17/18, 2019 at 00:00UTC (8:00pm US/Eastern)
The Ask Question Wizard is Live!
Data science time! April 2019 and salary with experienceReact – the right way to pass form element state to sibling/parent elements?React: How do I update state.item[1] on setState? (with JSFiddle)How to update store state in react-redux?Passing a function from an object to the component to edit the stateReact-Admin: Cannot change the style of <Filter>react-admin saving a resource is sending parts of the wrong resourceGrouping & Aligning Items in <SimpleShowLayout> with react-adminSupport for resource nestingHow to connect to nested paths in React-admin? (e.g. http://my.api.to/users/active)react-admin exclude “record” from the redux-form
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;
I have two different components User and Role. There is a many-to-many relationship between User and Role.
Is there any solution how should I get all User roles in a edit window?
The exact field like I have in my UserCreate
action:
<ReferenceArrayInput
source="UserRoles"
reference="Role"
sort= field: 'Name', order: 'ASC'
>
<SelectArrayInput optionText="Name"/>
</ReferenceArrayInput>
Image how it should look like link
Any ideas?
EDIT:
I have already tried to combine ReferenceArrayInput and ReferenceManyField to achieve a goal to have all current user roles and should be able to edit them.
But it is not good solution, I was just my idea. I don't have any other ideas how should i solve this. Should i call API call for data and use them somehow with ReferenceArrayInput, or how this can be done?
reactjs react-admin
add a comment |
I have two different components User and Role. There is a many-to-many relationship between User and Role.
Is there any solution how should I get all User roles in a edit window?
The exact field like I have in my UserCreate
action:
<ReferenceArrayInput
source="UserRoles"
reference="Role"
sort= field: 'Name', order: 'ASC'
>
<SelectArrayInput optionText="Name"/>
</ReferenceArrayInput>
Image how it should look like link
Any ideas?
EDIT:
I have already tried to combine ReferenceArrayInput and ReferenceManyField to achieve a goal to have all current user roles and should be able to edit them.
But it is not good solution, I was just my idea. I don't have any other ideas how should i solve this. Should i call API call for data and use them somehow with ReferenceArrayInput, or how this can be done?
reactjs react-admin
Could you add a code snippet to the question? That way people could recommend you more things
– Alejandro Vales
Mar 21 at 10:17
2
Pure code-writing requests are off-topic on Stack Overflow — we expect questions here to relate to specific programming problems — but we will happily help you write it yourself! Tell us what you've tried, and where you are stuck. This will also help us answer your question better.
– Stefan Becker
Mar 21 at 10:18
@StefanBecker I edited the question, I would like to know how this should be done, not the full code
– Jason Derrick
Mar 25 at 9:49
add a comment |
I have two different components User and Role. There is a many-to-many relationship between User and Role.
Is there any solution how should I get all User roles in a edit window?
The exact field like I have in my UserCreate
action:
<ReferenceArrayInput
source="UserRoles"
reference="Role"
sort= field: 'Name', order: 'ASC'
>
<SelectArrayInput optionText="Name"/>
</ReferenceArrayInput>
Image how it should look like link
Any ideas?
EDIT:
I have already tried to combine ReferenceArrayInput and ReferenceManyField to achieve a goal to have all current user roles and should be able to edit them.
But it is not good solution, I was just my idea. I don't have any other ideas how should i solve this. Should i call API call for data and use them somehow with ReferenceArrayInput, or how this can be done?
reactjs react-admin
I have two different components User and Role. There is a many-to-many relationship between User and Role.
Is there any solution how should I get all User roles in a edit window?
The exact field like I have in my UserCreate
action:
<ReferenceArrayInput
source="UserRoles"
reference="Role"
sort= field: 'Name', order: 'ASC'
>
<SelectArrayInput optionText="Name"/>
</ReferenceArrayInput>
Image how it should look like link
Any ideas?
EDIT:
I have already tried to combine ReferenceArrayInput and ReferenceManyField to achieve a goal to have all current user roles and should be able to edit them.
But it is not good solution, I was just my idea. I don't have any other ideas how should i solve this. Should i call API call for data and use them somehow with ReferenceArrayInput, or how this can be done?
reactjs react-admin
reactjs react-admin
edited Mar 22 at 7:48
marc_s
585k13011261272
585k13011261272
asked Mar 21 at 10:14
Jason DerrickJason Derrick
335
335
Could you add a code snippet to the question? That way people could recommend you more things
– Alejandro Vales
Mar 21 at 10:17
2
Pure code-writing requests are off-topic on Stack Overflow — we expect questions here to relate to specific programming problems — but we will happily help you write it yourself! Tell us what you've tried, and where you are stuck. This will also help us answer your question better.
– Stefan Becker
Mar 21 at 10:18
@StefanBecker I edited the question, I would like to know how this should be done, not the full code
– Jason Derrick
Mar 25 at 9:49
add a comment |
Could you add a code snippet to the question? That way people could recommend you more things
– Alejandro Vales
Mar 21 at 10:17
2
Pure code-writing requests are off-topic on Stack Overflow — we expect questions here to relate to specific programming problems — but we will happily help you write it yourself! Tell us what you've tried, and where you are stuck. This will also help us answer your question better.
– Stefan Becker
Mar 21 at 10:18
@StefanBecker I edited the question, I would like to know how this should be done, not the full code
– Jason Derrick
Mar 25 at 9:49
Could you add a code snippet to the question? That way people could recommend you more things
– Alejandro Vales
Mar 21 at 10:17
Could you add a code snippet to the question? That way people could recommend you more things
– Alejandro Vales
Mar 21 at 10:17
2
2
Pure code-writing requests are off-topic on Stack Overflow — we expect questions here to relate to specific programming problems — but we will happily help you write it yourself! Tell us what you've tried, and where you are stuck. This will also help us answer your question better.
– Stefan Becker
Mar 21 at 10:18
Pure code-writing requests are off-topic on Stack Overflow — we expect questions here to relate to specific programming problems — but we will happily help you write it yourself! Tell us what you've tried, and where you are stuck. This will also help us answer your question better.
– Stefan Becker
Mar 21 at 10:18
@StefanBecker I edited the question, I would like to know how this should be done, not the full code
– Jason Derrick
Mar 25 at 9:49
@StefanBecker I edited the question, I would like to know how this should be done, not the full code
– Jason Derrick
Mar 25 at 9:49
add a comment |
0
active
oldest
votes
Your Answer
StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55278109%2freactadmin-edit-user-roles%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55278109%2freactadmin-edit-user-roles%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Could you add a code snippet to the question? That way people could recommend you more things
– Alejandro Vales
Mar 21 at 10:17
2
Pure code-writing requests are off-topic on Stack Overflow — we expect questions here to relate to specific programming problems — but we will happily help you write it yourself! Tell us what you've tried, and where you are stuck. This will also help us answer your question better.
– Stefan Becker
Mar 21 at 10:18
@StefanBecker I edited the question, I would like to know how this should be done, not the full code
– Jason Derrick
Mar 25 at 9:49