index.wxml 1.2 KB

123456789101112131415161718192021
  1. <view>
  2. <view class="top_tip">体验更新字段记录能力,更新数据表中的销量数据。</view>
  3. <view class="box_text" wx:if="{{!record}}">数据将展示在这里</view>
  4. <view wx:if="{{record}}" class="code_box">
  5. <view class="code_box_title">地区销量统计</view>
  6. <view class="code_box_record">
  7. <view class="code_box_record_title">地域</view>
  8. <view class="code_box_record_title">城市</view>
  9. <view class="code_box_record_title">销量</view>
  10. </view>
  11. <view class="line"></view>
  12. <view class="code_box_record" wx:for="{{record}}" wx:key="_id">
  13. <view class="code_box_record_detail">{{item.region}}</view>
  14. <view class="code_box_record_detail">{{item.city}}</view>
  15. <input class="code_box_record_detail" bindinput="bindInput" data-index="{{index}}" value="{{item.sales}}" type="number"></input>
  16. </view>
  17. </view>
  18. <view class="button" bindtap="updateRecord">更新</view>
  19. <view class="tip">在”资源管理器>cloudfunctions>quickstartFunctions>updateRecord>index.js“找到查询记录函数,体验该能力</view>
  20. <cloud-tip-modal showUploadTipProps="{{showUploadTip}}"></cloud-tip-modal>
  21. </view>