|
@@ -34,16 +34,16 @@
|
|
|
|
|
|
<el-row :gutter="10">
|
|
|
<el-col :span="24" style="display: flex">
|
|
|
- <div style="height: 40px; line-height: 40px; margin-right: 10px">
|
|
|
+ <div style="height: 40px; line-height: 40px; margin-right: 10px" v-if="!userInfo.subsidiaryId">
|
|
|
<el-button type="primary" size="mini" @click="handleBOM()" v-db-click>选择bom</el-button>
|
|
|
</div>
|
|
|
- <div style="height: 40px; line-height: 40px; margin-right: 10px">
|
|
|
+ <div style="height: 40px; line-height: 40px; margin-right: 10px" v-if="userInfo.subsidiaryId">
|
|
|
<el-button type="primary" size="mini" @click="handleOpenOftenDialog()">选择常用包材</el-button>
|
|
|
</div>
|
|
|
- <div style="height: 40px; line-height: 40px; margin-right: 10px">
|
|
|
+ <div style="height: 40px; line-height: 40px; margin-right: 10px" v-if="userInfo.subsidiaryId">
|
|
|
<el-button type="primary" size="mini" style="background: #20b2aa; border-color: #20b2aa" @click="openSaveOftenDialog()">保存常用包材</el-button>
|
|
|
</div>
|
|
|
- <div style="height: 40px; line-height: 40px; margin-right: 10px">
|
|
|
+ <div style="height: 40px; line-height: 40px; margin-right: 10px" v-if="userInfo.subsidiaryId">
|
|
|
<el-button type="primary" size="mini" @click="handleOpenTwoBOM()">选择包材配件</el-button>
|
|
|
</div>
|
|
|
<div style="height: 40px; line-height: 40px; margin-right: 10px">
|
|
@@ -97,8 +97,8 @@
|
|
|
:row-style="{ height: '35px' }"
|
|
|
v-loading="loading"
|
|
|
header-row-class-name="tableHeader"
|
|
|
- height="calc(100vh - 58px - 20px - 114px - 134px)"
|
|
|
ref="table"
|
|
|
+ v-if="userInfo.subsidiaryId"
|
|
|
>
|
|
|
<el-table-column label="群组品号" prop="productCode" width="120" fixed />
|
|
|
<el-table-column label="SKU品号" prop="specCode" width="140" fixed />
|
|
@@ -112,6 +112,20 @@
|
|
|
</el-table-column>
|
|
|
</template>
|
|
|
</el-table>
|
|
|
+ <el-table
|
|
|
+ :data="tableList"
|
|
|
+ :cell-style="{ padding: '0' }"
|
|
|
+ :row-style="{ height: '35px' }"
|
|
|
+ v-loading="loading"
|
|
|
+ header-row-class-name="tableHeader"
|
|
|
+ ref="table"
|
|
|
+ v-else
|
|
|
+ >
|
|
|
+ <el-table-column label="群组品号" prop="productCode" width="120" />
|
|
|
+ <el-table-column label="SKU品号" prop="specCode" width="140" />
|
|
|
+ <el-table-column label="品名" prop="nameChinese" min-width="220" />
|
|
|
+ <el-table-column label="裸垫品号" prop="bomColorCode" width="140" />
|
|
|
+ </el-table>
|
|
|
|
|
|
<pagination v-show="total > 0" :total="total" :page.sync="queryParams.pageNum" :limit.sync="queryParams.pageSize" @pagination="getList" />
|
|
|
|
|
@@ -195,6 +209,7 @@ import * as API from '@/api/shengde/product/batchModification'
|
|
|
import { list, del, save } from '@/api/shengde/subsidiary/compose/index.js'
|
|
|
import { categoryList } from '@/api/shengde/group/BOM/category'
|
|
|
import SelectBOM from '@/components/shengde/SelectBOM/index'
|
|
|
+import { mapGetters } from 'vuex'
|
|
|
|
|
|
export default {
|
|
|
name: 'batchModification',
|
|
@@ -250,6 +265,7 @@ export default {
|
|
|
mounted() {
|
|
|
this.getList()
|
|
|
},
|
|
|
+ computed: mapGetters(['userInfo']),
|
|
|
methods: {
|
|
|
getList() {
|
|
|
this.loading = true
|
|
@@ -409,8 +425,7 @@ export default {
|
|
|
})
|
|
|
.then(() => {
|
|
|
let type = 10
|
|
|
- let packing = this.form.selectData.filter((item) => item.categoryId)
|
|
|
- if (packing && packing.length > 0) {
|
|
|
+ if (this.userInfo.subsidiaryId) {
|
|
|
type = 20
|
|
|
}
|
|
|
API.batchReplace({ type: type, bomColorList: this.form.selectData, productColor: this.queryParams }).then(() => {
|