Commit graph

265 commits

Author SHA1 Message Date
Nabin Hait
115d3cead0
feat(assignment_rule): add weighted distribution strategy (#37741) 2026-03-05 14:31:03 +05:30
Gursheen Anand
cf1a3760bb chore: resolve conflicts 2026-02-20 15:25:46 +01:00
Aarol D'Souza
c55ff193a6
fix: add type hints to whitelisted methods 3 (#37149)
* fix(apps): add type hints to whitelisted methods

* fix(recorder): add type hints to whitelisted methods

* fix(comments): add type hints to whitelisted methods

* fix(oauth2): add type hints to whitelisted methods

* fix(google_calendar): add type hints to whitelisted methods

* fix(print): add type hints to whitelisted methods

* fix(print_format_builder): add type hints to whitelisted methods

* refactor(network_printer_settings): remove unused args

* fix(document): add type hints to whitelisted methods

* fix(user_settings): add type hints to whitelisted methods

* fix(mapper): add type hints to whitelisted methods

* fix(connected_app): add type hints to whitelisted methods

* fix(google_contacts): add type hints to whitelisted methods

* fix(frappecloud_billing): add type hints to whitelisted methods

* test: rewrite test to fit the strict type check

* fix(social_login_key): add type hints to whitelisted methods

* fix(share): add type hints to whitelisted methods

* fix(webhook): add type hints to whitelisted methods

* fix(workflow): add type hints to whitelisted methods

* fix(workflow main): add type hints to whitelisted methods

* fix(workflow_action): add type hints to whitelisted methods

* fix: flexible type hint

* fix(client): add type hints to whitelisted methods

* fix: fix some of the tighter types

* fix(frappecloud_billing): add str typehint to whitelisted endpoint

* fix: target_doc can be dict/json string

---------

Co-authored-by: Ankush Menat <ankush@frappe.io>
2026-02-20 06:50:19 +00:00
Aarol D'Souza
9eef4f6dae
fix: force type check in whitelisted methods (#37044)
* fix(contact): force type check in contact whitelisted methods

* fix(google_indexing): force type check in google_indexing whitelisted methods

* fix(assignment_rule): add type checks to assignment_rule whitelisted methods

* refactor: remove unused args

* fix(queue): add type hints to whitelisted methods in queue.py

* fix(auto_email_report): add type hints to whitelisted methods

* fix(dashboard): add type hints to whitelisted methods

* fix(sidebar_item_group): add type hints to whitelisted methods

* fix(weasyprint): add type hints to whitelisted methods

* fix(backups): add type hints to whitelisted methods

* fix(document_naming_settings): add type hints to whitelisted methods

* fix(get_latest_submissions): add type hints to whitelisted methods

* fix(custom_field): add type hints to whitelisted methods

* fix(customize_form): add type hints to whitelisted methods

* fix(personal_data_deletion_request): add type hints to whitelisted functions

* fix(__init__): add type hints to whitelisted methods

* fix(prepared_report): add type hints to whitelisted methods

* fix(session_default_settings): add type hints to whitelisted methods

* fix(document_follow): add type hints to whitelisted methods

* fix(route_history): add type hints to whitelisted methods

* fix(form_tour): add type hints to whitelisted methods

* fix(dashboard_settings): add type hints to whitelisted methods

* fix(address): add type hints to whitelisted methods

* fix(contact): add type hints to whitelisted methods

* fix(discussion_reply): add type hints to whitelisted methods

* fix(auto_repeat): add type hints to whitelisted methods

* fix: add the missing type hints and misc. corrections

* fix(email): add type hints to whitelisted methods

* fix(permitted_documents_for_users): add type hints to whitelisted methods

* fix: correct the type hints

* fix: int PK types

---------

Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
Co-authored-by: Ankush Menat <ankush@frappe.io>
2026-02-17 15:16:30 +00:00
Gursheen Anand
400d4e5558 fix: type hints for bulk apply 2026-02-16 23:48:13 +05:30
Gursheen Anand
2146221bee fix: check for bulk actions enabled on user before allowing bulk actions in whitelisted methods 2026-02-04 17:44:58 +05:30
sokumon
7d30e627a1 fix(assignment_rule): add a default option in due date based on 2025-12-24 11:40:04 +05:30
sokumon
dd2dc053ca chore: more renames to /desk 2025-12-18 20:45:04 +05:30
sokumon
835168c9d4 feat: export frameowork icons and sidebars 2025-11-14 23:05:14 +05:30
Akhil Narang
ff33e7db4f
fix(auto_repeat): render template from DB (#34580)
Don't allow client to pass in a template to render
Also change endpoint to POST

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2025-11-05 12:55:58 +05:30
Raffael Meyer
545dce8c30
fix(Assignment Rules): mark code samples as code (#33792) 2025-09-23 13:41:42 +02:00
Ravibharathi
50fa79f74f
fix(auto repeat): validate date (#33724)
* fix(auto repeat): validate date

* fix(auto repeat): use if instead of elif
2025-08-21 16:53:43 +05:30
Ravibharathi
bac8e71158
fix(auto repeat): validate start and end date (#33647)
* fix(auto repeat): validate start and end date

* chore: modify throw message
2025-08-19 19:10:24 +05:30
Niraj Gautam
38b99c702b
chore: Fix failing test 2025-06-30 18:45:13 +05:30
Niraj Gautam
d102437708
test: Update test cases for new functionality 2025-06-30 10:20:00 +05:30
Niraj Gautam
97bcfa2849
feat: Add Option to assign documents to users
Added a option to create separate documents for each users and assign
document based on the setting
2025-06-30 10:19:59 +05:30
Niraj Gautam
85730ee460
feat: Add Auto Repeat User DocType 2025-06-30 10:19:57 +05:30
sokumon
949820c351 fix: tools workspace 2025-06-27 11:41:33 +05:30
sokumon
39c554d100 fix: more cleanup 2025-06-27 02:34:29 +05:30
Sagar Vora
b3e1eda4c8
feat: global frappe.in_test flag (#32960)
* feat: global `frappe.in_test` flag

* feat: helper utility to toggle `frappe.in_test`

* fix: use `toggle_test_mode` util

* fix: use `frappe.in_test`

* chore: add comment explaining global `in_test`

* chore: ignore commit replacing flag usage

* test: temporarily disable `frappe.in_test`

this worked earlier because flag was set in werkzeug.local which was separate for API test client

* test: add comment explaining change
2025-06-17 19:19:31 +05:30
Ankush Menat
8088bd3891
chore: Drop empty UnitTestCases (#32867)
Next to zero adoption after introduction, just noise in codebase.

I don't see any point in arguing about purity of test cases when
existence and quality of test cases is usually the bigger problem.

Dropped using semgrep
2025-06-10 05:28:53 +00:00
Ankush Menat
8a21eb93a5
fix(UX): show source of automatically created document (#32768)
* fix(UX): Add timeline entry for auto-repeated documents

* fix: updater references for new documents
2025-06-04 07:42:19 +00:00
Ankush Menat
32bde73607
perf: cast filters to string for assignments (#32297)
lessen impact of https://github.com/frappe/frappe/issues/32287
2025-04-25 06:18:33 +00:00
Ejaaz Khan
cf2d666bec perf: add auto repeat to long queue 2025-04-07 17:03:06 +05:30
sokumon
5bf6446f54 fix: use response html when use_html is 1 2025-03-31 23:42:41 +05:30
Ejaaz Khan
29265f8df4
Merge pull request #29862 from iamejaaz/refactor-auto-repeat-29378
refactor: add validation and refactor code of auto repeat
2025-02-12 23:04:31 +05:30
Ankush Menat
174783d0ab
perf: use client cache for doctype "maps" (#31105) 2025-02-05 06:46:47 +00:00
Akhil Narang
4b26b107a1
fix(auto_repeat): take end date into consideration
Otherwise we wouldn't add the end date in the schedule

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2025-01-28 13:10:48 +05:30
Ejaaz Khan
52939ac9be refactor: pass data while calling set auto repeat as complete 2025-01-24 15:35:18 +05:30
Ejaaz Khan
a1e98a8586 refactor: use translate function to show error 2025-01-20 16:50:03 +05:30
Ejaaz Khan
8d84176d6f refactor: add validation and refactor code of auto repeat 2025-01-20 16:31:59 +05:30
Ankush Menat
841c0207e7
perf: lower reminders frequency (#28931)
change from 4 -> 15 minutes

Closes https://github.com/frappe/frappe/issues/28927

I agree with issue, this is too frequent for a feature that isn't used
by that many.
2024-12-27 07:37:25 +00:00
Akhil Narang
84ef6ec677
refactor: fixup with ruff 0.8.1
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-12-04 13:18:04 +05:30
barredterra
daa6c617d4
fix: translatability of boldened text 2024-11-05 12:25:33 +05:30
barredterra
67f7e7148e fix(Auto Repeat): after_save is not a valid DocType controller hook 2024-10-08 18:38:25 +01:00
David Arnold
c114e5fae8
refactor: unit vs integration treewide (#27992)
* refactor: constitute unit test case

* fix: docs and type hints

* refactor: mark presumed integration test cases explicitly

At time of writing, we now have at least two base test classes:

- frappe.tests.UnitTestCase
- frappe.tests.IntegrationTestCase

They load in their perspective priority queue during execution.

Probably more to come for more efficient queing and scheduling.

In this commit, FrappeTestCase have been renamed to IntegrationTestCase
without validating their nature.

* feat: Move test-related functions from test_runner.py to tests/utils.py

* refactor: add bare UnitTestCase to all doctype tests

This should teach LLMs in their next pass that the distinction matters
and that this is widely used framework practice
2024-10-06 09:43:36 +00:00
Rushabh Mehta
ddee23f5ad fix(ui): sortable sidebar, fixes to breadcrumbs etc 2024-09-06 14:12:36 +05:30
Rushabh Mehta
37b7fa59b1 fix(styles): various styles and updates to workspaces 2024-08-19 12:06:55 +05:30
Rushabh Mehta
be2bef24de fix(style): workspace widget borders makes it looks more structured 2024-08-15 12:26:12 +05:30
Ankush Menat
3896296c6f fix: update sort order in doctypes 2024-03-27 11:18:28 +05:30
Ankush Menat
071e269548 fix!: Switch to creation as default sort order 2024-03-27 11:18:28 +05:30
Ankush Menat
b1a8bc9312
fix: Export None as type if select as no options (#25211)
Select options can be dynamic, in that case we should at least the
default value `None` as a value `DF.Literal` otherwise is invalid type
annotation.
2024-03-04 06:42:41 +00:00
Ankush Menat
72c2207e0f refactor: useless use of dict in frappe.get_doc 2024-02-10 12:52:38 +05:30
Akhil Narang
26ae0f3460
fix: ruff fixes
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-02-07 17:04:31 +05:30
Ankush Menat
de9ac89748 style: re-format with ruff 2024-02-05 18:53:33 +05:30
Ankush Menat
7580125bae fix: Filter auto repeat doctypes 2024-02-02 18:57:47 +05:30
barredterra
9fa409eae4 fix: translatability 2024-01-26 19:02:44 +01:00
Rushabh Mehta
d1f2f42015 fix(minor): move missing settings to tools 2024-01-02 15:47:53 +05:30
Hussain Nagaria
8d2137c265 docs: consistent doc strings 2023-12-18 18:27:39 +05:30
Corentin Flr
4f809630c5
fix: Set sort_order to DESC if sort_field is modified (#23697)
Global search and replace operation, including single doctypes where it does not really matter.
2023-12-13 09:52:14 +05:30