瀏覽代碼

fix: allow only system manager

Co-authored-by: Suraj Shetty <13928957+surajshetty3416@users.noreply.github.com>
version-14
Mohammad Hasnain Mohsin Rajan 4 年之前
committed by GitHub
父節點
當前提交
969e2b6db9
沒有發現已知的金鑰在資料庫的簽署中 GPG Key ID: 4AEE18F83AFDEB23
共有 1 個文件被更改,包括 1 次插入0 次删除
  1. +1
    -0
      frappe/core/doctype/document_naming_rule/document_naming_rule.py

+ 1
- 0
frappe/core/doctype/document_naming_rule/document_naming_rule.py 查看文件

@@ -33,5 +33,6 @@ class DocumentNamingRule(Document):

@frappe.whitelist()
def update_current(name, new_counter):
frappe.only_for('System Manager')
frappe.db.set_value('Document Naming Rule', name, 'counter', new_counter)
frappe.db.commit()

Loading…
取消
儲存