对象去重 -----------------------------------------------------
var arr = [{reportRole: "检验员"},{reportRole: "检验员"},{reportRole: "检验员"}] var hash = {}; arr = arr.reduce((preVal, curVal) => { hash[curVal.reportRole] ? '' : hash[curVal.reportRole] = true && preVal.push(curVal); return preVal }, []);