mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-16 11:39:18 +00:00
moved directory structure
This commit is contained in:
1
patches/august_2012/__init__.py
Normal file
1
patches/august_2012/__init__.py
Normal file
@@ -0,0 +1 @@
|
||||
from __future__ import unicode_literals
|
||||
35
patches/august_2012/change_profile_permission.py
Normal file
35
patches/august_2012/change_profile_permission.py
Normal file
@@ -0,0 +1,35 @@
|
||||
from __future__ import unicode_literals
|
||||
def execute():
|
||||
import webnotes
|
||||
import webnotes.model.doc
|
||||
webnotes.conn.sql("delete from `tabDocPerm` where parent='Profile' and permlevel=1")
|
||||
new_perms = [
|
||||
{
|
||||
'parent': 'Profile',
|
||||
'parentfield': 'permissions',
|
||||
'parenttype': 'DocType',
|
||||
'role': 'Administrator',
|
||||
'permlevel': 1,
|
||||
'read': 1,
|
||||
'write': 1
|
||||
},
|
||||
{
|
||||
'parent': 'Profile',
|
||||
'parentfield': 'permissions',
|
||||
'parenttype': 'DocType',
|
||||
'role': 'System Manager',
|
||||
'permlevel': 1,
|
||||
'read': 1,
|
||||
'write': 1
|
||||
},
|
||||
|
||||
]
|
||||
for perms in new_perms:
|
||||
doc = webnotes.model.doc.Document('DocPerm')
|
||||
doc.fields.update(perms)
|
||||
doc.save()
|
||||
webnotes.conn.commit()
|
||||
webnotes.conn.begin()
|
||||
|
||||
import webnotes.model.sync
|
||||
webnotes.model.sync.sync('core', 'profile')
|
||||
5
patches/august_2012/changed_blog_date_format.py
Normal file
5
patches/august_2012/changed_blog_date_format.py
Normal file
@@ -0,0 +1,5 @@
|
||||
from __future__ import unicode_literals
|
||||
def execute():
|
||||
import webnotes
|
||||
from webnotes.model.doclist import DocList
|
||||
DocList("Website Settings", "Website Settings").save()
|
||||
4
patches/august_2012/remove_cash_flow_statement.py
Normal file
4
patches/august_2012/remove_cash_flow_statement.py
Normal file
@@ -0,0 +1,4 @@
|
||||
from __future__ import unicode_literals
|
||||
def execute():
|
||||
import webnotes
|
||||
webnotes.conn.sql("delete from `tabSearch Criteria` where name = 'cash_flow_statement'")
|
||||
4
patches/august_2012/report_supplier_quotations.py
Normal file
4
patches/august_2012/report_supplier_quotations.py
Normal file
@@ -0,0 +1,4 @@
|
||||
from __future__ import unicode_literals
|
||||
def execute():
|
||||
from webnotes.modules import reload_doc
|
||||
reload_doc("buying", "report", "supplier_quotations")
|
||||
10
patches/august_2012/repost_billed_amt.py
Normal file
10
patches/august_2012/repost_billed_amt.py
Normal file
@@ -0,0 +1,10 @@
|
||||
from __future__ import unicode_literals
|
||||
def execute():
|
||||
import webnotes
|
||||
from webnotes.model.code import get_obj
|
||||
from selling.doctype.sales_common.sales_common import StatusUpdater
|
||||
|
||||
invoices = webnotes.conn.sql("select name from `tabSales Invoice` where docstatus = 1")
|
||||
for inv in invoices:
|
||||
inv_obj = get_obj('Sales Invoice', inv[0], with_children=1)
|
||||
StatusUpdater(inv_obj, 1).update_all_qty()
|
||||
15
patches/august_2012/task_allocated_to_assigned.py
Normal file
15
patches/august_2012/task_allocated_to_assigned.py
Normal file
@@ -0,0 +1,15 @@
|
||||
from __future__ import unicode_literals
|
||||
import webnotes
|
||||
|
||||
def execute():
|
||||
from webnotes.widgets.form.assign_to import add
|
||||
for t in webnotes.conn.sql("""select * from tabTask
|
||||
where ifnull(allocated_to, '')!=''""", as_dict=1):
|
||||
add({
|
||||
'doctype': "Task",
|
||||
'name': t['name'],
|
||||
'assign_to': t['allocated_to'],
|
||||
'assigned_by': t['owner'],
|
||||
'description': t['subject'],
|
||||
'date': t['creation']
|
||||
})
|
||||
Reference in New Issue
Block a user