mirror of
https://codeup.aliyun.com/67762337eccfc218f6110e0e/vue/learning-system-portal.git
synced 2025-12-12 12:26:44 +08:00
受从的查询,机构修改为接口调用,不再是本地调用了
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="box">
|
<div class="box">
|
||||||
<portal-header style="background: #387DF7;" :hideSearch="true" textColor="#ffffff"></portal-header>
|
<portal-header style="background: #387DF7;" :hideSearch="true" textColor="#ffffff"></portal-header>
|
||||||
<iframe :src="url" style="width: 100%;height: 100%;margin-top: 30px;" frameborder="0"></iframe>
|
<iframe :src="url" style="width: 100%;height: 100%;" frameborder="0"></iframe>
|
||||||
<portal-footer></portal-footer>
|
<portal-footer></portal-footer>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|||||||
@@ -64,16 +64,13 @@
|
|||||||
<!-- v-if="scope.row.collectNumber === 0" -->
|
<!-- v-if="scope.row.collectNumber === 0" -->
|
||||||
<el-button type="text" v-if="!scope.row.published" @click="releaseData(scope.row,true)">发布</el-button>
|
<el-button type="text" v-if="!scope.row.published" @click="releaseData(scope.row,true)">发布</el-button>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- // 成绩控制需要结束状态 -->
|
<!-- // 成绩控制需要结束状态 -->
|
||||||
<el-button type="text" v-if="scope.row.published" @click="viewResults(scope.row)">成绩</el-button>
|
<el-button type="text" v-if="scope.row.published" @click="viewResults(scope.row)">成绩</el-button>
|
||||||
<el-button type="text" v-if="scope.row.published" @click="pushResults(scope.row)">推送</el-button>
|
<el-button type="text" v-if="scope.row.published" @click="pushResults(scope.row)">推送</el-button>
|
||||||
<!-- <el-button type="text" v-if="scope.row.published" @click="creatQrCode(scope.row)">二维码</el-button> -->
|
<!-- <el-button type="text" v-if="scope.row.published" @click="creatQrCode(scope.row)">二维码</el-button> -->
|
||||||
<el-button type="text" v-if="scope.row.published" @click="releaseData(scope.row,false)">取消发布</el-button>
|
<el-button type="text" v-if="scope.row.published" @click="releaseData(scope.row,false)">取消发布</el-button>
|
||||||
<el-dropdown type="text" style="margin-left:10px">
|
<el-dropdown type="text" style="margin-left:10px">
|
||||||
<el-button type="text" > 考试 <i class="el-icon-arrow-down el-icon--right"></i> </el-button>
|
<el-button type="text" > 更多 <i class="el-icon-arrow-down el-icon--right"></i> </el-button>
|
||||||
<el-dropdown-menu slot="dropdown">
|
<el-dropdown-menu slot="dropdown">
|
||||||
<!-- <el-dropdown-item command="a">查看</el-dropdown-item> -->
|
<!-- <el-dropdown-item command="a">查看</el-dropdown-item> -->
|
||||||
<el-dropdown-item command="b" @click.native="editData(scope.row)">编辑</el-dropdown-item>
|
<el-dropdown-item command="b" @click.native="editData(scope.row)">编辑</el-dropdown-item>
|
||||||
|
|||||||
@@ -121,6 +121,7 @@
|
|||||||
import usergroupApi from "@/api/modules/usergroup";
|
import usergroupApi from "@/api/modules/usergroup";
|
||||||
import userApi from "@/api/system/user";
|
import userApi from "@/api/system/user";
|
||||||
import orgApi from "@/api/system/organiza";
|
import orgApi from "@/api/system/organiza";
|
||||||
|
import apiUserBasic from "@/api/boe/userbasic";
|
||||||
export default{
|
export default{
|
||||||
data(){
|
data(){
|
||||||
return{
|
return{
|
||||||
@@ -181,23 +182,46 @@
|
|||||||
if (node.level === 0) {
|
if (node.level === 0) {
|
||||||
resolve([{name:'组织机构树',id:'-1'}]);
|
resolve([{name:'组织机构树',id:'-1'}]);
|
||||||
}else{
|
}else{
|
||||||
|
let $this=this;
|
||||||
if(node.level === 1){
|
if(node.level === 1){
|
||||||
parentId = '-1';
|
parentId = '-1';
|
||||||
|
apiUserBasic.findOrgsByKeyword('').then(rs=>{
|
||||||
|
let treeList=[];
|
||||||
|
rs.result.forEach(item=>{
|
||||||
|
let node={
|
||||||
|
id:item.id,
|
||||||
|
name:item.name,
|
||||||
|
hrbpId:item.hrbpId,
|
||||||
|
children:[]
|
||||||
|
}
|
||||||
|
treeList.push(node);
|
||||||
|
});
|
||||||
|
resolve(treeList);
|
||||||
|
});
|
||||||
}else{
|
}else{
|
||||||
parentId = node.data.id;
|
parentId = node.data.id;
|
||||||
|
|
||||||
|
apiUserBasic.getOrgInfo(parentId).then(rs=>{
|
||||||
|
if(rs.status==200){
|
||||||
|
let treeList=[];
|
||||||
|
if(rs.result.directChildList){
|
||||||
|
rs.result.directChildList.forEach(item=>{
|
||||||
|
let node={
|
||||||
|
id:item.id,
|
||||||
|
name:item.name,
|
||||||
|
hrbpId:item.hrbpId,
|
||||||
|
children:[]
|
||||||
}
|
}
|
||||||
usergroupApi.userOrgs(parentId).then(res =>{
|
treeList.push(node);
|
||||||
if (res.status == 200) {
|
});
|
||||||
if(res.result != null && res.result.length > 0){
|
}
|
||||||
resolve(res.result);
|
resolve(treeList);
|
||||||
}else{
|
}else{
|
||||||
resolve([]);
|
resolve([]);
|
||||||
}
|
}
|
||||||
}else{
|
|
||||||
this.$message.error('查询用户的机构失败');
|
|
||||||
}
|
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
handleSelectionChange(val) {
|
handleSelectionChange(val) {
|
||||||
this.multipleSelection = val;
|
this.multipleSelection = val;
|
||||||
|
|||||||
@@ -22,40 +22,15 @@
|
|||||||
<el-button type="success" size="medium">导入</el-button>
|
<el-button type="success" size="medium">导入</el-button>
|
||||||
<el-button type="success" size="medium">批量删除</el-button>
|
<el-button type="success" size="medium">批量删除</el-button>
|
||||||
</div>
|
</div>
|
||||||
<el-table
|
<el-table ref="multipleTable" :data="tableData" tooltip-effect="dark" style="width: 100%" @selection-change="handleSelectionChange">
|
||||||
ref="multipleTable"
|
<el-table-column type="selection" width="55"> </el-table-column>
|
||||||
:data="tableData"
|
<el-table-column label="姓名" prop="name" >
|
||||||
tooltip-effect="dark"
|
|
||||||
style="width: 100%"
|
|
||||||
@selection-change="handleSelectionChange">
|
|
||||||
<el-table-column
|
|
||||||
type="selection"
|
|
||||||
width="55">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="姓名"
|
|
||||||
prop="name"
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">{{ scope.row.date }}</template>
|
<template slot-scope="scope">{{ scope.row.date }}</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column
|
<el-table-column prop="name" label="工号" > </el-table-column>
|
||||||
prop="name"
|
<el-table-column prop="address" label="部门" > </el-table-column>
|
||||||
label="工号"
|
<el-table-column prop="add" label="岗位" > </el-table-column>
|
||||||
>
|
<el-table-column label="操作" >
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
prop="address"
|
|
||||||
label="部门"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
prop="add"
|
|
||||||
label="岗位"
|
|
||||||
>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="操作"
|
|
||||||
>
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button>操作</el-button>
|
<el-button>操作</el-button>
|
||||||
</template>
|
</template>
|
||||||
@@ -65,11 +40,8 @@
|
|||||||
<el-button type="success" size="large">暂存</el-button>
|
<el-button type="success" size="large">暂存</el-button>
|
||||||
<el-button type="success" size="large">发布</el-button>
|
<el-button type="success" size="large">发布</el-button>
|
||||||
</div>
|
</div>
|
||||||
<el-dialog
|
<el-dialog title="组织" custom-class="g-dialog" :visible.sync="dialogVisible">
|
||||||
title="组织"
|
<span></span>
|
||||||
custom-class="g-dialog"
|
|
||||||
:visible.sync="dialogVisible">
|
|
||||||
<span>这是一段信息</span>
|
|
||||||
<span slot="footer" class="dialog-footer">
|
<span slot="footer" class="dialog-footer">
|
||||||
<el-button @click="dialogVisible = false">关闭</el-button>
|
<el-button @click="dialogVisible = false">关闭</el-button>
|
||||||
<el-button type="primary" @click="dialogVisible = false">完成</el-button>
|
<el-button type="primary" @click="dialogVisible = false">完成</el-button>
|
||||||
|
|||||||
Reference in New Issue
Block a user