Commit graph

42114 commits

Author SHA1 Message Date
Suraj Shetty
65a2cdcffc fix(safe_eval): Normalize code passed before validating the code 2023-06-04 08:59:08 +05:30
Ankush Menat
4a81d9f8e3
feat!: populate fields from kwargs in frappe.new_doc (#21190)
This makes it similar to `get_doc` API BUT still signifies intent that
it's a "NEW" document.

Minor Breaking Change: positional arguments are now forcefully keyword
arguments. Only seems to be used internally from what I can tell.

https://sourcegraph.com/search?q=context:global+repo:%5Egithub%5C.com/frappe/.*+/frappe.new_doc%5C%28.*%3F%2C.*%3F%5C%29/+lang:python+&patternType=regexp&case=yes&sm=0&groupBy=repo
2023-05-31 12:29:31 +05:30
Saurabh
aabaab0fd2
feat: used cached version of document in mapper (#21186)
* fix: in get_mapped_doc return cached version if available

* feat: specify explicitly cached version of doc in doc_mapper


[skip ci]
2023-05-31 11:15:33 +05:30
Suraj Shetty
6321e2ac0b
Merge pull request #21187 from surajshetty3416/duplicate-signature-in-communication-box 2023-05-31 10:12:12 +05:30
Suraj Shetty
abb479f89f fix: Check if signature already exist 2023-05-31 09:55:39 +05:30
Ankush Menat
ca85524f91 fix: skip form tours on mobile (#21180)
[skip ci]
2023-05-30 16:33:08 +05:30
Ankush Menat
77db84a2be fix: reset tour
[skip ci]
2023-05-30 15:39:14 +05:30
Ankush Menat
1e0daa6edc fix: correct abbreviation for lakh (L)
[skip ci]
2023-05-30 15:21:55 +05:30
Shariq Ansari
ea45d27de0
Merge pull request #21172 from shariquerik/css-for-web-form-mobile 2023-05-30 15:02:22 +05:30
Shariq Ansari
498a51fbb5
Merge branch 'develop' into css-for-web-form-mobile 2023-05-30 13:27:04 +05:30
Maharshi Patel
7727f294e5
fix: form tour set parent tab active. (#21163)
form tours were broken due to tabs i have added support for it by setting tab active on next and previous.
2023-05-30 13:17:10 +05:30
Shariq Ansari
fb26b39dc2
Merge pull request #21167 from shariquerik/private-custom-html-block 2023-05-30 13:05:57 +05:30
Shariq Ansari
abcc7b1870 style: make text smaller and reduced some spacings for webform for mobile view 2023-05-30 13:05:20 +05:30
Maharshi Patel
e6e59cbe07
fix(ux): re routes based on setup_complete (#21118)
* fix(ux): re routes based on setup_complete

If Setup Wizard is not complete re_route any route to setup_wizard and if it complete re_route setup-wizard to app

* fix: only re_route if not on setup-wizard.

* fix: remove hardcoded slide number

---------

Co-authored-by: Sagar Sharma <sagarsharma.s312@gmail.com>
2023-05-30 12:16:27 +05:30
Shariq Ansari
96e45d9d2a
Merge branch 'develop' into private-custom-html-block 2023-05-30 12:09:41 +05:30
Shariq Ansari
474186c264 fix: only show public and user's private blocks in dropdown 2023-05-30 12:08:43 +05:30
Shariq Ansari
07781eefe9 fix: create private custom html block 2023-05-30 12:07:43 +05:30
Corentin Flr
66eb377492
fix(role): Set desk properties (e.g. search_bar) to 1 for roles with desk access (#21162)
Replace get_doc with new_doc, because default values are not retrieved when using get_doc. Some roles with desk_access had no access to most features of the desk, such as the search bar or the form's sidebar.
2023-05-30 10:37:26 +05:30
Ankush Menat
50a8c4423e fix: remove hacky/broken like/unlike toggle code 2023-05-29 21:52:16 +05:30
mergify[bot]
95fc535f1a
Merge pull request #21142 from gavindsouza/server_script-cron
feat: Allow setting cron as Server Script frequency
2023-05-29 13:26:11 +00:00
Gavin D'souza
cdef2ccdd6
fix: Clear scheduled events if cron_format is changed 2023-05-29 18:34:39 +05:30
Ankush Menat
9f53b56bdb test: save server script 2023-05-29 18:30:17 +05:30
Gavin D'souza
a1b16792f9
fix: Pass cron format only if frequency is Cron 2023-05-29 18:16:23 +05:30
Ankush Menat
888209f6d2 test: cron/scheduled scripts 2023-05-29 17:45:26 +05:30
Ankush Menat
15aec06d13
Merge pull request #21156 from ankush/desc_self
fix!: inclusive descendants for tree link fields
2023-05-29 17:26:01 +05:30
Shariq Ansari
659e4718e8
Merge pull request #21157 from shariquerik/custom-html-block-global-css 2023-05-29 17:08:08 +05:30
Ankush Menat
a1c40d9158 feat: support tree-link-fields filtering in QB 2023-05-29 17:00:37 +05:30
Ankush Menat
842195ce29 fix: simplify plucking
no idea why itertools are used for this dumb operation
2023-05-29 17:00:37 +05:30
Ankush Menat
f858c41137 fix!: consider list view filters inclusive by default
It rarely makes sense to match treeview directly against internal nodes.

- In case of leaf node: behaviour is same, though SLIGHTLY slower
- In case of internal nodes: all child nodes are added in results.

Co-Authored-By: Faris Ansari <netchamp.faris@gmail.com>
2023-05-29 17:00:30 +05:30
Ankush Menat
3df13ca392 feat: new operator - descendants of (inclusive)
Co-Authored-By: Faris Ansari <netchamp.faris@gmail.com>
2023-05-29 16:59:57 +05:30
Shariq Ansari
d00e41d725 refactor: rearranged code 2023-05-29 16:21:00 +05:30
Shariq Ansari
7776f85cb0
Merge branch 'develop' into custom-html-block-global-css 2023-05-29 16:02:24 +05:30
Shariq Ansari
2a97e3b19f fix: removed html message since we no longer have no ristrictions 2023-05-29 15:59:41 +05:30
Shariq Ansari
62565b5191 fix: made a util to create shadow element 2023-05-29 15:57:58 +05:30
Shariq Ansari
08f0f8beb1 fix: make desk css available i shadow html 2023-05-29 15:56:38 +05:30
Ankush Menat
e5878b0c68 test: reduce duplication 2023-05-29 15:35:38 +05:30
Ankush Menat
30c8661063 fix(UX): add title for documentation link 2023-05-29 15:05:46 +05:30
Ankush Menat
b262d13f36
Merge pull request #21151 from ankush/form_tour_fixes
fix: misc form tour fixes
2023-05-29 13:36:21 +05:30
Ankush Menat
2ed2f8747d chore: track doc creation
This is alternate to "Activation" level that already exists, activation
level will be phased out over time.
2023-05-29 13:34:24 +05:30
Ankush Menat
a2a84215b1 fix: render first incomplete step instead of first step 2023-05-29 12:53:25 +05:30
Ankush Menat
b1433af3d7 fix: Dont show save step if frm is not dirty
Use case: single doctype review, in all other cases document will be
dirty and hence save step will be added
2023-05-29 12:43:55 +05:30
Raphael Krupinski
b66d8e8a40
chore(DX): add type hints to Document, BaseDocument and get_doc (#21060)
* chore: add type hints to Document, BaseDocument and get_doc

* refactor: better type hints

get_doc has multiple ways to use it, added all known ways

---------

Co-authored-by: Raphael Krupinski <10319569-mattesilver@users.noreply.gitlab.com>
Co-authored-by: Ankush Menat <ankush@frappe.io>
2023-05-29 11:01:51 +05:30
Sagar Vora
38c1207abe
fix: multiple fixes to Engine.get_query (#21135) 2023-05-29 10:48:26 +05:30
Sagar Vora
a379c5bc16
Merge pull request #21146 from resilient-tech/fix-get_values_from_single 2023-05-29 10:34:31 +05:30
Sagar Vora
d6d5d488a2 fix: ensure correct return value for get_values_from_single 2023-05-29 10:06:49 +05:30
Shariq Ansari
f6da683291
Merge pull request #21140 from shariquerik/select-btn-in-doctype-list 2023-05-27 17:03:07 +05:30
Gavin D'souza
b00aac92ba
feat: Allow setting cron as Server Script frequency 2023-05-27 16:52:09 +05:30
Shariq Ansari
a556cd6a58 test: fixed failing UI test 2023-05-27 15:28:15 +05:30
Shariq Ansari
064caaa3b4 fix: only show menu button if it contains action items 2023-05-27 14:59:58 +05:30
Shariq Ansari
7fdc6007ba refactor: show/hide form builder action buttons 2023-05-27 14:47:52 +05:30