diff --git a/erpnext/buying/doctype/purchase_order/purchase_order.js b/erpnext/buying/doctype/purchase_order/purchase_order.js index 7c38d80c03c0..d3bc2893d5db 100644 --- a/erpnext/buying/doctype/purchase_order/purchase_order.js +++ b/erpnext/buying/doctype/purchase_order/purchase_order.js @@ -195,7 +195,7 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend( frappe.set_route("query-report", "Purchase Order Report"); }, __("View")); } - if(!in_list(["Closed", "Ready", "Shipped", "Proposed Ready Date", "Open"], doc.status)) { + if(!in_list(["Closed", "Ready", "Shipped", "Proposed Ready Date", "Open", "Ready and Short Close", "Shipped and Short Close"], doc.status)) { /* if(this.frm.doc.status !== 'Closed' && flt(this.frm.doc.per_received) < 100 && flt(this.frm.doc.per_billed) < 100) { this.frm.add_custom_button(__('Update Items'), () => { erpnext.utils.update_child_items({ @@ -213,8 +213,16 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend( } else{ this.frm.add_custom_button(__('Resume'), () => this.unhold_purchase_order(), __("Status")); } */ - if (doc.status != "Ready") { - this.frm.add_custom_button(__('Ready'), () => this.direct_ready_purchase_order(), __("Status")); + var ready_not_shipped = 0; + $.each(doc.items || [], function (i, row) { + if (row.received_qty != row.shipped_qty) { + ready_not_shipped = 1 + } + }) + if (doc.status != "Ready and Short Close" && ready_not_shipped == 1) { + this.frm.add_custom_button(__('Ready and Short Close'), () => this.short_close_po_for_ready(), __("Status")); + } else if (doc.status != "Ready and Short Close" && ready_not_shipped == 0) { + this.frm.add_custom_button(__('Shipped and Short Close'), () => this.short_close_po_for_shipped(), __("Status")); } } } @@ -225,7 +233,7 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend( this.frm.page.set_inner_btn_group_as_primary(__("Status")); } */ - } else if(flt(doc.per_received, 6) < 100 && in_list(["Closed", "Delivered", "Ready"], doc.status)) { + } else if(flt(doc.per_received, 6) < 100 && in_list(["Closed", "Delivered", "Ready and Short Close", "Shipped and Short Close"], doc.status)) { if (this.frm.has_perm("submit")) { this.frm.add_custom_button(__('Re-open'), () => this.unclose_purchase_order(), __("Status")); } @@ -239,10 +247,10 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend( if(doc.status != "Closed") { if (doc.status != "On Hold") { // ***** START Proposed Ready Date & Ready PO Custom Button Instead of Purchase Receipt ***** // - if(flt(doc.per_received) < 100 && allow_receipt && !in_list(["Ready", "Shipped", "Open"], doc.status)) { + if(flt(doc.per_received) < 100 && allow_receipt && !in_list(["Ready", "Shipped", "Open", "Ready and Short Close", "Shipped and Short Close"], doc.status)) { cur_frm.add_custom_button(__('Ready PO'), this.make_purchase_receipt,); } - if (!in_list(["Ready", "Shipped", "Proposed Ready Date", "Partially Ready"], doc.status)) { + if (!in_list(["Ready", "Shipped", "Proposed Ready Date", "Partially Ready","Ready and Short Close", "Shipped and Short Close"], doc.status)) { cur_frm.add_custom_button(__("Proposed Ready Date"), function() { cur_frm.doc.po_status="Proposed Ready Date"; cur_frm.doc.status="Proposed Ready Date"; @@ -674,8 +682,13 @@ erpnext.buying.PurchaseOrderController = erpnext.buying.BuyingController.extend( cur_frm.cscript.update_status('Close', 'Closed') }, - direct_ready_purchase_order: function(){ - cur_frm.cscript.update_status('Ready', 'Ready') + short_close_po_for_ready: function(){ + cur_frm.cscript.update_status('Ready and Short Close', 'Ready and Short Close') + refresh_field('status') + }, + short_close_po_for_shipped: function(){ + cur_frm.cscript.update_status('Shipped and Short Close', 'Shipped and Short Close') + refresh_field('status') }, delivered_by_supplier: function(){ diff --git a/erpnext/buying/doctype/purchase_order/purchase_order.json b/erpnext/buying/doctype/purchase_order/purchase_order.json index 2549b5b0f9c6..75f8db9ddaed 100644 --- a/erpnext/buying/doctype/purchase_order/purchase_order.json +++ b/erpnext/buying/doctype/purchase_order/purchase_order.json @@ -976,7 +976,7 @@ "no_copy": 1, "oldfieldname": "status", "oldfieldtype": "Select", - "options": "\nOpen\nProposed Ready Date\nPartially Ready\nReady\nShipped\nCancelled", + "options": "\nOpen\nProposed Ready Date\nPartially Ready\nReady and Short Close\nReady\nShipped\nShipped and Short Close\nCancelled", "print_hide": 1, "read_only": 1, "reqd": 1, @@ -1245,7 +1245,7 @@ "fieldname": "po_status", "fieldtype": "Select", "label": "PO Status", - "options": "Open\nProposed Ready Date\nPartially Ready\nReady\nShipped\nCancelled" + "options": "Open\nProposed Ready Date\nPartially Ready\nReady and Short\nReady\nShipped\nCancelled" }, { "allow_on_submit": 1, @@ -1271,7 +1271,7 @@ { "fieldname": "section_break_142", "fieldtype": "Section Break", - "hidden": 1 + "hidden": 0 }, { "allow_on_submit": 1, @@ -1287,7 +1287,7 @@ "idx": 105, "is_submittable": 1, "links": [], - "modified": "2023-02-14 05:35:29.939784", + "modified": "2023-12-06 05:39:06.601927", "modified_by": "Administrator", "module": "Buying", "name": "Purchase Order", diff --git a/erpnext/buying/doctype/purchase_order/purchase_order.py b/erpnext/buying/doctype/purchase_order/purchase_order.py index 65a3b1e7fcc4..6573846d9195 100644 --- a/erpnext/buying/doctype/purchase_order/purchase_order.py +++ b/erpnext/buying/doctype/purchase_order/purchase_order.py @@ -701,12 +701,12 @@ def update_status(status, name): po = frappe.get_doc("Purchase Order", name) po.update_status(status) po.update_delivered_qty_in_sales_order() - if po.status == "Ready": - total_received_amt = 0 - for d in po.get("items"): - total_received_amt += d.rate - # Update Ammount in Account Payble DocType - frappe.db.set_value("Account Payable", po.name, 'total_payable_after_revision', 0) + # if po.status == "Ready": + # total_received_amt = 0 + # for d in po.get("items"): + # total_received_amt += d.rate + # # Update Ammount in Account Payble DocType + # frappe.db.set_value("Account Payable", po.name, 'total_payable_after_revision', 0) @frappe.whitelist() diff --git a/erpnext/buying/print_format/unizone_po/unizone_po.json b/erpnext/buying/print_format/unizone_po/unizone_po.json index ac209203d834..b1f13830744a 100644 --- a/erpnext/buying/print_format/unizone_po/unizone_po.json +++ b/erpnext/buying/print_format/unizone_po/unizone_po.json @@ -1,27 +1,27 @@ { - "absolute_value": 0, - "align_labels_right": 0, - "creation": "2022-08-22 19:30:39.041461", - "css": "/* @page {*/\n/* margin: 0;*/\n/*}*/\n\n.print-format, .print-format-preview {font-size: 10; padding: 0.25in;}\n\n.print-display-flex {\n display: flex;\n justify-content: space-between;\n }\n\n.print-display-flex h2 div {font-size: 16px; font-weight: bold;}\n\n.print-company-info {text-align: left;}\n.print-company-info h3 {margin-top: 0; color: #0b6cb4;}\n.print-company-info p {\n color: #0b6cb4; \n font-size: 11px;\n margin-bottom: 5px;\n }", - "custom_format": 0, - "default_print_language": "", - "disabled": 0, - "doc_type": "Purchase Order", - "docstatus": 0, - "doctype": "Print Format", - "font": "Helvetica Neue", - "format_data": "[{\"fieldname\": \"print_heading_template\", \"fieldtype\": \"Custom HTML\", \"options\": \"
\\n
\\n

UNIZONE PTE. LTD.

\\n

\\n UNIT 15-01 Valley Point
\\n 491B River Valley Road, Singapore 248373\\n

\\n
\\t\\n

Purchase Order
{{ doc.name }}\\t\\t\\t\\t

\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"supplier_name\", \"print_hide\": 0, \"label\": \"Supplier Name\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"address_display\", \"print_hide\": 0, \"label\": \"Supplier Address\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"transaction_date\", \"print_hide\": 0, \"label\": \"Date\"}, {\"fieldname\": \"proposed_ready_date\", \"print_hide\": 0, \"label\": \"Proposed Ready Date\"}, {\"fieldname\": \"ready_date\", \"print_hide\": 0, \"label\": \"Ready Date\"}, {\"fieldtype\": \"Section Break\", \"label\": \"Subcontracting\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"supplier_warehouse\", \"print_hide\": 0, \"label\": \"Supplier Warehouse\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"items\", \"print_hide\": 0, \"label\": \"Items\", \"visible_columns\": [{\"fieldname\": \"item_code\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"description\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"pack_size\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"product_label\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"qty\", \"print_width\": \"60px\", \"print_hide\": 0}, {\"fieldname\": \"rate\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"amount\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"batch_number\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"manufacturing_date\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"expiry_date\", \"print_width\": \"\", \"print_hide\": 0}]}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"\\tTotal (USD)\\t: {{ doc.get_formatted('total') }} \"}, {\"fieldtype\": \"Section Break\", \"label\": \"Payment Terms\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"payment_terms_template\", \"print_hide\": 0, \"align\": \"left\", \"label\": \"Payment Terms Template\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Section Break\", \"label\": \"Terms and Conditions\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"terms\", \"print_hide\": 0, \"label\": \"Terms and Conditions\"}, {\"fieldtype\": \"Section Break\", \"label\": \"Subscription Section\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"update_auto_repeat_reference\", \"print_hide\": 0, \"label\": \"Update Auto Repeat Reference\"}, {\"fieldtype\": \"Section Break\", \"label\": \"More Information\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"is_internal_supplier\", \"print_hide\": 0, \"label\": \"Is Internal Supplier\"}, {\"fieldname\": \"represents_company\", \"print_hide\": 0, \"label\": \"Represents Company\"}, {\"fieldname\": \"inter_company_order_reference\", \"print_hide\": 0, \"label\": \"Inter Company Order Reference\"}]", - "idx": 0, - "line_breaks": 1, - "modified": "2022-12-01 08:13:04.843477", - "modified_by": "Administrator", - "module": "Buying", - "name": "Unizone PO", - "owner": "Administrator", - "parent": "Purchase Order", - "print_format_builder": 1, - "print_format_type": "Jinja", - "raw_printing": 0, - "show_section_headings": 0, - "standard": "Yes" + "absolute_value": 0, + "align_labels_right": 0, + "creation": "2022-08-22 19:30:39.041461", + "css": "/* @page {*/\n/* margin: 0;*/\n/*}*/\n\n.print-format, .print-format-preview {font-size: 10; padding: 0.25in;}\n\n.print-display-flex {\n display: flex;\n justify-content: space-between;\n }\n\n.print-display-flex h2 div {font-size: 16px; font-weight: bold;}\n\n.print-company-info {text-align: left;}\n.print-company-info h3 {margin-top: 0; color: #0b6cb4;}\n.print-company-info p {\n color: #0b6cb4; \n font-size: 11px;\n margin-bottom: 5px;\n }", + "custom_format": 0, + "default_print_language": "", + "disabled": 0, + "doc_type": "Purchase Order", + "docstatus": 0, + "doctype": "Print Format", + "font": "Helvetica Neue", + "format_data": "[{\"fieldname\": \"print_heading_template\", \"fieldtype\": \"Custom HTML\", \"options\": \"
\\n
\\n \\n

\\n 30-70 East Beaver Creek Road,
\\n Richmond Hill, ON L4B 3B2\\n

\\n
\\t\\n

Purchase Order
{{ doc.name }}\\t\\t\\t\\t

\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"supplier_name\", \"print_hide\": 0, \"label\": \"Supplier Name\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"address_display\", \"print_hide\": 0, \"label\": \"Supplier Address\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"transaction_date\", \"print_hide\": 0, \"label\": \"Date\"}, {\"fieldname\": \"proposed_ready_date\", \"print_hide\": 0, \"label\": \"Proposed Ready Date\"}, {\"fieldname\": \"ready_date\", \"print_hide\": 0, \"label\": \"Ready Date\"}, {\"fieldtype\": \"Section Break\", \"label\": \"Subcontracting\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"supplier_warehouse\", \"print_hide\": 0, \"label\": \"Supplier Warehouse\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"items\", \"print_hide\": 0, \"label\": \"Items\", \"visible_columns\": [{\"fieldname\": \"item_code\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"description\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"pack_size\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"product_label\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"qty\", \"print_width\": \"60px\", \"print_hide\": 0}, {\"fieldname\": \"rate\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"amount\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"batch_number\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"manufacturing_date\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"expiry_date\", \"print_width\": \"\", \"print_hide\": 0}]}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"\\tTotal (USD)\\t: {{ doc.get_formatted('total') }} \"}, {\"fieldtype\": \"Section Break\", \"label\": \"Payment Terms\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"payment_terms_template\", \"print_hide\": 0, \"align\": \"left\", \"label\": \"Payment Terms Template\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Section Break\", \"label\": \"Terms and Conditions\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"terms\", \"print_hide\": 0, \"label\": \"Terms and Conditions\"}, {\"fieldtype\": \"Section Break\", \"label\": \"Subscription Section\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"update_auto_repeat_reference\", \"print_hide\": 0, \"label\": \"Update Auto Repeat Reference\"}, {\"fieldtype\": \"Section Break\", \"label\": \"More Information\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"is_internal_supplier\", \"print_hide\": 0, \"label\": \"Is Internal Supplier\"}, {\"fieldname\": \"represents_company\", \"print_hide\": 0, \"label\": \"Represents Company\"}, {\"fieldname\": \"inter_company_order_reference\", \"print_hide\": 0, \"label\": \"Inter Company Order Reference\"}]", + "idx": 0, + "line_breaks": 1, + "modified": "2023-08-24 02:46:36.770259", + "modified_by": "Administrator", + "module": "Buying", + "name": "Unizone PO", + "owner": "Administrator", + "parent": "Purchase Order", + "print_format_builder": 1, + "print_format_type": "Jinja", + "raw_printing": 0, + "show_section_headings": 0, + "standard": "Yes" } \ No newline at end of file diff --git a/erpnext/controllers/status_updater.py b/erpnext/controllers/status_updater.py index 9693ffc6acda..e0fdb1183ecd 100644 --- a/erpnext/controllers/status_updater.py +++ b/erpnext/controllers/status_updater.py @@ -86,7 +86,8 @@ def validate_status(status, options): ], ["Proposed Ready Date", "eval:self.status=='Proposed Ready Date' and self.per_received == 0"], ["Cancelled", "eval:self.docstatus==2"], - ["Ready", "eval:self.status=='Ready'"], + ["Ready and Short Close", "eval:self.status=='Ready and Short Close'"], + ["Shipped and Short Close", "eval:self.status=='Shipped and Short Close'"], ["Shipped", "eval:self.po_status=='Shipped'"] ], "Delivery Note": [ diff --git a/erpnext/controllers/trends.py b/erpnext/controllers/trends.py index 1d6c5dc0be0b..7bbc715a3958 100644 --- a/erpnext/controllers/trends.py +++ b/erpnext/controllers/trends.py @@ -67,6 +67,7 @@ def get_data(filters, conditions): "Purchase Invoice", "Purchase Receipt", "Delivery Note", + "Shipping Notice Instruction" ]: posting_date = "t1.posting_date" if filters.period_based_on: @@ -84,6 +85,10 @@ def get_data(filters, conditions): "Fiscal Year", filters.get("fiscal_year"), ["year_start_date", "year_end_date"] ) + if (conditions["trans"] == "Shipping Notice Instruction"): + item_table = "Shipping Note" + else: + item_table = conditions["trans"] if filters.get("group_by"): sel_col = "" ind = conditions["columns"].index(conditions["grbc"][0]) @@ -108,7 +113,7 @@ def get_data(filters, conditions): % ( query_details, conditions["trans"], - conditions["trans"], + item_table, conditions["addl_tables"], "%s", posting_date, @@ -137,7 +142,7 @@ def get_data(filters, conditions): % ( sel_col, conditions["trans"], - conditions["trans"], + item_table, conditions["addl_tables"], "%s", posting_date, @@ -165,7 +170,7 @@ def get_data(filters, conditions): sel_col, conditions["period_wise_select"], conditions["trans"], - conditions["trans"], + item_table, conditions["addl_tables"], "%s", posting_date, @@ -198,7 +203,7 @@ def get_data(filters, conditions): % ( query_details, conditions["trans"], - conditions["trans"], + item_table, conditions["addl_tables"], "%s", posting_date, @@ -224,7 +229,7 @@ def period_wise_columns_query(filters, trans): pwc = [] bet_dates = get_period_date_ranges(filters.get("period"), filters.get("fiscal_year")) - if trans in ["Purchase Receipt", "Delivery Note", "Purchase Invoice", "Sales Invoice"]: + if trans in ["Purchase Receipt", "Delivery Note", "Shipping Notice Instruction","Purchase Invoice", "Sales Invoice"]: trans_date = "posting_date" if filters.period_based_on: trans_date = filters.period_based_on @@ -330,7 +335,7 @@ def based_wise_columns_query(based_on, trans): "Customer:Link/Customer:120", "Territory:Link/Territory:120", ] - based_on_details["based_on_select"] = "t1.customer_name, t1.territory, " + based_on_details["based_on_select"] = "t1.customer, t1.territory, " based_on_details["based_on_group_by"] = ( "t1.party_name" if trans == "Quotation" else "t1.customer" ) @@ -366,7 +371,7 @@ def based_wise_columns_query(based_on, trans): based_on_details["addl_tables"] = "" elif based_on == "Project": - if trans in ["Sales Invoice", "Delivery Note", "Sales Order"]: + if trans in ["Sales Invoice", "Delivery Note", "Shipping Notice Instruction", "Sales Order"]: based_on_details["based_on_cols"] = ["Project:Link/Project:120"] based_on_details["based_on_select"] = "t1.project," based_on_details["based_on_group_by"] = "t1.project" diff --git a/erpnext/selling/doctype/customer/customer.json b/erpnext/selling/doctype/customer/customer.json index 0645293df4fb..8e10f40ff158 100644 --- a/erpnext/selling/doctype/customer/customer.json +++ b/erpnext/selling/doctype/customer/customer.json @@ -27,6 +27,7 @@ "account_manager", "category", "contact", + "disable_sdm", "customer_group", "territory", "tax_id", @@ -590,6 +591,12 @@ "options": "\nPrivate Sales\nGovt Sales" }, { + "default": "0", + "fieldname": "disable_sdm", + "fieldtype": "Check", + "label": "Disable Sales Data Module?" + }, + { "fieldname": "category", "fieldtype": "Link", "in_list_view": 1, @@ -610,7 +617,7 @@ "link_fieldname": "party" } ], - "modified": "2024-07-08 07:49:09.527242", + "modified": "2023-10-06 08:29:35.547007", "modified_by": "Administrator", "module": "Selling", "name": "Customer", diff --git a/erpnext/selling/report/sales_order_trends/sales_order_trends.py b/erpnext/selling/report/sales_order_trends/sales_order_trends.py index d34501e68258..50e4a3320ec9 100644 --- a/erpnext/selling/report/sales_order_trends/sales_order_trends.py +++ b/erpnext/selling/report/sales_order_trends/sales_order_trends.py @@ -11,7 +11,7 @@ def execute(filters=None): if not filters: filters = {} data = [] - conditions = get_columns(filters, "Sales Order") + conditions = get_columns(filters, "Customer Order") data = get_data(filters, conditions) chart_data = get_chart_data(data, conditions, filters) diff --git a/erpnext/stock/print_format/unizone_pro/unizone_pro.json b/erpnext/stock/print_format/unizone_pro/unizone_pro.json index 8ecc86e5bce7..b1d41774e03f 100644 --- a/erpnext/stock/print_format/unizone_pro/unizone_pro.json +++ b/erpnext/stock/print_format/unizone_pro/unizone_pro.json @@ -1,26 +1,26 @@ { - "absolute_value": 0, - "align_labels_right": 0, - "creation": "2022-10-11 08:08:05.552985", - "css": "/* @page {\nmargin: 0;\n}*/\n\n.print-format, .print-format-preview {font-size: 10; padding: 0.25in;}\n\n.print-display-flex {\n display: flex;\n justify-content: space-between;\n }\n\n.print-display-flex h2 div {font-size: 16px; font-weight: bold;}\n\n .print-company-info {text-align: left;}\n .print-company-info h3 {margin-top: 0; color: #0b6cb4;}\n .print-company-info p {\n color: #0b6cb4; \n font-size: 11px;\n margin-bottom: 5px;\n }", - "custom_format": 0, - "disabled": 0, - "doc_type": "Purchase Receipt", - "docstatus": 0, - "doctype": "Print Format", - "font": "Default", - "format_data": "[{\"fieldname\": \"print_heading_template\", \"fieldtype\": \"Custom HTML\", \"options\": \"
\\n
\\n

UNIZONE PTE. LTD.

\\n

\\n UNIT 15-01 Valley Point
\\n 491B River Valley Road, Singapore 248373\\n

\\n
\\n

Purchase Order Details with Ready Status
{{ doc.name }}\\t\\t\\t\\t

\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Supplier : {{ doc.supplier}}\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Purchase Order: {{doc.purchase_order}}\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Date : {{ doc.posting_date }}\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"items\", \"print_hide\": 0, \"label\": \"Items\", \"visible_columns\": [{\"fieldname\": \"item_code\", \"print_width\": \"100px\", \"print_hide\": 0}, {\"fieldname\": \"item_name\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"pack_size\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"batch_no\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"manufacturing_date\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"expiry_date\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"qty\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"rate\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"amount\", \"print_width\": \"\", \"print_hide\": 0}]}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Total(USD): {{ doc.get_formatted('total') }} \"}]", - "idx": 0, - "line_breaks": 1, - "modified": "2022-12-02 04:33:57.680459", - "modified_by": "Administrator", - "module": "Stock", - "name": "UNIZONE PRO", - "owner": "Administrator", - "parent": "Purchase Receipt", - "print_format_builder": 1, - "print_format_type": "Jinja", - "raw_printing": 0, - "show_section_headings": 0, - "standard": "Yes" - } \ No newline at end of file + "absolute_value": 0, + "align_labels_right": 0, + "creation": "2022-10-11 08:08:05.552985", + "css": "/* @page {\nmargin: 0;\n}*/\n\n.print-format, .print-format-preview {font-size: 10; padding: 0.25in;}\n\n.print-display-flex {\n display: flex;\n justify-content: space-between;\n }\n\n.print-display-flex h2 div {font-size: 16px; font-weight: bold;}\n\n .print-company-info {text-align: left;}\n .print-company-info h3 {margin-top: 0; color: #0b6cb4;}\n .print-company-info p {\n color: #0b6cb4; \n font-size: 11px;\n margin-bottom: 5px;\n }", + "custom_format": 0, + "disabled": 0, + "doc_type": "Purchase Receipt", + "docstatus": 0, + "doctype": "Print Format", + "font": "Default", + "format_data": "[{\"fieldname\": \"print_heading_template\", \"fieldtype\": \"Custom HTML\", \"options\": \"
\\n
\\n \\n

