* fix: Always bold report header row
* fix: update test cases
* refactor: add option to bold filter rows in XLSX output
* chore: minor changes
* chore: rename index variable
* revert: undo bold filters param use
* refactor: remove duplication for building xlsx data
* revert: add has_filters parameter to check for filter row bold
* refactor: add type hints and docstrings for XLSX data handling functions
* fix(query): check standard field definitions
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
* fix(postgres): fix order_by problem in pg
* fix(postgres): fix order_by in get_all for _test_connection_query
* fix: add check to a proper numeric fallback in _get_ifnull_fallback
* test(postgres): fix pg query used in assertion in test_permission_query
* fix(postgres): fix order_by in get_all for possible_link
* fix(postgres): fix order_by in get_all for set_modules
* fix(postgres): fix pg query count *
* fix(postgres): fix order_by in get_all for ask_pass_update
* fix(postgres): fix order_by statement in search_widget
* fix(postgres): fix order_by in get_list for get_stats
* test(postgres): normalize_sql for pg queries in test_arithmetic_operators_in_fields
* test(postgres): normalize_sql for pg queries in test_field_alias_in_group_by
* test(postgres): normalize_sql for pg queries in test_field_alias_permission_check
* test(postgres): fix order_by statement in get_all for test_db_keywords_as_fields
* test(postgres): fix order_by statement in get_all for test_prepare_select_args
* fix(treeview): use 0 instead of false to check since check field is an integer
* fix(postgres): fix order_by in get_all for sync_communication
* fix(postgres): fix order_by in get_all for get_references_across_doctypes_by_dynamic_link_field
* test(postgres): fix order_by in get_all for test_list_summary
* fix(postgres): fix order_by in get_all for email queries
* test(postgres): use order_by none and update assertion for postgres
* fix(postgres): use ILIKE to support case insensitive search in postgres
* test(test_query): update pg specific query assert to use ILIKE
* test(test_query): update test_nested_filters to use ilike instead for PG
* test(postgres): update pg query in assert to test updated qb query
* fix(search): update query to be db-agnostic
* test(postgres): normalize query for pg in test_build_match_conditions
* fix(postgres): suppress ORDER BY when SELECT DISTINCT in query for postgres specific behavior
* fix(postgres): suppress ORDER BY when GROUP BY is explicitly asked for pg specific behavior
* test(postgres): fix test behavior for pg ORDER BY drop when used with GROUP BY
* refactor: reducing noise in code by formatting code
* fix(query): use Star() to handle SQL wildcard character * correctly
* fix(postgres): display warning for ORDER BY fields that will be dropped
---------
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
Co-authored-by: Akhil Narang <me@akhilnarang.dev>
- Migrate all SQL function usage from string format to dict format
- Old: fields=['count(*) as count']
- New: fields=[{'COUNT': '*', 'as': 'count'}]
- Add `NULLIF`
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
* feat: add attachments to notification
* chore: remove unneeded comment
* fix: revert change of function name
* fix: simplify if statement
* fix: use doc language with highest prio in print
* fix: prevent empty list in attached_file
For empty list []:
- attachments and json.dumps(attachments) → returns [] (the empty list, because and short-circuits on falsy left side)
- json.dumps(attachments) if attachments else None → returns None (because empty list is falsy in if condition)
* fix(Notification): improve print letterhead handling in email attachments
Fix the logic for determining the print letterhead attachment to handle cases with multiple attachments, and only one of them printed.
* refactor: get_attachment to improve clarity
* fix(Notification): better fieldnames
* fix(Notification): condition & validation for From Attach Field
* test(Notification): attach files
---------
Co-authored-by: barredterra <14891507+barredterra@users.noreply.github.com>
Some doctypes like `Payment Entry`, `Bank Account`, `Pricing Rule` were present in 2 dashboards (customer and supplier dashboard), both of which were included in ERPNext communucation_doctype hooks
Signed-off-by: Akhil Narang <me@akhilnarang.dev>