mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-08 07:32:50 +00:00
chore: Clean up imports (#27302)
* chore: Added isort to pre-commit config * chore: Sort imports with isort * chore: Clean up imports with pycln * chore: Sort imports with isort * chore: Fix import issues * chore: Clean up sider issues * chore: Remove import errors from flake8 ignore list * chore: Clean up lint issues
This commit is contained in:
@@ -6,6 +6,7 @@ from __future__ import unicode_literals
|
||||
import frappe
|
||||
from frappe.model.utils.rename_field import rename_field
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("setup", "doctype", "company")
|
||||
if frappe.db.has_column('Company', 'default_terms'):
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'Italy'})
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_field
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.india.setup import make_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
if not company:
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import frappe
|
||||
from frappe.permissions import add_permission, update_permission_property
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
if not company:
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.india import states
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.united_states.setup import make_custom_fields
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('stock', 'doctype', 'item_variant_attribute')
|
||||
frappe.db.sql('''
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_field
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
frappe.reload_doc('accounts', 'doctype', 'accounting_dimension')
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import frappe
|
||||
|
||||
from erpnext.setup.install import create_default_energy_point_rules
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('social', 'doctype', 'energy_point_rule')
|
||||
create_default_energy_point_rules()
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.united_states.setup import make_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
frappe.reload_doc('accounts', 'doctype', 'allowed_to_transact_with', force=True)
|
||||
|
||||
@@ -1,9 +1,12 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
from frappe.custom.doctype.property_setter.property_setter import make_property_setter
|
||||
|
||||
from erpnext.regional.india.utils import get_gst_accounts
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'}, fields=['name'])
|
||||
if not company:
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
if not company:
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.db.sql("""
|
||||
DELETE FROM `tabProperty Setter`
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import frappe
|
||||
from frappe.utils import flt
|
||||
|
||||
|
||||
def execute():
|
||||
for project in frappe.get_all("Project", fields=["name", "percent_complete_method"]):
|
||||
total = frappe.db.count('Task', dict(project=project.name))
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
# fixes status of quotations which have status 'Expired' despite having valid sales order created
|
||||
|
||||
|
||||
@@ -2,9 +2,11 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import getdate, today
|
||||
|
||||
|
||||
def execute():
|
||||
""" Generates leave ledger entries for leave allocation/application/encashment
|
||||
for last allocation """
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("stock", "doctype", "item_manufacturer")
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('accounts', 'doctype', 'bank', force=1)
|
||||
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
''' Move credit limit and bypass credit limit to the child table of customer credit limit '''
|
||||
frappe.reload_doc("Selling", "doctype", "Customer Credit Limit")
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
''' Move from due_advance_amount to pending_amount '''
|
||||
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
import frappe
|
||||
import json
|
||||
from six import iteritems
|
||||
|
||||
import frappe
|
||||
from frappe.model.naming import make_autoname
|
||||
from six import iteritems
|
||||
|
||||
|
||||
def execute():
|
||||
if "tax_type" not in frappe.db.get_table_columns("Item Tax"):
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("setup", "doctype", "target_detail")
|
||||
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from erpnext.stock.stock_balance import update_bin_qty, get_indented_qty
|
||||
|
||||
from erpnext.stock.stock_balance import get_indented_qty, update_bin_qty
|
||||
|
||||
|
||||
def execute():
|
||||
bin_details = frappe.db.sql("""
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from erpnext.regional.india.setup import make_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("accounts", "doctype", "tax_category")
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import getdate, today
|
||||
|
||||
|
||||
def execute():
|
||||
''' Delete leave ledger entry created
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
"""Delete duplicate leave ledger entries of type allocation created."""
|
||||
frappe.reload_doc('hr', 'doctype', 'leave_ledger_entry')
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
# Copyright (c) 2019
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.delete_doc("Page", "medical_record")
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.rename_doc('DocType', 'Account Type', 'Bank Account Type', force=True)
|
||||
frappe.rename_doc('DocType', 'Account Subtype', 'Bank Account Subtype', force=True)
|
||||
|
||||
@@ -2,9 +2,11 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.model.utils.rename_field import rename_field
|
||||
|
||||
|
||||
def execute():
|
||||
''' Change the fieldname from bank_account_no to bank_account '''
|
||||
if not frappe.get_meta("Journal Entry Account").has_field("bank_account"):
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
if frappe.db.table_exists("Bank Reconciliation"):
|
||||
frappe.rename_doc('DocType', 'Bank Reconciliation', 'Bank Clearance', force=True)
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def _rename_single_field(**kwargs):
|
||||
count = frappe.db.sql("SELECT COUNT(*) FROM tabSingles WHERE doctype='{doctype}' AND field='{new_name}';".format(**kwargs))[0][0] #nosec
|
||||
if count == 0:
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
if frappe.db.exists("DocType", "Lost Reason Detail"):
|
||||
frappe.reload_doc("crm", "doctype", "opportunity_lost_reason")
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
count = frappe.db.sql("SELECT COUNT(*) FROM `tabSingles` WHERE doctype='Amazon MWS Settings' AND field='enable_sync';")[0][0]
|
||||
if count == 0:
|
||||
|
||||
@@ -1,8 +1,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
if frappe.db.table_exists("POS Closing Voucher"):
|
||||
if not frappe.db.exists("DocType", "POS Closing Entry"):
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
doctypes = {
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import frappe
|
||||
from frappe.model.utils.rename_field import rename_field
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("stock", "doctype", "item")
|
||||
frappe.reload_doc("stock", "doctype", "stock_settings")
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.db.sql("""UPDATE `tabUser` SET `home_settings` = REPLACE(`home_settings`, 'Accounting', 'Accounts')""")
|
||||
frappe.cache().delete_key('home_settings')
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
warehouse_perm = frappe.get_all("User Permission",
|
||||
fields=["count(*) as p_count", "is_default", "user"], filters={"allow": "Warehouse"}, group_by="user")
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
frappe.reload_doc('selling', 'doctype', 'sales_order_item', force=True)
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("accounts", "doctype", "accounts_settings")
|
||||
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('hr', 'doctype', 'expense_claim_detail')
|
||||
frappe.db.sql("""
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import cint
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.db.set_value('Homepage', 'Homepage', 'hero_section_based_on', 'Default')
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("hr", "doctype", "hr_settings")
|
||||
frappe.db.set_value("HR Settings", None, "payroll_based_on", "Leave")
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from six import iteritems
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doctype('Landed Cost Taxes and Charges')
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.india.setup import make_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
@@ -2,9 +2,12 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.italy.setup import add_permissions
|
||||
|
||||
|
||||
def execute():
|
||||
countries = frappe.get_all("Company", fields="country")
|
||||
countries = [country["country"] for country in countries]
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import flt
|
||||
from erpnext.stock.get_item_details import get_conversion_factor
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('buying', 'doctype', 'request_for_quotation_item')
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doctype("Payment Entry")
|
||||
frappe.db.sql("""update `tabPayment Entry` set status = CASE
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
import frappe
|
||||
from erpnext.regional.italy.setup import make_custom_fields
|
||||
from frappe.permissions import add_permission, update_permission_property
|
||||
|
||||
from erpnext.regional.italy.setup import make_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'Italy'})
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("support", "doctype", "issue_priority")
|
||||
frappe.reload_doc("support", "doctype", "service_level_priority")
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
import frappe
|
||||
from frappe.utils import flt
|
||||
|
||||
from erpnext.selling.doctype.sales_order.sales_order import update_produced_qty_in_so_item
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doctype('Sales Order Item')
|
||||
frappe.reload_doctype('Sales Order')
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("manufacturing", "doctype", "workstation")
|
||||
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("Hub Node", "doctype", "Hub Tracked Item")
|
||||
if not frappe.db.a_row_exists("Hub Tracked Item"):
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
from __future__ import unicode_literals
|
||||
import frappe
|
||||
|
||||
from collections import defaultdict
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
frappe.reload_doc('stock', 'doctype', 'delivery_note_item', force=True)
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
frappe.db.sql(""" UPDATE `tabQuotation` set status = 'Open'
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
purchase_receipts = frappe.db.sql("""
|
||||
SELECT
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import getdate, nowdate
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('stock', 'doctype', 'serial_no')
|
||||
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doctype('Task')
|
||||
|
||||
|
||||
@@ -5,6 +5,7 @@ from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("stock", "doctype", "pick_list")
|
||||
frappe.db.sql("""UPDATE `tabPick List` set purpose = 'Delivery'
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("buying", "doctype", "supplier_quotation")
|
||||
frappe.db.sql("""UPDATE `tabSupplier Quotation`
|
||||
|
||||
@@ -3,9 +3,11 @@
|
||||
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.custom.doctype.custom_field.custom_field import create_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
create_stock_entry_types()
|
||||
|
||||
|
||||
@@ -2,8 +2,10 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.db.sql("""
|
||||
DELETE FROM `tabProperty Setter`
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
|
||||
@@ -2,9 +2,12 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.address_template.setup import set_up_address_templates
|
||||
|
||||
|
||||
def execute():
|
||||
if frappe.db.get_value('Company', {'country': 'India'}, 'name'):
|
||||
address_template = frappe.db.get_value('Address Template', 'India', 'template')
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
job = frappe.db.exists('Scheduled Job Type', 'patient_appointment.send_appointment_reminder')
|
||||
if job:
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("stock", "doctype", "material_request_item")
|
||||
frappe.reload_doc("selling", "doctype", "sales_order_item")
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("accounts", "doctype", "gl_entry")
|
||||
|
||||
|
||||
@@ -1,7 +1,9 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import add_days, getdate, today
|
||||
|
||||
|
||||
def execute():
|
||||
if frappe.db.exists('DocType', 'Email Campaign'):
|
||||
email_campaign = frappe.get_all('Email Campaign')
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from erpnext.regional.india.setup import make_custom_fields
|
||||
|
||||
|
||||
def execute():
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.model.utils.rename_field import rename_field
|
||||
from frappe.modules import scrub, get_doctype_module
|
||||
from frappe.modules import get_doctype_module, scrub
|
||||
|
||||
field_rename_map = {
|
||||
'Healthcare Settings': [
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
try:
|
||||
frappe.db.sql("UPDATE `tabStock Ledger Entry` SET is_cancelled = 0 where is_cancelled in ('', NULL, 'No')")
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('accounts', 'doctype', 'item_tax_template')
|
||||
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from erpnext.accounts.doctype.accounting_dimension.accounting_dimension import get_doctypes_with_dimensions
|
||||
|
||||
from erpnext.accounts.doctype.accounting_dimension.accounting_dimension import (
|
||||
get_doctypes_with_dimensions,
|
||||
)
|
||||
|
||||
|
||||
def execute():
|
||||
accounting_dimensions = frappe.db.sql("""select fieldname from
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
from frappe.utils import getdate, flt
|
||||
from frappe.utils import getdate
|
||||
|
||||
from erpnext.setup.utils import get_exchange_rate
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("manufacturing", "doctype", "bom")
|
||||
frappe.reload_doc("manufacturing", "doctype", "bom_item")
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc("accounts", "doctype", "pricing_rule")
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
# License: GNU General Public License v3. See license.txt
|
||||
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import frappe
|
||||
|
||||
parentfield = {
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
import frappe
|
||||
|
||||
from erpnext.regional.india import states
|
||||
|
||||
|
||||
def execute():
|
||||
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
from __future__ import unicode_literals
|
||||
import frappe, json
|
||||
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
from erpnext.setup.setup_wizard.operations.install_fixtures import add_uom_data
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
frappe.reload_doc('custom', 'doctype', 'custom_field')
|
||||
company = frappe.get_all('Company', filters = {'country': 'India'})
|
||||
|
||||
Reference in New Issue
Block a user