60168 Commits

Author SHA1 Message Date
Mihir Kandoi
71f843e5bf Merge pull request #57154 from aerele/fix-production-plan-bom-warehouse-n-plus-one
fix: batch BOM source warehouse lookup in get_production_items to avo…
2026-07-14 22:18:58 +05:30
pandiyan
4705909cee fix: batch BOM source warehouse lookups to avoid n+1 queries in production plan work order creation 2026-07-14 22:07:52 +05:30
Nabin Hait
04f75cc64f Merge pull request #56983 from nabinhait/fix-flaky-usd-exchange-rate-tests
test: seed current-dated USD↔INR exchange rate to fix flaky currency tests
2026-07-14 18:13:28 +05:30
Nabin Hait
5133ba47b7 fix: make currency exchange truly idempotent against any pre-existing state
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
2026-07-14 18:02:59 +05:30
rohitwaghchaure
1fd2faa68d fix: permission issue (#57112) 2026-07-14 12:22:48 +00:00
Soham Kulkarni
4d2b603ba6 Merge pull request #57134 from sokumon/merge-workspaces
fix: merge erpnext workspaces
2026-07-14 17:10:28 +05:30
Mihir Kandoi
d7f4524cdd refactor: convert Hide Currency Symbol in Global Defaults to a Check field (#57135) 2026-07-14 11:10:07 +00:00
Mihir Kandoi
876adcb535 Merge pull request #57129 from SandraFrappe/fix/purchase-order-duplicate-material-request-item
fix: prevent duplicate material request items in purchase order
2026-07-14 16:31:26 +05:30
Mihir Kandoi
b2ec906ff3 test: remove test 2026-07-14 16:18:53 +05:30
sokumon
f2e8c7b664 fix: add sequence for erpnext 2026-07-14 16:05:44 +05:30
Mihir Kandoi
b6cce627a8 feat: company-wise restriction for Item, Customer and Supplier masters (#57124) 2026-07-14 10:30:47 +00:00
SandraFrappe
2d6f89a7f5 fix: prevent duplicate material request items in purchase order 2026-07-14 14:32:06 +05:30
sokumon
ac99d28100 chore: merge erpnext workspaces 2026-07-14 14:27:39 +05:30
Mihir Kandoi
823dbb7a2b Merge pull request #57127 from mihir-kandoi/naming-posting-date-default-on
feat: make naming series based on posting datetime on by default on n…
2026-07-14 13:49:34 +05:30
Mihir Kandoi
7db93d8b19 feat: make naming series based on posting datetime on by default on new sites 2026-07-14 13:38:41 +05:30
Diptanil Saha
d82e6c4f12 fix(accounts): added permission checks on get_account_balances_coa (#57107) 2026-07-14 07:26:43 +00:00
Smit Vora
7f4be47d43 Merge pull request #56912 from ljain112/refactor-subcon
refactor: move functionality in postprocess for mapped doc
2026-07-14 11:53:58 +05:30
Khushi Rawat
7371df129f Merge pull request #57111 from khushi8112/remove-dead-dashboard-fixtures
chore: remove dead assets dashboard_fixtures with broken imports
2026-07-14 11:53:07 +05:30
khushi8112
14a15cc6f9 chore: remove dead assets dashboard_fixtures with broken imports (#57079)
erpnext.accounts.dashboard_fixtures and erpnext.buying.dashboard_fixtures
were removed in 2020 when dashboards were exported to JSON fixtures.
The assets module's dashboard_fixtures.py was left behind unreferenced;
its dashboard, charts and number cards already exist as exported JSON.
2026-07-14 11:40:34 +05:30
Mihir Kandoi
f4f9030437 Merge pull request #57114 from frappe/mergify/bp/develop/pr-57113
fix(stock): set stock_uom on transferred Stock Reservation Entries (backport #57113)
2026-07-14 11:39:00 +05:30
Mihir Kandoi
1d5ec14530 Merge pull request #57116 from aerele/get_bundle_wise_serial_nos-db-params-limit
fix(stock): fix sqlparse token limit in get_bundle_wise_serial_nos
2026-07-14 11:29:34 +05:30
PranavDarade
e321e95e59 fix(stock): set stock_uom on transferred Stock Reservation Entries
StockReservation.transfer_reservation_entries_to() created the transferred SREs without copying stock_uom, in both the entries_to_reserve dict and the extra-items fallback. get_items_to_reserve() already selects the item's stock_uom, so entry.stock_uom is used.

On sites with a global default stock_uom (e.g. "Nos"), frappe's _set_defaults() backfilled the blank field, so the transfer silently stored the wrong UOM for any item whose stock UOM is not the default. On sites without that default the SRE's validate_mandatory() raised "Stock UOM is required", aborting Work Order submission for the Subcontracting Inward Order / Production Plan flows.

(cherry picked from commit 5991ecfa3d)
2026-07-14 11:27:07 +05:30
Afsal Syed
e748bf512b test(stock): add unit test for get_bundle_wise_serial_nos query 2026-07-14 11:18:17 +05:30
Afsal Syed
4544a6c935 fix(stock): fix sqlparse token limit in get_bundle_wise_serial_nos 2026-07-14 11:18:17 +05:30
Mihir Kandoi
336970aa5a Merge pull request #57115 from mihir-kandoi/fix/supplier-scorecard-month-end-idempotency
fix: duplicate scorecard period when supplier is created on a month end
2026-07-14 10:55:59 +05:30
Mihir Kandoi
3aafda331b fix: duplicate scorecard period when supplier is created on a month end
make_all_scorecards' dedup query used strict bounds, so a single-day
period (supplier created on a month's last day -> start == end under
"Per Month") never matched its own window and was re-created on every
call. The daily refresh_scorecards job would insert a duplicate
submitted period each day for such suppliers, and
test_make_all_scorecards_is_idempotent fails on any date where
nowdate() - 75 days lands on a month end — both nightly server suites
went red on 2026-07-14 (75 days after April 30).

Inclusive bounds cannot false-match adjacent periods: each next period
starts at end_date + 1, so closed intervals never touch.
2026-07-14 10:20:41 +05:30
Mihir Kandoi
39b5c6ba2a Merge pull request #57101 from aerele/fix/job-card-work-order-transferred-qty
fix(manufacturing): preserve job card transferred quantity
2026-07-13 21:06:28 +05:30
Mihir Kandoi
3dba2d23b8 Merge pull request #57099 from aerele/fix-stock-entry-bom-query-redundancy
perf: avoid redundant bom cost_allocation_per query per finished item…
2026-07-13 21:05:13 +05:30
Mihir Kandoi
b23224b3d6 Merge pull request #57091 from aerele/fix/so-qty-company-warehouse
fix(stock): show qty (company) and qty (warehouse) in sales transactions
2026-07-13 21:03:07 +05:30
Mihir Kandoi
c0147e5a2e Merge pull request #57089 from aerele/fix-pick-list-barcode-scan-max-qty
fix: allow barcode scan to add and increment items in pick list
2026-07-13 21:02:08 +05:30
Sudharsanan11
51f9b70bfa test(manufacturing): cover transferred quantity across job cards 2026-07-13 19:40:20 +05:30
Sudharsanan11
951e432a1b fix(manufacturing): preserve job card transferred quantity 2026-07-13 19:40:20 +05:30
pandiyan
feb750f082 perf: avoid redundant bom cost_allocation_per query per finished item row in stock entry 2026-07-13 18:29:23 +05:30
Diptanil Saha
9c353741ad fix(tnc): using get_cached_doc to retrieve template for get_terms_and_conditions and permission checks (#57096) 2026-07-13 11:24:56 +00:00
Sudharsanan11
4e5e1f6596 test(stock): assert qty (company) and qty (warehouse) on item details
covers sales order, quotation, sales invoice, delivery note and
purchase order, asserting actual_qty from the row warehouse and
company_total_stock across all warehouses of the company.
2026-07-13 14:37:23 +05:30
Sudharsanan11
ab30bab6cb fix(stock): show qty (company) and qty (warehouse) in sales transactions
company was passed to get_bin_details only for purchase order, so
company_total_stock was never returned for sales order, quotation,
sales invoice and delivery note and the qty (company) column always
read zero. pass ctx.company for every doctype, which also drops the
dependency on doc being supplied.

on the client, set_actual_qty copied only actual_qty out of the
response, so qty (company) never refreshed on a warehouse change. use
frm.call with child so every bin field is applied, pass
include_child_warehouses to match the server, and include quotation.
2026-07-13 14:37:23 +05:30
pandiyan
3ece4a615d fix: allow barcode scan to add and increment items in pick list
- allow new rows on scan when pick manually is enabled, since only
  then are scanned rows not subject to being overridden by
  set_item_locations on save
- stop capping picked qty at the default demand qty (1) for rows
  added by the scanner itself, so repeat scans of the same barcode
  keep incrementing the row instead of failing with "maximum
  quantity scanned"
- ignore barcode uom when matching an existing row if new rows
  aren't allowed, since there's no alternate-uom row to fall back to
2026-07-13 13:54:54 +05:30
ruthra kumar
33abc53d7a Merge pull request #56817 from Soham-ambibuzz/philipinnes_localization_coa_v3
feat: restructure Philippines chart of accounts with amortization sup…
2026-07-13 12:56:31 +05:30
ruthra kumar
47341ff55c Merge pull request #56628 from aerele/multi-currency
fix(journal-entry): fetch outstanding on foreign currency
2026-07-13 12:35:15 +05:30
ruthra kumar
7144e5b29a Merge pull request #56458 from Shllokkk/psoa-restrict-jinja-globals
fix: restrict jinja globals in process statement of accounts templates
2026-07-13 12:34:04 +05:30
ruthra kumar
f0326aa6cf Merge pull request #56902 from frappe/fix-budget-variance-chart-month-shift
fix(budget-variance): correct month shift in comparison chart
2026-07-13 12:31:27 +05:30
Khushi Rawat
2580601937 Merge pull request #57071 from iamejaaz/fix-letterhead-company-guard
fix: guard company logo lookup in default letterheads
2026-07-13 11:58:31 +05:30
Khushi Rawat
14dac6ecc4 Merge pull request #55276 from aerele/fix/asset-repair-fully-depreciated
fix(asset): allow asset repair creation for fully depreciated assets
2026-07-13 02:09:13 +05:30
Mihir Kandoi
e8a61ecfbb Merge pull request #57073 from mihir-kandoi/gh57072
fix: make represents company field in purchase invoice ignore user pe…
2026-07-13 00:08:24 +05:30
Mihir Kandoi
6729a53fee fix: make represents company field in purchase invoice ignore user permissions 2026-07-12 23:56:23 +05:30
MochaMind
612a3f20d8 chore: update POT file (#57067) 2026-07-12 20:25:54 +02:00
Ejaaz Khan
e39ca72997 fix: set explicit table and logo widths in grey letterhead 2026-07-12 22:03:32 +05:30
Ejaaz Khan
23c09fe0f3 fix: guard company logo lookup in default letterheads 2026-07-12 21:17:42 +05:30
Nabin Hait
e1e56b6920 test: adjust currency tests for deterministic seeded exchange rate
Seeding a current-dated USD->INR rate makes get_exchange_rate resolve
62.9 on today() instead of hitting the live API, which exposed three
tests that implicitly relied on a different/undefined current rate:

- customer: dropped its own colliding current-dated seed (ignored via
  ignore_if_duplicate, and its cleanup deleted the shared seed) and now
  asserts the quotation resolves the seeded rate via get_exchange_rate.
- exchange_rate_revaluation: the revalued rate (62.9) is now below the
  booked 80, so the revaluation is a loss (debited) rather than a gain;
  derive the gain/loss column from the sign instead of assuming a gain.
- purchase_invoice: the receipt rate was an accidental tuple (70,) that
  got discarded and recomputed to the seed; set explicit rates with the
  receipt above the invoice so the stock exchange difference is a credit,
  matching the asserted column.
2026-07-12 21:12:29 +05:30
Nabin Hait
7928608b0f Merge pull request #56973 from nabinhait/refactor-stock-gl-composer
refactor(stock): de-conditionalize BaseStockGLComposer via subclass hooks
2026-07-12 20:32:49 +05:30