|
@@ -19,7 +19,7 @@
|
|
|
layout="inline"
|
|
|
:model="queryParam"
|
|
|
@keyup.enter.native="$refs.table.refresh(true)" >
|
|
|
- <a-row :gutter="5">
|
|
|
+ <a-row :gutter="15">
|
|
|
<a-col :md="4" :sm="24">
|
|
|
<a-form-model-item label="产品编码">
|
|
|
<a-input id="chooseShelf-code" ref="searchProductCode" v-model.trim="queryParam.productCode" allowClear placeholder="请输入产品编码"/>
|
|
@@ -30,7 +30,7 @@
|
|
|
<a-input id="chooseShelf-name" v-model.trim="queryParam.productName" allowClear placeholder="请输入产品名称"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
- <a-col :md="4" :sm="24">
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="产品分类">
|
|
|
<ProductType id="chooseShelf-productType" :isDealer="true" @change="changeProductType" v-model="productType"></ProductType>
|
|
|
</a-form-model-item>
|
|
@@ -40,7 +40,7 @@
|
|
|
<a-checkbox-group v-model.trim="queryParam.stockStateList" :options="options" />
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
- <a-col :md="6" :sm="12" style="margin-bottom: 10px;">
|
|
|
+ <a-col :md="4" :sm="12" style="margin-bottom: 10px;">
|
|
|
<a-button type="primary" @click="$refs.table.refresh(true)" id="chooseShelf-refresh">查询</a-button>
|
|
|
<a-button style="margin-left: 5px" @click="resetSearchForm" id="chooseShelf-reset">重置</a-button>
|
|
|
</a-col>
|
|
@@ -50,7 +50,7 @@
|
|
|
<div class="chooseShelf-modal-table">
|
|
|
<div class="table-operator">
|
|
|
<div>
|
|
|
- <a-button type="primary">批量添加</a-button>
|
|
|
+ <a-button type="primary" @click="handlePlAdd">批量添加</a-button>
|
|
|
<span style="margin-left: 10px;" v-if="selectTotal">已选{{ selectTotal }}项</span>
|
|
|
</div>
|
|
|
<div>
|
|
@@ -129,18 +129,18 @@
|
|
|
layout="inline"
|
|
|
:model="queryParam1"
|
|
|
@keyup.enter.native="$refs.table1.refresh(true)" >
|
|
|
- <a-row :gutter="5">
|
|
|
- <a-col :md="4" :sm="24">
|
|
|
+ <a-row :gutter="15">
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="产品编码">
|
|
|
<a-input id="chooseShelf-code1" v-model.trim="queryParam1.productCode" allowClear placeholder="请输入产品编码"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
- <a-col :md="4" :sm="24">
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="产品名称">
|
|
|
<a-input id="chooseShelf-name1" v-model.trim="queryParam1.productName" allowClear placeholder="请输入产品名称"/>
|
|
|
</a-form-model-item>
|
|
|
</a-col>
|
|
|
- <a-col :md="4" :sm="24">
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
<a-form-model-item label="产品分类">
|
|
|
<ProductType id="chooseShelf-productType1" :isDealer="true" @change="changeProductType1" v-model="productType1"></ProductType>
|
|
|
</a-form-model-item>
|
|
@@ -334,9 +334,18 @@ export default {
|
|
|
this.queryParam.productTypeSn2 = val[1] ? val[1] : ''
|
|
|
this.queryParam.productTypeSn3 = val[2] ? val[2] : ''
|
|
|
},
|
|
|
+ // 添加
|
|
|
handleAdd (row) {
|
|
|
this.$emit('add', row)
|
|
|
},
|
|
|
+ // 批量添加
|
|
|
+ handlePlAdd () {
|
|
|
+ if (this.selectTotal) {
|
|
|
+ this.$emit('plAdd', this.rowSelectionInfo && this.rowSelectionInfo.selectedRows || [])
|
|
|
+ } else {
|
|
|
+ this.$message.info('请选择产品')
|
|
|
+ }
|
|
|
+ },
|
|
|
resetSearchForm () {
|
|
|
this.queryParam.productCode = ''
|
|
|
this.queryParam.productName = ''
|
|
@@ -346,8 +355,13 @@ export default {
|
|
|
this.productType = []
|
|
|
this.queryParam.stockStateList = []
|
|
|
this.$refs.ruleForm.resetFields()
|
|
|
+ this.$refs.table.clearSelected()
|
|
|
this.$refs.table.refresh(true)
|
|
|
},
|
|
|
+ reload () {
|
|
|
+ this.$refs.table.clearSelected()
|
|
|
+ this.$refs.table.refresh()
|
|
|
+ },
|
|
|
// ---------- 全部产品----------
|
|
|
// 产品分类 change
|
|
|
changeProductType1 (val, opt) {
|