Skip to content

Commit f9394aa

Browse files
committed
Make page orientations translatable
Fixes #3880
1 parent 2621381 commit f9394aa

File tree

3 files changed

+17
-16
lines changed

3 files changed

+17
-16
lines changed

frontend/src/components/print/config/PicassoConfig.vue

Lines changed: 11 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -28,22 +28,10 @@
2828
</template>
2929

3030
<script>
31-
import cloneDeep from 'lodash-es/cloneDeep'
3231
import DialogScheduleEntryFilter from './DialogScheduleEntryFilter.vue'
3332
import { filterMatchScheduleEntry } from '@/common/helpers/filterMatchScheduleEntry.js'
3433
import { repairPrintFilterConfig } from '../repairPrintConfig.js'
3534
36-
const ORIENTATIONS = [
37-
{
38-
value: 'L',
39-
text: 'Landscape',
40-
},
41-
{
42-
value: 'P',
43-
text: 'Portrait',
44-
},
45-
]
46-
4735
export default {
4836
name: 'PicassoConfig',
4937
components: { DialogScheduleEntryFilter },
@@ -53,7 +41,16 @@ export default {
5341
},
5442
data() {
5543
return {
56-
orientations: cloneDeep(ORIENTATIONS),
44+
orientations: [
45+
{
46+
value: 'L',
47+
text: this.$tc('components.print.config.picassoConfig.landscape'),
48+
},
49+
{
50+
value: 'P',
51+
text: this.$tc('components.print.config.picassoConfig.portrait'),
52+
},
53+
],
5754
}
5855
},
5956
computed: {
@@ -111,7 +108,7 @@ export default {
111108
return knownPeriods.includes(period)
112109
})
113110
}
114-
if (!ORIENTATIONS.map((o) => o.value).includes(config.options.orientation)) {
111+
if (!this.orientations.map((o) => o.value).includes(config.options.orientation)) {
115112
config.options.orientation = 'L'
116113
}
117114
return repairPrintFilterConfig(config, camp, knownPeriods)

frontend/src/locales/de.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,9 @@
360360
},
361361
"picassoConfig": {
362362
"orientation": "Seitenlayout",
363-
"periods": "Lagerabschnitt(e)"
363+
"landscape": "Querformat",
364+
"periods": "Lagerabschnitt(e)",
365+
"portrait": "Hochformat"
364366
},
365367
"programConfig": {
366368
"dayOverview": "Tagesübersicht"

frontend/src/locales/en.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,7 +360,9 @@
360360
},
361361
"picassoConfig": {
362362
"orientation": "Page layout",
363-
"periods": "Period(s)"
363+
"landscape": "Landscape",
364+
"periods": "Period(s)",
365+
"portrait": "Portrait"
364366
},
365367
"programConfig": {
366368
"dayOverview": "print day overview"

0 commit comments

Comments
 (0)