Sir there are two drop down, i want to add a new dropdown/button with them.
frm.add_custom_button(__('Navbar Settings'),
function() {
frappe.msgprint(āCustom Informationā); })
}, __("Show")
);
The Navbar Settings
is the name of the button.
The Show
is the name of button group.
thanku @rahy
i want to add button on navbar, as i attached pic with search, notification and help.
I understand the coding part but dont know which file should i update to add button with search, notification and help.
@Mdaniax, Please go through this video 48. How to Translate ERPNext to any language automatically - YouTube, I think it will help you to update the navbar.
Try in your browser console:
let navbar = document.querySelector(ā.navbar-collapseā);
navbar.prepend(āIt is Workingā);
To add menu on website navbar you can add in hooks.py
"top_bar_items": [
{"label": "label_of_menu", "url": "/endpoint/to/page", "right":1},
To modify the html files in the app (not doctype) do it here:
For adding button to doctype:
its working but for webpage navbar, i want same thing with desk navbar
Modify the navbar-items.html file in the directory I mentioned above.
can you suggest me any tutorials for this, i mean for basics of customization?
its customizing website not the desk.
Try here:
/frappe/public/js/frappe/ui/toolbar/navbar.html
I solved it by editing my custom application
Thatās how to do it actually⦠via custom app.
how do you edit it in cutom app?
Same question here
As far as I know, it is only possible to replace files that are within templates/www. Therefore: How did you do it? I would expect, that you have to replace the method that actually calls the navbar.html?
erpnext (or frappe)
|- erpnext (or frappe)
|-- templates
|-- www
(documented by @rahy before How to customisation website footer in version-12 - #5 by rahy )
I still did it not get working, yet. Any tip on how to āreplaceā the
/frappe/public/js/frappe/ui/toolbar/navbar.html
by my own navbar.html based on my custom app?
Just adding the file within my app in the given folder structure wonāt work (as I think I have to ātellā Frappe, that it should overwrite the original with mine. Normally I would guess to manage this within hooks.py, but I didnāt came to a solution, yet)
⦠what Iāve missed was to reference the navbar.html also within my modules build.json and run
bench build
You mean this is the solution?
You mean this is the solution?
Only for the sub-question regarding, how to modify the navbar.html-file.