Passed
Push — develop ( 35967f...ff770f )
by Andrew
04:34
created

src/assetbundles/retour/src/js/Redirects.js   A

Complexity

Total Complexity 4
Complexity/F 1

Size

Lines of Code 23
Function Count 4

Duplication

Duplicated Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
wmc 4
eloc 15
dl 0
loc 23
rs 10
c 0
b 0
f 0
cc 0
nc 1
mnd 0
bc 2
fnc 4
bpm 0.5
cpm 1
noi 2

2 Functions

Rating   Name   Duplication   Size   Complexity  
A ???.mounted 0 3 1
A ???.methods.onTableRefresh 0 4 1
1
import Vue from 'vue';
2
import VueEvents from 'vue-events';
3
import RedirectsTable from '../vue/RedirectsTable.vue';
4
5
Vue.use(VueEvents);
6
// Create our vue instance
7
const vm = new Vue({
0 ignored issues
show
Unused Code introduced by
The constant vm seems to be never used. Consider removing it.
Loading history...
8
    el: "#cp-nav-content",
9
    components: {
10
        'redirects-table': RedirectsTable,
11
    },
12
    data: {
13
    },
14
    methods: {
15
        onTableRefresh (vuetable) {
16
            console.log('onTableRefresh');
0 ignored issues
show
Debugging Code introduced by
console.log looks like debug code. Are you sure you do not want to remove it?
Loading history...
17
            Vue.nextTick( () => vuetable.refresh());
18
        }
19
    },
20
    mounted() {
21
        this.$events.$on('refresh-table', eventData => this.onTableRefresh(eventData));
22
    },
23
});
24