Skip to content

Commit d476c7a

Browse files
authored
Merge pull request #20867 from nextcloud/warnigns/js/workflowengine
Fix linter warnings in workflowengine
2 parents 02b1420 + e3bb6b6 commit d476c7a

File tree

5 files changed

+28
-25
lines changed

5 files changed

+28
-25
lines changed

apps/workflowengine/js/workflowengine.js

Lines changed: 20 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/workflowengine/js/workflowengine.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/workflowengine/src/components/Checks/FileMimeType.vue

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@
5353
<script>
5454
import Multiselect from '@nextcloud/vue/dist/Components/Multiselect'
5555
import valueMixin from './../../mixins/valueMixin'
56+
import { imagePath } from '@nextcloud/router'
5657
5758
export default {
5859
name: 'FileMimeType',
@@ -76,12 +77,12 @@ export default {
7677
pattern: '/image\\/.*/',
7778
},
7879
{
79-
iconUrl: OC.imagePath('core', 'filetypes/x-office-document'),
80+
iconUrl: imagePath('core', 'filetypes/x-office-document'),
8081
label: t('workflowengine', 'Office documents'),
8182
pattern: '/(vnd\\.(ms-|openxmlformats-).*)$/',
8283
},
8384
{
84-
iconUrl: OC.imagePath('core', 'filetypes/application-pdf'),
85+
iconUrl: imagePath('core', 'filetypes/application-pdf'),
8586
label: t('workflowengine', 'PDF documents'),
8687
pattern: 'application/pdf',
8788
},

apps/workflowengine/src/components/Checks/RequestUserGroup.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@
3636
<script>
3737
import Multiselect from '@nextcloud/vue/dist/Components/Multiselect'
3838
import axios from '@nextcloud/axios'
39+
import { generateOcsUrl } from '@nextcloud/router'
3940
4041
const groups = []
4142
const status = {
@@ -83,7 +84,7 @@ export default {
8384
}
8485
8586
this.status.isLoading = true
86-
return axios.get(OC.linkToOCS('cloud', 2) + 'groups?limit=20&search=' + encodeURI(searchQuery)).then((response) => {
87+
return axios.get(generateOcsUrl('cloud', 2) + 'groups?limit=20&search=' + encodeURI(searchQuery)).then((response) => {
8788
response.data.ocs.data.groups.reduce((obj, item) => {
8889
obj.push({
8990
id: item,

apps/workflowengine/src/helpers/api.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,12 @@
2121
*/
2222

2323
import { loadState } from '@nextcloud/initial-state'
24+
import { generateOcsUrl } from '@nextcloud/router'
2425

2526
const scopeValue = loadState('workflowengine', 'scope') === 0 ? 'global' : 'user'
2627

2728
const getApiUrl = (url) => {
28-
return OC.linkToOCS('apps/workflowengine/api/v1/workflows', 2) + scopeValue + url + '?format=json'
29+
return generateOcsUrl('apps/workflowengine/api/v1/workflows', 2) + scopeValue + url + '?format=json'
2930
}
3031

3132
export {

0 commit comments

Comments
 (0)