In `search.py` it was hardcoded that **DocType** and **Role** get translated before matching against the search text. This way, a user can type in his local language and still see correct results.
This feature is useful for other DocTypes as well. The criterion would be: there is a small, fairly static number of records, so that the performance impact of translating all names first is not too bad.
This PR adds a hook `translated_search_doctypes` that determines which DocType names get translated before search.
I also added **Country** to `translated_search_doctypes` for frappe. The link to **Country** is frequently used in **Address**, but until now there was no way to use it in the local language. There are ~70% less Countries than DocTypes (including ERPNext), so the performance should be fine.
ERPNext could, for example, add the **Gender** DocType to this hook. As there are very few genders, translating them is fast and improves the UX.
Docs: https://frappeframework.com/docs/v13/user/en/python-api/hooks/edit?wiki_page_patch=b4d7c8d6fc
* feat: implement valued parameter 'stream_only' in 'get_logger()' in order to stream logs into stderr instead rotating log files.
Co-authored-by: gavin <gavin18d@gmail.com>
Similar to set_value for accepting multiple columns ot be updated for
the same Table through a Dict as the second positional arg
Misc: Added type hints
* fix: Other user must not able to delete other user's comment except Admin
* Update frappe/public/js/frappe/form/footer/form_timeline.js
Co-authored-by: Sagar Vora <sagar@resilient.tech>
* fix: Close condition scope
Co-authored-by: Sagar Vora <sagar@resilient.tech>
Co-authored-by: Suraj Shetty <13928957+surajshetty3416@users.noreply.github.com>
(cherry picked from commit e4137ca8a1)
# Conflicts:
# frappe/public/js/frappe/form/footer/form_timeline.js