Skip to content

Commit

Permalink
fix: total allocated percentage for sales team issue
Browse files Browse the repository at this point in the history
(cherry picked from commit b498094)
  • Loading branch information
ruthra-kumar authored and mergify[bot] committed Jan 9, 2024
1 parent 0ebd133 commit 71f9b7f
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions erpnext/selling/doctype/quotation/quotation.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,15 +288,16 @@ def set_missing_values(source, target):
)

# sales team
for d in customer.get("sales_team") or []:
target.append(
"sales_team",
{
"sales_person": d.sales_person,
"allocated_percentage": d.allocated_percentage or None,
"commission_rate": d.commission_rate,
},
)
if not target.get("sales_team"):
for d in customer.get("sales_team") or []:
target.append(
"sales_team",
{
"sales_person": d.sales_person,
"allocated_percentage": d.allocated_percentage or None,
"commission_rate": d.commission_rate,
},
)

target.flags.ignore_permissions = ignore_permissions
target.delivery_date = nowdate()
Expand Down

0 comments on commit 71f9b7f

Please sign in to comment.