mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-02 11:49:10 +00:00
Merge pull request #29774 from deepeshgarg007/patch_fixes
fix: Patch fixes
This commit is contained in:
@@ -329,7 +329,6 @@ execute:frappe.delete_doc_if_exists('Workspace', 'ERPNext Integrations Settings'
|
|||||||
erpnext.patches.v14_0.set_payroll_cost_centers
|
erpnext.patches.v14_0.set_payroll_cost_centers
|
||||||
erpnext.patches.v13_0.agriculture_deprecation_warning
|
erpnext.patches.v13_0.agriculture_deprecation_warning
|
||||||
erpnext.patches.v13_0.hospitality_deprecation_warning
|
erpnext.patches.v13_0.hospitality_deprecation_warning
|
||||||
erpnext.patches.v13_0.update_exchange_rate_settings
|
|
||||||
erpnext.patches.v13_0.update_asset_quantity_field
|
erpnext.patches.v13_0.update_asset_quantity_field
|
||||||
erpnext.patches.v13_0.delete_bank_reconciliation_detail
|
erpnext.patches.v13_0.delete_bank_reconciliation_detail
|
||||||
erpnext.patches.v13_0.enable_provisional_accounting
|
erpnext.patches.v13_0.enable_provisional_accounting
|
||||||
@@ -351,5 +350,6 @@ erpnext.patches.v13_0.convert_to_website_item_in_item_card_group_template
|
|||||||
erpnext.patches.v13_0.shopping_cart_to_ecommerce
|
erpnext.patches.v13_0.shopping_cart_to_ecommerce
|
||||||
erpnext.patches.v13_0.update_disbursement_account
|
erpnext.patches.v13_0.update_disbursement_account
|
||||||
erpnext.patches.v13_0.update_reserved_qty_closed_wo
|
erpnext.patches.v13_0.update_reserved_qty_closed_wo
|
||||||
|
erpnext.patches.v13_0.update_exchange_rate_settings
|
||||||
erpnext.patches.v14_0.delete_amazon_mws_doctype
|
erpnext.patches.v14_0.delete_amazon_mws_doctype
|
||||||
erpnext.patches.v13_0.set_work_order_qty_in_so_from_mr
|
erpnext.patches.v13_0.set_work_order_qty_in_so_from_mr
|
||||||
|
|||||||
@@ -6,9 +6,6 @@ from erpnext.setup.utils import get_exchange_rate
|
|||||||
|
|
||||||
|
|
||||||
def execute():
|
def execute():
|
||||||
frappe.reload_doc('crm', 'doctype', 'opportunity')
|
|
||||||
frappe.reload_doc('crm', 'doctype', 'opportunity_item')
|
|
||||||
|
|
||||||
opportunities = frappe.db.get_list('Opportunity', filters={
|
opportunities = frappe.db.get_list('Opportunity', filters={
|
||||||
'opportunity_amount': ['>', 0]
|
'opportunity_amount': ['>', 0]
|
||||||
}, fields=['name', 'company', 'currency', 'opportunity_amount'])
|
}, fields=['name', 'company', 'currency', 'opportunity_amount'])
|
||||||
@@ -20,15 +17,11 @@ def execute():
|
|||||||
if opportunity.currency != company_currency:
|
if opportunity.currency != company_currency:
|
||||||
conversion_rate = get_exchange_rate(opportunity.currency, company_currency)
|
conversion_rate = get_exchange_rate(opportunity.currency, company_currency)
|
||||||
base_opportunity_amount = flt(conversion_rate) * flt(opportunity.opportunity_amount)
|
base_opportunity_amount = flt(conversion_rate) * flt(opportunity.opportunity_amount)
|
||||||
grand_total = flt(opportunity.opportunity_amount)
|
|
||||||
base_grand_total = flt(conversion_rate) * flt(opportunity.opportunity_amount)
|
|
||||||
else:
|
else:
|
||||||
conversion_rate = 1
|
conversion_rate = 1
|
||||||
base_opportunity_amount = grand_total = base_grand_total = flt(opportunity.opportunity_amount)
|
base_opportunity_amount = flt(opportunity.opportunity_amount)
|
||||||
|
|
||||||
frappe.db.set_value('Opportunity', opportunity.name, {
|
frappe.db.set_value('Opportunity', opportunity.name, {
|
||||||
'conversion_rate': conversion_rate,
|
'conversion_rate': conversion_rate,
|
||||||
'base_opportunity_amount': base_opportunity_amount,
|
'base_opportunity_amount': base_opportunity_amount
|
||||||
'grand_total': grand_total,
|
|
||||||
'base_grand_total': base_grand_total
|
|
||||||
}, update_modified=False)
|
}, update_modified=False)
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ def make_custom_fields():
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
create_custom_fields(custom_fields, update=True)
|
create_custom_fields(custom_fields, ignore_validate=True, update=True)
|
||||||
|
|
||||||
def update_regional_tax_settings(country, company):
|
def update_regional_tax_settings(country, company):
|
||||||
create_ksa_vat_setting(company)
|
create_ksa_vat_setting(company)
|
||||||
|
|||||||
Reference in New Issue
Block a user