答案 0 :(得分:0)
在vue js中,最简单的方法是在路线上使用meta标记,这样:
let display = Display()
display.somethingToDisplay()
然后使用全局路由器防护程序,在让用户实际看到页面之前,检查当前用户是否属于元数据中存储的类。
LEFT JOIN
您也可以基于路线进行此操作:
SELECT u1.userid, a.date, u1.name, d.reason, u2.name AS supervisor
FROM user u1
LEFT JOIN attendance a ON u1.userid = a.member
LEFT JOIN detail d ON u1.userid = d.userid
LEFT JOIN user u2 ON a.supervisor = u2.userid
WHERE d.attendance = 0