mirror of
https://github.com/eitchtee/WYGIWYH.git
synced 2026-04-25 10:08:36 +02:00
fix: DCA Tracker using wrong templates for editing
This commit is contained in:
@@ -76,7 +76,7 @@ def strategy_edit(request, strategy_id):
|
|||||||
return render(
|
return render(
|
||||||
request,
|
request,
|
||||||
"dca/fragments/strategy/edit.html",
|
"dca/fragments/strategy/edit.html",
|
||||||
{"form": form, "dca_strategy": dca_strategy},
|
{"form": form, "strategy": dca_strategy},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
@@ -206,7 +206,7 @@ def strategy_entry_edit(request, strategy_id, entry_id):
|
|||||||
|
|
||||||
return render(
|
return render(
|
||||||
request,
|
request,
|
||||||
"dca/fragments/strategy/edit.html",
|
"dca/fragments/entry/edit.html",
|
||||||
{"form": form, "dca_entry": dca_entry},
|
{"form": form, "dca_entry": dca_entry},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
{% block title %}{% translate 'Edit DCA entry' %}{% endblock %}
|
{% block title %}{% translate 'Edit DCA entry' %}{% endblock %}
|
||||||
|
|
||||||
{% block body %}
|
{% block body %}
|
||||||
<form hx-post="{% url 'exchange_rate_edit' pk=exchange_rate.id %}" hx-target="#generic-offcanvas" novalidate>
|
<form hx-post="{% url 'dca_entry_edit' entry_id=dca_entry.id strategy_id=dca_entry.strategy.id %}" hx-target="#generic-offcanvas" novalidate>
|
||||||
{% crispy form %}
|
{% crispy form %}
|
||||||
</form>
|
</form>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
@@ -198,7 +198,6 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<script defer>
|
<script defer>
|
||||||
// Add Chart.js initialization for performance visualization
|
|
||||||
var perfomancectx = document.getElementById('performanceChart').getContext('2d');
|
var perfomancectx = document.getElementById('performanceChart').getContext('2d');
|
||||||
new Chart(perfomancectx, {
|
new Chart(perfomancectx, {
|
||||||
type: 'line',
|
type: 'line',
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
{% block title %}{% translate 'Edit DCA strategy' %}{% endblock %}
|
{% block title %}{% translate 'Edit DCA strategy' %}{% endblock %}
|
||||||
|
|
||||||
{% block body %}
|
{% block body %}
|
||||||
<form hx-post="{% url 'dca_entry_edit' entry_id=dca_entry.id strategy_id=dca_entry.strategy.id %}" hx-target="#generic-offcanvas" novalidate>
|
<form hx-post="{% url 'dca_strategy_edit' strategy_id=strategy.id %}" hx-target="#generic-offcanvas" novalidate>
|
||||||
{% crispy form %}
|
{% crispy form %}
|
||||||
</form>
|
</form>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|||||||
Reference in New Issue
Block a user