Commit graph

39175 commits

Author SHA1 Message Date
Sagar Vora
f9bfbfec98
perf: reduce DB calls made in get_fetch_values (#17671)
* perf: reduce DB calls made in `get_fetch_values`

* fix: ensure return value is same as before

* test: add test for `frappe.model.utils.get_fetch_values`
2022-08-05 11:52:37 +05:30
vishdha
9a50c30586 fix: add_user_permission with applicale_for arg set not updating in user permission 2022-08-05 00:27:38 +02:00
Ankush Menat
f6210e7c38
Merge pull request #17697 from ankush/ast_translate
feat: use babel to extract translation sources
2022-08-04 15:53:42 +05:30
Ankush Menat
7452ac5d37
chore: correct default arg for extract_javascript
Tuples need extra comma to make sure it's not treated as string. 

[skip ci]

Co-authored-by: Sagar Vora <sagar@resilient.tech>
2022-08-04 15:52:32 +05:30
Ankush Menat
16fdff8231 chore: remove pointless template strings 2022-08-04 15:33:03 +05:30
Ankush Menat
ec8f20c097 fix: send all messages on boot instead of scanning
close https://github.com/frappe/frappe/issues/17684
2022-08-04 15:33:03 +05:30
Ankush Menat
2d7fc1825f refactor: simplify get_messages_from_file 2022-08-04 15:33:03 +05:30
Ankush Menat
da872a0edf feat: modified parser for frappe JS translate syntax 2022-08-04 15:33:02 +05:30
Ankush Menat
cd53466b6a feat: JS extractor and custom JS parser 2022-08-04 15:19:56 +05:30
Ankush Menat
1425842ef0 refactor: extract python translations using babel
RIP my cool handwritten AST code :'(

Few things to note:

1. Publicly documented APIs, they don't support capturing kwargs.
2. We can't use documented "lower level" APIs, we need to go _even lower_.
2022-08-04 15:19:55 +05:30
Ankush Menat
ea836a824a feat: use AST to extract translation sources 2022-08-04 15:19:55 +05:30
Ankush Menat
0cb4da1195 fix: ignore built assets in translation 2022-08-04 15:19:55 +05:30
Ankush Menat
7c80d1e0ab
Merge pull request #17495 from ankush/format_js
style: auto-format JS files
2022-08-04 15:19:13 +05:30
Ankush Menat
7c051875b2 chore: ignore js format commit 2022-08-04 14:52:09 +05:30
Ankush Menat
40f27f908a style: format JS files with prettier 2022-08-04 14:51:01 +05:30
Ankush Menat
015937a03a test: fix anticipiated test failures 2022-08-04 14:50:24 +05:30
Ankush Menat
7c1b96bc62 style: autoformat JS files 2022-08-04 14:50:24 +05:30
Ankush Menat
a1eaefefda refactor: simplfiy translate pattern
\s already includes \n
2022-08-04 14:50:24 +05:30
Ankush Menat
2746ac6aea
Merge pull request #17719 from gavindsouza/trim-fat
chore: Minified DocType JSON notation from old verbose notation
2022-08-03 14:05:46 +05:30
Ankush Menat
bdeb032fba
refactor: use separate config key for encryption (#17720) 2022-08-03 13:52:02 +05:30
gavin
e4fcf563d2
Merge pull request #17682 from resilient-tech/refactor-only-for
refactor: improve `frappe.only_for`
2022-08-03 12:54:32 +05:30
Gavin D'souza
8def87331f chore: Add minification to blame ignore 2022-08-03 12:26:38 +05:30
Gavin D'souza
85e3ee9403 chore: Minified DocType JSON notation from old verbose notation 2022-08-03 12:22:03 +05:30
Ritwik Puri
9b620bb648
fix: set /app as redirect for pageview home button (#17715) 2022-08-03 11:53:10 +05:30
Sagar Vora
eb1c9fff68 fix: translate each role 2022-08-02 19:28:33 +05:30
Sagar Vora
74c26ac34d fix: use throw 2022-08-02 19:16:53 +05:30
Sagar Vora
53118367b2 fix: use warn util 2022-08-02 19:08:02 +05:30
Sagar Sharma
d88d9f5186
fix: max_positive_value for Integer types (#17712)
* fix: max_positive_value for Integer types

* style: formatting

Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
2022-08-02 15:48:54 +05:30
Sagar Vora
ebb0cd13fe
perf: reduce DB call in frappe.client.get (#17665) 2022-08-02 15:38:39 +05:30
P-Godfroid
2d1fe02dba
fix: Append to condition misleading message (#17696)
* Update Append to doctype description

Hello,

To append email to a doctype to enable automatic creation, there are two required fields listed
![image](https://user-images.githubusercontent.com/109596710/182173486-d7141ec9-451d-4de9-8303-a8e8dbd289bf.png)

However, there is a third one required which is lacking in the above description (as seen below), because the email settings of the document must be enabled.
![image_2022-08-01_163225456](https://user-images.githubusercontent.com/109596710/182173390-7285e92f-6f04-4e42-a215-ad45e50e0fd3.png)

I propose to simply modify the sentence to the following :

Append as communication against this DocType (must have fields ("Status", "Subject") and "Sender" defined in the related doctype Email Settings).


To avoid any problem, in the code, it becomes the following : 
Append as communication against this DocType (must have fields (\"Status\", \"Subject\") and \"Sender\" defined in the related doctype Email Settings).


The same must be applied in email_domain.json and in lots of csv in translations of course.

Pierre

* Update email_domain.json

* Updated sentence email account

* Updated sentence of email domain

* More brackets

* More brackets

* Typo

* Update email_account.json

* No dot
2022-08-02 15:20:19 +05:30
Ankush Menat
63c3c8ff84
Merge pull request #17702 from gavindsouza/global-search-fixes
fix(global_search): Trigger rebuilding on Custom Field's `in_global_search` property change
2022-08-02 15:06:36 +05:30
Ankush Menat
bbb6451636
Merge pull request #17700 from resilient-tech/perf-doc-follow
perf(Document Follow): specify reference doctype in filters
2022-08-02 14:58:34 +05:30
Gavin D'souza
3863d9bb80 fix(global_search): Trigger rebuilding on Custom Field's property change 2022-08-02 14:49:04 +05:30
dependabot[bot]
3c4840f208
chore(deps): bump actions/labeler from 3 to 4 (#17698)
Bumps [actions/labeler](https://github.com/actions/labeler) from 3 to 4.
- [Release notes](https://github.com/actions/labeler/releases)
- [Commits](https://github.com/actions/labeler/compare/v3...v4)

---
updated-dependencies:
- dependency-name: actions/labeler
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-08-02 11:50:48 +05:30
Ankush Menat
d3343a6cd8 ci: mergify v14 hotfix and develop backports 2022-08-02 11:47:27 +05:30
Sagar Vora
183f60232c perf: specify reference doctype in filters 2022-08-02 06:15:00 +05:30
Sagar Vora
61ec026712 refactor: improve frappe.only_for 2022-08-01 22:10:25 +00:00
Raffael Meyer
e72a02e42c
feat: translate indian number system symbols (#17694) 2022-08-01 19:08:02 +05:30
Shariq Ansari
3927522873
fix: Show Report & Dashboard View for File Doctype (#17688) 2022-08-01 19:05:30 +05:30
Ankush Menat
2e85a49fd2
refactor: remove test doctype from core (#17598)
This was commited by mistake, instead of using the test doctype, create
it on demand for tests.
2022-08-01 19:05:13 +05:30
Shariq Ansari
4b9493a921
fix: import translate.js before utils.js (#17693) 2022-08-01 17:45:29 +05:30
Ankush Menat
01fbd035a7
ci: label test requirement (#17691)
[skip ci]
2022-08-01 15:30:03 +05:30
Shariq Ansari
c478673367
fix: allow to import time field (#17677) 2022-08-01 14:50:40 +05:30
Ankush Menat
9485c31f16 chore: typo
missed out in last commit
2022-08-01 14:31:53 +05:30
Ankush Menat
d9e62303a4
fix: translatable short number symbol (#17689) 2022-08-01 14:20:59 +05:30
Raffael Meyer
038aed7e27
feat: number shortening in German (#17662)
* feat: number shortening in German

* feat: don't forget Liechtenstein

* feat: number system

- extract into a separate file
- add other countries with indian system
- add german translations

* refactor: get_number_system
2022-08-01 12:46:58 +05:30
Ankush Menat
b836f2070f
Merge pull request #17680 from phot0n/clear-password
fix: clear password when saving email account with Oauth
2022-07-30 20:40:16 +05:30
phot0n
16f9a2e811 fix: clear password when saving account with Oauth 2022-07-30 00:03:02 +05:30
Ankush Menat
13148750ae
Merge pull request #17673 from vishdha/DEP-368
fix: Dropdown selection list in Reports should be translatable
2022-07-29 21:23:30 +05:30
Shariq Ansari
1b9aef4034
fix: Rating field value is faulty in list view (#17672) 2022-07-29 20:52:45 +05:30