fix: Ambiguous column error while submitting stock entry
Stock Entry Type=Manufacture
request.js:457 Traceback (most recent call last):
File "apps/frappe/frappe/app.py", line 94, in application
response = frappe.api.handle()
File "apps/frappe/frappe/api.py", line 54, in handle
return frappe.handler.handle()
File "apps/frappe/frappe/handler.py", line 47, in handle
data = execute_cmd(cmd)
File "apps/frappe/frappe/handler.py", line 85, in execute_cmd
return frappe.call(method, **frappe.form_dict)
File "apps/frappe/frappe/__init__.py", line 1610, in call
return fn(*args, **newargs)
File "apps/frappe/frappe/desk/form/save.py", line 28, in savedocs
doc.save()
File "apps/frappe/frappe/model/document.py", line 305, in save
return self._save(*args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 327, in _save
return self.insert()
File "apps/frappe/frappe/model/document.py", line 259, in insert
self.run_before_save_methods()
File "apps/frappe/frappe/model/document.py", line 1045, in run_before_save_methods
self.run_method("validate")
File "apps/frappe/frappe/model/document.py", line 914, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 1264, in composer
return composed(self, method, *args, **kwargs)
File "apps/frappe/frappe/model/document.py", line 1246, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File "apps/frappe/frappe/model/document.py", line 911, in fn
return method_object(*args, **kwargs)
File "apps/erpnext/erpnext/stock/doctype/stock_entry/stock_entry.py", line 122, in validate
self.validate_qty()
File "apps/erpnext/erpnext/stock/doctype/stock_entry/stock_entry.py", line 433, in validate_qty
transferred_materials = frappe.db.sql(
File "apps/frappe/frappe/database/database.py", line 220, in sql
self._cursor.execute(query, values)
File "env/lib/python3.10/site-packages/pymysql/cursors.py", line 158, in execute
result = self._query(query)
File "env/lib/python3.10/site-packages/pymysql/cursors.py", line 325, in _query
conn.query(q)
File "env/lib/python3.10/site-packages/pymysql/connections.py", line 549, in query
self._affected_rows = self._read_query_result(unbuffered=unbuffered)
File "env/lib/python3.10/site-packages/pymysql/connections.py", line 779, in _read_query_result
result.read()
File "env/lib/python3.10/site-packages/pymysql/connections.py", line 1157, in read
first_packet = self.connection._read_packet()
File "env/lib/python3.10/site-packages/pymysql/connections.py", line 729, in _read_packet
packet.raise_for_error()
File "env/lib/python3.10/site-packages/pymysql/protocol.py", line 221, in raise_for_error
err.raise_mysql_exception(self._data)
File "env/lib/python3.10/site-packages/pymysql/err.py", line 143, in raise_mysql_exception
raise errorclass(errno, errval)
pymysql.err.OperationalError: (1052, "Column 'qty' in field list is ambiguous")
(cherry picked from commit c21fd45883)
Co-authored-by: MohsinAli <mmatiyailol@gmail.com>
In a multi term payment schedule, overallocation logic broke. Fixing
it using individual term outstanding amount in references. this should
work for the simple, one term payment schedule as well
(cherry picked from commit f8d4b19cb9)
In a multi term payment schedule, overallocation logic broke. Fixing
it using individual term outstanding amount in references. this should
work for the simple, one term payment schedule as well
(cherry picked from commit f8d4b19cb9)
* fix: Remove current fiscal year from Global Defaults (#35960)
* fix: Remove current fiscal year from Global Defaults
* fix: Remove button to set default
* fix: Add utils to get fiscal year
* fix: Incorrect import
* feat: Add hook for naming series parser
(cherry picked from commit 6270607c6d)
# Conflicts:
# erpnext/accounts/doctype/fiscal_year/fiscal_year.py
# erpnext/patches.txt
# erpnext/public/js/utils.js
* chore: resolve conflicts
---------
Co-authored-by: Deepesh Garg <deepeshgarg6@gmail.com>
chore: add validation for account type of party type and account (#36141)
chore: add validation to check if account type of party type and account match
(cherry picked from commit 305c37917f)
Co-authored-by: Anand Baburajan <anandbaburajan@gmail.com>
* perf: index `variant_of` and `attribute` in `Item Variant Attribute`
(cherry picked from commit e4128a5c91)
* perf: index `disabled` in `Item`
(cherry picked from commit 04400eb2e4)
---------
Co-authored-by: s-aga-r <sagarsharma.s312@gmail.com>
* feat: add local holidays
(cherry picked from commit aa18b25a71)
* test(Holiday List): weekly off and local holidays
(cherry picked from commit fd23bd0434)
* feat(Holiday List): display localized country name
(cherry picked from commit 4888d75e72)
* fix: German translations of Holiday List
(cherry picked from commit 509061f05b)
# Conflicts:
# erpnext/translations/de.csv
* fix(Holiday List): use current user's language
For consistency with "weekly off" descriptions
(cherry picked from commit 8271a39cdb)
* fix(Holiday List): allow empty value
(cherry picked from commit 8aff5a1dab)
* refactor(Holiday List): use autocomplete fieldtype
(cherry picked from commit dab9688410)
* chore: resolve merge conflicts
---------
Co-authored-by: barredterra <14891507+barredterra@users.noreply.github.com>