Merge pull request #16817 from phot0n/remove-is_first_startup
This commit is contained in:
commit
116fe34e74
5 changed files with 10 additions and 19 deletions
|
|
@ -11,7 +11,6 @@
|
|||
"language",
|
||||
"column_break_3",
|
||||
"time_zone",
|
||||
"is_first_startup",
|
||||
"enable_onboarding",
|
||||
"setup_complete",
|
||||
"date_and_number_format",
|
||||
|
|
@ -103,14 +102,6 @@
|
|||
"read_only": 1,
|
||||
"reqd": 1
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "is_first_startup",
|
||||
"fieldtype": "Check",
|
||||
"hidden": 1,
|
||||
"label": "Is First Startup",
|
||||
"read_only": 1
|
||||
},
|
||||
{
|
||||
"default": "0",
|
||||
"fieldname": "setup_complete",
|
||||
|
|
@ -502,7 +493,7 @@
|
|||
"icon": "fa fa-cog",
|
||||
"issingle": 1,
|
||||
"links": [],
|
||||
"modified": "2022-04-21 09:11:35.218721",
|
||||
"modified": "2022-05-02 18:53:35.218721",
|
||||
"modified_by": "Administrator",
|
||||
"module": "Core",
|
||||
"name": "System Settings",
|
||||
|
|
|
|||
|
|
@ -269,7 +269,6 @@ def add_all_roles_to(name):
|
|||
def disable_future_access():
|
||||
frappe.db.set_default("desktop:home_page", "workspace")
|
||||
frappe.db.set_value("System Settings", "System Settings", "setup_complete", 1)
|
||||
frappe.db.set_value("System Settings", "System Settings", "is_first_startup", 1)
|
||||
|
||||
# Enable onboarding after install
|
||||
frappe.db.set_value("System Settings", "System Settings", "enable_onboarding", 1)
|
||||
|
|
@ -334,11 +333,6 @@ def load_user_details():
|
|||
}
|
||||
|
||||
|
||||
@frappe.whitelist()
|
||||
def reset_is_first_startup():
|
||||
frappe.db.set_value("System Settings", "System Settings", "is_first_startup", 0)
|
||||
|
||||
|
||||
def prettify_args(args):
|
||||
# remove attachments
|
||||
for key, val in args.items():
|
||||
|
|
|
|||
|
|
@ -189,6 +189,7 @@ frappe.patches.v14_0.save_ratings_in_fraction #23-12-2021
|
|||
frappe.patches.v14_0.transform_todo_schema
|
||||
frappe.patches.v14_0.remove_post_and_post_comment
|
||||
frappe.patches.v14_0.reset_creation_datetime
|
||||
frappe.patches.v14_0.remove_is_first_startup
|
||||
|
||||
[post_model_sync]
|
||||
frappe.patches.v14_0.drop_data_import_legacy
|
||||
|
|
|
|||
8
frappe/patches/v14_0/remove_is_first_startup.py
Normal file
8
frappe/patches/v14_0/remove_is_first_startup.py
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
import frappe
|
||||
|
||||
|
||||
def execute():
|
||||
singles = frappe.qb.Table("tabSingles")
|
||||
frappe.qb.from_(singles).delete().where(
|
||||
(singles.doctype == "System Settings") & (singles.field == "is_first_startup")
|
||||
).run()
|
||||
|
|
@ -187,9 +187,6 @@ def get():
|
|||
bootinfo["disable_async"] = frappe.conf.disable_async
|
||||
|
||||
bootinfo["setup_complete"] = cint(frappe.db.get_single_value("System Settings", "setup_complete"))
|
||||
bootinfo["is_first_startup"] = cint(
|
||||
frappe.db.get_single_value("System Settings", "is_first_startup")
|
||||
)
|
||||
|
||||
bootinfo["desk_theme"] = frappe.db.get_value("User", frappe.session.user, "desk_theme") or "Light"
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue