• Vue使用笔记


    var vueModel = new Vue({
                el: '#tbodyJsID',
                data: {
                    tsgList: []
                },
                watch: {
                    'tsgList': function() {
                        this.$nextTick(function () {
                            $('#tbodyShowJsID').append($('#tbodyJsID').html());
                        })
                    }
                }
            })
    var commClass = {
                currentPage:1,
                pagesize: 2,
                loadData: function (page, sk) {
                    $.getJSON('/F/MyFKList', { _pageIndex: page, _pageSize: commClass.pagesize }, function (res) {
                        $.each(res.List, function (idx, ele) {
                            ele['index'] = idx + 1 + (page - 1) * commClass.pagesize;
                        })
    
                        vueModel.tsgList = res.List;
                        var totalCount = 0;
                        if (res.List.length > 0) {
                            totalCount = res.List[0].TotalCount;
                        }
                        if (commClass.currentPage * commClass.pagesize >= totalCount) {
                            $('#moreItemJsID').hide();
                        }
    
                    })
                }
            }
    <ul class="list-group" id="tbodyJsID" style="display:none">
                    <li class="list-group-item" v-for="dinner in tsgList" v-bind:id="dinner.ID">
                        <span class="badge">{{dinner.HFlag}}</span>
                        <div>名称:{{dinner.Title}}</div>
                        <h5>联系人:{{dinner.FKDBName}} 联系人电话:{{dinner.FKDBMobie}}</h5>
                        <h5>填写日期:{{dinner.CreateTime}}</h5>
                        <div>
                            <a v-bind:href="'/F/code?itemID='+dinner.ID">我的码</a>
                            <a v-bind:href="'/F/MyDetail?FKAID='+dinner.ID" style="margin-left:22px;">详情</a>
                        </div>
                    </li>
                </ul>
  • 相关阅读:
    SpringBoot定制修改Servlet容器
    springboot配置i18n
    idea properties编码问题
    多线程分页查询
    浏览器 私有属性&内核
    css添加样式的四种方式
    html、css、js注释
    JS中的 变量提升
    ECMAScript
    NOSCRIPT标签的用处
  • 原文地址:https://www.cnblogs.com/life512/p/15662922.html
Copyright © 2020-2023  润新知