12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849 |
- Component({
-
- properties: {
- option:{
- type:Function
- }
- },
-
- data: {
-
- list:[
- {
- id:"001",
- value:"管理员"
- },
- {
- id:"002",
- value:"店长"
- },{
- id:"003",
- value:"店员"
- },{
- id:"004",
- value:"游客"
- },
- ],
- indexSelect:0,
- },
-
- methods: {
-
- itemChenge(e){
- const {index}=e.target.dataset
- this.triggerEvent("option",this.data.list[index])
- this.setData({
- indexSelect:index
- })
- }
- }
- })
|