|
@@ -11,7 +11,7 @@
|
|
|
<el-dialog
|
|
|
:title="title"
|
|
|
:visible.sync="open"
|
|
|
- width="700px"
|
|
|
+ width="900px"
|
|
|
append-to-body
|
|
|
:close-on-click-modal="false"
|
|
|
@close="cancel"
|
|
@@ -27,6 +27,23 @@
|
|
|
@click="handleAdd"
|
|
|
>添加</el-button>
|
|
|
</el-col>
|
|
|
+ <el-col :span="1.5">
|
|
|
+ <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" label-width="120px">
|
|
|
+ <el-form-item label="团队名称" label-width="70px">
|
|
|
+ <el-input
|
|
|
+ v-model="queryParams.name"
|
|
|
+ placeholder="请输入团队名称"
|
|
|
+ clearable
|
|
|
+ style="width: 240px;"
|
|
|
+ @keyup.enter.native="getList"
|
|
|
+ />
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button type="primary" icon="el-icon-search" size="mini" @click="getList">搜索</el-button>
|
|
|
+ <el-button icon="el-icon-refresh" size="mini" @click="resetQuery1">重置</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </el-col>
|
|
|
</el-row>
|
|
|
<el-table ref="tables" v-loading="tabLoading" :data="dataList" border>
|
|
|
<el-table-column label="序号" align="center" type="index" width="50"></el-table-column>
|
|
@@ -37,7 +54,7 @@
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="负责人" align="center" prop="contact" />
|
|
|
- <el-table-column label="操作" align="center" width="200" class-name="small-padding fixed-width">
|
|
|
+ <el-table-column label="操作" align="center" width="80px" class-name="small-padding fixed-width">
|
|
|
<template slot-scope="scope">
|
|
|
<el-button
|
|
|
size="mini"
|
|
@@ -65,8 +82,25 @@
|
|
|
@close="selectionCancel"
|
|
|
>
|
|
|
<div class="dialog" style="padding: 0">
|
|
|
- <el-table ref="tables" v-loading="selectionTabLoading" :data="selectionDataList" border @selection-change="handleSelectionChange">
|
|
|
- <el-table-column type="selection" width="50" align="center" />
|
|
|
+ <div>
|
|
|
+ <el-form :model="queryParamsS" ref="queryForm" size="small" :inline="true" label-width="120px">
|
|
|
+ <el-form-item label="团队名称" label-width="70px">
|
|
|
+ <el-input
|
|
|
+ v-model="queryParamsS.name"
|
|
|
+ placeholder="请输入团队名称"
|
|
|
+ clearable
|
|
|
+ style="width: 240px;"
|
|
|
+ @keyup.enter.native="handleQuery"
|
|
|
+ />
|
|
|
+ </el-form-item>
|
|
|
+ <el-form-item>
|
|
|
+ <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
|
|
|
+ <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
|
|
|
+ </el-form-item>
|
|
|
+ </el-form>
|
|
|
+ </div>
|
|
|
+ <el-table ref="tablesS" row-key="id" v-loading="selectionTabLoading" :data="selectionDataList" border @selection-change="handleSelectionChange">
|
|
|
+ <el-table-column type="selection" reserve-selection width="50" align="center" />
|
|
|
<el-table-column label="序号" align="center" type="index" width="50"></el-table-column>
|
|
|
<el-table-column label="团队名称" align="center" prop="name" />
|
|
|
<el-table-column label="团队类型" align="center" prop="type">
|
|
@@ -89,13 +123,14 @@
|
|
|
<el-button
|
|
|
type="primary"
|
|
|
@click="submitForm"
|
|
|
+ :disabled="selectList.length==0"
|
|
|
v-loading.fullscreen.lock="loading"
|
|
|
element-loading-text="提交中..."
|
|
|
element-loading-spinner="el-icon-loading"
|
|
|
element-loading-background="rgba(0, 0, 0, 0.8)"
|
|
|
>
|
|
|
<span v-if="loading">提交中...</span>
|
|
|
- <span v-else>确认</span>
|
|
|
+ <span v-else>确认(已选{{ selectList.length }})</span>
|
|
|
</el-button>
|
|
|
</span>
|
|
|
</el-dialog>
|
|
@@ -148,6 +183,7 @@ export default {
|
|
|
selectList: [],
|
|
|
selectionOpen: false,
|
|
|
onwObj: {},
|
|
|
+ queryParamsS: {}
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
@@ -160,18 +196,24 @@ export default {
|
|
|
openDialog(title, obj) {
|
|
|
this.open = true;
|
|
|
this.title = "团队绑定";
|
|
|
+ this.queryParams.name = null
|
|
|
this.onwObj = obj;
|
|
|
this.getList(obj);
|
|
|
},
|
|
|
handleAdd() {
|
|
|
+ this.selectList = []
|
|
|
+ this.queryParamsS = {}
|
|
|
this.getSelectList();
|
|
|
this.selectionOpen = true
|
|
|
+ this.$nextTick(()=>{
|
|
|
+ this.$refs.tablesS.clearSelection()
|
|
|
+ })
|
|
|
},
|
|
|
/** 查询列表 */
|
|
|
getList(obj) {
|
|
|
this.tabLoading = true;
|
|
|
this.queryParams.configId = this.onwObj.id
|
|
|
- queryBindTeam(this.queryParams)
|
|
|
+ queryBindTeam({...this.queryParams})
|
|
|
.then(response => {
|
|
|
this.dataList = response.data.rows;
|
|
|
this.total = response.data.total;
|
|
@@ -184,7 +226,7 @@ export default {
|
|
|
/** 查询列表 */
|
|
|
getSelectList(obj) {
|
|
|
this.selectionTabLoading = true;
|
|
|
- queryBindTeam(this.selectQueryParams)
|
|
|
+ queryBindTeam({...this.selectQueryParams,...this.queryParamsS})
|
|
|
.then(response => {
|
|
|
this.selectionDataList = response.data.rows;
|
|
|
this.selectionTabTotal = response.data.total;
|
|
@@ -264,6 +306,18 @@ export default {
|
|
|
},
|
|
|
selectionCancel() {
|
|
|
this.selectionOpen = false;
|
|
|
+ },
|
|
|
+
|
|
|
+ handleQuery() {
|
|
|
+ this.getSelectList()
|
|
|
+ },
|
|
|
+ resetQuery() {
|
|
|
+ this.queryParamsS = {}
|
|
|
+ this.getSelectList()
|
|
|
+ },
|
|
|
+ resetQuery1() {
|
|
|
+ this.queryParams.name = null
|
|
|
+ this.getList()
|
|
|
}
|
|
|
},
|
|
|
};
|
|
@@ -273,6 +327,8 @@ export default {
|
|
|
.dialog {
|
|
|
padding: 0 30px;
|
|
|
max-height: 65vh;
|
|
|
+ min-height: 65vh;
|
|
|
+ overflow: hidden;
|
|
|
overflow-y: auto;
|
|
|
}
|
|
|
.dialog {
|