-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Dépôt de besoin : Détail : cacher les CTA en fonction de l'intérêt en…
… co-traitance du prestataire (#1055) * Add siae_has_detail_cocontracting_click_date. Add tests * Final changes to make contact & cocontracting work together
- Loading branch information
Showing
7 changed files
with
178 additions
and
106 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
lemarche/templates/tenders/_detail_cocontracting_click_confirm.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
<div class="alert alert-success mt-3 mt-lg-0" role="alert"> | ||
<p class="mb-0 fs-sm"> | ||
Votre intérêt a bien été signalé au client. | ||
<strong>Co-traitance</strong> : votre intérêt a bien été signalé au client. | ||
</p> | ||
</div> |
32 changes: 17 additions & 15 deletions
32
lemarche/templates/tenders/_detail_cta_cocontracting.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,25 @@ | ||
<div id="detail_cocontracting_container" class="mt-3"> | ||
{% if not tender.siae_detail_cocontracting_click_date_count %} | ||
<div class="card c-card rounded-lg shadow-lg"> | ||
<div class="card-body"> | ||
<h3>Répondre en co-traitance ?</h3> | ||
<p> | ||
Cette demande vous intéresse mais vous ne pouvez pas répondre seul ? Signalez au client que vous souhaiteriez répondre en co-traitance. | ||
</p> | ||
<div class="card c-card rounded-lg shadow-lg"> | ||
<div class="card-body"> | ||
<h3>Répondre en co-traitance ?</h3> | ||
<p> | ||
Cette demande vous intéresse mais vous ne pouvez pas répondre seul ? Signalez au client que vous souhaiteriez répondre en co-traitance. | ||
</p> | ||
{% if user_can_click %} | ||
{% if user.is_authenticated %} | ||
<button type="button" class="btn btn-primary btn-block" title="Répondre en co-traitance" hx-post="{% url 'tenders:detail-cocontracting-click' tender.slug %}" hx-target="#detail_cocontracting_container"> | ||
Répondre en co-traitance | ||
<button type="button" class="btn btn-primary btn-block" title="{{ tender.cta_cocontracting_card_button_text|safe }}" hx-post="{% url 'tenders:detail-cocontracting-click' tender.slug %}" hx-target="#detail_cocontracting_container"> | ||
<span>{{ tender.cta_cocontracting_card_button_text|safe }}</span> | ||
</button> | ||
{% elif siae_id %} | ||
<button type="button" class="btn btn-primary btn-block" title="Répondre en co-traitance" hx-post="{% url 'tenders:detail-cocontracting-click' tender.slug %}?siae_id={{siae_id}}" hx-target="#detail_cocontracting_container"> | ||
Répondre en co-traitance | ||
<button type="button" class="btn btn-primary btn-block" title="{{ tender.cta_cocontracting_card_button_text|safe }}" hx-post="{% url 'tenders:detail-cocontracting-click' tender.slug %}?siae_id={{siae_id}}" hx-target="#detail_cocontracting_container"> | ||
<span>{{ tender.cta_cocontracting_card_button_text|safe }}</span> | ||
</button> | ||
{% endif %} | ||
</div> | ||
{% else %} | ||
<a href="#" id="show-tender-cocontracting-modal-btn" class="btn btn-primary btn-block" data-toggle="modal" data-target="#login_or_signup_siae_tender_modal" data-next-params="{% url 'tenders:detail' tender.slug %}"> | ||
<span>{{ tender.cta_cocontracting_card_button_text|safe }}</span> | ||
</a> | ||
{% endif %} | ||
</div> | ||
{% else %} | ||
{% include "tenders/_detail_cocontracting_click_confirm.html" %} | ||
{% endif %} | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.