1
0
Fork 0
mirror of https://gitlab.com/bramw/baserow.git synced 2025-04-17 18:32:35 +00:00

fixed moment dependency issue

This commit is contained in:
Bram Wiepjes 2021-08-11 09:30:43 +00:00
parent d7c35a92de
commit 0d32330f56
18 changed files with 26 additions and 26 deletions
changelog.md
premium/web-frontend
modules/baserow_premium
components
crud_table/fields
row_comments
store
test/unit/premium/admin/users
web-frontend

View file

@ -24,6 +24,7 @@
* **Premium**: You can now comment and discuss rows with others in your group, click the
expand row button at the start of the row to view and add comments.
* Added "Last Modified" and "Created On" field types.
* Fixed moment issue if core is installed as a dependency.
* New templates:
* Blog Post Management
* Updated templates:

View file

@ -5,7 +5,8 @@
</template>
<script>
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
export default {
name: 'LocalDateField',
functional: true,

View file

@ -21,9 +21,10 @@
</template>
<script>
import moment from 'moment'
import { mapGetters } from 'vuex'
import moment from '@baserow/modules/core/moment'
export default {
name: 'RowComment',
props: {

View file

@ -1,6 +1,8 @@
import RowCommentService from '@baserow_premium/services/row_comments/row_comments'
import _ from 'lodash'
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import RowCommentService from '@baserow_premium/services/row_comments/row_comments'
export const state = () => ({
comments: [],

View file

@ -1,6 +1,6 @@
import { TestApp } from '@baserow/test/helpers/testApp'
import UsersAdminTable from '@baserow_premium/components/admin/users/UsersAdminTable'
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import flushPromises from 'flush-promises'
import UserAdminUserHelpers from '../../../../fixtures/uiHelpers'
import MockPremiumServer from '@baserow_premium/../../test/fixtures/mockPremiumServer'

View file

@ -11,8 +11,7 @@
</template>
<script>
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import context from '@baserow/modules/core/mixins/context'
export default {

View file

@ -49,8 +49,8 @@
<script>
import { mapGetters } from 'vuex'
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import modal from '@baserow/modules/core/mixins/modal'
import error from '@baserow/modules/core/mixins/error'
import { notifyIf } from '@baserow/modules/core/utils/error'

View file

@ -68,7 +68,7 @@
* contents.
*/
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import TrashEntry from '@baserow/modules/core/components/trash/TrashEntry'
import InfiniteScroll from '@baserow/modules/core/components/helpers/InfiniteScroll'
import TrashEmptyModal from '@baserow/modules/core/components/trash/TrashEmptyModal'

View file

@ -41,7 +41,7 @@
* trashed entry. Shows extra information about the entry like it's name, who trashed it
* , how long ago it was trashed etc.
*/
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
export default {
name: 'TrashEntry',

View file

@ -0,0 +1,5 @@
// Moment should always be imported from here. This will enforce that the timezone
// is always included. There were some problems when Baserow is installed as a
// dependency and then moment-timezone does not work. Still will resolve that issue.
export { default } from 'moment'
export { tz } from 'moment-timezone'

View file

@ -1,10 +1,5 @@
import Vue from 'vue'
// Make sure that moment timezone is imported because it extends moment to enable
// moment().tz(...) which we need in a couple of places.
// eslint-disable-next-line
import { tz } from 'moment-timezone'
import Context from '@baserow/modules/core/components/Context'
import Modal from '@baserow/modules/core/components/Modal'
import Editable from '@baserow/modules/core/components/Editable'

View file

@ -80,8 +80,7 @@
</template>
<script>
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import { UploadFileUserFileUploadType } from '@baserow/modules/core/userFileUploadTypes'
import UserFilesModal from '@baserow/modules/core/components/files/UserFilesModal'
import FileFieldModal from '@baserow/modules/database/components/field/FileFieldModal'

View file

@ -35,8 +35,7 @@
</template>
<script>
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import {
getDateMomentFormat,
getDateHumanReadableFormat,

View file

@ -1,6 +1,6 @@
import moment from 'moment'
import BigNumber from 'bignumber.js'
import moment from '@baserow/modules/core/moment'
import {
isValidURL,
isValidEmail,

View file

@ -1,5 +1,4 @@
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import {
getDateMomentFormat,
getTimeMomentFormat,

View file

@ -1,4 +1,4 @@
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import {
getDateMomentFormat,
getTimeMomentFormat,

View file

@ -1,5 +1,4 @@
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import { Registerable } from '@baserow/modules/core/registry'
import ViewFilterTypeText from '@baserow/modules/database/components/view/ViewFilterTypeText'
import ViewFilterTypeNumber from '@baserow/modules/database/components/view/ViewFilterTypeNumber'

View file

@ -1,5 +1,5 @@
import { TestApp } from '@baserow/test/helpers/testApp'
import moment from 'moment'
import moment from '@baserow/modules/core/moment'
import {
DateBeforeViewFilterType,
DateAfterViewFilterType,