Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/polls.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordartcafe <github@dartcafe.de>2021-05-31 12:05:46 +0300
committerdartcafe <github@dartcafe.de>2021-05-31 12:05:46 +0300
commita0b39d525a0464100b31a652a9f76e2ef186e35b (patch)
treed9ebfcd1c87a7b1f041abce7746c07ab6d4f8780 /src
parente334e9f293323c51b4bf9fef7699586be422f88a (diff)
fix firstDayOfWeek #1560
Signed-off-by: dartcafe <github@dartcafe.de>
Diffstat (limited to 'src')
-rw-r--r--src/js/components/Configuration/ConfigProposals.vue9
-rw-r--r--src/js/components/Options/OptionsDateAdd.vue9
2 files changed, 18 insertions, 0 deletions
diff --git a/src/js/components/Configuration/ConfigProposals.vue b/src/js/components/Configuration/ConfigProposals.vue
index 284ba1ee..22e68234 100644
--- a/src/js/components/Configuration/ConfigProposals.vue
+++ b/src/js/components/Configuration/ConfigProposals.vue
@@ -95,6 +95,15 @@ export default {
},
},
+ firstDOW() {
+ // vue2-datepicker needs 7 for sunday
+ if (moment.localeData()._week.dow === 0) {
+ return 7
+ }
+ return moment.localeData()._week.dow
+
+ },
+
expirationDatePicker() {
return {
editable: true,
diff --git a/src/js/components/Options/OptionsDateAdd.vue b/src/js/components/Options/OptionsDateAdd.vue
index 33a39d38..68d71425 100644
--- a/src/js/components/Options/OptionsDateAdd.vue
+++ b/src/js/components/Options/OptionsDateAdd.vue
@@ -164,6 +164,15 @@ export default {
},
+ firstDOW() {
+ // vue2-datepicker needs 7 for sunday
+ if (moment.localeData()._week.dow === 0) {
+ return 7
+ }
+ return moment.localeData()._week.dow
+
+ },
+
pickerOptions() {
return {
appendToBody: true,