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

Adding Objects API client integration #793

Closed
wants to merge 17 commits into from

Conversation

alextreme
Copy link
Member

No description provided.

@alextreme alextreme marked this pull request as draft September 28, 2023 14:53
@bart-maykin bart-maykin force-pushed the feature/1776-objects-api-integration branch 2 times, most recently from 506f4be to 9942955 Compare October 6, 2023 09:20
</h2>
<div>
{% if objects %}
{% map 52.1326 5.2913 zoom=3 geojson_feature_collection=objects %}
Copy link
Member Author

Choose a reason for hiding this comment

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

Zou nog instelbaar gemaakt kunnen worden

{% if objects %}
{% map 52.1326 5.2913 zoom=3 geojson_feature_collection=objects %}
{% else %}
<p>Er staan geen taken gevonden</p>
Copy link
Member Author

Choose a reason for hiding this comment

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

Zou nog instelbaar gemaakt kunnen worden

@alextreme
Copy link
Member Author

Dank @bart-maykin voor een mooie eerste integratie van de Objecten API.

@jiromaykin goed om later deze maand ter voorbereiding op NLDS integratie hier naar te kijken. Bart heeft de stijling overgenomen op basis van:

Het storybook

React / Actions / Action - Link ⋅ Storybook (nl-design-system.github.io)

Github voor de frontend code

https://github.com/nl-design-system/denhaag

Ik twijfel nog wel wat de volgende stap hiermee wordt. We kunnen het (na wat poetsen) samenvoegen echter aangezien geen van de huidige OIP gemeenten de Objecten API gebruikt voelt het nog prematuur. @Bartvaderkin mag hier ook een blik op werpen

@bart-maykin bart-maykin force-pushed the feature/1776-objects-api-integration branch from 9942955 to eaed778 Compare October 24, 2023 09:24
@bart-maykin bart-maykin force-pushed the feature/1776-objects-api-integration branch from eaed778 to 92b6365 Compare October 24, 2023 09:28
Copy link
Contributor

@Bartvaderkin Bartvaderkin left a comment

Choose a reason for hiding this comment

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

Looks good, some small notes in the files.

Two other notes:

  • Can you rebase on current development and get rid of the ancient merge commits and other old noise.
  • We try to use [#1234] Added a thing to fix that other thing commit messages (eg: uppercase verb, no gitmoji and a useful message)
  • Why is this called a Den Haag action' ?

Comment on lines +18 to +23
if component := instance.component:
match component:
case ComponentChoices.link:
return "cms/objects/objects_list.html"
case ComponentChoices.map:
return "cms/objects/objects_map.html"
Copy link
Contributor

Choose a reason for hiding this comment

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

The project uses python 3.9 so no pattern matching.

<div class="denhaag-action__content">{{title}}</div>
<div class="denhaag-action__details">
<div class="denhaag-action__date">
<time datetime="2023-09-28T19:47:36.593Z">{{date}}</time>
Copy link
Contributor

Choose a reason for hiding this comment

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

Hardcoded datetime.

@@ -0,0 +1,15 @@
{% load l10n i18n %}

<a href="{{link}}" class="denhaag-action denhaag-action--single">
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is a lot of this namepaced as 'Den Haag'?

Comment on lines +1 to +11
from django import template

register = template.Library()


@register.inclusion_tag("components/DenhaagAction/DenhaagAction.html")
def denhaag_action(title, date, link, **kwargs):
kwargs["title"] = title
kwargs["date"] = date
kwargs["link"] = link
return kwargs
Copy link
Contributor

@Bartvaderkin Bartvaderkin Oct 24, 2023

Choose a reason for hiding this comment

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

What is 'Den Haag' about this? What is a 'DenhaagAction'?

</svg>
</div>
</div>
</a>
Copy link
Contributor

Choose a reason for hiding this comment

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

Github shows a red no-newline warning here (configure your editor to add it on save).

@alextreme alextreme added the on hold Pause working for now, continued after decisions label Feb 12, 2024
@alextreme
Copy link
Member Author

Vervangen met #1442 tijdens de afgelopen hackathon, dank Bart voor de oude PR we hebben er nuttig gebruik van weten te maken

@alextreme alextreme closed this Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
on hold Pause working for now, continued after decisions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants