updated profile permission
diff --git a/erpnext/patches/august_2012/change_profile_permission.py b/erpnext/patches/august_2012/change_profile_permission.py
new file mode 100644
index 0000000..27169d8
--- /dev/null
+++ b/erpnext/patches/august_2012/change_profile_permission.py
@@ -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')
\ No newline at end of file
diff --git a/erpnext/patches/august_2012/task_allocated_to_assigned.py b/erpnext/patches/august_2012/task_allocated_to_assigned.py
index 9578206..1bbc447 100644
--- a/erpnext/patches/august_2012/task_allocated_to_assigned.py
+++ b/erpnext/patches/august_2012/task_allocated_to_assigned.py
@@ -1,3 +1,4 @@
+from __future__ import unicode_literals
import webnotes
def execute():
diff --git a/erpnext/patches/patch_list.py b/erpnext/patches/patch_list.py
index 999a904..71fc6b3 100644
--- a/erpnext/patches/patch_list.py
+++ b/erpnext/patches/patch_list.py
@@ -548,5 +548,9 @@
{
'patch_module': 'patches.august_2012',
'patch_file': 'task_allocated_to_assigned',
+ },
+ {
+ 'patch_module': 'patches.august_2012',
+ 'patch_file': 'change_profile_permission',
}
]
\ No newline at end of file
diff --git a/erpnext/projects/page/projects/projects.py b/erpnext/projects/page/projects/projects.py
index b9ee190..5949518 100644
--- a/erpnext/projects/page/projects/projects.py
+++ b/erpnext/projects/page/projects/projects.py
@@ -14,6 +14,7 @@
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
+from __future__ import unicode_literals
import webnotes
@webnotes.whitelist()