fix: remove patch for retaining permissions for Video DocType (#22932)

Co-authored-by: Marica <maricadsouza221197@gmail.com>
This commit is contained in:
Rucha Mahabal 2020-08-06 19:01:42 +05:30 committed by GitHub
parent 5de8a7a775
commit a78336e77d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 22 deletions

View File

@ -679,7 +679,6 @@ erpnext.patches.v12_0.fix_quotation_expired_status
erpnext.patches.v12_0.update_appointment_reminder_scheduler_entry
erpnext.patches.v12_0.rename_pos_closing_doctype
erpnext.patches.v13_0.replace_pos_payment_mode_table
erpnext.patches.v12_0.retain_permission_rules_for_video_doctype
erpnext.patches.v12_0.remove_duplicate_leave_ledger_entries #2020-05-22
erpnext.patches.v13_0.patch_to_fix_reverse_linking_in_additional_salary_encashment_and_incentive
execute:frappe.reload_doc("HR", "doctype", "Employee Advance")

View File

@ -1,21 +0,0 @@
from __future__ import unicode_literals
import frappe
def execute():
# to retain the roles and permissions from Education Module
# after moving doctype to core
permissions = frappe.db.sql("""
SELECT
*
FROM
`tabDocPerm`
WHERE
parent='Video'
""", as_dict=True)
frappe.reload_doc('core', 'doctype', 'video')
doc = frappe.get_doc('DocType', 'Video')
doc.permissions = []
for perm in permissions:
doc.append('permissions', perm)
doc.save()