Compare commits

..

11 Commits

Author SHA1 Message Date
Frappe PR Bot
33185e0a3b chore(release): Bumped to Version 15.17.0
# [15.17.0](https://github.com/frappe/erpnext/compare/v15.16.2...v15.17.0) (2024-03-13)

### Bug Fixes

* **accounts:** Allow setting Number of new Cost Center (backport [#40212](https://github.com/frappe/erpnext/issues/40212)) ([#40314](https://github.com/frappe/erpnext/issues/40314)) ([7001e0a](7001e0a820))
* advance paid amount and ledger entries against SO/PO ([6a5a941](6a5a941a5a))
* barcode field on line item not working (backport [#40381](https://github.com/frappe/erpnext/issues/40381)) ([#40384](https://github.com/frappe/erpnext/issues/40384)) ([9ce68de](9ce68deff5))
* batch no not copied while making Material Consumption entry (backport [#40290](https://github.com/frappe/erpnext/issues/40290)) ([#40300](https://github.com/frappe/erpnext/issues/40300)) ([6d1c144](6d1c144a66))
* Blanket order rate getting changed on converting to order ([d8c6eb0](d8c6eb0bf2))
* conditionally apply `is_group` filter in accounting dimension query (backport [#40414](https://github.com/frappe/erpnext/issues/40414)) ([#40416](https://github.com/frappe/erpnext/issues/40416)) ([40752c1](40752c1f5c))
* decimal issue while making the stock entry (backport [#40394](https://github.com/frappe/erpnext/issues/40394)) ([#40397](https://github.com/frappe/erpnext/issues/40397)) ([91af7c0](91af7c033a))
* error message wording ([#40403](https://github.com/frappe/erpnext/issues/40403)) ([2a40808](2a40808b05))
* Filter for projects in Sales Cycle ([173b3b8](173b3b85f6))
* get_user_default_as_list args order ([44ff607](44ff607dcd))
* if input manualy material request on WO the material_request_item is not set so validate WO give error (backport [#40180](https://github.com/frappe/erpnext/issues/40180)) ([#40421](https://github.com/frappe/erpnext/issues/40421)) ([a5e6763](a5e6763be5))
* incorrect advance paid in Sales/Purchase Order ([6832908](6832908e92))
* incorrect work order status (backport [#40407](https://github.com/frappe/erpnext/issues/40407)) ([#40411](https://github.com/frappe/erpnext/issues/40411)) ([605132a](605132a31c))
* load ignored doctype and include Mode of Payment Account ([#40334](https://github.com/frappe/erpnext/issues/40334)) ([5fac500](5fac50036a))
* MR Default Supplier search query (backport [#40273](https://github.com/frappe/erpnext/issues/40273)) ([#40351](https://github.com/frappe/erpnext/issues/40351)) ([a195dd3](a195dd3c1f))
* negative stock error for the batch (backport [#40389](https://github.com/frappe/erpnext/issues/40389)) ([#40391](https://github.com/frappe/erpnext/issues/40391)) ([478b988](478b988290))
* not able to cancel purchase receipt for old subcontracting flow (backport [#40298](https://github.com/frappe/erpnext/issues/40298)) ([#40302](https://github.com/frappe/erpnext/issues/40302)) ([e0e80f7](e0e80f7eed))
* qc created for raw materials during manufacture entry (backport [#40408](https://github.com/frappe/erpnext/issues/40408)) ([#40413](https://github.com/frappe/erpnext/issues/40413)) ([f932265](f932265218))
* recursion issue while submitting work order (backport [#40400](https://github.com/frappe/erpnext/issues/40400)) ([#40402](https://github.com/frappe/erpnext/issues/40402)) ([d6e87f3](d6e87f3f17))
* Sender email in process statements of accounts ([953f640](953f64091a))
* **Shipment Parcel:** make length, width and height non-mandatory ([1476196](1476196966))
* stock ledger balance qty for the batch (backport [#40274](https://github.com/frappe/erpnext/issues/40274)) ([#40301](https://github.com/frappe/erpnext/issues/40301)) ([62aefce](62aefcef04))
* use serial batch fields for subcontracting receipt (backport [#40311](https://github.com/frappe/erpnext/issues/40311)) ([#40315](https://github.com/frappe/erpnext/issues/40315)) ([4b15c00](4b15c00b11))
* use serial/batch field for rejected items (backport [#40327](https://github.com/frappe/erpnext/issues/40327)) ([#40329](https://github.com/frappe/erpnext/issues/40329)) ([7ca7242](7ca72423b9))
* Use serial/batch fields for delivery note return (backport [#40374](https://github.com/frappe/erpnext/issues/40374)) ([#40376](https://github.com/frappe/erpnext/issues/40376)) ([32660ab](32660abdc8))

### Features

* add recursion qty field in promotional scheme ([5f4b23d](5f4b23d4af))
2024-03-13 04:29:12 +00:00
Deepesh Garg
0e4e0b3084 Merge pull request #40395 from frappe/version-15-hotfix
chore: release v15
2024-03-13 09:57:54 +05:30
mergify[bot]
a5e6763be5 fix: if input manualy material request on WO the material_request_item is not set so validate WO give error (backport #40180) (#40421)
fix: if input manualy material request on WO the material_request_item is not set so validate WO give error (#40180)

(cherry picked from commit f24f51b7de)

Co-authored-by: HENRY Florian <florian.henry@open-concept.pro>
2024-03-12 21:56:14 +05:30
mergify[bot]
26a1d84935 chore: Add translation to buttons in Update stock_summary_template.html (backport #40099) (#40419)
chore: Add translation to buttons in Update stock_summary_template.html (#40099)

chore: Add translation to buttons in Update stock_summary_template.html
(cherry picked from commit f3b4237ab6)

Co-authored-by: Ernesto Ruiz <eruiz@wbapps.com>
2024-03-12 21:31:30 +05:30
mergify[bot]
40752c1f5c fix: conditionally apply is_group filter in accounting dimension query (backport #40414) (#40416)
fix: conditionally apply `is_group` filter in accounting dimension query (#40414)

(cherry picked from commit daf4ae2a6b)

Co-authored-by: Rucha Mahabal <ruchamahabal2@gmail.com>
2024-03-12 20:45:31 +05:30
Raffael Meyer
0ad203ab89 Merge pull request #40406 from frappe/mergify/bp/version-15-hotfix/pr-40403
fix: error message wording (backport #40403)
2024-03-12 14:29:49 +01:00
mergify[bot]
605132a31c fix: incorrect work order status (backport #40407) (#40411)
fix: incorrect work order status (#40407)

(cherry picked from commit 948297692e)

Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
2024-03-12 18:34:25 +05:30
mergify[bot]
f932265218 fix: qc created for raw materials during manufacture entry (backport #40408) (#40413)
fix: qc created for raw materials during manufacture entry (#40408)

(cherry picked from commit f8a1a7f515)

Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
2024-03-12 18:29:11 +05:30
Raffael Meyer
2a40808b05 fix: error message wording (#40403)
(cherry picked from commit 79a0473705)
2024-03-12 11:26:56 +00:00
mergify[bot]
d6e87f3f17 fix: recursion issue while submitting work order (backport #40400) (#40402)
* fix: recursion issue while submitting work order (#40400)

(cherry picked from commit 72614bb8ff)

* chore: fix linter issue

---------

Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
2024-03-12 16:50:00 +05:30
mergify[bot]
91af7c033a fix: decimal issue while making the stock entry (backport #40394) (#40397)
fix: decimal issue while making the stock entry (#40394)

(cherry picked from commit 4a02d1497c)

Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
2024-03-12 15:35:55 +05:30
8 changed files with 32 additions and 13 deletions

View File

@@ -3,7 +3,7 @@ import inspect
import frappe
__version__ = "15.16.2"
__version__ = "15.17.0"
def get_default_company(user=None):

View File

@@ -410,11 +410,11 @@ class Subscription(Document):
# Earlier subscription didn't had any company field
company = self.get("company") or get_default_company()
if not company:
# fmt: off
frappe.throw(
_("Company is mandatory was generating invoice. Please set default company in Global Defaults.")
_(
"Company is mandatory for generating an invoice. Please set a default company in Global Defaults."
)
)
# fmt: on
invoice = frappe.new_doc(self.invoice_document_type)
invoice.company = company

View File

@@ -665,7 +665,7 @@ def get_filtered_dimensions(
searchfields = frappe.get_meta(doctype).get_search_fields()
meta = frappe.get_meta(doctype)
if meta.is_tree:
if meta.is_tree and meta.has_field("is_group"):
query_filters.append(["is_group", "=", 0])
if meta.has_field("disabled"):

View File

@@ -264,7 +264,7 @@ class JobCard(Document):
if not self.has_overlap(production_capacity, time_logs):
return {}
if self.workstation_type and time_logs:
if not self.workstation and self.workstation_type and time_logs:
if workstation_time := self.get_workstation_based_on_available_slot(time_logs):
self.workstation = workstation_time.get("workstation")
return workstation_time
@@ -420,7 +420,7 @@ class JobCard(Document):
if not workstation_doc.working_hours or cint(
frappe.db.get_single_value("Manufacturing Settings", "allow_overtime")
):
if get_datetime(row.planned_end_time) < get_datetime(row.planned_start_time):
if get_datetime(row.planned_end_time) <= get_datetime(row.planned_start_time):
row.planned_end_time = add_to_date(row.planned_start_time, minutes=row.time_in_mins)
row.remaining_time_in_mins = 0.0
else:

View File

@@ -52,10 +52,10 @@
</span>
</div>
<div class="col-sm-1">
<button style="margin-left: 7px;" class="btn btn-default btn-xs btn-add" data-item-code="{{ escape(row.item_code) }}">Add</button>
<button style="margin-left: 7px;" class="btn btn-default btn-xs btn-add" data-item-code="{{ escape(row.item_code) }}">{{ __("Add") }}</button>
</div>
<div class="col-sm-1">
<button style="margin-left: 7px;" class="btn btn-default btn-xs btn-move" data-item-code="{{ escape(row.item_code) }}">Move</button>
<button style="margin-left: 7px;" class="btn btn-default btn-xs btn-move" data-item-code="{{ escape(row.item_code) }}">{{ __("Move") }}</button>
</div>
</div>
{% }); %}
{% }); %}

View File

@@ -330,6 +330,13 @@ class WorkOrder(Document):
else:
status = "Cancelled"
if (
self.skip_transfer
and self.produced_qty
and self.qty > (flt(self.produced_qty) + flt(self.process_loss_qty))
):
status = "In Process"
return status
def update_work_order_qty(self):
@@ -784,7 +791,7 @@ class WorkOrder(Document):
)
def update_completed_qty_in_material_request(self):
if self.material_request:
if self.material_request and self.material_request_item:
frappe.get_doc("Material Request", self.material_request).update_completed_qty(
[self.material_request_item]
)

View File

@@ -2219,7 +2219,7 @@ erpnext.TransactionController = class TransactionController extends erpnext.taxe
});
this.frm.doc.items.forEach(item => {
if (!item.quality_inspection) {
if (this.has_inspection_required(item)) {
let dialog_items = dialog.fields_dict.items;
dialog_items.df.data.push({
"docname": item.name,
@@ -2243,6 +2243,16 @@ erpnext.TransactionController = class TransactionController extends erpnext.taxe
}
}
has_inspection_required(item) {
if (this.frm.doc.doctype === "Stock Entry" && this.frm.doc.purpose == "Manufacture" ) {
if (item.is_finished_item && !item.quality_inspection) {
return true;
}
} else if (!item.quality_inspection) {
return true;
}
}
get_method_for_payment() {
var method = "erpnext.accounts.doctype.payment_entry.payment_entry.get_payment_entry";
if(cur_frm.doc.__onload && cur_frm.doc.__onload.make_payment_via_journal_entry){

View File

@@ -2064,6 +2064,7 @@ class StockEntry(StockController):
as_dict=1,
)
precision = frappe.get_precision("Stock Entry Detail", "qty")
for key, row in available_materials.items():
remaining_qty_to_produce = flt(wo_data.trans_qty) - flt(wo_data.produced_qty)
if remaining_qty_to_produce <= 0 and not self.is_return:
@@ -2086,7 +2087,8 @@ class StockEntry(StockController):
serial_nos = row.serial_nos[0 : cint(qty)]
row.serial_nos = serial_nos
self.update_item_in_stock_entry_detail(row, item, qty)
if flt(qty, precision) != 0.0:
self.update_item_in_stock_entry_detail(row, item, qty)
def update_batches_to_be_consume(self, batches, row, qty):
qty_to_be_consumed = qty