mirror of
https://gitlab.com/pamhyr/pamhyr2.git
synced 2026-10-30 03:20:41 +01:00
merge
This commit is contained in:
commit
8d9a196059
123 files changed
+15495
-187
No files matched your search
@@ -24,7 +24,14 @@ _translate = QCoreApplication.translate
|
||||
|
||||
|
||||
class ResultsTranslate(MainTranslate):
|
||||
def __init__(self):
|
||||
def __init__(self, pollutants=None):
|
||||
if pollutants is not None:
|
||||
self.pollutants = pollutants
|
||||
if "total_sediment" in self.pollutants:
|
||||
self.pollutants.remove("total_sediment")
|
||||
else:
|
||||
self.pollutants = pollutants
|
||||
|
||||
super(ResultsTranslate, self).__init__()
|
||||
|
||||
self._dict["Results"] = _translate("Results", "Results")
|
||||
@@ -48,11 +55,19 @@ class ResultsTranslate(MainTranslate):
|
||||
"name": _translate("Results", "Reach name"),
|
||||
}
|
||||
|
||||
self._sub_dict["table_headers_phys_var"] = {
|
||||
"name": _translate("Results", "Variables names"),
|
||||
}
|
||||
|
||||
self._sub_dict["table_headers_profile"] = {
|
||||
"name": self._dict["name"],
|
||||
"rk": self._dict["unit_rk"],
|
||||
}
|
||||
|
||||
self._sub_dict["table_headers_pollutants"] = {
|
||||
"name": _translate("Results", "Pollutant name"),
|
||||
}
|
||||
|
||||
self._sub_dict["table_headers_raw_data"] = {
|
||||
"name": _translate("Results", "Profile"),
|
||||
"water_elevation": self._dict["unit_water_elevation"],
|
||||
@@ -83,6 +98,22 @@ class ResultsTranslate(MainTranslate):
|
||||
"wet_area": self._dict["unit_wet_area"],
|
||||
}
|
||||
|
||||
if self.pollutants is not None:
|
||||
self._sub_dict["table_headers_raw_data"] = {
|
||||
"name": _translate("Results", "Profile"),
|
||||
}
|
||||
tmp = self._sub_dict["table_headers_raw_data"]
|
||||
for pol in self.pollutants:
|
||||
tmp[pol + " Concentration"] = pol + "\n Concentration"
|
||||
tmp[pol + " Mass"] = pol + "\n Mass"
|
||||
else:
|
||||
self._sub_dict["table_headers_raw_data"] = {
|
||||
"name": _translate("Results", "Profile"),
|
||||
"water_elevation": self._dict["unit_water_elevation"],
|
||||
"discharge": self._dict["unit_discharge"],
|
||||
"discharge": self._dict["unit_discharge"],
|
||||
}
|
||||
|
||||
self._sub_dict["values_y_envelop"] = {
|
||||
"min_bed_elevation": self._dict["unit_min_bed_elevation"],
|
||||
"max_bed_elevation": self._dict["unit_max_bed_elevation"],
|
||||
@@ -127,3 +158,8 @@ class CompareResultsTranslate(ResultsTranslate):
|
||||
"froude": u"Δ "+self._dict["unit_froude"],
|
||||
"wet_area": u"Δ "+self._dict["unit_wet_area"],
|
||||
}
|
||||
self._sub_dict["values_y_pol"] = {
|
||||
"unit_C": self._dict["unit_concentration"],
|
||||
"unit_M": self._dict["unit_mass"],
|
||||
"unit_thickness": self._dict["unit_thickness"],
|
||||
}
|
||||
Reference in new issue
Block a user