Commit e839a952 by chenwq Committed by 杨北旺

sop-选择客户

1 parent d213eb62
......@@ -7,8 +7,8 @@
<div slot="customerList">
<el-button class="default-blue-btn" :size="size" @click="handleSelectCustomer">选择客户</el-button>
<el-button :size="size" @click="handleResetCostomer">重置客户</el-button>
<div v-show="editForm.customerList.length != 0" :key="key" class="el-input-tag input-tag-wrapper">
<el-tag v-for="(item, idx) in editForm.customerList" :key="idx" :size="size" type="info" closable :disable-transitions="false" @close="removeTag(item, idx)">
<div v-show="editForm.customerList.length != 0" :key="key" class="el-input-tag input-tag-wrapper m-t-10">
<el-tag v-for="(item, idx) in editForm.customerList" :key="idx" :size="size" type="info" closable :disable-transitions="false" @close="handleDeleteCustomer(idx)">
<i class="el-icon-user-solid"></i>
{{ item.customerName }}
</el-tag>
......@@ -151,7 +151,13 @@ export default {
// console.log(this.isTagVisible)
},
handleResetCostomer() { },
handleResetCostomer() {
this.editForm.customerList = []
},
handleDeleteCustomer(idx) {
this.editForm.customerList.splice(idx, 1)
},
handleConfirm() {
this.$refs.editFormRef.$refs[this.editChildRef].validate(valid => {
......@@ -199,7 +205,7 @@ export default {
<style lang="scss" scoped>
.sop-base-info {
.input-tag-wrapper {
max-height: 75px;
max-height: 227px;
overflow: auto;
position: relative;
font-size: 14px;
......@@ -211,7 +217,7 @@ export default {
color: #666;
display: inline-block;
outline: none;
padding: 5px 5px 0px 5px;
padding: 5px;
flex-wrap: wrap;
transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
width: 450px;
......
......@@ -123,6 +123,15 @@ export default {
}
},
watch: {
selectedCustomerList: {
handler() {
this.selectedSum = this.selectedCustomerList.length
},
deep: true
}
},
mounted() {
// this.getList()
},
......@@ -202,10 +211,10 @@ export default {
color: #666;
display: inline-block;
outline: none;
padding: 5px 5px 0px 5px;
padding: 5px;
flex-wrap: wrap;
transition: border-color 0.2s cubic-bezier(0.645, 0.045, 0.355, 1);
width: 450px;
width: 648px;
display: flex;
align-items: center;
font-size: 14px;
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!