mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Fixed test using manual exchange backend, template update
This commit is contained in:
parent
93bfe4c5f1
commit
b04ad48178
@ -11,7 +11,7 @@ from .models import Company, Contact, ManufacturerPart, SupplierPart
|
||||
from .models import rename_company_image
|
||||
from part.models import Part
|
||||
|
||||
from InvenTree.exchange import get_exchange_rate_backend
|
||||
from InvenTree.exchange import InvenTreeManualExchangeBackend
|
||||
from djmoney.contrib.exchange.models import Rate
|
||||
|
||||
|
||||
@ -42,7 +42,7 @@ class CompanySimpleTest(TestCase):
|
||||
self.zergm312 = SupplierPart.objects.get(SKU='ZERGM312')
|
||||
|
||||
# Exchange rate backend
|
||||
backend = get_exchange_rate_backend()
|
||||
backend = InvenTreeManualExchangeBackend()
|
||||
backend.update_rates(base_currency=backend.base_currency)
|
||||
|
||||
Rate.objects.create(
|
||||
|
@ -45,7 +45,7 @@
|
||||
{{ block.super }}
|
||||
|
||||
{% if api_rates_success is False %}
|
||||
var alert_msg = {% blocktrans %}"Failed to refresh exchange rates. Verify your API key and/or subscription plan" {% endblocktrans %};
|
||||
var alert_msg = {% blocktrans %}"Failed to refresh exchange rates" {% endblocktrans %};
|
||||
showAlertOrCache("alert-danger", alert_msg, null, 5000);
|
||||
{% endif %}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user