[fix] quoted links now dont contain links (#2246)

This commit is contained in:
RicardoJohann 2016-11-03 05:41:42 -02:00 committed by Rushabh Mehta
parent 3ed6bef17e
commit 17932d7caf

View file

@ -80,6 +80,9 @@ frappe.form.formatters = {
if(!value) {
return "";
}
if(value[0] == "'" && value[value.length -1] == "'") {
return value.substring(1, value.length - 1);
}
if(docfield && docfield.link_onclick) {
return repl('<a onclick="%(onclick)s">%(value)s</a>',
{onclick: docfield.link_onclick.replace(/"/g, '&quot;'), value:value});