fix: Problems while using translations via Globe Symbol (#14128)
Co-authored-by: Vama Mehta <vama.mehta@inqubit.in> (cherry picked from commit 40f2e915918860ade1e514c8b0bb4cf1bb6d0b2b) Co-authored-by: vama <vamagithub@gmail.com>
This commit is contained in:
parent
62a205fe2e
commit
f4d260de0d
2 changed files with 4 additions and 1 deletions
|
|
@ -131,7 +131,7 @@ frappe.ui.form.Control = class BaseControl {
|
|||
if (!this.doc.__islocal) {
|
||||
new frappe.views.TranslationManager({
|
||||
'df': this.df,
|
||||
'source_text': value,
|
||||
'source_text': this.value,
|
||||
'target_language': this.doc.language,
|
||||
'doc': this.doc
|
||||
});
|
||||
|
|
|
|||
|
|
@ -821,6 +821,9 @@ def update_translations_for_source(source=None, translation_dict=None):
|
|||
|
||||
translation_dict = json.loads(translation_dict)
|
||||
|
||||
if is_html(source):
|
||||
source = strip_html_tags(source)
|
||||
|
||||
# for existing records
|
||||
translation_records = frappe.db.get_values('Translation', {
|
||||
'source_text': source
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue