牛骨文教育服务平台(让学习变的简单)
博文笔记

vue 表格根据日期排序

创建时间:2018-01-29 投稿人: 浏览次数:455
 <el-table
                ref="multipleTable"
                :data="数据名"
                @sort-change="orderByDate"
                tooltip-effect="dark"
                style="width: 100%">  
            <el-table-column
                    prop="installDate"
                    label="安装时间"
                    sortable="installDate">
            </el-table-column>


        </el-table>


orderByDate:function(Date){
            if(Date.prop == "installDate"){
                if(Date.order=="ascending"){
                    vue.query.installBtn = 1;


                }else if(Date.order=="descending"){
                    vue.query.installBtn = 0;


                }else{
                    vue.query.installBtn = null;
                }
            }
            vue.searchBsRoadsideOnline();
        },
声明:该文观点仅代表作者本人,牛骨文系教育信息发布平台,牛骨文仅提供信息存储空间服务。