tab.click(function () {
$(this).addClass("active");
$(this).siblings().removeClass("active");
});
.active{
background: #ccc;
}
.siblings() 返回被选元素的所有同级元素
const code = Math.floor(Math.random() * 1000000).toString().padStart(6, "0");
// 942377
随机生成六位数字