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

github.com/nextcloud/tasks.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorRaimund Schlüßler <raimund.schluessler@mailbox.org>2020-04-15 16:33:04 +0300
committerRaimund Schlüßler <raimund.schluessler@mailbox.org>2020-04-15 22:25:28 +0300
commit7546257d129072ea47f990b7408df3e2d8068a76 (patch)
tree85902afed7daa5abe98c8ffde9bf3bc47333752e /src
parent7392c1e1785db63ef61ec01e127605590277ba02 (diff)
Use @nextcloud/moment, closes #961
Signed-off-by: Raimund Schlüßler <raimund.schluessler@mailbox.org>
Diffstat (limited to 'src')
-rw-r--r--src/components/AppNavigation/TheSettings.vue1
-rw-r--r--src/components/TaskBody.vue1
-rw-r--r--src/components/TheCollections/General.vue1
-rw-r--r--src/components/TheCollections/Week.vue1
-rw-r--r--src/components/TheDetails.vue1
-rw-r--r--src/main.js2
-rw-r--r--src/models/task.js1
-rw-r--r--src/store/storeHelper.js1
-rw-r--r--src/store/tasks.js1
9 files changed, 8 insertions, 2 deletions
diff --git a/src/components/AppNavigation/TheSettings.vue b/src/components/AppNavigation/TheSettings.vue
index 69d4010b..b4c683c4 100644
--- a/src/components/AppNavigation/TheSettings.vue
+++ b/src/components/AppNavigation/TheSettings.vue
@@ -61,6 +61,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
</template>
<script>
+import moment from '@nextcloud/moment'
import { mapState, mapGetters, mapActions } from 'vuex'
export default {
diff --git a/src/components/TaskBody.vue b/src/components/TaskBody.vue
index c3a73040..501dd2cc 100644
--- a/src/components/TaskBody.vue
+++ b/src/components/TaskBody.vue
@@ -158,6 +158,7 @@ import { linkify } from '../directives/linkify.js'
import TaskStatusDisplay from './TaskStatusDisplay'
import TaskDragContainer from './TaskDragContainer'
+import moment from '@nextcloud/moment'
import Actions from '@nextcloud/vue/dist/Components/Actions'
import ActionButton from '@nextcloud/vue/dist/Components/ActionButton'
import { showError } from '@nextcloud/dialogs'
diff --git a/src/components/TheCollections/General.vue b/src/components/TheCollections/General.vue
index d20da38e..2b0bc125 100644
--- a/src/components/TheCollections/General.vue
+++ b/src/components/TheCollections/General.vue
@@ -62,6 +62,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
</template>
<script>
+import moment from '@nextcloud/moment'
import { mapGetters, mapActions } from 'vuex'
import { sort, isTaskInList, isParentInList } from '../../store/storeHelper'
import SortorderDropdown from '../SortorderDropdown'
diff --git a/src/components/TheCollections/Week.vue b/src/components/TheCollections/Week.vue
index 2ad23ec4..0053955a 100644
--- a/src/components/TheCollections/Week.vue
+++ b/src/components/TheCollections/Week.vue
@@ -59,6 +59,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
</template>
<script>
+import moment from '@nextcloud/moment'
import { mapGetters, mapActions } from 'vuex'
import { sort, isTaskInList } from '../../store/storeHelper'
import SortorderDropdown from '../SortorderDropdown'
diff --git a/src/components/TheDetails.vue b/src/components/TheDetails.vue
index 593cfd2a..413ea1fd 100644
--- a/src/components/TheDetails.vue
+++ b/src/components/TheDetails.vue
@@ -384,6 +384,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>.
<script>
import { mapGetters, mapActions } from 'vuex'
import { overdue } from '../store/storeHelper'
+import moment from '@nextcloud/moment'
import DatetimePicker from '@nextcloud/vue/dist/Components/DatetimePicker'
import Multiselect from '@nextcloud/vue/dist/Components/Multiselect'
import Markdown from './Markdown'
diff --git a/src/main.js b/src/main.js
index b5c22bdd..756b931d 100644
--- a/src/main.js
+++ b/src/main.js
@@ -86,8 +86,6 @@ OCA.Tasks.App = new Vue({
this.$OC.Search = new OCA.Search(this.filter, this.cleanSearch)
},
beforeMount() {
- // Configure the locale of moment.js
- moment.locale(this.$OC.getLocale().replace('_', '-').toLowerCase())
this.$store.dispatch('loadCollections')
this.$store.dispatch('loadSettings')
},
diff --git a/src/models/task.js b/src/models/task.js
index 661bc1d3..ed6b1853 100644
--- a/src/models/task.js
+++ b/src/models/task.js
@@ -22,6 +22,7 @@
*
*/
+import moment from '@nextcloud/moment'
import { v4 as uuid } from 'uuid'
import ICAL from 'ical.js'
import PQueue from 'p-queue'
diff --git a/src/store/storeHelper.js b/src/store/storeHelper.js
index 12b513bb..c50a79e5 100644
--- a/src/store/storeHelper.js
+++ b/src/store/storeHelper.js
@@ -21,6 +21,7 @@
*/
'use strict'
+import moment from '@nextcloud/moment'
import ICAL from 'ical.js'
/**
diff --git a/src/store/tasks.js b/src/store/tasks.js
index f834141b..db9d6a4e 100644
--- a/src/store/tasks.js
+++ b/src/store/tasks.js
@@ -29,6 +29,7 @@ import TaskStatus from '../models/taskStatus'
import router from '../router'
import { findVTODObyUid } from './cdav-requests'
import { showError } from '@nextcloud/dialogs'
+import moment from '@nextcloud/moment'
Vue.use(Vuex)