client-type.vue
1013 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
<template>
<Radio-group v-model="clientType" @on-change="typeChange">
<Radio label="all">
<span>All</span>
</Radio>
<Radio label="pc" disabled>
<Icon type="android-desktop"></Icon>
<span>PC</span>
</Radio>
<Radio label="android">
<Icon type="social-android"></Icon>
<span>Android</span>
</Radio>
<Radio label="ios">
<Icon type="social-apple"></Icon>
<span>IOS</span>
</Radio>
<Radio label="wap" disabled>
<Icon type="android-phone-portrait"></Icon>
<span>WAP</span>
</Radio>
</Radio-group>
</template>
<script>
export default {
name: 'client-type',
props: ['value'],
data() {
return {
clientType: this.value
};
},
methods: {
typeChange: function() {
this.$emit('input', this.clientType);
}
}
};
</script>
<style lang="scss">
</style>