\\n 30-70 East Beaver Creek Road,
\\n Richmond Hill, ON L4B 3B2\\n

\\n
\\n

Purchase Order Details with Ready Status
{{ doc.name }}\\t\\t\\t\\t

\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Supplier : {{ doc.supplier}}\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Purchase Order: {{doc.purchase_order}}\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Date : {{ doc.posting_date }}\"}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"items\", \"print_hide\": 0, \"label\": \"Items\", \"visible_columns\": [{\"fieldname\": \"item_code\", \"print_width\": \"100px\", \"print_hide\": 0}, {\"fieldname\": \"item_name\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"pack_size\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"batch_no\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"manufacturing_date\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"expiry_date\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"qty\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"rate\", \"print_width\": \"\", \"print_hide\": 0}, {\"fieldname\": \"amount\", \"print_width\": \"\", \"print_hide\": 0}]}, {\"fieldtype\": \"Section Break\", \"label\": \"\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldtype\": \"Column Break\"}, {\"fieldname\": \"_custom_html\", \"print_hide\": 0, \"label\": \"Custom HTML\", \"fieldtype\": \"HTML\", \"options\": \"Total(USD): {{ doc.get_formatted('total') }} \"}]", + "idx": 0, + "line_breaks": 1, + "modified": "2023-08-24 02:53:06.003939", + "modified_by": "Administrator", + "module": "Stock", + "name": "UNIZONE PRO", + "owner": "Administrator", + "parent": "Purchase Receipt", + "print_format_builder": 1, + "print_format_type": "Jinja", + "raw_printing": 0, + "show_section_headings": 0, + "standard": "Yes" +} \ No newline at end of file diff --git a/erpnext/stock/report/delivery_note_trends/delivery_note_trends.py b/erpnext/stock/report/delivery_note_trends/delivery_note_trends.py index 7a1b8c0cee91..0524a23d1ac7 100644 --- a/erpnext/stock/report/delivery_note_trends/delivery_note_trends.py +++ b/erpnext/stock/report/delivery_note_trends/delivery_note_trends.py @@ -11,7 +11,7 @@ def execute(filters=None): if not filters: filters = {} data = [] - conditions = get_columns(filters, "Delivery Note") + conditions = get_columns(filters, "Shipping Notice Instruction") data = get_data(filters, conditions) chart_data = get_chart_data(data, filters) diff --git a/erpnext/stock/stock_balance.py b/erpnext/stock/stock_balance.py index 9ffbf72b7b12..bfa9f15105cb 100644 --- a/erpnext/stock/stock_balance.py +++ b/erpnext/stock/stock_balance.py @@ -231,7 +231,7 @@ def get_ordered_qty(item_code, warehouse): from `tabPurchase Order Item` po_item, `tabPurchase Order` po where po_item.item_code=%s and po_item.warehouse=%s and po_item.qty > po_item.received_qty and po_item.parent=po.name - and po.status not in ('Closed', 'Delivered') and po.docstatus=1 + and po.status not in ('Closed', 'Delivered', 'Ready and Short Close','Shipped and Short Close') and po.docstatus=1 and po_item.delivered_by_supplier = 0""", (item_code, warehouse), )