-
+
{% trans "Date added: " %} {{ invoice.requested_at }}
diff --git a/hypha/apply/projects/models/payment.py b/hypha/apply/projects/models/payment.py
index f36f8ae689..afe47dc377 100644
--- a/hypha/apply/projects/models/payment.py
+++ b/hypha/apply/projects/models/payment.py
@@ -1,6 +1,5 @@
import decimal
import os
-from textwrap import wrap
from django.conf import settings
from django.core.validators import MinValueValidator
@@ -141,7 +140,7 @@ def __str__(self):
)
def transition_invoice_to_resubmitted(self):
"""
- Tranistion invoice to resubmitted status.
+ Transition invoice to resubmitted status.
This method generally gets used on invoice edit.
"""
pass
@@ -154,16 +153,6 @@ def has_changes_requested(self):
def status_display(self):
return self.get_status_display()
- @property
- def vendor_document_number(self):
- """
- Vendor document number is a required field to create invoices in IntAcct.
-
- Formatting should be HP###### i.e. HP000001 and so on.
- """
- prefix = "HP-"
- return prefix + "-".join(wrap(f"{self.id:06}", 3))
-
def can_user_delete(self, user):
if user.is_applicant or user.is_apply_staff:
if self.status in (SUBMITTED):
diff --git a/hypha/core/context_processors.py b/hypha/core/context_processors.py
index 8b6cfe7d33..5300a707be 100644
--- a/hypha/core/context_processors.py
+++ b/hypha/core/context_processors.py
@@ -15,7 +15,6 @@ def global_vars(request):
"HIDE_IDENTITY_FROM_REVIEWERS": settings.HIDE_IDENTITY_FROM_REVIEWERS,
"GOOGLE_OAUTH2": settings.SOCIAL_AUTH_GOOGLE_OAUTH2_KEY,
"ENABLE_PUBLIC_SIGNUP": settings.ENABLE_PUBLIC_SIGNUP,
- "ENABLE_GOOGLE_TRANSLATE": settings.ENABLE_GOOGLE_TRANSLATE,
"SENTRY_TRACES_SAMPLE_RATE": settings.SENTRY_TRACES_SAMPLE_RATE,
"SENTRY_ENVIRONMENT": settings.SENTRY_ENVIRONMENT,
"SENTRY_DENY_URLS": settings.SENTRY_DENY_URLS,
diff --git a/hypha/settings/base.py b/hypha/settings/base.py
index f9b0ec1db7..95d6c5c080 100644
--- a/hypha/settings/base.py
+++ b/hypha/settings/base.py
@@ -191,6 +191,8 @@
# Make sure the set lang code is included in LANGUAGES setting.
LANGUAGE_CODE = env.str("LANGUAGE_CODE", "en")
+LOCALE_PATHS = (PROJECT_DIR + "/locale",)
+
# Optional language switcher
# Set LANGUAGE setting to limit the languages available.
LANGUAGE_SWITCHER = env.bool("LANGUAGE_SWITCHER", False)
@@ -567,7 +569,7 @@
# Django Elevate settings
# https://django-elevate.readthedocs.io/en/latest/config/index.html
-
+# ------------------------------------------------------------------------------
# How long should Elevate mode be active for?
ELEVATE_COOKIE_AGE = env.int("ELEVATE_COOKIE_AGE", 3600) # 1 hours
@@ -575,19 +577,8 @@
ELEVATE_COOKIE_SALT = env.str("ELEVATE_COOKIE_SALT", SECRET_KEY)
-# Rest Framework settings
-REST_FRAMEWORK = {
- "DEFAULT_PAGINATION_CLASS": "rest_framework.pagination.PageNumberPagination",
- "PAGE_SIZE": 10,
- "DEFAULT_AUTHENTICATION_CLASSES": (
- "rest_framework.authentication.SessionAuthentication",
- ),
- "DEFAULT_PERMISSION_CLASSES": ("rest_framework.permissions.IsAuthenticated",),
-}
-
-
# django-file-form settings
-
+# ------------------------------------------------------------------------------
FILE_FORM_CACHE = "django_file_form"
FILE_FORM_UPLOAD_DIR = "temp_uploads"
# Ensure FILE_FORM_UPLOAD_DIR exists:
@@ -597,24 +588,12 @@
FILE_FORM_TEMP_STORAGE = PRIVATE_FILE_STORAGE
-# Sage IntAcct integration settings
-
-INTACCT_ENABLED = env.bool("INTACCT_ENABLED", False)
-INTACCT_SENDER_ID = env.str("INTACCT_SENDER_ID", "")
-INTACCT_SENDER_PASSWORD = env.str("INTACCT_SENDER_PASSWORD", "")
-INTACCT_USER_ID = env.str("INTACCT_USER_ID", "")
-INTACCT_COMPANY_ID = env.str("INTACCT_COMPANY_ID", "")
-INTACCT_USER_PASSWORD = env.str("INTACCT_USER_PASSWORD", "")
-
-
# Misc settings
-
+# ------------------------------------------------------------------------------
# Use Pillow to create QR codes so they are PNG and not SVG.
# Apples Safari on iOS and macOS can then recognise them automatically.
# TWO_FACTOR_QR_FACTORY = 'qrcode.image.pil.PilImage'
-LOCALE_PATHS = (PROJECT_DIR + "/locale",)
-
DEBUG = False
DEBUGTOOLBAR = False
@@ -628,8 +607,6 @@
"KV": "Kosovo",
}
-# Google Translate
-ENABLE_GOOGLE_TRANSLATE = env.bool("ENABLE_GOOGLE_TRANSLATE", True)
# Sentry configuration.
# -----------------------------------------------------------------------------
diff --git a/hypha/settings/dev.py b/hypha/settings/dev.py
index fd073e0608..2041918055 100644
--- a/hypha/settings/dev.py
+++ b/hypha/settings/dev.py
@@ -159,8 +159,4 @@
"SHOW_COLLAPSED": True,
}
-# Required for testing the apis from postman
-REST_FRAMEWORK["DEFAULT_AUTHENTICATION_CLASSES"] = REST_FRAMEWORK[
- "DEFAULT_AUTHENTICATION_CLASSES"
-] + ("rest_framework.authentication.BasicAuthentication",)
SENTRY_DENY_URLS += ["__reload__", "/favicon.ico", "/media/", "/static/", "__debug__"]