- Home
- Forum
- React - EJ 2
- Column chooser when add new record
Column chooser when add new record
When same column is not selected in column chooser, it disappear in add new record.
How can i show all column in "add new record" feature?
Thank you
SIGN IN To post a reply.
3 Replies
PS
Pon Selva Jeganathan
Syncfusion Team
October 14, 2024 11:02 AM UTC
Hi Alessandro,
Before we proceed with your query, could you kindly provide us with the following details to help us deliver the most accurate solution as soon as possible:
- Can you confirm if you are using the EJ1 Grid or EJ2 Grid? This information is crucial for us to proceed with your query.
- How do you add a new row? Are you using the toolbar to insert a row or the addRecord method?
- Code example details
- A video demo or screenshot of your requirement would greatly help us understand your scenario better
Your prompt response will allow us to address your query efficiently.
Regards,
Pon Selva
AP
Alessandro Puricelli
October 16, 2024 09:40 AM UTC
Hi Pon,
- ej2 grid
- toolbar
- it's not simple, but if you need i'll try to make an example
- there are two pictures, the first i selected just one column, the second i selected 3 column and so on...
SR
Sivaranjani Rajasekaran
Syncfusion Team
October 17, 2024 02:50 PM UTC
Hi Alessandro Puricelli,
Thank you for your inquiry.
Based on your inquiry, we understand that you want to choose some columns in the column menu, and when you try to add a new column, all the columns should be visible.
By default, both normal and dialog editing in the Grid reflect only the columns currently displayed in the UI. To fulfill your requirement, we recommend utilizing the template editing feature of the Grid component. This feature allows you to define the structure and content of the cells using templates. As a result, when you select columns through the column chooser (for example, selecting 4 out of 10 columns), the dialog for adding new records will include all columns, rather than just the ones selected.
Please refer to the code and sample below for more information.
Code Example : App.Js const editSettings = { allowEditing: true, allowAdding: true, allowDeleting: true, mode: 'Dialog', template: dialogTemplate }; function dialogTemplate(props) { return (<DialogFormTemplate {...props}/>); } function DialogFormTemplate(props) { //you can define your dialog here } |
Screenshot : |
Documentation Link :
- Template Editing : https://ej2.syncfusion.com/react/documentation/grid/editing/template-editing
If this does not address your case, please share the exact requirements and provide a video demo along with the complete grid rendering code. Once we have this information, we can provide the appropriate solution.
Please get back to us if you need further assistance.
Regards,
Sivaranjani R.
SIGN IN To post a reply.
- 3 Replies
- 3 Participants
-
AP Alessandro Puricelli
- Oct 11, 2024 10:51 AM UTC
- Oct 17, 2024 02:50 PM UTC