mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-28 17:34:47 +00:00
Merge pull request #40719 from frappe/fix-ruff-qb-formatting
fix: exclude some query builder lines from ruff rules
This commit is contained in:
@@ -22,7 +22,7 @@ def execute():
|
|||||||
.where(
|
.where(
|
||||||
(si.creation.gte(creation_date))
|
(si.creation.gte(creation_date))
|
||||||
& (si.docstatus == 1)
|
& (si.docstatus == 1)
|
||||||
& (si.is_return is True)
|
& (si.is_return.eq(True))
|
||||||
& (si.return_against.notnull())
|
& (si.return_against.notnull())
|
||||||
)
|
)
|
||||||
.run()
|
.run()
|
||||||
@@ -51,7 +51,7 @@ def execute():
|
|||||||
.where(
|
.where(
|
||||||
(pi.creation.gte(creation_date))
|
(pi.creation.gte(creation_date))
|
||||||
& (pi.docstatus == 1)
|
& (pi.docstatus == 1)
|
||||||
& (pi.is_return is True)
|
& (pi.is_return.eq(True))
|
||||||
& (pi.return_against.notnull())
|
& (pi.return_against.notnull())
|
||||||
)
|
)
|
||||||
.run()
|
.run()
|
||||||
|
|||||||
@@ -62,10 +62,10 @@ def fetch_item_prices(
|
|||||||
or_conditions = []
|
or_conditions = []
|
||||||
if items:
|
if items:
|
||||||
and_conditions.append(ip.item_code.isin([x.item_code for x in items]))
|
and_conditions.append(ip.item_code.isin([x.item_code for x in items]))
|
||||||
and_conditions.append(ip.selling is True)
|
and_conditions.append(ip.selling.eq(True))
|
||||||
|
|
||||||
or_conditions.append(ip.customer is None)
|
or_conditions.append(ip.customer.isnull())
|
||||||
or_conditions.append(ip.price_list is None)
|
or_conditions.append(ip.price_list.isnull())
|
||||||
|
|
||||||
if customer:
|
if customer:
|
||||||
or_conditions.append(ip.customer == customer)
|
or_conditions.append(ip.customer == customer)
|
||||||
|
|||||||
Reference in New Issue
Block a user