summaryrefslogtreecommitdiff
path: root/ishtar_common
diff options
context:
space:
mode:
Diffstat (limited to 'ishtar_common')
-rw-r--r--ishtar_common/admin.py3
-rw-r--r--ishtar_common/models_common.py10
-rw-r--r--ishtar_common/models_imports.py8
-rw-r--r--ishtar_common/models_rest.py2
4 files changed, 13 insertions, 10 deletions
diff --git a/ishtar_common/admin.py b/ishtar_common/admin.py
index b7cc5adf6..86a9af8e8 100644
--- a/ishtar_common/admin.py
+++ b/ishtar_common/admin.py
@@ -2279,6 +2279,9 @@ def generate_match_document(modeladmin, request, queryset):
return response
+generate_match_document.short_description = _("Generate match document")
+
+
def update_association_from_match_document(modeladmin, request, queryset):
return_url = (
reverse(
diff --git a/ishtar_common/models_common.py b/ishtar_common/models_common.py
index 8707120f9..66025948a 100644
--- a/ishtar_common/models_common.py
+++ b/ishtar_common/models_common.py
@@ -2093,7 +2093,7 @@ GEOJSON_POINT_TPL = {
GEOMETRY_TYPE_LBL = {
"POINT": _("Point"),
"MULTILINE": _("Line(s)"),
- "MULTIPOINTS": _("Points"),
+ "MULTIPOINTS": _("Point(s)"),
"MULTIPOLYGON": _("Polygon(s)"),
}
@@ -2124,7 +2124,7 @@ class GeoVectorData(Imported, OwnPerms):
null=True,
on_delete=models.PROTECT,
verbose_name=_("Origin"),
- help_text=_("For instance: topographical surveys, georeferencing, ..."),
+ help_text=_("For instance: topographical survey, georeferencing, ..."),
)
data_type = models.ForeignKey(
GeoDataType,
@@ -2170,8 +2170,8 @@ class GeoVectorData(Imported, OwnPerms):
point_2d = models.PointField(_("Point (2D)"), blank=True, null=True)
point_3d = models.PointField(_("Point (3D)"), blank=True, null=True, dim=3)
multi_points = models.MultiPointField(_("Multi points"), blank=True, null=True)
- multi_line = models.MultiLineStringField(_("Multi line"), blank=True, null=True)
- multi_polygon = models.MultiPolygonField(_("Multi polygon"), blank=True, null=True)
+ multi_line = models.MultiLineStringField(_("Multi lines"), blank=True, null=True)
+ multi_polygon = models.MultiPolygonField(_("Multi polygons"), blank=True, null=True)
need_update = models.BooleanField(_("Need update"), default=False)
class Meta:
@@ -2245,7 +2245,7 @@ class GeoVectorData(Imported, OwnPerms):
def get_coordinates(self, rounded=5, srid: int = None, dim=2, cache=False):
if dim not in (2, 3):
- raise ValueError(_("Only 2 or 3 dimension"))
+ raise ValueError(_("Only 2 or 3 dimensions"))
if cache:
coordinates = [self.cached_x, self.cached_y]
if dim == 3:
diff --git a/ishtar_common/models_imports.py b/ishtar_common/models_imports.py
index 1fb5d4fcc..c85533268 100644
--- a/ishtar_common/models_imports.py
+++ b/ishtar_common/models_imports.py
@@ -157,7 +157,7 @@ class ImporterType(models.Model):
help_text=_("For GIS file with multiple layers"),
)
is_main_geometry = models.BooleanField(
- _("Set to main geometry"),
+ _("Set as main geometry"),
default=True,
help_text=_("Only relevant for GIS files"),
)
@@ -1462,10 +1462,10 @@ class Import(models.Model):
else:
z.extract(filename, tmp_dir)
elif not imported_file.endswith(".gpkg"):
- raise ImporterError(_("Incorrect GIS file."))
+ raise ImporterError(_("Invalid GIS file."))
if not imported_file:
- raise ImporterError(_("Incorrect GIS file."))
+ raise ImporterError(_("Invalid GIS file."))
kwargs = {}
if self.importer_type.layer_name:
@@ -1524,7 +1524,7 @@ class Import(models.Model):
_(f"Error reading feature {idx + 1} - {e}")
)
except fiona.errors.DriverError:
- raise ImporterError(_("Incorrect GIS file."))
+ raise ImporterError(_("Invalid GIS file."))
if tmp_dir:
shutil.rmtree(tmp_dir)
diff --git a/ishtar_common/models_rest.py b/ishtar_common/models_rest.py
index b0ed5cbd4..17db09fc2 100644
--- a/ishtar_common/models_rest.py
+++ b/ishtar_common/models_rest.py
@@ -60,7 +60,7 @@ class ApiSearchModel(models.Model):
user = models.ForeignKey(ApiUser, on_delete=models.CASCADE)
content_type = models.ForeignKey(ContentType, on_delete=models.CASCADE)
limit_query = models.TextField(
- verbose_name=_("Limit query"),
+ verbose_name=_("Filter query"),
blank=True,
null=True,
help_text=_("Search query add to each request"),