Remove deprecated global API calls

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2020-04-27 16:23:49 +02:00
parent 7623a378f0
commit c940617478
12 changed files with 77 additions and 73 deletions

View File

@@ -58,6 +58,7 @@
<script>
import { Avatar, PopoverMenu, Tooltip } from '@nextcloud/vue'
import { generateUrl } from '@nextcloud/router'
export default {
name: 'AvatarList',
@@ -93,7 +94,7 @@ export default {
}
const user = assignable.participant.uid
const size = 32
const avatarUrl = OC.generateUrl('/avatar/{user}/{size}',
const avatarUrl = generateUrl('/avatar/{user}/{size}',
{
user: user,
size: size,

View File

@@ -70,6 +70,8 @@
import { Modal, Actions, ActionButton, Multiselect } from '@nextcloud/vue'
import { mapGetters, mapState } from 'vuex'
import axios from '@nextcloud/axios'
import { generateUrl } from '@nextcloud/router'
import { getCurrentUser } from '@nextcloud/auth'
export default {
name: 'CardMenu',
@@ -127,7 +129,7 @@ export default {
this.$store.dispatch('assignCardToUser', {
card: this.copiedCard,
assignee: {
userId: OC.getCurrentUser().uid,
userId: getCurrentUser()?.uid,
type: 0,
},
})
@@ -140,7 +142,7 @@ export default {
},
async loadStacksFromBoard(board) {
try {
const url = OC.generateUrl('/apps/deck/stacks/' + board.id)
const url = generateUrl('/apps/deck/stacks/' + board.id)
const response = await axios.get(url)
this.stacksFromBoard = response.data
} catch (err) {