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

Dépôt de besoin : détail : template pour le message affiché aux utilisateurs SIAE sans structures #1060

Merged
merged 1 commit into from
Jan 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions lemarche/templates/tenders/_detail_siae_user_without_siae.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<div class="alert alert-info" role="alert">
<p class="mb-1">
<i class="ri-lightbulb-line ri-lg"></i>
<strong>Comment contacter le client ?</strong>
</p>
<p class="mb-0">
Pour accéder aux coordonnées du client, veuillez d'abord vous <a id="add-siae-btn" href="{% url 'dashboard_siaes:siae_search_by_siret' %}">rattacher à votre structure</a>.
</p>
<p>
Besoin d'aide ? contacter le support via le chat en ligne qui se trouve en bas à droite.
</p>
</div>
17 changes: 4 additions & 13 deletions lemarche/templates/tenders/_detail_sidebar.html
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,7 @@
<!-- siae info & actions -->
{% elif user.kind == user.KIND_SIAE %}
{% if not user.has_siae %}
<div class="alert alert-info" role="alert">
<p class="mb-1">
<i class="ri-lightbulb-line ri-lg"></i>
<strong>Comment contacter le client ?</strong>
</p>
<p class="mb-0">
Pour accéder aux coordonnées du client, veuillez d'abord vous <a id="add-siae-btn" href="{% url 'dashboard_siaes:siae_search_by_siret' %}">rattacher à votre structure</a>.
</p>
<p>
Besoin d'aide ? contacter le support via le chat en ligne qui se trouve en bas à droite.
</p>
</div>
{% include "tenders/_detail_siae_user_without_siae.html" %}
{% elif siae_has_detail_contact_click_date %}
{% elif siae_has_detail_not_interested_click_date %}
{% include "tenders/_detail_not_interested_click_confirm.html" %}
Expand All @@ -72,7 +61,9 @@
<!-- anonymous tender -->
{% else %}
{% if user.is_authenticated or siae_id %}
{% if siae_has_detail_contact_click_date %}
{% if user.is_authenticated and not user.has_siae %}
{% include "tenders/_detail_siae_user_without_siae.html" %}
{% elif siae_has_detail_contact_click_date %}
{% include "tenders/_detail_contact_click_confirm_tender_response_is_anonymous.html" %}
{% elif siae_has_detail_not_interested_click_date %}
{% include "tenders/_detail_not_interested_click_confirm.html" %}
Expand Down
2 changes: 1 addition & 1 deletion lemarche/www/tenders/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -887,7 +887,7 @@ def test_tender_response_is_anonymous_contact_display(self):
self.client.force_login(self.siae_user_without_siae)
url = reverse("tenders:detail", kwargs={"slug": self.tender_3_response_is_anonymous.slug})
response = self.client.get(url)
self.assertNotContains(response, "veuillez d'abord vous")
self.assertContains(response, "veuillez d'abord vous")
self.assertNotContains(response, "Voir l'appel d'offres")
# author
self.client.force_login(self.user_buyer_1)
Expand Down
Loading