Skip to content

Commit

Permalink
Merge pull request #888 from oslokommune/improved-kr-defaults
Browse files Browse the repository at this point in the history
Improve key result defaults
  • Loading branch information
simenheg authored Oct 12, 2023
2 parents 39fc690 + 31d52ab commit 18af070
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file. The format

## [UNRELEASED]

### Changed

- New key results are now given a start value of 0, a target value of 100, and
percentage as unit of measurement by default.

## [3.10.0] 2023-10-10

### Changed
Expand Down
4 changes: 4 additions & 0 deletions src/components/drawers/EditKeyResult.vue
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,8 @@ export default {
thisKeyResult: null,
keyResultDefaults: {
weight: 1,
startValue: 0,
targetValue: 100,
},
pageCount: 2,
loading: false,
Expand Down Expand Up @@ -264,6 +266,8 @@ export default {
return;
}
this.keyResultDefaults.unit = this.$t('keyResult.defaultUnit');
this.thisKeyResult = this.keyResult
? { ...this.keyResultDefaults, ...this.keyResult }
: { ...this.keyResultDefaults };
Expand Down
1 change: 1 addition & 0 deletions src/locale/locales/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,7 @@
"startValue": "Start value",
"targetValue": "Target value",
"unit": "Unit of measurement",
"defaultUnit": "percent",
"newValue": "New value",
"editValue": "Edit value",
"automation": {
Expand Down
1 change: 1 addition & 0 deletions src/locale/locales/nb-NO.json
Original file line number Diff line number Diff line change
Expand Up @@ -348,6 +348,7 @@
"startValue": "Startverdi",
"targetValue": "Målverdi",
"unit": "Måleenhet",
"defaultUnit": "prosent",
"newValue": "Ny verdi",
"editValue": "Endre verdi",
"automation": {
Expand Down

0 comments on commit 18af070

Please sign in to comment.