本文实例为大家分享了bootstrap vue.js实现tab效果的具体代码,供大家参考,具体内容如下
项目目录结构
Student.js代码
function Student(){ this.baseInfo = { tabStatus : true , name : '张三', sex : 'male' } , this.parentsInfo = { tabStatus : false, fatherName : '张全蛋', motherName : '李铁柱' } , this.studySituation = { tabStatus : false, classSort : 1, gradeSort : 2 } }
CommonUtil.js代码
Array.prototype.del = function(filter){ var idx = filter; if(typeof filter == 'function'){ for(var i=0;i<this.length;i++){ if(filter(this[i],i)) idx = i; } } this.splice(idx,1) } var ary=[{id:1,name:"b"},{id:2,name:"b"}]; var delid = 2; ary.del(function(obj){ return obj.id == delid; })
html页
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no"> <title>Student Management</title> <link rel="stylesheet" type="text/css" href="https://cdn.bootcss.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="external nofollow" > <script src="/UploadFiles/2021-04-02/jquery.js">以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持。