Skip to content

Commit

Permalink
fix: patch - Duplicate entry quality inspection parameter (backport #…
Browse files Browse the repository at this point in the history
…38262) (#38263)

fix: patch - Duplicate entry quality inspection parameter (#38262)

(cherry picked from commit 0ca7527)

Co-authored-by: rohitwaghchaure <[email protected]>
  • Loading branch information
mergify[bot] and rohitwaghchaure authored Nov 23, 2023
1 parent 5261aba commit 756f08b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions erpnext/patches/v13_0/convert_qi_parameter_to_link_field.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ def execute():
params = set({x.casefold(): x for x in params}.values())

for parameter in params:
if frappe.db.exists("Quality Inspection Parameter", parameter):
continue

frappe.get_doc(
{"doctype": "Quality Inspection Parameter", "parameter": parameter, "description": parameter}
).insert(ignore_permissions=True)

0 comments on commit 756f08b

Please sign in to comment.