fix: require email OR phone in shipment doctype not both (backport #47300) (#47330)

fix: require email OR phone in shipment doctype not both (#47300)

(cherry picked from commit fc02a6510e)

Co-authored-by: Mihir Kandoi <kandoimihir@gmail.com>
This commit is contained in:
mergify[bot]
2025-04-29 16:27:56 +05:30
committed by GitHub
parent 2edd12b26d
commit 0056fb1d0f

View File

@@ -162,7 +162,7 @@ frappe.ui.form.on("Shipment", {
args: { contact: contact_name },
callback: function (r) {
if (r.message) {
if (!(r.message.contact_email && (r.message.contact_phone || r.message.contact_mobile))) {
if (!(r.message.contact_email || r.message.contact_phone || r.message.contact_mobile)) {
if (contact_type == "Delivery") {
frm.set_value("delivery_contact_name", "");
frm.set_value("delivery_contact", "");