Commit graph

2365 commits

Author SHA1 Message Date
barredterra
cd37bf0337 fix(Blog Post): correct indicator filter 2023-12-30 01:37:53 +01:00
Ankush Menat
8c515a9a5d fix: correct perm check for guests
Allow viewing document page if doctype allows guest to view
2023-12-29 17:59:39 +05:30
Ankush Menat
38314aec59
fix: Check permissions before rendering web view (#24032) 2023-12-29 17:07:17 +05:30
Suraj Shetty
529d0aa5a7
Merge pull request #24018 from surajshetty3416/hook-to-add-custom-route-resolver 2023-12-29 06:53:18 +05:30
Suraj Shetty
a51a150376 feat: Hook to add custom route resolver 2023-12-29 06:33:59 +05:30
Akhil Narang
ff4dca3e16
fix(redirect): make the status codes a select field instead of int
Drop mandatory, assume sane defaults
The current implementation broke old users of redirects like helpdesk app

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-12-22 12:25:41 +05:30
Ankush Menat
36451b6951
Merge pull request #23765 from akhilnarang/http-307-redirect
feat: allow setting a custom http status code for redirects
2023-12-21 13:53:51 +05:30
Ankush Menat
0fd6f5eed7
Merge pull request #23827 from frappe/api-docs
docs: add Python API missing docstrings / type hints
2023-12-21 12:13:05 +05:30
Akhil Narang
2224d86c94
refactor: cache status code as well
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-12-20 17:47:16 +05:30
Akhil Narang
6819a38fbe
fix: set correct response code for redirections
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-12-20 17:36:42 +05:30
Akhil Narang
44667901bf
feat: allow setting a custom http status code for redirects
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-12-20 17:36:42 +05:30
Hussain Nagaria
8d2137c265 docs: consistent doc strings 2023-12-18 18:27:39 +05:30
barredterra
70c7315ed8 Merge branch 'develop' into jinja-syntax 2023-12-17 19:54:16 +01:00
Ankush Menat
174e24f159 fix: validate custom portal menu entries during sync 2023-12-13 17:55:05 +05:30
Ankush Menat
957f9a01b5
fix: discard deleted doctypes unconditionally (#23770) 2023-12-13 15:57:18 +05:30
Arjun
8e4b0ade78
fix: remove web_form rate limit key (#23767) 2023-12-13 15:39:10 +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
barredterra
468f3c6738 feat(Web Template): switch from pure HTML to Jinja highlighting 2023-12-12 20:06:45 +01:00
Suraj Shetty
bc2b41d2f5 perf: Simplify dynamic route evaluation to speed up route resolution
validate complete route only if starting of the path matches with the webform route

This avoids the expensive matching from huge route_map (in sites with lots of web forms)
2023-12-08 21:15:34 +05:30
Suraj Shetty
7452e71d02 perf: Use get_cached_doc instead of get_doc
- Makes document pages with no-cache load a bit faster
2023-12-08 20:55:25 +05:30
Ankush Menat
57699a54b1
fix: Show server script name in traceback (#23676)
* fix: Show server script name in traceback

* chore: typo

Co-authored-by: Sagar Vora <sagar@resilient.tech>

---------

Co-authored-by: Sagar Vora <sagar@resilient.tech>
2023-12-08 15:01:13 +05:30
barredterra
c35476256f refactor: simplify conditional logic
Command: `sourcery review --fix --enable de-morgan .`
2023-12-05 11:14:41 +01:00
Ankush Menat
15384f88e0 chore: dead code/comment 2023-11-29 22:11:37 +05:30
Ankush Menat
74a3e24653
Merge pull request #23490 from ankush/preload_headers
fix: Only preload icons for desk
2023-11-29 22:07:09 +05:30
Ankush Menat
957293bd54 fix: Only preload icons for desk 2023-11-29 21:50:18 +05:30
Corentin Flr
932ef76da3
chore(kb): Drop unused parameter path 2023-11-29 16:12:01 +01:00
Corentin Flr
5781a913c7
refactor(kb): Rename clear_website_cache to clear_knowledge_base_cache 2023-11-29 16:09:04 +01:00
Corentin Flr
d432ff7a08
refactor(kb): Don't call website.utils.clear_cache again
Indeed, `website.utils.clear_cache` is already called by `WebsiteGenerator.clear_cache` the parent class of Help Article/Category.
2023-11-29 16:09:04 +01:00
Corentin Flr
4b3ddf30f3
fix(kb): Fix cache clearing not being triggered 2023-11-29 16:09:04 +01:00
18alantom
5722d9c2ba fix: set sidebar only if not present
The get_context of some templates set their own sidebar
if this is done, no need to override
2023-11-29 12:11:34 +05:30
Rushabh Mehta
8a38976442
Merge pull request #23405 from rmehta/inter-fix
fix: Inter V loading issues + Update to Version 4
2023-11-24 15:17:48 +05:30
Rushabh Mehta
f9f36b6f72 fix: Inter V loading issues 2023-11-24 15:01:45 +05:30
Shariq Ansari
655e646d8b
Merge pull request #23401 from shariquerik/banner-image-name-overlapping
fix: webform banner_image name replacing navbar banner_image
2023-11-24 12:43:42 +05:30
Shariq Ansari
01fb455a76 fix: webform banner_image name replacing navbar banner_image 2023-11-24 11:29:29 +05:30
Akhil Narang
23bcb6733e
refactor(website_generator): update variable name to make more sense as per usage
Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
2023-11-23 16:06:07 +05:30
Akhil Narang
fbc88a4d24
refactor(treewide): code cleanup
Drop redundant bool conversion

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-11-23 13:57:51 +05:30
Akhil Narang
3896750e2e
refactor(web_form): cleanup code
`frappe.get_meta()` gives us all the data we require

Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-11-22 17:01:01 +05:30
Akhil Narang
67b74cd4bb
fix(web_form): check properties for title field as well
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-11-22 11:54:36 +05:30
Corentin Flr
8b03a48f24
fix(WebForm): Replace get_cached_value with get_value
frappe.get_cached_value does not support filters
2023-11-20 12:13:55 +01:00
mergify[bot]
318b2e5ca2
fix:The title of the Link control does not appear correctly in the we… (backport #23270) (#23280)
Co-authored-by: Nrtyck <37080373+Nrtyck@users.noreply.github.com>
2023-11-18 23:06:12 +05:30
Corentin Flr
b079d3ef78
fix(web): Send first_day_of_the_week and number_format in bootinfo 2023-11-17 16:14:37 +01:00
David Arnold
18f34c36f6
fix(float): input formatting 2023-11-07 18:07:06 +01:00
Raffael Meyer
f0155674a5
refactor!: remove redundant sending of translations (#22962)
* chore!: remove redundant translation

* refactor!: remove "get_translated_dict" hook

Instead, include the results from
`frappe.geo.country_info.get_translated_dict` in `get_all_translations`.

* test: money_in_words uses translated currency

... and now we have translations.

* Revert "test: money_in_words uses translated currency"

This reverts commit e07d594ac1ce4b120c0fceb5d23377cb981fe820.

* refactor!: stop translating timezone and currency

* refactor: rename `get_translated_dict`

... to `get_translated_countries`
2023-11-02 20:04:14 +05:30
Suraj Shetty
b56cbdfff8
perf: Enqueue "removing of index" on web page deletion (#23044) 2023-11-01 09:40:51 +05:30
Akhil Narang
796b11d665
chore(help_article): drop usage of ifnull
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-10-31 15:36:01 +05:30
Thomas Fojan
36ad7e053e
fix: developer mode in website theme (#22958)
[skip ci]
2023-10-30 18:06:19 +05:30
Suraj Shetty
7497b00167
Merge pull request #22967 from maharshivpatel/fix-inter-font-load-web 2023-10-30 17:39:38 +05:30
Akhil Narang
13537ad0f6
chore(blog_post): drop usage of ifnull (#22983)
`published` is a `Check` (int, non-nullable) field which has a default value in the database

Signed-off-by: Akhil Narang <me@akhilnarang.dev>


[skip ci]
2023-10-30 17:21:43 +05:30
Maharshi Patel
cd8c2dd21c fix: font loading on custom website theme
- added inter.scss as css import is failing in custom website theme
- changed css to inter.scss for website/index.scss
- inter.css is deprecated and should be removed in future
- update --font-stack if custom fonts are used in website theme.
- removed espresso variables from css_variables.scss
  as they are already imported in variables.scss
2023-10-30 12:44:35 +05:30
Maharshi Patel
259695a1c7 fix: web styles espresso
- added Inter & Inter V on website and font-stack
- added flex to logged-in to center avatar
- decreased brand logo height to 22px
- added primary border-bottom to active navbar link
- added underline to links for blog content
  and added to from-markdown for web pages
2023-10-26 12:50:56 +05:30