Commit 927a9d8d by chenwq

tab切换,card计算

1 parent 3111b7b0
......@@ -116,7 +116,6 @@ Page({
wx.$util.showToast('敬请期待')
return true
}
console.log(e.detail)
wx.$router.go('addTransformDetail', { proName: obj.proName, attrName: obj.detailAttrName })
},
......
......@@ -34,7 +34,7 @@
<view class="tips">预估收益根据您的新车销量 {{ actualForm.sales || 0 }}台 测算所得</view>
</view>
<view wx:for="{{cardList}}" wx:key="index">
<card cardForm="{{item}}" actualForm="{{actualForm}}" sales="{{sales}}" bindclick="handleCardClick"></card>
<card cardForm="{{item}}" actualForm="{{actualForm}}" tagIndex="{{tagIndex}}" bindclick="handleCardClick"></card>
</view>
</view>
</add-tab-view>
......
......@@ -10,17 +10,23 @@ Component({
        this.setData({
cardForm: n
        })
}
},
actualForm: {
type: Object,
observer(n) {
      this.setData({
}
},
actualForm: {
type: Object,
observer(n) {
      this.setData({
actualForm: n
      })
      })
this.calcProfit()
}
},
tagIndex: {
type: Number,
observer(n) {
this.calcProfit()
}
}
}
},
/**
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!