Ubuntu
3 years ago
5 changed files with 35 additions and 12 deletions
File diff suppressed because one or more lines are too long
@ -1,8 +1,14 @@ |
|||
# Copyright (c) 2021, Hard n Soft Technologies Pvt Ltd and contributors |
|||
# For license information, please see license.txt |
|||
|
|||
# import frappe |
|||
import frappe |
|||
from frappe.model.document import Document |
|||
|
|||
class Transmission(Document): |
|||
pass |
|||
@frappe.whitelist() |
|||
def validate_text(language,source_text,translated_text): |
|||
current_db_name = frappe.conf.get("db_name") |
|||
tr_record = frappe.db.sql("""select name from {0}.`tabTranslation` where language = '{1}' and source_text = '{2}' and translated_text = '{3}'""".format(current_db_name,language,source_text,translated_text)) |
|||
if tr_record: |
|||
return tr_record |
|||
|
Loading…
Reference in new issue