|
@@ -62,9 +62,9 @@
|
|
|
<a-spin :spinning="spinning" tip="Loading...">
|
|
|
<!-- 操作按钮 -->
|
|
|
<div class="table-operator">
|
|
|
- <a-button type="primary" v-if="$hasPermissions('B_costSetAddProduct')" @click="newProduct=true">新增</a-button>
|
|
|
- <a-button type="primary" v-if="$hasPermissions('B_costSetBatchImport')" class="button-warning" @click="handleBatchImport">批量导入</a-button>
|
|
|
- <a-button type="primary" ghost v-if="$hasPermissions('B_costSetAudit')" @click="handleBatchAudit">批量审核</a-button>
|
|
|
+ <a-button id="costSetDetailList-new" type="primary" v-if="$hasPermissions('B_costSetAddProduct')" @click="newProduct=true">新增</a-button>
|
|
|
+ <a-button id="costSetDetailList-import" type="primary" v-if="$hasPermissions('B_costSetBatchImport')" class="button-warning" @click="handleBatchImport">批量导入</a-button>
|
|
|
+ <a-button id="costSetDetailList-paudit" type="primary" ghost v-if="$hasPermissions('B_costSetAudit')" @click="handleBatchAudit">批量审核</a-button>
|
|
|
</div>
|
|
|
<!-- 列表 -->
|
|
|
<s-table
|
|
@@ -91,6 +91,7 @@
|
|
|
<template slot="action" slot-scope="text, record">
|
|
|
<div>
|
|
|
<a-button
|
|
|
+ :id="'costSetDetailList-audit-'+record.id"
|
|
|
size="small"
|
|
|
type="link"
|
|
|
class="button-warning"
|
|
@@ -98,6 +99,7 @@
|
|
|
@click="handleAudit([record.supplierProductSn])"
|
|
|
>审核</a-button>
|
|
|
<a-button
|
|
|
+ :id="'costSetDetailList-editcost-'+record.id"
|
|
|
size="small"
|
|
|
type="link"
|
|
|
class="button-warning"
|
|
@@ -105,6 +107,7 @@
|
|
|
@click="handleCostSet(record,editFlag = true)"
|
|
|
>编辑成本</a-button>
|
|
|
<a-button
|
|
|
+ :id="'costSetDetailList-setcost-'+record.id"
|
|
|
size="small"
|
|
|
type="link"
|
|
|
class="button-warning"
|
|
@@ -145,8 +148,8 @@ export default {
|
|
|
spinning: false,
|
|
|
exportLoading: false,
|
|
|
advanced: true, // 高级搜索 展开/关闭
|
|
|
- openGuideModal: false,
|
|
|
- tableHeight: 0,
|
|
|
+ openGuideModal: false, // 导入指导弹窗
|
|
|
+ tableHeight: 0, // 表格高度
|
|
|
queryParam: { // 查询条件
|
|
|
supplierName: '',
|
|
|
product: {
|
|
@@ -157,7 +160,7 @@ export default {
|
|
|
productTypeSn2: '', // 产品二级分类
|
|
|
productTypeSn3: '' // 产品三级分类
|
|
|
},
|
|
|
- auditState: undefined
|
|
|
+ auditState: undefined // 审核状态
|
|
|
},
|
|
|
disabled: false, // 查询、重置按钮是否可操作
|
|
|
productType: [],
|
|
@@ -179,10 +182,10 @@ export default {
|
|
|
return data
|
|
|
})
|
|
|
},
|
|
|
- rowSelectionInfo: null,
|
|
|
- newProduct: false,
|
|
|
- openSetModal: false,
|
|
|
- editFlag: false
|
|
|
+ rowSelectionInfo: null, // 已选数据
|
|
|
+ newProduct: false, // 新增弹框
|
|
|
+ openSetModal: false, // 设置弹框
|
|
|
+ editFlag: false // 是否编辑
|
|
|
}
|
|
|
},
|
|
|
computed: {
|
|
@@ -232,7 +235,7 @@ export default {
|
|
|
this.productType = []
|
|
|
this.$refs.table.refresh(true)
|
|
|
},
|
|
|
- // 产品分类 change
|
|
|
+ // 选择产品分类 change
|
|
|
changeProductType (val, opt) {
|
|
|
this.queryParam.product.productTypeSn1 = val[0] ? val[0] : ''
|
|
|
this.queryParam.product.productTypeSn2 = val[1] ? val[1] : ''
|
|
@@ -288,6 +291,7 @@ export default {
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
+ // 提交审核
|
|
|
auditOrder (sn, val) {
|
|
|
this.spinning = true
|
|
|
supplierProductUpdateAuditState({
|
|
@@ -308,12 +312,14 @@ export default {
|
|
|
this.editFlag = !!flag
|
|
|
this.$refs.settingCost.setData(row)
|
|
|
},
|
|
|
+ // 页面初始化
|
|
|
pageInit () {
|
|
|
const _this = this
|
|
|
this.$nextTick(() => { // 页面渲染完成后的回调
|
|
|
_this.setTableH()
|
|
|
})
|
|
|
},
|
|
|
+ // 计算表格高度
|
|
|
setTableH () {
|
|
|
const tableSearchH = this.$refs.tableSearch.offsetHeight
|
|
|
this.tableHeight = window.innerHeight - tableSearchH - 240
|