Commit graph

2145 commits

Author SHA1 Message Date
Shariq Ansari
2eb70c381a chore: rearranged web form tabs and fields 2022-08-17 19:02:40 +05:30
Shariq Ansari
fec57546ee fix: show empty fields in web form's view mode 2022-08-17 18:33:59 +05:30
Shariq Ansari
7cd528084e fix: added in_view_mode flag 2022-08-17 18:21:14 +05:30
Shariq Ansari
b0adf07790 chore: renamed is_form_editable to in_edit_mode 2022-08-17 18:14:46 +05:30
Shariq Ansari
f7942a4a8b fix: Keep action button size consistent 2022-08-17 18:11:18 +05:30
Ankush Menat
1c9ea57279 fix: dont use sendmail with now=True 2022-08-17 16:39:42 +05:30
Ankush Menat
3e2d2a703a test: Use FrappeTestCase everywhere 2022-08-17 16:39:42 +05:30
Shariq Ansari
14bcd977b5
feat: Webform Success Page and some customization options (#17790) 2022-08-11 21:18:51 +05:30
Shariq Ansari
cfb56688e9
refactor: Multi Step Web Form (#17783) 2022-08-10 18:05:20 +05:30
Ankush Menat
5d4e1e66b8 refactor!: drop lazy loading utility
Browsers now natively support this with `lazy` attribute.
2022-08-09 18:15:14 +05:30
Ankush Menat
ce164d59e3 fix: limit allowed attributes for lazy images
Co-Authored-by: Sagar Vora <sagar@resilient.tech>
2022-08-09 17:59:45 +05:30
Shariq Ansari
0ce7f44d45
fix: Webform Misc Fix (#17642) 2022-08-07 15:24:50 +05:30
Ankush Menat
40f27f908a style: format JS files with prettier 2022-08-04 14:51:01 +05:30
Gavin D'souza
85e3ee9403 chore: Minified DocType JSON notation from old verbose notation 2022-08-03 12:22:03 +05:30
phot0n
ed39d2c6ed chore: remove payments params from webform's whitelisted accept fuction 2022-07-27 11:00:02 +05:30
phot0n
a1ffcb37ee chore: remove payments fields from edit_profile, request_data & request_to_delete_data webforms 2022-07-26 23:17:05 +05:30
phot0n
332919317d chore: remove payments_tab from web form 2022-07-26 23:17:05 +05:30
phot0n
be4b7906c0 chore: remove payment stuff from web form controller class 2022-07-26 15:11:56 +05:30
phot0n
6c75787d40 chore: remove payments section from webform doctype 2022-07-26 15:11:56 +05:30
Shariq Ansari
b1e9bc8d12
fix: error while genarating date for blog post google search preview (#17581) 2022-07-21 20:46:03 +05:30
Ankush Menat
066d5a4245
Merge pull request #17528 from phot0n/mis-fixes-goauth
fix: misc fixes (google oauth)
2022-07-19 15:55:24 +05:30
Shariq Ansari
a50e0ffa08
refactor: Webform (#17232) 2022-07-19 15:52:15 +05:30
Ankush Menat
29c855b028
fix: db.get_value -> db.get_single_value (#17531)
db.get_value for singles returns string type always, this is confusing
behaviour, db.get_single_value should be used instead.

semgrep rule: https://github.com/frappe/semgrep-rules/pull/16
2022-07-18 15:10:49 +05:30
phot0n
f679dc3fdd fix(security): restrict the god google callback
the common google callback can be used to trigger any method in the whole codebase
restrict it by only allowing domain specific callback method and raise
an error if the domain is not found
2022-07-17 21:37:21 +05:30
Shariq Ansari
a8f86abbd8
refactor: Replaced blog's feedback with comment's comment_type='Like' (#17479) 2022-07-14 14:09:00 +05:30
phot0n
31c5f260d7 chore: use f-strings 2022-07-13 12:29:25 +05:30
phot0n
8b38fcb438 chore: move getting site address to GoogleOAuth 2022-07-13 12:05:46 +05:30
phot0n
484758d6e0 chore: remove additional/unnecessary set_value calls 2022-07-13 12:05:46 +05:30
phot0n
6848c93770 chore: remove GET method whitelisting from google integrations 2022-07-13 12:05:46 +05:30
phot0n
07a577af86 feat: google oauth for google emails
* used unique constraint on email_id in Email Account Doctype
2022-07-13 12:05:46 +05:30
phot0n
26dd606831 refactor: GoogleOAuth
* refactor: single callback method for google oauth
2022-07-13 12:05:46 +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
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
81b37cb7d2
refactor: clean up code to py310 supported features (#17367)
refactor: clean up code to py39+ supported syntax

- f-strings instead of format
- latest typing support instead of pre 3.9 TitleCase
- remove UTF-8 declarations.
- many more changes

Powered by https://github.com/asottile/pyupgrade/ + manual cleanups
2022-07-01 11:51:05 +05:30
Suraj Shetty
b0d53d93ad
Merge pull request #17264 from netchampfaris/page-builder-section-ids 2022-06-22 12:48:36 +05:30
Faris Ansari
8814041b33 fix: set web-template attr in script and style tags from web templates
Also, deduplication of styles and scripts when web_blocks jinja method is used
2022-06-21 20:42:14 +05:30
Faris Ansari
891a2c7d5b feat(PageBuilder): Section IDs
Set IDs on sections so that you can link to them using anchor tags
2022-06-21 20:03:00 +05:30
Suraj Shetty
64cc07227e refactor: Replace usage of deprecated attribute 2022-06-21 08:00:49 +05:30
Gavin D'souza
a1691784a8 chore: Drop duplicate get_frontmatter definition 2022-06-13 18:39:56 +05:30
gavin
9ce74fb6c4
Merge branch 'develop' into request-cache 2022-06-09 12:32:03 +05:30
Suraj Shetty
27b49743e3 fix: Comment tag extractor code 2022-06-09 09:22:07 +05:30
gavin
6f6ded256f
Merge pull request #17111 from gavindsouza/refactor-re
perf: Pre-compile and re-use regexp pattern
2022-06-08 15:05:59 +05:30
Jannat Patel
d9f9ef28de
fix: translatable web templates (#17086) 2022-06-08 14:48:56 +05:30
Gavin D'souza
b696fa6da5 perf: Pre-compile and re-use regexp pattern
Converted all possible usages of re.* that weren't compiling the regex
separately and re-using it. Separated out the compiled patterns as
global variables. Repetitive patterns could be made DRY-er.

Would be nicer to have all regexes in a single module so that we could
re-use better, keep track of outdated, and keep checks for possible
reDos' etc
2022-06-08 14:07:38 +05:30
gavin
44dba28159
Merge branch 'develop' into refactor-file 2022-06-08 12:43:35 +05:30
Gavin D'souza
958745fbc0 refactor(minor): Website Settings 2022-06-07 15:56:26 +05:30
Ernesto Ruiz
e925600b70
fix: link to Google Settings in Website Settings (#17083) 2022-06-06 20:13:48 +05:30
Gavin D'souza
5ec2690160 Merge branch 'develop' into refactor-file 2022-06-01 15:47:55 +05:30
Suraj Shetty
1431cb26d3 fix: Catch any expection and show proper error page
- Also, show title & message if it is defined in the exception class
2022-06-01 08:08:52 +05:30