继续浏览精彩内容
慕课网APP
程序员的梦工厂
打开
继续
感谢您的支持,我会继续努力的
赞赏金额会直接到老师账户
将二维码发送给自己后长按识别
微信支付
支付宝支付

【金秋打卡】第8天 全新升级,基于Vue3新标准,打造后台综合解决方案 第八讲

ToRAmen
关注TA
已关注
手记 77
粉丝 10
获赞 4

课程章节: excel 、zip 与前端结合解决方案之用户管理页面实现

主讲老师: Sunday

课程内容:

今天学习的内容包括:

用户管理页面的实现

课程收获:

8.1 心得:

"use strict";
Component({
    properties: {
        list: {
            type: Array,
            value: [],
            observer: "onListChange"
        },
        loadMore: {
            type: Object,
            value: {
                enableLoadMore: false,
                hasMore: true,
            },
            observer: "onLoadMoreChange"
        },
        
    },


    data: {
        enableLoadMore: false,
        hasMore: true,
    },


    methods: {

        onListChange: function onListChange() {
            this.setData({
                list: this.data.list,
            });
        },

        /**
         * list里面item内部点击
         * 可通过e.detail.clickEvent.target知道是Item内部哪个子控件自身点击事件
         * @param {*} e 
         */
        onClickItem: function onClickItem(e) {
            // console.log(e);
            this.triggerEvent('onClickListItem', e.detail);
        },
        
        /**
         * 加载更多控件更新
         */
        onLoadMoreChange: function onLoadMoreChange() {
            this.setData({
                enableLoadMore: this.data.loadMore.enableLoadMore,
                hasMore: this.data.loadMore.hasMore,
            });
        },

    }
});
.container {
  display: flex;
  flex-direction: column;
  background-color: #fff;
  margin: 0;
  padding: 0;
  width: 100%;
  box-sizing: border-box;
}

.loadmore_parent {
  text-align: center;
  flex-shrink: 0;
  width: 100%;
  background-color: #f8f9fa
}

.loading {
  width: 64rpx;
  height: 64rpx;
  margin-top: 32rpx;
  margin-bottom: 32rpx;
  display: inline-block
}

.loadmore {
  font-size: 14rpx;
  height: 160rpx;
  text-align: center
}

.loadmore, .loadmore-end-container {
  width: 100%
}

.loadmore-end {
  padding-bottom: 48rpx;
  padding-top: 48rpx
}

.loadmore-tip {
  width: auto;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center
}

.loadmore-end-tip {
  width: auto;
  height: 34rpx;
  font-size: 24rpx;
  line-height: 34rpx;
  margin-right: 14rpx;
  margin-left: 14rpx;
  display: inline-block;
  color: #888;
  flex-shrink: 0
}

.loadmore-end-line {
  width: auto;
  height: 1px;
  flex-grow: 1;
  margin-right: 32rpx;
  margin-left: 32rpx;
  background: #e5e5e5;
  display: inline-block;
  vertical-align: middle
}

图片描述

打开App,阅读手记
0人推荐
发表评论
随时随地看视频慕课网APP