小程序源码
This commit is contained in:
42
source/wx/xzs-student/component/iView/page/index.js
Normal file
42
source/wx/xzs-student/component/iView/page/index.js
Normal file
@@ -0,0 +1,42 @@
|
||||
Component({
|
||||
externalClasses: ['i-class'],
|
||||
|
||||
options: {
|
||||
multipleSlots: true
|
||||
},
|
||||
|
||||
properties: {
|
||||
// button || number || pointer
|
||||
mode: {
|
||||
type: String,
|
||||
value: 'button'
|
||||
},
|
||||
current: {
|
||||
type: Number,
|
||||
value: 1
|
||||
},
|
||||
total: {
|
||||
type: Number,
|
||||
value: 0
|
||||
},
|
||||
// 是否隐藏数值
|
||||
simple: {
|
||||
type: Boolean,
|
||||
value: false
|
||||
}
|
||||
},
|
||||
|
||||
methods: {
|
||||
handleChange (type) {
|
||||
this.triggerEvent('change', {
|
||||
type: type
|
||||
});
|
||||
},
|
||||
handlePrev () {
|
||||
this.handleChange('prev');
|
||||
},
|
||||
handleNext () {
|
||||
this.handleChange('next');
|
||||
}
|
||||
}
|
||||
});
|
||||
Reference in New Issue
Block a user