|
|
@ -485,11 +485,9 @@ frappe.ui.form.on('Publish', { |
|
|
|
dulicate = true; |
|
|
|
} |
|
|
|
}); |
|
|
|
console.log("first if") |
|
|
|
frappe.msgprint("Variant Mapping already added"); |
|
|
|
} |
|
|
|
if (dulicate === false){ |
|
|
|
console.log("2if") |
|
|
|
var child = cur_frm.add_child("publish_documents"); |
|
|
|
child.variant_mapping = frm.doc.variant_mapping; |
|
|
|
child.item_category = "Variant Mapping"; |
|
|
@ -516,7 +514,7 @@ frappe.ui.form.on('Publish', { |
|
|
|
cur_frm.doc.vehicle_status = ''; |
|
|
|
cur_frm.refresh_field('vehicle'); |
|
|
|
cur_frm.refresh_field('vehicle_status'); |
|
|
|
frappe.throw("Already publish record " + r.message + " created for " + vehicle + " vehicle. Please edit already available internal publish!") |
|
|
|
frappe.throw("Already publish record " + r.message + " created for " + vehicle + " vehicle. Please edit already available publish!") |
|
|
|
} |
|
|
|
} |
|
|
|
}); |
|
|
|