|
@@ -2,7 +2,7 @@
|
|
<div class="app-container">
|
|
<div class="app-container">
|
|
<div class="filter-container">
|
|
<div class="filter-container">
|
|
<span>
|
|
<span>
|
|
- <el-radio-group v-model="queryParams.model.audit_status" @change="search()">
|
|
|
|
|
|
+ <el-radio-group v-model="queryParams.model.auditStatus" @change="search()">
|
|
<el-radio-button label="2">{{$t("prepare.searchForm.auditStatuss.two")}}</el-radio-button>
|
|
<el-radio-button label="2">{{$t("prepare.searchForm.auditStatuss.two")}}</el-radio-button>
|
|
<el-radio-button label="1">{{$t("prepare.searchForm.auditStatuss.one")}}</el-radio-button>
|
|
<el-radio-button label="1">{{$t("prepare.searchForm.auditStatuss.one")}}</el-radio-button>
|
|
<el-radio-button label="3">{{$t("prepare.searchForm.auditStatuss.three")}}</el-radio-button>
|
|
<el-radio-button label="3">{{$t("prepare.searchForm.auditStatuss.three")}}</el-radio-button>
|
|
@@ -48,11 +48,11 @@
|
|
</span>-->
|
|
</span>-->
|
|
<span>
|
|
<span>
|
|
<span>{{$t("prepare.searchForm.parts_no")}}:</span>
|
|
<span>{{$t("prepare.searchForm.parts_no")}}:</span>
|
|
- <el-input v-model="queryParams.model.parts_no" :placeholder='$t("common.pleaseEnter")' style="width: 150px;" size="medium"/>
|
|
|
|
|
|
+ <el-input v-model="queryParams.model.partsNo" :placeholder='$t("common.pleaseEnter")' style="width: 150px;" size="medium"/>
|
|
</span>
|
|
</span>
|
|
<span style="margin-left: 15px;">
|
|
<span style="margin-left: 15px;">
|
|
<span>{{$t("prepare.searchForm.bomAlias")}}:</span>
|
|
<span>{{$t("prepare.searchForm.bomAlias")}}:</span>
|
|
- <el-input v-model="queryParams.model.bom_alias" :placeholder='$t("common.pleaseEnter")' style="width: 150px;" size="medium"/>
|
|
|
|
|
|
+ <el-input v-model="queryParams.model.bomAlias" :placeholder='$t("common.pleaseEnter")' style="width: 150px;" size="medium"/>
|
|
</span>
|
|
</span>
|
|
<span style="margin-left: 15px;">
|
|
<span style="margin-left: 15px;">
|
|
<span>{{$t("prepare.searchForm.parts_name")}}:</span>
|
|
<span>{{$t("prepare.searchForm.parts_name")}}:</span>
|
|
@@ -60,7 +60,7 @@
|
|
</span>
|
|
</span>
|
|
<span style="margin-left: 15px;">
|
|
<span style="margin-left: 15px;">
|
|
<span>{{$t("prepare.searchForm.partsAlias")}}:</span>
|
|
<span>{{$t("prepare.searchForm.partsAlias")}}:</span>
|
|
- <el-input v-model="queryParams.model.parts_alias" :placeholder='$t("common.pleaseEnter")' style="width: 150px;" size="medium"/>
|
|
|
|
|
|
+ <el-input v-model="queryParams.model.partsAlias" :placeholder='$t("common.pleaseEnter")' style="width: 150px;" size="medium"/>
|
|
</span>
|
|
</span>
|
|
<span style="margin-left: 15px;">
|
|
<span style="margin-left: 15px;">
|
|
<el-button plain type="primary" icon="el-icon-search" size="medium" @click="search">
|
|
<el-button plain type="primary" icon="el-icon-search" size="medium" @click="search">
|
|
@@ -93,7 +93,7 @@
|
|
:key="tableKey"
|
|
:key="tableKey"
|
|
ref="table"
|
|
ref="table"
|
|
v-loading="loading"
|
|
v-loading="loading"
|
|
- :data="tableData.data"
|
|
|
|
|
|
+ :data="tableData.records"
|
|
border
|
|
border
|
|
fit
|
|
fit
|
|
row-key="id"
|
|
row-key="id"
|
|
@@ -106,7 +106,7 @@
|
|
@cell-click="cellClick"
|
|
@cell-click="cellClick"
|
|
>
|
|
>
|
|
<el-table-column align="center" type="selection" width="40px" :reserve-selection="true" />
|
|
<el-table-column align="center" type="selection" width="40px" :reserve-selection="true" />
|
|
- <el-table-column v-for="item in tableData.titleList" :key="item.id" :prop="item.field" :label='item.text' :show-overflow-tooltip="true" width="180px"></el-table-column>
|
|
|
|
|
|
+ <el-table-column v-for="item in titleList" :key="item.id" :prop="item.field" :label='item.text' :show-overflow-tooltip="true" width="180px" :formatter="textFormatter"></el-table-column>
|
|
<!--<el-table-column prop="name" label="名称" :show-overflow-tooltip="true" width="250px"></el-table-column>
|
|
<!--<el-table-column prop="name" label="名称" :show-overflow-tooltip="true" width="250px"></el-table-column>
|
|
<el-table-column prop="status" label="状态" align="center" width="90px">
|
|
<el-table-column prop="status" label="状态" align="center" width="90px">
|
|
<template slot-scope="{ row }">
|
|
<template slot-scope="{ row }">
|
|
@@ -217,6 +217,7 @@
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
|
+import i18n from '@/lang'
|
|
import Pagination from "@/components/Pagination"
|
|
import Pagination from "@/components/Pagination"
|
|
import TenantEdit from "./components/Edit"
|
|
import TenantEdit from "./components/Edit"
|
|
import TenantView from "./components/View"
|
|
import TenantView from "./components/View"
|
|
@@ -234,6 +235,8 @@ export default {
|
|
expands: [], // 展开行的key
|
|
expands: [], // 展开行的key
|
|
qiyongStatus: [], //状态
|
|
qiyongStatus: [], //状态
|
|
statusList: [], // 启用状态
|
|
statusList: [], // 启用状态
|
|
|
|
+ titleList: [{"field":"partsNo","text":i18n.t("prepare.searchForm.parts_no")},{"field":"bomAlias","text":i18n.t("prepare.searchForm.bomAlias")},{"field":"name","text":i18n.t("prepare.searchForm.name")},{"field":"partsAlias","text":i18n.t("prepare.searchForm.partsAlias")},{"field":"batchNo","text":i18n.t("prepare.searchForm.batchNo")},{"field":"materialBrandName","text":i18n.t("prepare.searchForm.materialBrandName")},{"field":"batchNo","text":i18n.t("prepare.searchForm.batchNo")},
|
|
|
|
+ {"field":"keyFlag","text":i18n.t("prepare.searchForm.keyFlag")},{"field":"importantFlag","text":i18n.t("prepare.searchForm.importantFlag")},{"field":"productModuleName","text":i18n.t("prepare.searchForm.productModuleName")},{"field":"remark","text":i18n.t("prepare.searchForm.remark")},{"field":"status","text":i18n.t("prepare.searchForm.status")},{"field":"auditStatus","text":i18n.t("prepare.searchForm.auditStatus")}],
|
|
dialog: {
|
|
dialog: {
|
|
isVisible: false,
|
|
isVisible: false,
|
|
title: ""
|
|
title: ""
|
|
@@ -400,7 +403,21 @@ export default {
|
|
onSelectChange (selection) {
|
|
onSelectChange (selection) {
|
|
this.selection = selection
|
|
this.selection = selection
|
|
},
|
|
},
|
|
-
|
|
|
|
|
|
+ textFormatter(row, column){
|
|
|
|
+ if (column.property == "keyFlag"){
|
|
|
|
+ return (row.keyFlag === '1')? "是" : "否"
|
|
|
|
+ }
|
|
|
|
+ else if (column.property == "importantFlag"){
|
|
|
|
+ return (row.importantFlag === '1')? "是" : "否"
|
|
|
|
+ }else if (column.property == "status"){
|
|
|
|
+ return (row.status === '1')? "启用" : "冻结"
|
|
|
|
+ }else if (column.property == "auditStatus"){
|
|
|
|
+ return (row.auditStatus === '0')? "新增" : (row.auditStatus === '1')? "未审核":(row.auditStatus === '2')? "审核通过" : "审核未通过"
|
|
|
|
+ }else{
|
|
|
|
+ return row[column.property]
|
|
|
|
+ }
|
|
|
|
+
|
|
|
|
+ },
|
|
// 搜索
|
|
// 搜索
|
|
search () {
|
|
search () {
|
|
// 清空,table的选中函数
|
|
// 清空,table的选中函数
|
|
@@ -563,9 +580,9 @@ export default {
|
|
// 分页信息
|
|
// 分页信息
|
|
this.queryParams.current = params.current ? params.current : this.queryParams.current
|
|
this.queryParams.current = params.current ? params.current : this.queryParams.current
|
|
this.queryParams.size = params.size ? params.size : this.queryParams.size
|
|
this.queryParams.size = params.size ? params.size : this.queryParams.size
|
|
-
|
|
|
|
|
|
+
|
|
// 测试数据,真实数据,请使用page
|
|
// 测试数据,真实数据,请使用page
|
|
- bomMgrApi.pageList(this.queryParams).then(response => {
|
|
|
|
|
|
+ bomMgrApi.page(this.queryParams).then(response => {
|
|
const res = response.data
|
|
const res = response.data
|
|
console.log("列表的数据:", res)
|
|
console.log("列表的数据:", res)
|
|
if (res.isSuccess) {
|
|
if (res.isSuccess) {
|