|
@@ -1,11 +1,11 @@
|
|
|
<template>
|
|
|
<a-card :bordered="false">
|
|
|
- <div class="table-page-search-wrapper" @keyup.enter="handleEnter">
|
|
|
+ <div class="table-page-search-wrapper">
|
|
|
<a-form layout="inline">
|
|
|
<a-row :gutter="48">
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
<a-form-item label="关键字">
|
|
|
- <a-input v-model="queryParam.keyword" placeholder="请输入备件名称/备件编码"/>
|
|
|
+ <a-input v-model="queryParam.keyword" placeholder="请输入名称/编码"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
<a-col :md="8" :sm="24">
|
|
@@ -13,8 +13,8 @@
|
|
|
<a-input v-model="queryParam.brand" placeholder="模糊查询"/>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
- <a-form-item label="备件类别">
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
+ <a-form-item label="类型">
|
|
|
<a-tree-select
|
|
|
style="width: 100%"
|
|
|
:dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }"
|
|
@@ -27,10 +27,72 @@
|
|
|
</a-tree-select>
|
|
|
</a-form-item>
|
|
|
</a-col>
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
+ <a-form-item label="规格型号">
|
|
|
+ <a-input v-model="queryParam.ggxh" placeholder="模糊查询"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
+ <a-form-item label="原厂编号">
|
|
|
+ <a-input v-model="queryParam.initNo" placeholder="模糊查询"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
+ <a-form-item label="生产商">
|
|
|
+ <a-input v-model="queryParam.producerName" placeholder="名称模糊查询"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
+ <a-form-item label="供应商">
|
|
|
+ <a-input v-model="queryParam.supplierName" placeholder="名称模糊查询"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="8" :sm="24">
|
|
|
+ <a-form-item label="等级">
|
|
|
+ <a-select v-model="queryParam.level" placeholder="请选择">
|
|
|
+ <a-select-option
|
|
|
+ v-for="(label,value) in levelMap"
|
|
|
+ :key="value"
|
|
|
+ :label="label"
|
|
|
+ :value="parseInt(value)">{{ label }}
|
|
|
+ </a-select-option>
|
|
|
+ </a-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="用途">
|
|
|
+ <a-select v-model="queryParam.yt" placeholder="请选择">
|
|
|
+ <a-select-option
|
|
|
+ v-for="(label,value) in ytMap"
|
|
|
+ :key="value"
|
|
|
+ :label="label"
|
|
|
+ :value="parseInt(value)">{{ label }}
|
|
|
+ </a-select-option>
|
|
|
+ </a-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="是否专用">
|
|
|
+ <a-select v-model="queryParam.isSpecial" placeholder="请选择">
|
|
|
+ <a-select-option
|
|
|
+ v-for="(label,value) in specialMap"
|
|
|
+ :key="value"
|
|
|
+ :label="label"
|
|
|
+ :value="parseInt(value)">{{ label }}
|
|
|
+ </a-select-option>
|
|
|
+ </a-select>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
+ <a-form-item label="关联设备">
|
|
|
+ <a-input v-model="queryParam.model" placeholder="新号/旧号/名称/规格"/>
|
|
|
+ </a-form-item>
|
|
|
+ </a-col>
|
|
|
<a-col :md="6 || 24" :sm="24">
|
|
|
<span class="table-page-search-submitButtons">
|
|
|
<a-button type="primary" @click="$refs.table.refresh(true)">查询</a-button>
|
|
|
<a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
|
+ <!-- <a-button style="margin-left: 8px" @click="searchTypeNull">空类型</a-button> -->
|
|
|
</span>
|
|
|
</a-col>
|
|
|
</a-row>
|
|
@@ -45,7 +107,7 @@
|
|
|
<s-table
|
|
|
ref="table"
|
|
|
size="default"
|
|
|
- rowKey="spareId"
|
|
|
+ rowKey="id"
|
|
|
:columns="columns"
|
|
|
:data="loadData"
|
|
|
:alert="options.alert"
|
|
@@ -64,10 +126,10 @@
|
|
|
</template>
|
|
|
</span>
|
|
|
<span slot="status" slot-scope="text">
|
|
|
- <badge
|
|
|
- :status="DictCache.COLOR.SPARE_WARN_STATUS[text]"
|
|
|
- :text="warnStatusMap[text]" />
|
|
|
- </span>
|
|
|
+ <badge
|
|
|
+ :status="DictCache.COLOR.SPARE_WARN_STATUS[text]"
|
|
|
+ :text="warnStatusMap[text]" />
|
|
|
+ </span>
|
|
|
</s-table>
|
|
|
<base-form ref="baseModal" @ok="handleOk"/>
|
|
|
<detail ref="detailModal"/>
|
|
@@ -109,6 +171,9 @@ export default {
|
|
|
companyList: {},
|
|
|
projectList: {},
|
|
|
warnStatusMap: {},
|
|
|
+ ytMap: {},
|
|
|
+ specialMap: {},
|
|
|
+ levelMap: {},
|
|
|
spareTypeTreeData: [],
|
|
|
// 查询参数
|
|
|
queryParam: {
|
|
@@ -136,6 +201,12 @@ export default {
|
|
|
checked: true,
|
|
|
dataIndex: 'name'
|
|
|
},
|
|
|
+ {
|
|
|
+ title: '备件类别',
|
|
|
+ dataIndex: 'typeName',
|
|
|
+ checked: true,
|
|
|
+ width: '150px'
|
|
|
+ },
|
|
|
{
|
|
|
title: '规格型号',
|
|
|
checked: true,
|
|
@@ -224,6 +295,9 @@ export default {
|
|
|
created () {
|
|
|
// 下拉框map
|
|
|
this.warnStatusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SPARE_WARN_STATUS)
|
|
|
+ this.ytMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SPARE_USE_TYPE)
|
|
|
+ this.specialMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
|
|
|
+ this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SPARE_PART_INFO_LEVEL)
|
|
|
this.tableOption()
|
|
|
queryDept({ nature: this.DictCache.VALUE.SYS_DEPT_NATURE.FEN_GONG_SI }).then(res => {
|
|
|
this.companyList = res.data
|