Commit graph

38772 commits

Author SHA1 Message Date
Suraj Shetty
2b0a3533d3 test: Update test case according to changes 2022-07-12 12:58:15 +05:30
Suraj Shetty
a574e3c09e fix: Send emails immediately during tests 2022-07-11 18:55:43 +05:30
Suraj Shetty
8f5650de5b fix: Use errored email stats while showing send status 2022-07-11 17:43:56 +05:30
Suraj Shetty
a1bd1b3b23 perf: Index status of recipeint & unsubscribed & email_group of member
- This will improve the performance of few get queries newsletter
2022-07-11 17:42:41 +05:30
Suraj Shetty
bae2db278d fix: Update status color
Because both "Not Sent" & "Not Saved" had same indicator color and it was hard to distinguish
2022-07-11 15:27:43 +05:30
Suraj Shetty
802a1ac993 refactor: Newsletter status updator
- Freeze newsletter till emails are queued
- Show newsletter status as "Sending" if emails are in queue
- Remove unused dashboard code
2022-07-11 13:42:15 +05:30
Suraj Shetty
da52098bd3 perf: Batch email queuing while sending emails to large no. of recipients separately
- Batch email queue
- Re-use smtp_session while sending bulk emails (from same sender)
instead of creating new session for everytime.
Note: creation of new email session is very expensive.
2022-07-11 12:24:25 +05:30
Sagar Vora
fc99c22ea2
fix: ensure that frappe.db.get_defaults works for all parents (#17296)
fix: ensure that frappe.db.get_defaults` for all parents, as designed
2022-07-08 18:08:36 +05:30
Suraj Shetty
0a8a91e30b
Merge pull request #17447 from ankush/test/private_files 2022-07-08 11:28:20 +05:30
Ankush Menat
d04df394a5 test: check for uploaded file to be private 2022-07-08 11:06:49 +05:30
Sagar Vora
6597dedaed
chore!: remove unused APIs from frappe.client (#17446)
chore: remove unused APIs from `frappe.client`
2022-07-08 10:49:39 +05:30
Suraj Shetty
658f5b6aa7
Merge pull request #17437 from surajshetty3416/files-private-by-default
fix: Set files private by default
2022-07-07 18:05:14 +05:30
Ankush Menat
111060224b fix: naming series tool doesn't load if missing numbers 2022-07-07 17:38:52 +05:30
Suraj Shetty
5d01fffac5 fix: Set files private by default 2022-07-07 15:15:41 +05:30
Shariq Ansari
15018b96fa
test: fixed flaky workspace blocks UI test (#17436) 2022-07-07 14:53:25 +05:30
Ankush Menat
bea2df6dcc
perf: drop country_info from boot (#17431)
* fix: unknown function call

* perf: drop country_info from boot

This is ~50kb of data that is sent with every boot.
2022-07-07 14:41:13 +05:30
Ankush Menat
b5128a35fd
refactor: simplify fetching of readable records (#17417)
- remove encoding, use cstr directly
- remove falsy values by default None, empty string.
2022-07-07 14:40:59 +05:30
Shariq Ansari
44117f6702
fix: switch tab if mandatory field is in different tab (#17435) 2022-07-07 14:20:54 +05:30
Bhavesh Maheshwari
f972bb320b
fix: phone field type hidden property break form load (#17426)
Co-authored-by: Shariq Ansari <30859809+shariquerik@users.noreply.github.com>
2022-07-07 12:19:23 +05:30
mergify[bot]
010a436569
Merge pull request #17407 from ruthra-kumar/error_on_export_of_composite_cell_value
fix: valueerror on export with composite cell valu
2022-07-07 05:49:18 +00:00
Ankush Menat
1f9a6b010a
perf: add __slots__ to most used classes (#17421)
Added slots for these classes:

- Session - Created on EACH request
- LoginManager - Created on each request
- Monitor - Created on each request if monitor is enabled (usually in
  prod setup)
2022-07-07 11:15:50 +05:30
Ritwik Puri
b115aef414
fix: sanitize all line boundaries for email headers (#17408)
* test: add test case for subject with LF, CR and line separator
2022-07-07 10:43:00 +05:30
Suraj Shetty
281160ba2f
Merge pull request #17429 from frappe/dependabot/npm_and_yarn/moment-2.29.4
build(deps): bump moment from 2.29.2 to 2.29.4
2022-07-07 09:44:47 +05:30
dependabot[bot]
39ded52028
build(deps): bump moment from 2.29.2 to 2.29.4
Bumps [moment](https://github.com/moment/moment) from 2.29.2 to 2.29.4.
- [Release notes](https://github.com/moment/moment/releases)
- [Changelog](https://github.com/moment/moment/blob/develop/CHANGELOG.md)
- [Commits](https://github.com/moment/moment/compare/2.29.2...2.29.4)

---
updated-dependencies:
- dependency-name: moment
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-07-07 04:10:25 +00:00
Suraj Shetty
5efbedf06d
Merge pull request #17419 from surajshetty3416/replace-incompatible-libraries 2022-07-07 09:39:56 +05:30
Suraj Shetty
ccebf352c6
Merge branch 'develop' into replace-incompatible-libraries 2022-07-07 09:27:35 +05:30
Suraj Shetty
52c45bf464 fix: Multi argument dispatch 2022-07-07 09:25:30 +05:30
Suraj Shetty
295926f6b4 fix: Font awesome path 2022-07-06 13:01:38 +05:30
ruthra kumar
abd8f2c2c4 test: excel export with composite cell value 2022-07-06 12:52:47 +05:30
ruthra kumar
ffd75e8a16 fix: valueerror on export with composite cell valu 2022-07-06 12:35:20 +05:30
Suraj Shetty
3e724cd2f2 fix: Use "html.parser" to avoid additional parser dependency
- result from html.parser is fine for further processing
2022-07-06 08:31:18 +05:30
Suraj Shetty
fd7e607ad1 refactor: Use minified font-awesome file and add FA license 2022-07-06 08:31:01 +05:30
Suraj Shetty
d4166dbe20 refactor: Replace html2text with markdownify 2022-07-06 08:23:14 +05:30
Ankush Menat
aed9d22609
fix: incorrect default fraction for USD (#17415)
fix: correct fraction for El Salvador
2022-07-05 19:51:58 +05:30
Suraj Shetty
4b6ab45c57 refactor: Replace fluxify with vuex
Reason:
fluxify has GPL2 licence which is incompatible with MIT hence using vuex which is a similar library and has MIT license.
2022-07-05 19:45:17 +05:30
Ankush Menat
18af7da807 fix: missing add/remove field button on listview settings
closes https://github.com/frappe/frappe/issues/16783
2022-07-05 18:38:32 +05:30
Ankush Menat
5d2aedc698 fix(postgres): end transaction before DDL
closes https://github.com/frappe/frappe/issues/17210
2022-07-05 17:43:02 +05:30
Ankush Menat
93c2cb757f
Merge pull request #17414 from ankush/url_enhancements
fix: misc url/routing fixes
2022-07-05 17:07:07 +05:30
Ankush Menat
70fbab828c fix: do not update URL on saved reports
"Saved reports" imply that they have already stored filters, columns
etc. Applying URL from filters doesn't make sense here.
2022-07-05 16:45:51 +05:30
Ankush Menat
39c5d0d454 fix: only update URL if active list is still same
If you rapidly move from a list view while it was being refreshed then
changed URL is applied on a page that MIGHT not be the list/report view.

This check ensures that same page is present before updating URL.
2022-07-05 16:35:49 +05:30
Ankush Menat
261fbfcd11
Revert "fix(doc)!: Always cast datetime, date and time fields"
Revert "fix(doc)!: Always cast datetime, date and time fields (#15891)"

This reverts commit d7789ab6ff.
2022-07-05 13:43:32 +05:30
Himanshu
d7789ab6ff
fix(doc)!: Always cast datetime, date and time fields (#15891)
### BREAKING CHANGE
#### Datetime, Date and Time fields will always be cast to respective objects in `setattr`, this will ensure uniformity while accessing the values, no more `getdate`, `get_datetime`, `to_timedelta` wrapper.
- While importing data, the framework does check for `set_only_once`.
- In normal case scenarios, this will work flawlessly since most date fields might not be set_only_once.
- But in Subscription, the date field is set to `set_only_once` and in `after_insert`, `document.save` is called, and while doing so, `set_only_once` is checked [here](1944a547f9/frappe/model/document.py (L566)).
-This works fine if the data imported is in the correct format.
- If the date's data is not in the correct format, the framework throws an error.
- for eg `06-02-2022 00:00:00 != 06-02-2022`
- fixes [Issue/#15370](https://github.com/frappe/frappe/issues/15370)

> no-docs
2022-07-05 07:07:16 +00:00
Ankush Menat
9a03c53572
Merge pull request #17405 from ankush/feat/currency_symbol_loc
feat: configurable location of currency symbol
2022-07-05 11:22:02 +05:30
Ankush Menat
054ad9c30c feat: Allow showing currency symbol to the right 2022-07-05 11:21:23 +05:30
mergify[bot]
fa3f72fef4
Merge pull request #17289 from surajshetty3416/cleanup-libs
chore: Remove unused libraries/files and update licenses
2022-07-05 05:17:14 +00:00
gavin
93ef06f233
Merge pull request #17388 from gavindsouza/ci-mariadb-10_6
ci: Bump mariadb from 10.3 to 10.6
2022-07-05 09:51:02 +05:30
Ankush Menat
faf0d15c51 refactor: load country and currency info in boot
Previously this was done in ERPNext but all currency formatting
functionality depends on this, hence moved to framework. Largely
rewritten from scratch.
2022-07-04 20:29:38 +05:30
Gavin D'souza
db53813a68 ci(install): Set mariadb root password via envvar
ref: https://github.com/frappe/frappe/runs/7175643618
2022-07-04 20:21:28 +05:30
Raffael Meyer
f4fa4d303f
fix: "You viewed/edited/created this" (#17365)
### Issues
In the form timeline we show events like “{user} {created/viewed/edited} this {some_time_ago}”. If user is the current user, we used “You” instead of “Jon Doe”. This works in English, but in other languages it messes up the rest of the sentence.

Because of this, people added wrong translations of “You” that made the grammar work, but also made the message less clear.

Also, the _last viewed_ message used to link to **View Log**. That can be read by system managers only and doesn't hold additional information. So it's just a source of errors for users trying to click on it.

### Fixes

- don't mix up users and salutations. Always show user's full name.
- change the _last viewed_ message to work like the other two, remove link to **View Log**

### Demo

Logged an as Administrator:

English

![Bildschirmfoto 2022-06-30 um 15 28 37](https://user-images.githubusercontent.com/14891507/176689772-dd878c90-4a2c-4a32-aa6c-d2e14a6340e1.png)

German

![Bildschirmfoto 2022-06-30 um 15 28 03](https://user-images.githubusercontent.com/14891507/176689812-ce13bb31-6c70-40f2-8699-6fb0db1d06f9.png)
2022-07-04 14:03:31 +00:00
Ankush Menat
9a5d11234c
fix: validate scheduler, hook method names (#17400)
* chore: warn about missing scheduler / doc events

* fix: pass list instead of filter

filter can only be iterated upon once

* refactor: many typehints in __init__.py
2022-07-04 19:29:16 +05:30