12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- // components/tabbar/tabbar.js
- const app = getApp()
- Component({
- /**
- * 组件的属性列表
- */
- properties: {
- currentIndex: {
- type: String,
- value: '0',
- }
- },
-
- /**
- * 组件的初始数据
- */
- data: {
- list: [
- {
- text: "对话",
- iconPath: "/images/tabbar/tabbar_1.png",
- selectedIconPath: "/images/tabbar/tabbar_1.png",
- dot: true
- },
- {
- text: "设置",
- iconPath: "/images/tabbar/tabbar_2.png",
- selectedIconPath: "/images/tabbar/tabbar_2.png",
- badge: '99+'
- }
- ]
- },
-
- /**
- * 组件的方法列表
- */
- methods: {
- tabChange(e) {
- console.log('tab change--aa', e)
- }
- }
- })
|