Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature/ogc 1408 videos in directories #1157

Merged
merged 22 commits into from
Feb 9, 2024

Conversation

Tschuppi81
Copy link
Contributor

@Tschuppi81 Tschuppi81 commented Feb 1, 2024

Directories: Adds support for videos

TYPE: Feature
LINK: ogc-1408

Copy link

linear bot commented Feb 1, 2024

url = None
data = self.escape(field.data)

if kwargs:
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Daverball I did not find a good way to distinguish between editing and displaying the video url.
My goal is to show the 'plain url' in a StringField when editing the directory entry and the embedded video otherwise.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Field display is strictly for display, it should never be editable, so it does not make sense to render an input field here.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You'll want to create a separate Widget for rendering the input, but considering the widget is just a regular url field anyways, you don't need a custom widget.

@codecov-commenter
Copy link

codecov-commenter commented Feb 1, 2024

Codecov Report

Attention: 2 lines in your changes are missing coverage. Please review.

Comparison is base (e641db1) 87.61% compared to head (59140cf) 87.62%.
Report is 2 commits behind head on master.

Files Patch % Lines
src/onegov/form/parser/core.py 88.88% 1 Missing ⚠️
src/onegov/form/parser/form.py 66.66% 1 Missing ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1157   +/-   ##
=======================================
  Coverage   87.61%   87.62%           
=======================================
  Files        1188     1188           
  Lines       79454    79500   +46     
=======================================
+ Hits        69616    69660   +44     
- Misses       9838     9840    +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

src/onegov/form/fields.py Outdated Show resolved Hide resolved
Tschuppi81 and others added 5 commits February 1, 2024 15:20
Use markup directly

Co-authored-by: David Salvisberg <david.salvisberg@seantis.ch>
Make use of the original widget

Co-authored-by: David Salvisberg <david.salvisberg@seantis.ch>
fix multi-line import

Co-authored-by: David Salvisberg <david.salvisberg@seantis.ch>
@Tschuppi81 Tschuppi81 marked this pull request as ready for review February 9, 2024 07:43
src/onegov/form/display.py Outdated Show resolved Hide resolved
src/onegov/form/display.py Outdated Show resolved Hide resolved
Tschuppi81 and others added 2 commits February 9, 2024 09:24
Co-authored-by: David Salvisberg <david.salvisberg@seantis.ch>
…ape on any parameter of the format method.

Co-authored-by: David Salvisberg <david.salvisberg@seantis.ch>
@Tschuppi81 Tschuppi81 merged commit 4e6fe19 into master Feb 9, 2024
9 of 11 checks passed
@Tschuppi81 Tschuppi81 deleted the feature/ogc-1408-videos-in-directories branch February 9, 2024 08:29
@Tschuppi81 Tschuppi81 restored the feature/ogc-1408-videos-in-directories branch February 9, 2024 09:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants