Commit 6e93dc1f authored by 张冬's avatar 张冬

跳转

parent 36aa3a61
<template> <template>
<div class="othercontent"> <div class="othercontent">
<div class="message"> <div class="message1">
<div> <div>
<div class="describe">基本信息</div> <div class="describe">基本信息</div>
<div class="message-form"> <div class="message-form">
...@@ -134,7 +134,7 @@ ...@@ -134,7 +134,7 @@
<el-button type="primary" @click="dialogFormVisible=true">添加</el-button> <el-button type="primary" @click="dialogFormVisible=true">添加</el-button>
<el-button>删除</el-button> <el-button>删除</el-button>
</div> </div>
<dataTable :table-data="tableData" :columns="columns" :page-obj="pageObj" :margin-top="10" :margin-bottom="0"> <dataTable :table-data="ruleForm.companyVOList" :columns="columns" :page-obj="pageObj" :margin-top="10" :margin-bottom="0">
<el-table-column slot="operate" label="操作" align="center" fixed="right" width="100"> <el-table-column slot="operate" label="操作" align="center" fixed="right" width="100">
<template slot-scope="scope"> <template slot-scope="scope">
<el-button type="text" size="small" @click="handleDelete(scope.row)">删除</el-button> <el-button type="text" size="small" @click="handleDelete(scope.row)">删除</el-button>
...@@ -235,7 +235,6 @@ export default { ...@@ -235,7 +235,6 @@ export default {
dataTableList dataTableList
}, },
data() { data() {
let isMin = (rule, value, callback) => { let isMin = (rule, value, callback) => {
if (!value) { if (!value) {
callback(new Error('请输入')) callback(new Error('请输入'))
...@@ -441,7 +440,8 @@ export default { ...@@ -441,7 +440,8 @@ export default {
isNeedEarnest: false, isNeedEarnest: false,
provinceId: '', provinceId: '',
cityId: '', cityId: '',
districtId: '' districtId: '',
multipleSelection:[]
} }
} }
}, },
...@@ -472,6 +472,21 @@ export default { ...@@ -472,6 +472,21 @@ export default {
getfile(val) { getfile(val) {
console.log(val) console.log(val)
}, },
// 获取邀请的供应商列表
getSelection(val) {
this.multipleSelection = val
},
// 删除操作
delAllSelection() {
const length = this.multipleSelection.length;
let str = '';
this.delList = this.ruleForm.companyVOList.concat(this.multipleSelection);
for (let i = 0; i < length; i++) {
str += this.multipleSelection[i].name + ' ';
}
this.$message.error(`删除了${str}`);
this.multipleSelection = [];
},
// 到下一步 // 到下一步
async next() { async next() {
const valid = await this.$refs['ruleForm'].validate() const valid = await this.$refs['ruleForm'].validate()
...@@ -504,17 +519,19 @@ export default { ...@@ -504,17 +519,19 @@ export default {
// 邀请状态下选择供应商 // 邀请状态下选择供应商
choice(row) { choice(row) {
let indexof = false let indexof = false
if (this.tableData.length > 0) { if (this.ruleForm.companyVOList.length > 0) {
for (let item of this.tableData) { for (let item of this.ruleForm.companyVOList) {
if (row.id === item.id) { if (row.id === item.id) {
indexof = true indexof = true
} }
} }
if (!indexof) { if (!indexof) {
this.tableData.push(row) this.ruleForm.companyVOList.push(row)
// this.tableData..push(row)
} }
} else { } else {
this.tableData.push(row) this.ruleForm.companyVOList.push(row)
// this.tableData.push(row)
} }
}, },
// NeedEarnest(val) { // NeedEarnest(val) {
...@@ -536,10 +553,7 @@ export default { ...@@ -536,10 +553,7 @@ export default {
getdistrictId(val) { getdistrictId(val) {
this.ruleForm.districtId = val this.ruleForm.districtId = val
}, },
// 获取邀请的供应商列表
getSelection(val) {
this.ruleForm.companyVOList = val
},
// 获取项目经理 // 获取项目经理
async userList() { async userList() {
const { const {
...@@ -580,7 +594,7 @@ export default { ...@@ -580,7 +594,7 @@ export default {
</script> </script>
<style scoped> <style scoped>
.message>div { .message1>div {
background: #fff; background: #fff;
margin-bottom: 30px; margin-bottom: 30px;
} }
...@@ -590,7 +604,7 @@ export default { ...@@ -590,7 +604,7 @@ export default {
margin: 0 auto margin: 0 auto
} }
.message { .message1 {
background: #F0F2F5; background: #F0F2F5;
} }
......
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
</div> </div>
</div> </div>
<!-- 项目信息 --> <!-- 项目信息 -->
<div v-show="activeIdx==0" class="message"> <div v-show="activeIdx==0" class="message1">
<messaage @getruleForm="getruleForm"></messaage> <messaage @getruleForm="getruleForm"></messaage>
</div> </div>
<!-- 标的需求 --> <!-- 标的需求 -->
...@@ -56,7 +56,7 @@ export default { ...@@ -56,7 +56,7 @@ export default {
}, },
data() { data() {
return { return {
activeIdx: 3, activeIdx: 0,
allForm: {} allForm: {}
} }
}, },
......
export function getSearchString(key) { export function getSearchString(key) {
// 获取URL中?之后的字符 // 获取URL中?之后的字符
var str = location.search; var str = location.search;
console.log(str)
str = str.substring(1,str.length); str = str.substring(1,str.length);
console.log(str)
// 以&分隔字符串,获得类似name=xiaoli这样的元素数组 // 以&分隔字符串,获得类似name=xiaoli这样的元素数组
var arr = str.split("&"); var arr = str.split("&");
var obj = new Object(); var obj = new Object();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment