<style> </style> <template> <el-row> <el-row> <el-tabs type="card"> <el-tab-pane v-for="(item, index) in companyList" :key="item.Id" :label="item.BName" :name="item.BName" > {{item.content}} </el-tab-pane> </el-tabs> </el-row> </el-row> </template> <script> export default { data(){ return { companyList: [] } }, mounted(){ this.getCompanyList() }, methods:{ getCompanyList() { let userInfo = this.getLocalStorage(); let RB_Group_id = userInfo.RB_Group_id; let msg = { Status: 0, is_show: 0, RB_Group_Id: RB_Group_id } this.apipost('admin_get_BranchGetList', msg, res => { if (res.data.resultCode == 1) { res.data.data.forEach(x => { var obj = { Id: '', BName: '' } obj.Id = x.Id.toString(); obj.BName = x.BName; this.companyList.push(obj); }) } }, err => {}) }, goUrl (path,id) { this.$router.push({ path: "Details",query:{path,id} }) }, } } </script>