|
@@ -1,64 +1,85 @@
|
|
<template>
|
|
<template>
|
|
<div>
|
|
<div>
|
|
|
|
+ <a-space v-show="visible" :size="50">
|
|
|
|
+ <div class="filter-icon" :class="current===0?'active':''" @click="handleFilter(0)">
|
|
|
|
+ <my-icon type="icon-shebeiguanli"></my-icon>
|
|
|
|
+ <div>全部</div>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="filter-icon" :class="current===1?'active':''" @click="handleFilter(1)">
|
|
|
|
+ <my-icon type="icon-cangkuxinxi"></my-icon>
|
|
|
|
+ <div>在库</div>
|
|
|
|
+ </div>
|
|
|
|
+ <div class="filter-icon" :class="current===2?'active':''" @click="handleFilter(2)">
|
|
|
|
+ <my-icon type="icon-jijubaofeishenqing"></my-icon>
|
|
|
|
+ <div>
|
|
|
|
+ 报废
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </a-space>
|
|
<a-card :bordered="false" v-show="visible">
|
|
<a-card :bordered="false" v-show="visible">
|
|
- <a-row :gutter="8">
|
|
|
|
- <a-col :span="24">
|
|
|
|
- <div>
|
|
|
|
- <div class="table-page-search-wrapper">
|
|
|
|
- <a-form layout="inline">
|
|
|
|
- <a-row :gutter="48">
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="关键字">
|
|
|
|
- <a-input v-model.trim="queryParam.keyword" placeholder="设备编号" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="车间位置">
|
|
|
|
- <a-select v-model="queryParam.positionId" placeholder="请选择">
|
|
|
|
- <a-select-option v-for="({id,name}) in sbPositionData" :key="id" :label="name" :value="id">{{ name }}
|
|
|
|
- </a-select-option>
|
|
|
|
- </a-select>
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="设备名称">
|
|
|
|
- <a-input v-model.trim="queryParam.name" placeholder="名称" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="父位号">
|
|
|
|
- <a-input v-model.trim="queryParam.ppNo" placeholder="父位号" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="设备位号">
|
|
|
|
- <a-input v-model.trim="queryParam.positionNo" placeholder="设备位号" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="生产商">
|
|
|
|
- <a-input v-model.trim="queryParam.producerId" placeholder="生产商" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="设备编号">
|
|
|
|
- <a-input v-model.trim="queryParam.financingNo" placeholder="设备编号" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <!-- <a-col :md="6" :sm="24">
|
|
|
|
|
|
+ <a-drawer
|
|
|
|
+ title="设备筛选"
|
|
|
|
+ placement="top"
|
|
|
|
+ :closable="false"
|
|
|
|
+ :visible="showFilter"
|
|
|
|
+ :height="330"
|
|
|
|
+ @close="showFilter=false"
|
|
|
|
+ >
|
|
|
|
+ <div class="table-page-search-wrapper">
|
|
|
|
+ <a-form layout="inline">
|
|
|
|
+ <a-row :gutter="48">
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="关键字">
|
|
|
|
+ <a-input v-model.trim="queryParam.keyword" placeholder="设备编号" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="车间位置">
|
|
|
|
+ <a-select v-model="queryParam.positionId" placeholder="请选择">
|
|
|
|
+ <a-select-option v-for="({id,name}) in sbPositionData" :key="id" :label="name" :value="id">{{ name }}
|
|
|
|
+ </a-select-option>
|
|
|
|
+ </a-select>
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="设备名称">
|
|
|
|
+ <a-input v-model.trim="queryParam.name" placeholder="名称" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="父位号">
|
|
|
|
+ <a-input v-model.trim="queryParam.ppNo" placeholder="父位号" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="设备位号">
|
|
|
|
+ <a-input v-model.trim="queryParam.positionNo" placeholder="设备位号" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="生产商">
|
|
|
|
+ <a-input v-model.trim="queryParam.producerId" placeholder="生产商" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="设备编号">
|
|
|
|
+ <a-input v-model.trim="queryParam.financingNo" placeholder="设备编号" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <!-- <a-col :md="6" :sm="24">
|
|
<a-form-item label="设备自编号">
|
|
<a-form-item label="设备自编号">
|
|
<a-input v-model="queryParam.zbh" placeholder="设备自编号"/>
|
|
<a-input v-model="queryParam.zbh" placeholder="设备自编号"/>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>-->
|
|
</a-col>-->
|
|
- <a-col :md="6" :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-col :md="6" :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-form-item label="自定义类型">
|
|
<a-select v-model="queryParam.useType" placeholder="请选择">
|
|
<a-select v-model="queryParam.useType" placeholder="请选择">
|
|
<a-select-option
|
|
<a-select-option
|
|
@@ -70,57 +91,87 @@
|
|
</a-select>
|
|
</a-select>
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>-->
|
|
</a-col>-->
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="检定日期范围">
|
|
|
|
+ <a-range-picker v-model="dateRangeCheck" />
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="有效日期范围">
|
|
|
|
+ <a-range-picker v-model="dateRange" />
|
|
|
|
+ </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" :sm="24">
|
|
|
|
+ <a-form-item label="设备类型">
|
|
|
|
+ <a-tree-select
|
|
|
|
+ style="width: 100%"
|
|
|
|
+ :dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }"
|
|
|
|
+ :treeData="treeData"
|
|
|
|
+ :treeNodeFilterProp="'title'"
|
|
|
|
+ v-model="dd"
|
|
|
|
+ :showSearch="true"
|
|
|
|
+ placeholder="请选择"
|
|
|
|
+ @change="handleChange">
|
|
|
|
+ </a-tree-select>
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6" :sm="24">
|
|
|
|
+ <a-form-item label="设备状态">
|
|
|
|
+ <a-select v-model="queryParam.status" placeholder="请选择">
|
|
|
|
+ <a-select-option v-for="(label,value) in statusMap" :key="value" :defaultValue="DictCache.VALUE.SB_INFO_STATUS.IN_USE" :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.isChild" placeholder="请选择">
|
|
|
|
+ <a-select-option value="1">子设备</a-select-option>
|
|
|
|
+ <a-select-option value="2">父设备</a-select-option>
|
|
|
|
+ <a-select-option value="3">普通设备</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.baoyangTimes" placeholder="请选择">
|
|
|
|
+ <a-select-option v-for="(label,value) in lineMap" :key="value" :label="label" :value="parseInt(value)">{{ label }}
|
|
|
|
+ </a-select-option>
|
|
|
|
+ </a-select>
|
|
|
|
+ </a-form-item>
|
|
|
|
+ </a-col>
|
|
|
|
+ <a-col :md="6 || 24" :sm="24">
|
|
|
|
+ <span class="table-page-search-submitButtons">
|
|
|
|
+ <a-button type="primary" @click="handleOk">查询</a-button>
|
|
|
|
+ <a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
|
|
+ </span>
|
|
|
|
+ </a-col>
|
|
|
|
+ </a-row>
|
|
|
|
+ </a-form>
|
|
|
|
+ </div>
|
|
|
|
+ </a-drawer>
|
|
|
|
+ <a-row :gutter="8">
|
|
|
|
+ <a-col :span="24">
|
|
|
|
+ <div>
|
|
|
|
+ <div class="table-page-search-wrapper">
|
|
|
|
+ <a-form layout="inline">
|
|
|
|
+ <a-row :gutter="48">
|
|
<a-col :md="6" :sm="24">
|
|
<a-col :md="6" :sm="24">
|
|
- <a-form-item label="检定日期范围">
|
|
|
|
- <a-range-picker v-model="dateRangeCheck" />
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="有效日期范围">
|
|
|
|
- <a-range-picker v-model="dateRange" />
|
|
|
|
- </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" :sm="24">
|
|
|
|
- <a-form-item label="设备类型">
|
|
|
|
- <a-tree-select style="width: 100%" :dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }" :treeData="treeData" :treeNodeFilterProp="'title'" v-model="dd" :showSearch="true" placeholder="请选择" @change="handleChange">
|
|
|
|
- </a-tree-select>
|
|
|
|
- </a-form-item>
|
|
|
|
- </a-col>
|
|
|
|
- <a-col :md="6" :sm="24">
|
|
|
|
- <a-form-item label="设备状态">
|
|
|
|
- <a-select v-model="queryParam.status" placeholder="请选择">
|
|
|
|
- <a-select-option v-for="(label,value) in statusMap" :key="value" :defaultValue="DictCache.VALUE.SB_INFO_STATUS.IN_USE" :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.isChild" placeholder="请选择">
|
|
|
|
- <a-select-option value="1">子设备</a-select-option>
|
|
|
|
- <a-select-option value="2">父设备</a-select-option>
|
|
|
|
- <a-select-option value="3">普通设备</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.baoyangTimes" placeholder="请选择">
|
|
|
|
- <a-select-option v-for="(label,value) in lineMap" :key="value" :label="label" :value="parseInt(value)">{{ label }}
|
|
|
|
- </a-select-option>
|
|
|
|
- </a-select>
|
|
|
|
|
|
+ <a-form-item label="关键字">
|
|
|
|
+ <a-input v-model.trim="queryParam.keyword" placeholder="设备编号" />
|
|
</a-form-item>
|
|
</a-form-item>
|
|
</a-col>
|
|
</a-col>
|
|
<a-col :md="6 || 24" :sm="24">
|
|
<a-col :md="6 || 24" :sm="24">
|
|
- <span class="table-page-search-submitButtons">
|
|
|
|
|
|
+ <a-space>
|
|
<a-button type="primary" @click="handleOk">查询</a-button>
|
|
<a-button type="primary" @click="handleOk">查询</a-button>
|
|
- <a-button style="margin-left: 8px" @click="resetSearchForm">重置</a-button>
|
|
|
|
- </span>
|
|
|
|
|
|
+ <a-button type="primary" @click="showFilter=true">筛选</a-button>
|
|
|
|
+ <a-button @click="resetSearchForm">重置</a-button>
|
|
|
|
+ </a-space>
|
|
</a-col>
|
|
</a-col>
|
|
</a-row>
|
|
</a-row>
|
|
</a-form>
|
|
</a-form>
|
|
@@ -165,7 +216,18 @@
|
|
</a-dropdown>
|
|
</a-dropdown>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
- <s-table ref="table" @expand="onExpand" size="default" rowKey="id" :widthSpace="true" :columns="columns" :data="loadData" :alert="options.alert" :rowSelection="options.rowSelection" :scroll="{x: 1500, y: BaseTool.Constant.scrollY}" showPagination="auto">
|
|
|
|
|
|
+ <s-table
|
|
|
|
+ ref="table"
|
|
|
|
+ @expand="onExpand"
|
|
|
|
+ size="default"
|
|
|
|
+ rowKey="id"
|
|
|
|
+ :widthSpace="true"
|
|
|
|
+ :columns="columns"
|
|
|
|
+ :data="loadData"
|
|
|
|
+ :alert="options.alert"
|
|
|
|
+ :rowSelection="options.rowSelection"
|
|
|
|
+ :scroll="{x: 1500, y: BaseTool.Constant.scrollY}"
|
|
|
|
+ showPagination="auto">
|
|
<template #positionNo="text,record">
|
|
<template #positionNo="text,record">
|
|
<a @click="showChangeLog(record)">{{ text }}</a>
|
|
<a @click="showChangeLog(record)">{{ text }}</a>
|
|
</template>
|
|
</template>
|
|
@@ -266,7 +328,7 @@ import {
|
|
fetchSbInfo,
|
|
fetchSbInfo,
|
|
fetchSbInfos,
|
|
fetchSbInfos,
|
|
exportSbInfo,
|
|
exportSbInfo,
|
|
- batchLocationList,
|
|
|
|
|
|
+ batchLocationList
|
|
} from '@/api/sb/info'
|
|
} from '@/api/sb/info'
|
|
import { queryDept } from '@/api/upms/dept'
|
|
import { queryDept } from '@/api/upms/dept'
|
|
import { generateSbCodeAll } from '@/api/upms/code'
|
|
import { generateSbCodeAll } from '@/api/upms/code'
|
|
@@ -298,41 +360,42 @@ export default {
|
|
BaseFormLocation,
|
|
BaseFormLocation,
|
|
BaseFormStatusLog,
|
|
BaseFormStatusLog,
|
|
SbChangeLogSelectModal,
|
|
SbChangeLogSelectModal,
|
|
- SbBomSyncSelectModal,
|
|
|
|
|
|
+ SbBomSyncSelectModal
|
|
},
|
|
},
|
|
props: {
|
|
props: {
|
|
filter: {
|
|
filter: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: -1,
|
|
|
|
|
|
+ default: -1
|
|
},
|
|
},
|
|
useType: {
|
|
useType: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: null,
|
|
|
|
|
|
+ default: null
|
|
},
|
|
},
|
|
correctType: {
|
|
correctType: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: 1,
|
|
|
|
|
|
+ default: 1
|
|
},
|
|
},
|
|
measureStatus: {
|
|
measureStatus: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: null,
|
|
|
|
|
|
+ default: null
|
|
},
|
|
},
|
|
isMeasure: {
|
|
isMeasure: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: null,
|
|
|
|
|
|
+ default: null
|
|
},
|
|
},
|
|
isSelf: {
|
|
isSelf: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: null,
|
|
|
|
|
|
+ default: null
|
|
},
|
|
},
|
|
status: {
|
|
status: {
|
|
type: Number,
|
|
type: Number,
|
|
- default: null,
|
|
|
|
- },
|
|
|
|
|
|
+ default: null
|
|
|
|
+ }
|
|
},
|
|
},
|
|
- data() {
|
|
|
|
|
|
+ data () {
|
|
return {
|
|
return {
|
|
// 查询参数
|
|
// 查询参数
|
|
|
|
+ showFilter: false,
|
|
queryParam: {
|
|
queryParam: {
|
|
filter: this.filter,
|
|
filter: this.filter,
|
|
useType: this.useType,
|
|
useType: this.useType,
|
|
@@ -341,8 +404,9 @@ export default {
|
|
isSelf: this.isSelf,
|
|
isSelf: this.isSelf,
|
|
id: this.$route.query.id,
|
|
id: this.$route.query.id,
|
|
typeId: this.$route.query.typeId,
|
|
typeId: this.$route.query.typeId,
|
|
- status: this.$route.query.status || this.status,
|
|
|
|
|
|
+ status: this.$route.query.status || this.status
|
|
},
|
|
},
|
|
|
|
+ current: 0,
|
|
depreciationTypeMap: {},
|
|
depreciationTypeMap: {},
|
|
visible: true,
|
|
visible: true,
|
|
dateRange: [],
|
|
dateRange: [],
|
|
@@ -382,26 +446,26 @@ export default {
|
|
title: '设备位置',
|
|
title: '设备位置',
|
|
checked: true,
|
|
checked: true,
|
|
width: 200,
|
|
width: 200,
|
|
- dataIndex: 'positionName',
|
|
|
|
|
|
+ dataIndex: 'positionName'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '设备名称',
|
|
title: '设备名称',
|
|
checked: true,
|
|
checked: true,
|
|
width: 200,
|
|
width: 200,
|
|
- dataIndex: 'name',
|
|
|
|
|
|
+ dataIndex: 'name'
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '设备位号',
|
|
title: '设备位号',
|
|
dataIndex: 'positionNo',
|
|
dataIndex: 'positionNo',
|
|
width: 150,
|
|
width: 150,
|
|
scopedSlots: { customRender: 'positionNo' },
|
|
scopedSlots: { customRender: 'positionNo' },
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '父位号',
|
|
title: '父位号',
|
|
dataIndex: 'ppNo',
|
|
dataIndex: 'ppNo',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
|
|
|
|
{
|
|
{
|
|
@@ -411,7 +475,7 @@ export default {
|
|
width: 150,
|
|
width: 150,
|
|
customRender: (text, record, index) => {
|
|
customRender: (text, record, index) => {
|
|
return record.typeName
|
|
return record.typeName
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
/* {
|
|
/* {
|
|
title: '设备等级',
|
|
title: '设备等级',
|
|
@@ -426,19 +490,19 @@ export default {
|
|
title: '规格型号',
|
|
title: '规格型号',
|
|
dataIndex: 'model',
|
|
dataIndex: 'model',
|
|
width: 150,
|
|
width: 150,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '设备编号',
|
|
title: '设备编号',
|
|
dataIndex: 'no',
|
|
dataIndex: 'no',
|
|
width: 150,
|
|
width: 150,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '巡检序号',
|
|
title: '巡检序号',
|
|
dataIndex: 'sortNum',
|
|
dataIndex: 'sortNum',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
/* {
|
|
/* {
|
|
title: '自定义类型',
|
|
title: '自定义类型',
|
|
@@ -473,43 +537,43 @@ export default {
|
|
title: '出厂编号',
|
|
title: '出厂编号',
|
|
dataIndex: 'zzh',
|
|
dataIndex: 'zzh',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '设备识别码',
|
|
title: '设备识别码',
|
|
dataIndex: 'identifyNo',
|
|
dataIndex: 'identifyNo',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '使用证号',
|
|
title: '使用证号',
|
|
dataIndex: 'useNo',
|
|
dataIndex: 'useNo',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '设备代号',
|
|
title: '设备代号',
|
|
dataIndex: 'sbCode',
|
|
dataIndex: 'sbCode',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '安装单位',
|
|
title: '安装单位',
|
|
dataIndex: 'installUnit',
|
|
dataIndex: 'installUnit',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '检验结论',
|
|
title: '检验结论',
|
|
dataIndex: 'examResult',
|
|
dataIndex: 'examResult',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '单位内部使用地点',
|
|
title: '单位内部使用地点',
|
|
dataIndex: 'usePosition',
|
|
dataIndex: 'usePosition',
|
|
width: 120,
|
|
width: 120,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
/* {
|
|
/* {
|
|
title: '是否显示',
|
|
title: '是否显示',
|
|
@@ -581,7 +645,7 @@ export default {
|
|
dataIndex: 'nextCheckDate',
|
|
dataIndex: 'nextCheckDate',
|
|
fixed: 'right',
|
|
fixed: 'right',
|
|
width: 150,
|
|
width: 150,
|
|
- checked: true,
|
|
|
|
|
|
+ checked: true
|
|
},
|
|
},
|
|
/* {
|
|
/* {
|
|
title: '检定截止',
|
|
title: '检定截止',
|
|
@@ -602,7 +666,7 @@ export default {
|
|
dataIndex: 'status',
|
|
dataIndex: 'status',
|
|
fixed: 'right',
|
|
fixed: 'right',
|
|
width: 100,
|
|
width: 100,
|
|
- scopedSlots: { customRender: 'status' },
|
|
|
|
|
|
+ scopedSlots: { customRender: 'status' }
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '检定状态',
|
|
title: '检定状态',
|
|
@@ -610,7 +674,7 @@ export default {
|
|
dataIndex: 'measureStatus',
|
|
dataIndex: 'measureStatus',
|
|
fixed: 'right',
|
|
fixed: 'right',
|
|
width: 100,
|
|
width: 100,
|
|
- scopedSlots: { customRender: 'measureStatus' },
|
|
|
|
|
|
+ scopedSlots: { customRender: 'measureStatus' }
|
|
},
|
|
},
|
|
{
|
|
{
|
|
title: '操作',
|
|
title: '操作',
|
|
@@ -619,8 +683,8 @@ export default {
|
|
fixed: 'right',
|
|
fixed: 'right',
|
|
align: 'center',
|
|
align: 'center',
|
|
width: '120',
|
|
width: '120',
|
|
- scopedSlots: { customRender: 'action' },
|
|
|
|
- },
|
|
|
|
|
|
+ scopedSlots: { customRender: 'action' }
|
|
|
|
+ }
|
|
],
|
|
],
|
|
// 加载数据方法 必须为 Promise 对象
|
|
// 加载数据方法 必须为 Promise 对象
|
|
loadData: (parameter) => {
|
|
loadData: (parameter) => {
|
|
@@ -630,8 +694,8 @@ export default {
|
|
typeList: this.typeList,
|
|
typeList: this.typeList,
|
|
dataScope: {
|
|
dataScope: {
|
|
sortBy: 'asc',
|
|
sortBy: 'asc',
|
|
- sortName: 'no',
|
|
|
|
- },
|
|
|
|
|
|
+ sortName: 'no'
|
|
|
|
+ }
|
|
}
|
|
}
|
|
this.selectedRowKeys = []
|
|
this.selectedRowKeys = []
|
|
return getSbInfoPage(Object.assign(parameter, this.queryParam)).then((res) => {
|
|
return getSbInfoPage(Object.assign(parameter, this.queryParam)).then((res) => {
|
|
@@ -646,17 +710,17 @@ export default {
|
|
show: true,
|
|
show: true,
|
|
clear: () => {
|
|
clear: () => {
|
|
this.selectedRowKeys = []
|
|
this.selectedRowKeys = []
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
rowSelection: {
|
|
rowSelection: {
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
- onChange: this.onSelectChange,
|
|
|
|
- },
|
|
|
|
|
|
+ onChange: this.onSelectChange
|
|
|
|
+ }
|
|
},
|
|
},
|
|
- optionAlertShow: false,
|
|
|
|
|
|
+ optionAlertShow: false
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- created() {
|
|
|
|
|
|
+ created () {
|
|
console.log('this.$route.query.parentId: ' + this.$route.query.parentId)
|
|
console.log('this.$route.query.parentId: ' + this.$route.query.parentId)
|
|
this.queryParam.parentId = this.$route.query.parentId
|
|
this.queryParam.parentId = this.$route.query.parentId
|
|
this.queryParam.parentName = this.$route.query.parentName
|
|
this.queryParam.parentName = this.$route.query.parentName
|
|
@@ -676,7 +740,7 @@ export default {
|
|
})
|
|
})
|
|
},
|
|
},
|
|
methods: {
|
|
methods: {
|
|
- tableOption() {
|
|
|
|
|
|
+ tableOption () {
|
|
this.setTree()
|
|
this.setTree()
|
|
if (!this.optionAlertShow) {
|
|
if (!this.optionAlertShow) {
|
|
this.options = {
|
|
this.options = {
|
|
@@ -684,7 +748,7 @@ export default {
|
|
show: true,
|
|
show: true,
|
|
clear: () => {
|
|
clear: () => {
|
|
this.selectedRowKeys = []
|
|
this.selectedRowKeys = []
|
|
- },
|
|
|
|
|
|
+ }
|
|
},
|
|
},
|
|
rowSelection: {
|
|
rowSelection: {
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
selectedRowKeys: this.selectedRowKeys,
|
|
@@ -692,21 +756,21 @@ export default {
|
|
getCheckboxProps: (record) => ({
|
|
getCheckboxProps: (record) => ({
|
|
props: {
|
|
props: {
|
|
disabled: false,
|
|
disabled: false,
|
|
- name: record.id,
|
|
|
|
- },
|
|
|
|
- }),
|
|
|
|
- },
|
|
|
|
|
|
+ name: record.id
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ }
|
|
}
|
|
}
|
|
this.optionAlertShow = true
|
|
this.optionAlertShow = true
|
|
} else {
|
|
} else {
|
|
this.options = {
|
|
this.options = {
|
|
alert: false,
|
|
alert: false,
|
|
- rowSelection: null,
|
|
|
|
|
|
+ rowSelection: null
|
|
}
|
|
}
|
|
this.optionAlertShow = false
|
|
this.optionAlertShow = false
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- batchDelete(id) {
|
|
|
|
|
|
+ batchDelete (id) {
|
|
let ids = []
|
|
let ids = []
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
const length = this.selectedRows.length
|
|
const length = this.selectedRows.length
|
|
@@ -724,7 +788,7 @@ export default {
|
|
this.$refs.table.clearSelected()
|
|
this.$refs.table.clearSelected()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- batchGenerate() {
|
|
|
|
|
|
+ batchGenerate () {
|
|
this.confirmLoading = true
|
|
this.confirmLoading = true
|
|
this.$message.info('正在生成请稍后')
|
|
this.$message.info('正在生成请稍后')
|
|
generateSbCodeAll().then((res) => {
|
|
generateSbCodeAll().then((res) => {
|
|
@@ -734,21 +798,21 @@ export default {
|
|
this.$refs.table.clearSelected()
|
|
this.$refs.table.clearSelected()
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleEdit(record) {
|
|
|
|
|
|
+ handleEdit (record) {
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
this.visible = false
|
|
this.visible = false
|
|
const modal = this.$refs.baseModal
|
|
const modal = this.$refs.baseModal
|
|
modal.base(res.data)
|
|
modal.base(res.data)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handlePrint(record) {
|
|
|
|
|
|
+ handlePrint (record) {
|
|
this.visible = false
|
|
this.visible = false
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
const modal = this.$refs.printInSbInfoBatch
|
|
const modal = this.$refs.printInSbInfoBatch
|
|
modal.base([res.data])
|
|
modal.base([res.data])
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- batchLocation() {
|
|
|
|
|
|
+ batchLocation () {
|
|
let ids = []
|
|
let ids = []
|
|
const length = this.selectedRows.length
|
|
const length = this.selectedRows.length
|
|
if (length === 0) {
|
|
if (length === 0) {
|
|
@@ -763,7 +827,7 @@ export default {
|
|
modal.base(res.data)
|
|
modal.base(res.data)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- batchIncorrect(id) {
|
|
|
|
|
|
+ batchIncorrect (id) {
|
|
let ids = []
|
|
let ids = []
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
const length = this.selectedRows.length
|
|
const length = this.selectedRows.length
|
|
@@ -779,7 +843,7 @@ export default {
|
|
const modal = this.$refs.baseModalMeasure
|
|
const modal = this.$refs.baseModalMeasure
|
|
modal.base(ids, this.correctType)
|
|
modal.base(ids, this.correctType)
|
|
},
|
|
},
|
|
- batchIncorrectInStore(id) {
|
|
|
|
|
|
+ batchIncorrectInStore (id) {
|
|
let ids = []
|
|
let ids = []
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
if (this.BaseTool.String.isBlank(id)) {
|
|
const length = this.selectedRows.length
|
|
const length = this.selectedRows.length
|
|
@@ -795,11 +859,11 @@ export default {
|
|
const modal = this.$refs.baseModalMeasureInStore
|
|
const modal = this.$refs.baseModalMeasureInStore
|
|
modal.base(ids, this.correctType)
|
|
modal.base(ids, this.correctType)
|
|
},
|
|
},
|
|
- handleMeasureBatch() {
|
|
|
|
|
|
+ handleMeasureBatch () {
|
|
const modal = this.$refs.detailSbMeasureModal
|
|
const modal = this.$refs.detailSbMeasureModal
|
|
modal.base()
|
|
modal.base()
|
|
},
|
|
},
|
|
- handlePrintBatch() {
|
|
|
|
|
|
+ handlePrintBatch () {
|
|
this.visible = false
|
|
this.visible = false
|
|
let ids = []
|
|
let ids = []
|
|
const length = this.selectedRows.length
|
|
const length = this.selectedRows.length
|
|
@@ -813,7 +877,7 @@ export default {
|
|
modal.base(res.data)
|
|
modal.base(res.data)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleStart(record) {
|
|
|
|
|
|
+ handleStart (record) {
|
|
const modal = this.$refs.baseModalStatusLog
|
|
const modal = this.$refs.baseModalStatusLog
|
|
modal.base(null, {
|
|
modal.base(null, {
|
|
sbId: record.id,
|
|
sbId: record.id,
|
|
@@ -821,10 +885,10 @@ export default {
|
|
changeUserId: this.$store.getters.userInfo.userId,
|
|
changeUserId: this.$store.getters.userInfo.userId,
|
|
actualUser: this.$store.getters.userInfo.realName,
|
|
actualUser: this.$store.getters.userInfo.realName,
|
|
preStatus: record.status,
|
|
preStatus: record.status,
|
|
- afterStatus: this.DictCache.VALUE.SB_INFO_STATUS.IN_USE,
|
|
|
|
|
|
+ afterStatus: this.DictCache.VALUE.SB_INFO_STATUS.IN_USE
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleStop(record) {
|
|
|
|
|
|
+ handleStop (record) {
|
|
const modal = this.$refs.baseModalStatusLog
|
|
const modal = this.$refs.baseModalStatusLog
|
|
modal.base(null, {
|
|
modal.base(null, {
|
|
sbId: record.id,
|
|
sbId: record.id,
|
|
@@ -832,33 +896,33 @@ export default {
|
|
changeUserId: this.$store.getters.userInfo.userId,
|
|
changeUserId: this.$store.getters.userInfo.userId,
|
|
actualUser: this.$store.getters.userInfo.realName,
|
|
actualUser: this.$store.getters.userInfo.realName,
|
|
preStatus: record.status,
|
|
preStatus: record.status,
|
|
- afterStatus: this.DictCache.VALUE.SB_INFO_STATUS.IN_STOP,
|
|
|
|
|
|
+ afterStatus: this.DictCache.VALUE.SB_INFO_STATUS.IN_STOP
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleAdd() {
|
|
|
|
|
|
+ handleAdd () {
|
|
this.visible = false
|
|
this.visible = false
|
|
this.$refs.baseModal.base()
|
|
this.$refs.baseModal.base()
|
|
},
|
|
},
|
|
- handleView(record) {
|
|
|
|
|
|
+ handleView (record) {
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
this.visible = false
|
|
this.visible = false
|
|
const modal = this.$refs.detailModal
|
|
const modal = this.$refs.detailModal
|
|
modal.base(res.data)
|
|
modal.base(res.data)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- showChangeLog(record) {
|
|
|
|
|
|
+ showChangeLog (record) {
|
|
console.log(record)
|
|
console.log(record)
|
|
console.log(this.$refs)
|
|
console.log(this.$refs)
|
|
this.$refs.sbChangeRecordSelectModal.base({}, { sbId: record.id })
|
|
this.$refs.sbChangeRecordSelectModal.base({}, { sbId: record.id })
|
|
},
|
|
},
|
|
- handleCopy(record) {
|
|
|
|
|
|
+ handleCopy (record) {
|
|
this.visible = false
|
|
this.visible = false
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
fetchSbInfo({ id: record.id }).then((res) => {
|
|
const modal = this.$refs.baseModal
|
|
const modal = this.$refs.baseModal
|
|
modal.base(res.data, 1)
|
|
modal.base(res.data, 1)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- handleOk() {
|
|
|
|
|
|
+ handleOk () {
|
|
this.visible = true
|
|
this.visible = true
|
|
this.setTree()
|
|
this.setTree()
|
|
if (this.dateRange != null) {
|
|
if (this.dateRange != null) {
|
|
@@ -883,11 +947,11 @@ export default {
|
|
}
|
|
}
|
|
this.$refs.table.refresh()
|
|
this.$refs.table.refresh()
|
|
},
|
|
},
|
|
- onSelectChange(selectedRowKeys, selectedRows) {
|
|
|
|
|
|
+ onSelectChange (selectedRowKeys, selectedRows) {
|
|
this.selectedRowKeys = selectedRowKeys
|
|
this.selectedRowKeys = selectedRowKeys
|
|
this.selectedRows = selectedRows
|
|
this.selectedRows = selectedRows
|
|
},
|
|
},
|
|
- resetSearchForm() {
|
|
|
|
|
|
+ resetSearchForm () {
|
|
this.queryParam = {
|
|
this.queryParam = {
|
|
filter: this.filter,
|
|
filter: this.filter,
|
|
useType: this.useType,
|
|
useType: this.useType,
|
|
@@ -896,27 +960,28 @@ export default {
|
|
isSelf: this.isSelf,
|
|
isSelf: this.isSelf,
|
|
id: this.$route.query.id,
|
|
id: this.$route.query.id,
|
|
typeId: this.$route.query.typeId,
|
|
typeId: this.$route.query.typeId,
|
|
- status: this.$route.query.status || this.status,
|
|
|
|
|
|
+ status: this.$route.query.status || this.status
|
|
}
|
|
}
|
|
this.typeList = []
|
|
this.typeList = []
|
|
this.dd = undefined
|
|
this.dd = undefined
|
|
this.visible = true
|
|
this.visible = true
|
|
|
|
+ this.handleFilter(this.current)
|
|
this.$refs.table.refresh(true)
|
|
this.$refs.table.refresh(true)
|
|
},
|
|
},
|
|
- doExport() {
|
|
|
|
|
|
+ doExport () {
|
|
const parameter = {
|
|
const parameter = {
|
|
...this.queryParam,
|
|
...this.queryParam,
|
|
sbIds: this.selectedRowKeys,
|
|
sbIds: this.selectedRowKeys,
|
|
dataScope: {
|
|
dataScope: {
|
|
sortBy: 'asc',
|
|
sortBy: 'asc',
|
|
- sortName: 'no',
|
|
|
|
- },
|
|
|
|
|
|
+ sortName: 'no'
|
|
|
|
+ }
|
|
}
|
|
}
|
|
exportSbInfo(parameter).then((file) => {
|
|
exportSbInfo(parameter).then((file) => {
|
|
this.BaseTool.UPLOAD.downLoadExportExcel(file)
|
|
this.BaseTool.UPLOAD.downLoadExportExcel(file)
|
|
})
|
|
})
|
|
},
|
|
},
|
|
- setTree(record = {}) {
|
|
|
|
|
|
+ setTree (record = {}) {
|
|
queryDept({ nature: this.DictCache.VALUE.SYS_DEPT_NATURE.JITUAN }).then((res) => {
|
|
queryDept({ nature: this.DictCache.VALUE.SYS_DEPT_NATURE.JITUAN }).then((res) => {
|
|
this.areaList = res.data
|
|
this.areaList = res.data
|
|
})
|
|
})
|
|
@@ -929,7 +994,7 @@ export default {
|
|
this.queryParam.typeId = selectedKeys.length > 0 ? selectedKeys[0] : ''
|
|
this.queryParam.typeId = selectedKeys.length > 0 ? selectedKeys[0] : ''
|
|
this.$refs.table.refresh(true)
|
|
this.$refs.table.refresh(true)
|
|
},
|
|
},
|
|
- onExpand(expanded, record) {
|
|
|
|
|
|
+ onExpand (expanded, record) {
|
|
// expanded判断展开or收缩操作,record当前行数据
|
|
// expanded判断展开or收缩操作,record当前行数据
|
|
console.log(expanded)
|
|
console.log(expanded)
|
|
if (expanded) {
|
|
if (expanded) {
|
|
@@ -938,17 +1003,17 @@ export default {
|
|
})
|
|
})
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- doImport() {
|
|
|
|
|
|
+ doImport () {
|
|
this.$refs.importModal.base(null, null)
|
|
this.$refs.importModal.base(null, null)
|
|
},
|
|
},
|
|
- doImportStandard() {
|
|
|
|
|
|
+ doImportStandard () {
|
|
// this.$refs.importModalStandard.base()
|
|
// this.$refs.importModalStandard.base()
|
|
this.$refs.importModalUpdate.base(null, 1)
|
|
this.$refs.importModalUpdate.base(null, 1)
|
|
},
|
|
},
|
|
- doImportForUpdate() {
|
|
|
|
|
|
+ doImportForUpdate () {
|
|
this.$refs.importModalUpdate.base(null, 2)
|
|
this.$refs.importModalUpdate.base(null, 2)
|
|
},
|
|
},
|
|
- handleChange(value, label, extra) {
|
|
|
|
|
|
+ handleChange (value, label, extra) {
|
|
const data = this.treeData.find((item) => item.id === value)
|
|
const data = this.treeData.find((item) => item.id === value)
|
|
if (data && data.children && data.children.length > 0) {
|
|
if (data && data.children && data.children.length > 0) {
|
|
this.typeList = data.children.map((item) => item.id)
|
|
this.typeList = data.children.map((item) => item.id)
|
|
@@ -956,9 +1021,42 @@ export default {
|
|
this.typeList = [value]
|
|
this.typeList = [value]
|
|
}
|
|
}
|
|
},
|
|
},
|
|
- handleSync(record) {
|
|
|
|
|
|
+ handleSync (record) {
|
|
this.$refs.sbBomSyncSelectModal.base({ sbId: record.id })
|
|
this.$refs.sbBomSyncSelectModal.base({ sbId: record.id })
|
|
},
|
|
},
|
|
- },
|
|
|
|
|
|
+ handleFilter (key) {
|
|
|
|
+ this.current = key
|
|
|
|
+ switch (key) {
|
|
|
|
+ case 0:
|
|
|
|
+ this.queryParam.status = null
|
|
|
|
+ break
|
|
|
|
+ case 1:
|
|
|
|
+ this.queryParam.status = 1
|
|
|
|
+ break
|
|
|
|
+ case 2:
|
|
|
|
+ this.queryParam.status = 4
|
|
|
|
+ break
|
|
|
|
+ }
|
|
|
|
+ this.$refs.table.refresh()
|
|
|
|
+ }
|
|
|
|
+ }
|
|
}
|
|
}
|
|
</script>
|
|
</script>
|
|
|
|
+<style lang="less" scoped>
|
|
|
|
+.filter-icon{
|
|
|
|
+ font-size: 18px;
|
|
|
|
+ text-align: center;
|
|
|
|
+ color: #666;
|
|
|
|
+ cursor: pointer;
|
|
|
|
+ margin-bottom: 10px;
|
|
|
|
+ &>:first-child{
|
|
|
|
+ font-size: 30px;
|
|
|
|
+}
|
|
|
|
+&:hover{
|
|
|
|
+ color: #1890ff;
|
|
|
|
+}
|
|
|
|
+}
|
|
|
|
+.active{
|
|
|
|
+ color:#1890ff;
|
|
|
|
+}
|
|
|
|
+</style>
|