You have to change
modified value and then run
bench frappe --latest.
But why you are directly changing json, you can add the field from UI, it will automatically be reflected in json, if
developer_mode is set to 1 in site_config.
If you want to add a custom field in existing doctype, you can create
Custom Field record.
oke, if i added a new field from UI, it will be appear in JSON?? in database am able to see the fields. but in doc i didn’t see any changes.
As I said you have to set
developer_mode as 1, in your site’s site_config.json file.
It should work, if you directly add a field in the doctype, it should be appeared in json file. Ensure that you have changing in right file, in right branch and in right site.
i just printed the status in list view, thats working fine. but the custom filed is not getting from doc type.
You have to include the field_name in
How can I create new custom field through .json file?
Why not just use Customize Form?
Editing the multiple .json files will be faster if i want to create same field in multiple files than using Customize Form.
Use the Import tool to export the custom field .csv, make your fields, and import. Probably the fastest way.
Here’s a blank template:
I tried adding a field to the Employee form by editing employee.json but the field doesn’t show up on the site. When I add the field from the UI, I don’t see it in the employee.json file. The reason it’s important for me is simply because this new field is supposed to be part of the Pull Request for a proposed new feature
How to proceed?
Still hoping for some assistance here…
Have you tried to change the “modified by” field and run
bench migrate ?
Thanks a lot for your response. Could you please explain what you mean by this?
When you do
bench migrate the system will update the database based on your JSON file only if the “modified” (sorry not “modified by”) field has changed since the last update.
Oh, I see!
Thanks a lot for this. I’ll try it and let you know how it goes
Thanks a great deal… it worked!
Sir they way you have suggest i am trying to do in same manner…all the fields are appearing in doctype while customisation … but when am trying to save that doc so that field will be create in database…getting error.