Commit graph

20 commits

Author SHA1 Message Date
sivankar
a48b76b940 refactored code to add support in filters to get descendant or ancest… (#5847)
* refactored code to add support in filters to get descendant or ancestor for tree type documents

* added semicolon and comments to imporve code quality

* refactored code to add not ancestor and not descendants of filters

* added test cases for ancestors of and descendants of

* Translate labels
2018-08-14 12:19:18 +05:30
Saurabh
93165d4a5c test case fixes (#5807) 2018-07-11 11:02:27 +05:30
Rushabh Mehta
a4dd9ec91b [test] [style] 2018-07-10 16:10:08 +05:30
Rushabh Mehta
05d68968ca [fix] test 2018-07-10 15:26:43 +05:30
Rushabh Mehta
53a298a5c1 [fix] test_db_query.py 2018-07-06 18:27:08 +05:30
Saurabh
a135c6c431 resolved merge conflicts 2018-07-06 13:37:51 +05:30
Saurabh
9aeb79b874 [fix][test-case] filter sanitizer 2018-07-05 17:33:30 +05:30
Saurabh
e2b1ebe84c [Security][fix] To avoid possible sql injection via filters and or_filters parameters and tighten the field level checks (#5721)
* [fix] sanitize filters and or_filters to avoid sql injection

* add test cases for filter sanitizer

* codacy fix

* added test cases to test valid scenarios
2018-06-27 09:15:42 +05:30
Suraj Shetty
95c02f94ef Nested permission (#5460)
* nested permission

* test for nested permission

* [minor] Format code

* Fix nested permission test

* Fix codacy
2018-04-20 18:07:55 +05:30
Suraj Shetty
0be4342649 User permissions redux (#5314)
* [start] removing simpler user permission structure

* permission changes
removed "apply user permission" from has_permission

* test fixes and other supporting fixes

* Removed Apply user permission code

* additional check to see if user has some user permissions related to a doctype

* test fixes

* removed a test

* Permission changes
- Code to restrict access if module is blocked for user.
- [Fix] ignore user perm if applicable

* List view restrictions ui changes

* removed unwanted apply user perm code

* permission (block module fix)

* permission fix

* change user permission
user permission will not be applied if user doesn't have role permission

* removed left "apply_user_permissions" property

* add user permission help template

* perm js refactor

* ui / ux changes
restrict list view before entering view if user is not permitterd
add description for if owner check in role permission manager

* codacy fixes

* permission code fix
add controller permission check
add blocked module check in build_permission

* optimized get blocked module method
2018-04-03 10:42:04 +05:30
Saurabh
40d818af90 [hotfix] sanitize fields to avoid mysql injection (#4994)
* [fix] sanitize fields to avoid mysql injection

* sanitize sql statements to avoid subqueries

* Added test cases

* Raise exception if mysql injection found in fields and related test-cases

* [fix] riase exception if blacklistes function or keyworkds found in fields
2018-02-13 14:45:51 +05:30
Manas Solanki
7031473915 fixed between filters (#4497) 2017-11-15 13:57:53 +05:30
Makarand Bauskar
fc715efdbb [hotfix] fixes for AttributeError: 'NoneType' object has no attribute 'split' (#3840)
* [hotfix] fixes for AttributeError: 'NoneType' object has no attribute 'split'

* [tests] added test cases for not in and in filters
2017-08-02 12:47:10 +05:30
Rushabh Mehta
262f361021 [minor] ignore permissions option for filters in db_query (#3234) 2017-05-06 12:43:47 +05:30
Makarand Bauskar
8eeda18692 [fixes] minor fix for between operator filter (#3196)
* [fixes] minor fix for between operator filter

* [minor] added a test case for between operator filter
2017-05-01 14:14:04 +05:30
Anand Doshi
2995f02f3b Web Notes to Frappe, better alerts, css fixes, fixed splash 2015-03-03 15:09:34 +05:30
Anand Doshi
f3b37df2dd [fix] Added unicode_literals if missing in py files 2015-02-24 12:24:20 +05:30
Rushabh Mehta
2405ed2e81 added or_filters to db_query. link search will not search 'search_fields' by default 2014-05-07 14:09:40 +05:30
Anand Doshi
291cd2777f Added notification clearing hook, fixed db query test cases 2014-03-05 15:23:22 +05:30
Rushabh Mehta
3964db5d95 refactored reportview.py and added frappe/model/db_query.py 2014-03-03 17:53:25 +05:30