فهرست منبع

feat(check): 差异化调整保养任务列表及详情多处字段展示逻辑

- 保养相关页面(checkType===2)实现列展示差异化
- 保养任务显示执行人/班组列,隐藏设备部位列
- 保养记录/延期任务展示完成状态相关字段调整
- 详情页补充保养标准缺失参数及执行人/班组显示逻辑
- 检查标准列表根据checkType变更展示字段
- 修复并优化设备列表部分字段排序与显示问题

feat(repair): 优化报修单相关列表及详情字段显示和映射

- 新增故障类型紧急程度字段映射及展示
- 报修单列表及详情统一使用映射显示紧急程度和故障类型
- 维修单及检验单对应映射字典加载补充故障类型
- 报修单详情增加审批操作按钮样式与事件修正
- 细化维修费用、费用列表及故障报告操作交互
- 优化图片展示组件使用,提升体验与一致性
- 调整表格、按钮、样式格式及代码风格统一性

style(sqarepartmanage/sparepartinfo): 格式化代码及优化查询表单UI细节

- 统一输入框与选择框布局样式及间距
- 优化下拉框及树形选择控件属性缩进
- 修复部分类名及属性命名格式规范
- 调整默认列选择状态与名称匹配
- 优化字段自定义类型与使用人展示代码逻辑

refactor(sb/info): 调整设备列表查询及显示字段细节

- 隐藏设备旧号查询条件
- 调整设备位置选择显示格式及缩进
- 修改设备旧号列默认不选中
- 调整使用人、自定义类型字段位置及渲染逻辑
- 修复部分模板代码格式与排版

style(repair/application-form): 统一代码风格和格式修正

- 统一模板中的空格、缩进与换行风格
- 修正部分表达式拼接规则以确保正确输出
- 优化按钮及弹窗组件标签闭合格式
- 整理方法定义风格统一性
- 规范CSS样式书写格式及选择器合并
408249787@qq.com 3 هفته پیش
والد
کامیت
31d1cec6fe

+ 25 - 7
src/views/check/checkjob/CheckJob.vue

@@ -260,6 +260,12 @@ export default {
   },
   data() {
     this.names = ['负责', '巡检']
+    // 保养相关页面(checkType===2)列展示差异化处理:
+    // 保养任务(无 status、无 receiveOvertime)、保养记录(status=已完成)、延期任务(receiveOvertime=true)
+    const isPolling = this.checkType === 2
+    const isFinish = isPolling && this.status === DictCache.VALUE.CHECK_JOB_STATUS.FINISHED
+    const isOverTime = isPolling && this.receiveOvertime === true
+    const isPollingTask = isPolling && !isFinish && !isOverTime
     return {
       visible: true,
       // 查询参数
@@ -303,12 +309,23 @@ export default {
           checked: true,
           width: '200px'
         },
-        {
-          title: '设备部位',
-          dataIndex: 'partName',
-          checked: true,
-          width: '150px'
-        },
+        isPollingTask
+          ? {
+            title: '执行人/班组',
+            dataIndex: 'checkDeptName',
+            checked: true,
+            width: '150px',
+            customRender: (text, record) => {
+              return record.checkDeptName || record.checkUserName || '-'
+            }
+          }
+          : {
+            title: '设备部位',
+            dataIndex: 'partName',
+            // 保养记录/延期任务页面隐藏设备部位列
+            checked: !isPolling,
+            width: '150px'
+          },
         {
           title: '维护等级',
           dataIndex: 'standardLevel',
@@ -340,7 +357,8 @@ export default {
           checked: true
         }, */
         {
-          title: '负责人',
+          // 保养记录页面显示为“实际执行人”
+          title: isFinish ? '实际执行人' : '负责人',
           dataIndex: 'checkUserName',
           checked: true,
           width: '150px',

+ 5 - 2
src/views/check/checkjob/modules/Detail.vue

@@ -23,8 +23,11 @@
       <detail-list-item term="维护等级">{{ BaseTool.Object.getField(levelMap, modelStandard.level) }}</detail-list-item>
       <detail-list-item term="标准工时">{{ modelStandard.standardHours }}</detail-list-item>
       <detail-list-item term="动作类型">{{ BaseTool.Object.getField(actionTypeMap, modelStandard.actionType)
+      }}</detail-list-item>
+      <!-- 保养任务(checkType=2)同步列表页:隐藏设备部位,改显示执行人/班组(checkDeptName 优先,其次 checkUserName) -->
+      <detail-list-item v-if="checkType === 2" term="执行人/班组">{{ model.checkDeptName || model.checkUserName || '-'
         }}</detail-list-item>
-      <detail-list-item term="部位">{{ modelStandard.partName }}</detail-list-item>
+      <detail-list-item v-else term="部位">{{ modelStandard.partName }}</detail-list-item>
       <!--      <detail-list-item term="更新人">{{ model.updateUserName }}</detail-list-item>
             <detail-list-item term="创建时间">{{ model.updateTime }}</detail-list-item>
             <detail-list-item term="更新时间">{{ model.updateTime }}</detail-list-item>-->
@@ -71,7 +74,7 @@
         <badge :status="DictCache.COLOR.CHECK_JOB_STATUS[model.status]" :text="statusMap[model.status]" />
       </detail-list-item>
       <detail-list-item term="是否延期">{{ (model.receiveOvertime === null || model.receiveOvertime === 0) ? '否' : '是'
-        }}</detail-list-item>
+      }}</detail-list-item>
     </detail-list>
     <detail-list title="" :col="1">
       <detail-list-item term="检查结果">{{ model.feedback }}</detail-list-item>

+ 25 - 15
src/views/check/checkstandard/CheckStandard.vue

@@ -140,7 +140,7 @@
     <detail-standard-check-job ref="detailSbCheckJobModal" @ok="handleOk" />
     <base-form ref="baseModal" :check-type="checkType" @ok="handleOk" />
     <BatchBaseForm ref="batchBaseForm" :check-type="checkType" @ok="handleOk" />
-    <detail ref="detailModal" />
+    <detail ref="detailModal" :check-type="checkType" />
     <import-form-update ref="importModal" @ok="handleOk" />
     <BatchEditForm ref="batchEditForm" @ok="handleOk" />
   </a-card>
@@ -235,23 +235,33 @@ export default {
             return this.BaseTool.Table.getMapText(this.levelMap, text)
           },
         },
-        {
-          title: '检查标准',
-          dataIndex: 'remark',
-          checked: true,
-          width: '250px',
-          customRender: (text, record, index) => {
-            if (text != null) {
-              if (text.length > 40) {
-                return text.slice(0, 40)
+        this.checkType === 2
+          ? {
+            title: '执行人/班组',
+            dataIndex: 'checkDeptName',
+            checked: true,
+            width: '200px',
+            customRender: (text, record, index) => {
+              return record.checkDeptName || record.checkUserName || '-'
+            },
+          }
+          : {
+            title: '检查标准',
+            dataIndex: 'remark',
+            checked: true,
+            width: '250px',
+            customRender: (text, record, index) => {
+              if (text != null) {
+                if (text.length > 40) {
+                  return text.slice(0, 40)
+                } else {
+                  return text
+                }
               } else {
                 return text
               }
-            } else {
-              return text
-            }
+            },
           },
-        },
         {
           title: '计划周期',
           dataIndex: 'period',
@@ -403,7 +413,7 @@ export default {
     handleView(record) {
       fetchCheckStandard({ id: record.id }).then((res) => {
         const modal = this.$refs.detailModal
-        modal.base(res.data)
+        modal.base(res.data, record)
       })
     },
     handleViewCheckJob(record) {

+ 20 - 1
src/views/check/checkstandard/modules/Detail.vue

@@ -4,6 +4,13 @@
       <!--      <detail-list-item term="标准名称">{{ model.name }}</detail-list-item>-->
       <detail-list-item term="排序">{{ model.sort }}</detail-list-item>
       <detail-list-item term="编码">{{ model.no }}</detail-list-item>
+      <!-- 保养标准查看界面补充缺失参数 -->
+      <detail-list-item v-if="checkType === 2" term="设备编号">{{ sbInfo.sbNo }}</detail-list-item>
+      <detail-list-item v-if="checkType === 2" term="设备名称">{{ sbInfo.sbName }}</detail-list-item>
+      <detail-list-item v-if="checkType === 2" term="执行人方式">{{ BaseTool.Object.getField(checkUserTypeMap,
+        sbInfo.checkUserType) }}</detail-list-item>
+      <detail-list-item v-if="checkType === 2" term="执行人/班组">{{ sbInfo.checkUserName || sbInfo.checkDeptName || '-'
+      }}</detail-list-item>
       <!--      <detail-list-item term="检查类型">{{ BaseTool.Object.getField(typeMap,model.type) }}</detail-list-item>-->
       <detail-list-item term="维护等级">{{ BaseTool.Object.getField(levelMap, model.level) }}</detail-list-item>
       <detail-list-item term="计划周期">{{ model.period }}{{ BaseTool.Object.getField(periodTypeMap, model.periodType)
@@ -79,6 +86,15 @@ export default {
     DetailList,
     DetailListItem,
   },
+  props: {
+    /**
+     * 检查类型: 1-点检 2-保养
+     */
+    checkType: {
+      type: Number,
+      default: 1,
+    },
+  },
   data() {
     return {
       confirmLoading: false,
@@ -109,6 +125,7 @@ export default {
         updateUserName: null,
         updateTime: null,
       },
+      sbInfo: {},
       // 表头
       columns2: [
         {
@@ -190,10 +207,12 @@ export default {
       // // 不要他的底部工具栏
       // this.$viewer.options.toolbar = false
     },
-    base(record) {
+    base(record, sbInfo) {
       this.visible = true
       this.modalTitle = '详情'
       this.model = record
+      this.sbInfo = sbInfo
+
       this.data = record.detailList
     },
     handleCancel() {

+ 18 - 24
src/views/repair/application-form/RepairApplicationForm.vue

@@ -186,16 +186,22 @@ export default {
           }
         },
         {
-          title: '报修人',
+          title: '紧急程度',
           checked: true,
           width: '120px',
-          dataIndex: 'actualUser'
+          dataIndex: 'level',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Object.getField(this.levelMap, text)
+          }
         },
         {
-          title: '维修人',
+          title: '故障类型',
           checked: true,
           width: '120px',
-          dataIndex: 'repairUserName'
+          dataIndex: 'repairErrorTypeId',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Object.getField(this.faultTypeMap, text)
+          }
         },
         /*  {
             title: '报修来源',
@@ -244,30 +250,16 @@ export default {
           dataIndex: 'createdTime'
         },
         {
-          title: '接收超时',
+          title: '报修人',
           checked: true,
-          width: '100px',
-          dataIndex: 'receiveOvertime',
-          customRender: (text, record, index) => {
-            if (text) {
-              return '是'
-            } else {
-              return '否'
-            }
-          }
+          width: '120px',
+          dataIndex: 'actualUser'
         },
         {
-          title: '维修超时',
+          title: '维修人',
           checked: true,
-          width: '100px',
-          dataIndex: 'repairOvertime',
-          customRender: (text, record, index) => {
-            if (text) {
-              return '是'
-            } else {
-              return '否'
-            }
-          }
+          width: '120px',
+          dataIndex: 'repairUserName'
         },
         {
           title: '报修状态',
@@ -293,6 +285,7 @@ export default {
       statusMap: {},
       needStopMap: {},
       categoryMap: {},
+      faultTypeMap: {},
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         parameter = {
@@ -329,6 +322,7 @@ export default {
     this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_STATUS)
     this.needStopMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
     this.categoryMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_CATEGORY)
+    this.faultTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_ERROR_TYPE)
     // 获取浏览器的请求参数:报修单编号:no
     const no = this.$route.query.no
     if (no != null) {

+ 12 - 16
src/views/repair/application-form/RepairCheckForm.vue

@@ -133,29 +133,21 @@ export default {
           dataIndex: 'createdTime'
         },
         {
-          title: '接收超时',
+          title: '紧急程度',
           checked: true,
-          width: '100px',
-          dataIndex: 'receiveOvertime',
+          width: '120px',
+          dataIndex: 'level',
           customRender: (text, record, index) => {
-            if (text) {
-              return '是'
-            } else {
-              return '否'
-            }
+            return this.BaseTool.Object.getField(this.levelMap, text)
           }
         },
         {
-          title: '维修超时',
+          title: '故障类型',
           checked: true,
-          width: '100px',
-          dataIndex: 'repairOvertime',
+          width: '120px',
+          dataIndex: 'repairErrorTypeId',
           customRender: (text, record, index) => {
-            if (text === true) {
-              return '是'
-            } else {
-              return '否'
-            }
+            return this.BaseTool.Object.getField(this.faultTypeMap, text)
           }
         },
         {
@@ -179,6 +171,8 @@ export default {
       // 下拉框map
       statusMap: {},
       planFlagMap: {},
+      levelMap: {},
+      faultTypeMap: {},
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         return getRepairApplicationFormPage({
@@ -197,6 +191,8 @@ export default {
     // 下拉框map:仅保留列表中实际渲染用到的字典
     this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_STATUS)
     this.planFlagMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_CATEGORY)
+    this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_LEVEL)
+    this.faultTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_ERROR_TYPE)
     // 获取浏览器的请求参数:报修单编号:no
     const no = this.$route.query.no
     if (no != null) {

+ 20 - 26
src/views/repair/application-form/RepairForm.vue

@@ -71,8 +71,8 @@
       </div>
 
       <div class="table-operator">
-        <a-button v-if="$auth('repair-application-forms-add') && filter != 0 && searchType != 2" type="primary" icon="plus"
-          @click="$refs.baseModal.base({}, { filter: -1 })">新增</a-button>
+        <a-button v-if="$auth('repair-application-forms-add') && filter != 0 && searchType != 2" type="primary"
+          icon="plus" @click="$refs.baseModal.base({}, { filter: -1 })">新增</a-button>
         <a-button style="margin-left: 8px" v-if="$auth('repair-application-forms-export')" type="primary"
           icon="download" @click="doExport">导出</a-button>
         <a-dropdown v-action:edit v-if="selectedRowKeys.length > 0 && $auth('repair-application-forms-del')">
@@ -199,16 +199,22 @@ export default {
           }
         },
         {
-          title: '报修人',
+          title: '紧急程度',
           checked: true,
           width: '120px',
-          dataIndex: 'actualUser'
+          dataIndex: 'level',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Object.getField(this.levelMap, text)
+          }
         },
         {
-          title: '维修人',
+          title: '故障类型',
           checked: true,
           width: '120px',
-          dataIndex: 'repairUserName'
+          dataIndex: 'repairErrorTypeId',
+          customRender: (text, record, index) => {
+            return this.BaseTool.Object.getField(this.faultTypeMap, text)
+          }
         },
         {
           title: '工单类型',
@@ -248,30 +254,16 @@ export default {
           dataIndex: 'createdTime'
         },
         {
-          title: '接收超时',
+          title: '报修人',
           checked: true,
-          width: '100px',
-          dataIndex: 'receiveOvertime',
-          customRender: (text, record, index) => {
-            if (text) {
-              return '是'
-            } else {
-              return '否'
-            }
-          }
+          width: '120px',
+          dataIndex: 'actualUser'
         },
         {
-          title: '维修超时',
+          title: '维修人',
           checked: true,
-          width: '100px',
-          dataIndex: 'repairOvertime',
-          customRender: (text, record, index) => {
-            if (text) {
-              return '是'
-            } else {
-              return '否'
-            }
-          }
+          width: '120px',
+          dataIndex: 'repairUserName'
         },
         {
           title: '报修状态',
@@ -297,6 +289,7 @@ export default {
       statusMap: {},
       needStopMap: {},
       planFlagMap: {},
+      faultTypeMap: {},
       // 部门下拉数据
       deptList: [],
       // 加载数据方法 必须为 Promise 对象
@@ -337,6 +330,7 @@ export default {
     this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_STATUS)
     this.needStopMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.YES_NO)
     this.planFlagMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_CATEGORY)
+    this.faultTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_ERROR_TYPE)
     // 获取浏览器的请求参数:报修单编号:no
     const no = this.$route.query.no
     if (no != null) {

+ 78 - 78
src/views/repair/application-form/modules/DetailCheck.vue

@@ -4,11 +4,16 @@
       <a-row :gutter="48" slot="extra">
         <a-col :md="48" :sm="48">
           <span class="table-page-search-submitButtons" style="float: right">
-            <a-button v-if="$auth('repair-application-forms-edit')" style="margin-left: 8px" type="primary" @click="handleEdit()">修改</a-button>
-            <a-popconfirm v-if="$auth('repair-application-forms-approve') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.NOT_ACCEPTANCE === model.status" title="是否要接受?" @confirm="handleApprove">
+            <a-button v-if="$auth('repair-application-forms-edit')" style="margin-left: 8px" type="primary"
+              @click="handleEdit()">修改</a-button>
+            <a-popconfirm
+              v-if="$auth('repair-application-forms-approve') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.NOT_ACCEPTANCE === model.status"
+              title="是否要接受?" @confirm="handleApprove">
               <a-button :loading="confirmLoading" style="margin-left: 8px" type="primary">接受</a-button>
             </a-popconfirm>
-            <a-popconfirm v-if="$auth('repair-application-forms-reback') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.NOT_ACCEPTANCE === model.status" title="是否要拒绝?" @confirm="handleReturn">
+            <a-popconfirm
+              v-if="$auth('repair-application-forms-reback') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.NOT_ACCEPTANCE === model.status"
+              title="是否要拒绝?" @confirm="handleReturn">
               <a-button style="margin-left: 8px" type="error">拒绝</a-button>
             </a-popconfirm>
             <a-button style="margin-left: 8px" @click="handleCancel">返回</a-button>
@@ -24,13 +29,22 @@
             <detail-list-item term="设备名称">{{ model.sbName }}</detail-list-item>
             <detail-list-item term="使用位置">{{ model.sbCph }}</detail-list-item>
             <!--<detail-list-item term="部件名称">{{ model.partName }}</detail-list-item>-->
-            <detail-list-item term="工单类别">{{ BaseTool.Object.getField(planFlagMap,model.category) }}</detail-list-item>
+            <detail-list-item term="工单类别">{{ BaseTool.Object.getField(planFlagMap, model.category) }}</detail-list-item>
             <!--            <detail-list-item term="是否停机">{{ BaseTool.Object.getField(needStopMap,model.needStop) }}</detail-list-item>-->
             <detail-list-item term="报修人">{{ model.actualUser }}</detail-list-item>
+            <detail-list-item term="紧急程度">
+              <badge :text="BaseTool.Object.getField(levelMap, model.level)"
+                :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_LEVEL[model.level]" />
+            </detail-list-item>
+            <detail-list-item term="故障类型">{{ BaseTool.Object.getField(faultTypeMap, model.repairErrorTypeId)
+              }}</detail-list-item>
             <!-- <detail-list-item term="报修来源">{{ BaseTool.Object.getField(this.sourceMap, model.source) }}</detail-list-item>
                        <detail-list-item term="紧急等级"><badge :text="BaseTool.Object.getField(levelMap,model.level)" :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_LEVEL[model.applicationLevel]"/></detail-list-item>-->
             <detail-list-item term="报修时间">{{ model.applyTime }}</detail-list-item>
-            <detail-list-item term="报修状态"><badge :text="BaseTool.Object.getField(statusMap, model.status)" :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_STATUS[model.status]"/></detail-list-item>
+            <detail-list-item term="报修状态">
+              <badge :text="BaseTool.Object.getField(statusMap, model.status)"
+                :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_STATUS[model.status]" />
+            </detail-list-item>
             <detail-list-item term="要求完成时间">{{ model.limitHours }}小时</detail-list-item>
             <detail-list-item term="预计完成日期">{{ model.limitDate }}</detail-list-item>
           </detail-list>
@@ -41,11 +55,12 @@
           <title-divider title="报修图片" width="90px"></title-divider>
           <detail-list title="" :col="1">
             <detail-list-item term="" v-if="model.applicationFileList != null && model.applicationFileList.length > 0">
-              <viewer :images="model.applicationFileList" @inited="inited" ref="viewer" :index="1" >
+              <viewer :images="model.applicationFileList" @inited="inited" ref="viewer" :index="1">
                 <img v-for="item in model.applicationFileList" :src="item.url" :key="item.id" class="image">
               </viewer>
             </detail-list-item>
-            <detail-list-item term="" v-if="model.applicationFileList == null || model.applicationFileList.length === 0">
+            <detail-list-item term=""
+              v-if="model.applicationFileList == null || model.applicationFileList.length === 0">
               暂无
             </detail-list-item>
           </detail-list>
@@ -64,7 +79,7 @@
           <title-divider title="维修图片" width="90px"></title-divider>
           <detail-list title="" :col="1">
             <detail-list-item term="" v-if="model.repairFileList != null && model.repairFileList.length > 0">
-              <viewer :images="model.repairFileList" @inited="inited" ref="viewer" :index="1" >
+              <viewer :images="model.repairFileList" @inited="inited" ref="viewer" :index="1">
                 <img v-for="item in model.repairFileList" :src="item.url" :key="item.id" class="image">
               </viewer>
             </detail-list-item>
@@ -91,18 +106,18 @@
             <detail-list-item term="审核人员">{{ model.checkUserName }}</detail-list-item>
             <detail-list-item term="审核描述">{{ model.checkContent }}</detail-list-item>
           </detail-list>
-<!--          <detail-list title="审核图片:" :col="6">
+          <!--          <detail-list title="审核图片:" :col="6">
             <upload-image-detail :images-list="model.checkFileList"/>
           </detail-list>-->
         </a-layout-content>
         <a-layout-sider style="background-color: rgb(255, 255, 255)">
           <div style="margin-top: 30px;margin-left: 30px;">
-            <a-steps progress-dot :current="6" direction="vertical" >
-              <a-step title="报修时间:" :description="''+model.applyTime?model.applyTime:''" />
-              <a-step title="维修开始时间:" :description="''+model.repairStartTime?model.repairStartTime:''" />
-              <a-step title="维修结束时间:" :description="''+model.repairEndTime?model.repairEndTime:''" />
-              <a-step title="审核开始时间:" :description="''+model.checkStartTime?model.checkStartTime:''" />
-              <a-step title="审核结束时间:" :description="''+model.checkEndTime?model.checkEndTime:''" />
+            <a-steps progress-dot :current="6" direction="vertical">
+              <a-step title="报修时间:" :description="'' + model.applyTime ? model.applyTime : ''" />
+              <a-step title="维修开始时间:" :description="'' + model.repairStartTime ? model.repairStartTime : ''" />
+              <a-step title="维修结束时间:" :description="'' + model.repairEndTime ? model.repairEndTime : ''" />
+              <a-step title="审核开始时间:" :description="'' + model.checkStartTime ? model.checkStartTime : ''" />
+              <a-step title="审核结束时间:" :description="'' + model.checkEndTime ? model.checkEndTime : ''" />
             </a-steps>
           </div>
         </a-layout-sider>
@@ -110,65 +125,47 @@
       <title-divider title="配件清单" width="90px"></title-divider>
       <div class="table-operator" v-if="$auth('repair-application-forms-finish')">
         <a-button type="primary" @click="handleSpareSelect">
-          <a-icon type="plus"/>
+          <a-icon type="plus" />
           添加
         </a-button>
       </div>
-      <a-table
-        :data-source="dataSpare"
-        :columns="columnsSpare"
-        tableLayout="auto"
-        rowKey="id">
+      <a-table :data-source="dataSpare" :columns="columnsSpare" tableLayout="auto" rowKey="id">
       </a-table>
       <title-divider title="费用清单" width="90px"></title-divider>
-      <div class="table-operator" v-if="$auth('repair-application-forms-finish') ">
+      <div class="table-operator" v-if="$auth('repair-application-forms-finish')">
         <a-button type="primary" @click="handleAddFee">
-          <a-icon type="plus"/>
+          <a-icon type="plus" />
           添加
         </a-button>
       </div>
-      <a-table
-        :data-source="dataFee"
-        :columns="columnsFee"
-        tableLayout="auto"
-        rowKey="id">
+      <a-table :data-source="dataFee" :columns="columnsFee" tableLayout="auto" rowKey="id">
         <span slot="action" slot-scope="record">
           <template>
             <a @click="handleViewFee(record)">查看</a>
-            <operation-button
-              v-if="$auth('repair-application-forms-finish')"
-              @click="handleEditFee(record)" >修改</operation-button>
-            <operation-button
-              v-if="$auth('repair-application-forms-finish')"
-              :type="2"
-              title="确认删除该笔费用?"
-              @confirm="batchDeleteFee(record.id)" >删除</operation-button>
+            <operation-button v-if="$auth('repair-application-forms-finish')"
+              @click="handleEditFee(record)">修改</operation-button>
+            <operation-button v-if="$auth('repair-application-forms-finish')" :type="2" title="确认删除该笔费用?"
+              @confirm="batchDeleteFee(record.id)">删除</operation-button>
           </template>
         </span>
       </a-table>
       <title-divider title="维修报告" width="90px"></title-divider>
-      <div class="table-operator" >
-        <a-button type="primary" v-if="$auth('repair-repair-reasons-add') && ((dataReason === null) || (dataReason.length===0))" @click="handleAddReason">
-          <a-icon type="plus"/>
+      <div class="table-operator">
+        <a-button type="primary"
+          v-if="$auth('repair-repair-reasons-add') && ((dataReason === null) || (dataReason.length === 0))"
+          @click="handleAddReason">
+          <a-icon type="plus" />
           添加
         </a-button>
       </div>
-      <a-table
-        :data-source="dataReason"
-        :columns="columnsReason"
-        tableLayout="fixed"
-        rowKey="id">
+      <a-table :data-source="dataReason" :columns="columnsReason" tableLayout="fixed" rowKey="id">
         <span slot="action" slot-scope="record">
           <template>
             <a @click="handleViewReason(record)">查看</a>
-            <operation-button
-              v-if="$auth('repair-repair-reasons-edit')"
-              @click="handleEditReason(record)" >修改</operation-button>
-            <operation-button
-              v-if="$auth('repair-repair-reasons-del')"
-              :type="2"
-              title="确认删除该记录?"
-              @confirm="batchDeleteReason(record.id)" >删除</operation-button>
+            <operation-button v-if="$auth('repair-repair-reasons-edit')"
+              @click="handleEditReason(record)">修改</operation-button>
+            <operation-button v-if="$auth('repair-repair-reasons-del')" :type="2" title="确认删除该记录?"
+              @confirm="batchDeleteReason(record.id)">删除</operation-button>
           </template>
         </span>
       </a-table>
@@ -216,7 +213,7 @@ export default {
     SparePartUsedSelectTable,
     SparePickFormSelectTable
   },
-  data () {
+  data() {
     return {
       confirmLoading: false,
       mdl: {},
@@ -230,6 +227,7 @@ export default {
       // 下拉框map
       sourceMap: {},
       levelMap: {},
+      faultTypeMap: {},
       descripitionMap: {},
       statusMap: {},
       typeMap: {},
@@ -418,10 +416,11 @@ export default {
       }
     }
   },
-  created () {
+  created() {
     // 下拉框map
     this.sourceMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_SOURCE)
     this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_LEVEL)
+    this.faultTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_ERROR_TYPE)
     this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_STATUS)
     this.statusRepairMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_FORM_STATUS)
     this.statusCheckMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_CHECK_STATUS)
@@ -434,14 +433,14 @@ export default {
     this.planFlagMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_CATEGORY)
   },
   methods: {
-    base (record) {
+    base(record) {
       this.visible = true
       this.modalTitle = '详情'
       this.model = record
       this.dispatchList = JSON.parse(record.repairDispatchList)
       this.init()
     },
-    init () {
+    init() {
       selectRepairProjectListByRepairId({ id: this.model.id }).then(res => {
         this.data = res.data
       })
@@ -455,18 +454,18 @@ export default {
         this.dataReason = res.data
       })
     },
-    handleCancel () {
+    handleCancel() {
       this.visible = false
       this.confirmLoading = false
       this.$emit('ok')
     },
-    receive () {
+    receive() {
       receive(this.model).then(() => {
         this.$message.info('任务接收成功,请及时维修')
         this.handleOk()
       })
     },
-    batchDeleteFee (id) {
+    batchDeleteFee(id) {
       let ids = []
       if (this.BaseTool.String.isBlank(id)) {
         const length = this.selectedRows.length
@@ -484,23 +483,23 @@ export default {
         this.$refs.table.clearSelected()
       })
     },
-    handleAddFee () {
+    handleAddFee() {
       const modal = this.$refs.feeForm
       modal.base(null, this.model)
     },
-    handleEditFee (record) {
+    handleEditFee(record) {
       fetchRepairFee({ id: record.id }).then(res => {
         const modal = this.$refs.feeForm
         modal.base(res.data, this.model)
       })
     },
-    handleViewFee (record) {
+    handleViewFee(record) {
       fetchRepairFee({ id: record.id }).then(res => {
         const modal = this.$refs.feeDetail
         modal.base(res.data)
       })
     },
-    batchDeleteReason (id) {
+    batchDeleteReason(id) {
       let ids = []
       if (this.BaseTool.String.isBlank(id)) {
         const length = this.selectedRows.length
@@ -518,25 +517,25 @@ export default {
         this.$refs.table.clearSelected()
       })
     },
-    handleAddReason () {
+    handleAddReason() {
       const modal = this.$refs.reasonForm
       this.visible = false
       modal.base(null, this.model)
     },
-    handleEditReason (record) {
+    handleEditReason(record) {
       fetchRepairReason({ id: record.id }).then(res => {
         const modal = this.$refs.reasonForm
         this.visible = false
         modal.base(res.data, this.model)
       })
     },
-    handleViewReason (record) {
+    handleViewReason(record) {
       fetchRepairReason({ id: record.id }).then(res => {
         const modal = this.$refs.reasonDetail
         modal.base(res.data)
       })
     },
-    handleApprove () {
+    handleApprove() {
       this.confirmLoading = true
       approve(this.model).then(() => {
         this.$message.info('操作成功')
@@ -544,11 +543,11 @@ export default {
         this.handleOk()
       })
     },
-    handleReturn () {
+    handleReturn() {
       const modal = this.$refs.checkForm
       modal.base(this.model)
     },
-    handleOk () {
+    handleOk() {
       this.loading = true
       fetchRepairApplicationForm({ id: this.model.id }).then(res => {
         this.loading = false
@@ -558,18 +557,18 @@ export default {
         this.init()
       })
     },
-    handleEdit () {
+    handleEdit() {
       const modal = this.$refs.editForm
       modal.base(this.model)
     },
-    handleSpareSelect () {
+    handleSpareSelect() {
       this.$refs.spareSelectModal.base()
     },
-    handleDispatch () {
+    handleDispatch() {
       const modal = this.$refs.dispatchForm
       modal.base(this.model)
     },
-    changeTab (activeKey) {
+    changeTab(activeKey) {
       this.activeKey = activeKey
       if (this.activeKey === 'a' && this.BaseTool.Object.isNotBlank(this.$refs.sparePartUsedSelectTable)) {
         const modal = this.$refs.sparePartUsedSelectTable
@@ -581,16 +580,16 @@ export default {
         modal.handleOk()
       }
     },
-    inited (viewer) {
+    inited(viewer) {
       this.$viewer = viewer
     },
     // 转派记录审批状态文字:pending-待审批 approved-已通过 rejected-已驳回;老数据无 status 字段时按已通过展示(早期转派无审批流程)
-    getTransferStatusText (status) {
+    getTransferStatusText(status) {
       if (status === 'pending') return '待审批'
       if (status === 'rejected') return '已驳回'
       return '已通过'
     },
-    getTransferBadgeStatus (status) {
+    getTransferBadgeStatus(status) {
       if (status === 'pending') return 'warning'
       if (status === 'rejected') return 'error'
       return 'success'
@@ -604,14 +603,15 @@ export default {
   width: 300px;
   height: 300px;
 }
-.ant-carousel >>> .slick-slide {
+
+.ant-carousel>>>.slick-slide {
   text-align: center;
   height: 300px;
   line-height: 300px;
   overflow: hidden;
 }
 
-.ant-carousel >>> .slick-slide h3 {
+.ant-carousel>>>.slick-slide h3 {
   color: #fff;
 }
 

+ 8 - 0
src/views/repair/application-form/modules/DetailRepair.vue

@@ -53,6 +53,12 @@
             <detail-list-item term="工单类别">{{ BaseTool.Object.getField(planFlagMap, model.category) }}</detail-list-item>
             <!--            <detail-list-item term="是否停机">{{ BaseTool.Object.getField(needStopMap,model.needStop) }}</detail-list-item>-->
             <detail-list-item term="报修人">{{ model.actualUser }}</detail-list-item>
+            <detail-list-item term="紧急程度">
+              <badge :text="BaseTool.Object.getField(levelMap, model.level)"
+                :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_LEVEL[model.level]" />
+            </detail-list-item>
+            <detail-list-item term="故障类型">{{ BaseTool.Object.getField(faultTypeMap, model.repairErrorTypeId)
+              }}</detail-list-item>
             <!--            <detail-list-item term="报修来源">{{ BaseTool.Object.getField(this.sourceMap, model.source) }}</detail-list-item>
             <detail-list-item term="紧急等级"><badge :text="BaseTool.Object.getField(levelMap,model.level)" :status="DictCache.COLOR.REPAIR_APPLICATION_FORM_LEVEL[model.applicationLevel]"/></detail-list-item>-->
             <detail-list-item term="报修时间">{{ model.applyTime }}</detail-list-item>
@@ -337,6 +343,7 @@ export default {
       sourceMap: {},
       typeMap: {},
       levelMap: {},
+      faultTypeMap: {},
       descripitionMap: {},
       selectedRowKeys: [],
       statusMap: {},
@@ -576,6 +583,7 @@ export default {
     // 下拉框map
     this.sourceMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_SOURCE)
     this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_LEVEL)
+    this.faultTypeMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_ERROR_TYPE)
     this.statusMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_APPLICATION_FORM_STATUS)
     this.statusRepairMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_FORM_STATUS)
     this.statusCheckMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.REPAIR_CHECK_STATUS)

+ 17 - 14
src/views/sb/info/SbInfo.vue

@@ -21,11 +21,13 @@
                     <a-input v-model="queryParam.keyword" placeholder="名称/设备新号" />
                   </a-form-item>
                 </a-col>
+                <!-- 设备旧号查询条件已隐藏
                 <a-col :md="6" :sm="24">
                   <a-form-item label="设备旧号">
                     <a-input v-model="queryParam.zbh" placeholder="设备旧号" />
                   </a-form-item>
                 </a-col>
+                -->
                 <a-col :md="6" :sm="24">
                   <a-form-item label="第一维修人">
                     <a-input v-model="queryParam.repairUserName" placeholder="第一维修人" />
@@ -62,7 +64,8 @@
                 <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 v-for="({ id, name }) in sbPositionData" :key="id" :label="name" :value="id">{{
+                        name
                         }}
                       </a-select-option>
                     </a-select>
@@ -86,7 +89,7 @@
                     <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 }}
+                          label }}
                       </a-select-option>
                     </a-select>
                   </a-form-item>
@@ -247,14 +250,14 @@
             :filter-option="filterPositionOption" option-filter-prop="children" placeholder="请选择设备位置"
             style="width: 100%">
             <a-select-option v-for="item in sbPositionData" :key="item.id" :value="item.id">{{ item.name
-              }}</a-select-option>
+            }}</a-select-option>
           </a-select>
         </a-form-item>
         <a-divider orientation="left">底图与显示</a-divider>
         <a-form-item label="选择底图" :label-col="{ span: 4 }" :wrapper-col="{ span: 18 }">
           <a-select v-model="initPointsData.mapName" placeholder="请选择底图" style="width: 100%">
             <a-select-option v-for="item in mapNameList" :key="item.targetId" :value="item.targetId">{{ item.targetId
-              }}</a-select-option>
+            }}</a-select-option>
           </a-select>
         </a-form-item>
         <a-form-item label="是否显示" :label-col="{ span: 4 }" :wrapper-col="{ span: 18 }">
@@ -381,7 +384,7 @@ export default {
           title: '设备旧号',
           dataIndex: 'zbh',
           width: 120,
-          checked: true
+          checked: false
         },
         {
           title: '设备类型',
@@ -408,13 +411,10 @@ export default {
           checked: true
         },
         {
-          title: '自定义类型',
+          title: '使用人',
           checked: true,
-          dataIndex: 'useType',
-          width: 150,
-          customRender: (text, record, index) => {
-            return this.BaseTool.Object.getField(this.useTypeMap, text)
-          }
+          width: 200,
+          dataIndex: 'saveUserName'
         },
         {
           title: '维修负责人',
@@ -435,10 +435,13 @@ export default {
           dataIndex: 'positionName'
         },
         {
-          title: '使用机台',
+          title: '自定义类型',
           checked: true,
-          width: 200,
-          dataIndex: 'saveUserName'
+          dataIndex: 'useType',
+          width: 150,
+          customRender: (text, record, index) => {
+            return this.BaseTool.Object.getField(this.useTypeMap, text)
+          }
         },
         {
           title: '生产商',

+ 74 - 90
src/views/sqarepartmanage/sparepartinfo/SparePartInfo.vue

@@ -17,55 +17,46 @@
             <a-row :gutter="48">
               <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">
                 <a-form-item label="品牌">
-                  <a-input v-model="queryParam.brand" placeholder="模糊查询"/>
+                  <a-input v-model="queryParam.brand" placeholder="模糊查询" />
                 </a-form-item>
               </a-col>
               <a-col :md="8" :sm="24">
                 <a-form-item label="类型">
-                  <a-tree-select
-                    style="width: 100%"
-                    :dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }"
-                    :treeData="spareTypeTreeData"
-                    :treeNodeFilterProp="'title'"
-                    :showSearch="true"
-                    v-model="queryParam.typeId"
-                    placeholder="请选择"
-                  >
+                  <a-tree-select style="width: 100%" :dropdownStyle="{ maxHeight: '400px', overflow: 'auto' }"
+                    :treeData="spareTypeTreeData" :treeNodeFilterProp="'title'" :showSearch="true"
+                    v-model="queryParam.typeId" placeholder="请选择">
                   </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-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-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-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-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"
+                    <a-select-option v-for="(label, value) in levelMap" :key="value" :label="label"
                       :value="parseInt(value)">{{ label }}
                     </a-select-option>
                   </a-select>
@@ -74,10 +65,7 @@
               <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"
+                    <a-select-option v-for="(label, value) in ytMap" :key="value" :label="label"
                       :value="parseInt(value)">{{ label }}
                     </a-select-option>
                   </a-select>
@@ -86,10 +74,7 @@
               <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"
+                    <a-select-option v-for="(label, value) in specialMap" :key="value" :label="label"
                       :value="parseInt(value)">{{ label }}
                     </a-select-option>
                   </a-select>
@@ -97,7 +82,7 @@
               </a-col>
               <a-col :md="6" :sm="24">
                 <a-form-item label="关联设备">
-                  <a-input v-model="queryParam.model" placeholder="新号/旧号/名称/规格"/>
+                  <a-input v-model="queryParam.model" placeholder="新号/旧号/名称/规格" />
                 </a-form-item>
               </a-col>
               <a-col :md="6 || 24" :sm="24">
@@ -112,14 +97,20 @@
         </div>
 
         <div class="table-operator">
-          <a-button v-if="$auth('sqarepartmanage-spare-part-info-add')" type="primary" icon="plus" @click="handleAdd">新增</a-button>
-          <a-button style="margin-left: 8px" v-if="$auth('sqarepartmanage-spare-part-info-export')" type="primary" icon="download" @click="doExport">导出</a-button>
-          <a-button style="margin-left: 8px" v-if="$auth('sqarepartmanage-spare-part-info-export')" type="primary" icon="upload" @click="doImport">初始化新增导入</a-button>
-          <a-button style="margin-left: 8px" v-if="$auth('sqarepartmanage-spare-part-info-export')" type="primary" icon="upload" @click="doImportForUpdate">修改导入</a-button>
-          <a-button style="margin-left: 8px" type="primary" icon="download" @click="doDownloadImportTemplate">导入模板下载</a-button>
+          <a-button v-if="$auth('sqarepartmanage-spare-part-info-add')" type="primary" icon="plus"
+            @click="handleAdd">新增</a-button>
+          <a-button style="margin-left: 8px" v-if="$auth('sqarepartmanage-spare-part-info-export')" type="primary"
+            icon="download" @click="doExport">导出</a-button>
+          <a-button style="margin-left: 8px" v-if="$auth('sqarepartmanage-spare-part-info-export')" type="primary"
+            icon="upload" @click="doImport">初始化新增导入</a-button>
+          <a-button style="margin-left: 8px" v-if="$auth('sqarepartmanage-spare-part-info-export')" type="primary"
+            icon="upload" @click="doImportForUpdate">修改导入</a-button>
+          <a-button style="margin-left: 8px" type="primary" icon="download"
+            @click="doDownloadImportTemplate">导入模板下载</a-button>
           <!--          <a-button style="margin-left: 8px" v-if="selectedRowKeys.length > 0 && $auth('sqarepartmanage-spare-part-info-del')" type="primary" icon="upload" @click="handleSpareSelect">批量矫正</a-button>-->
           <a-button style="margin-left: 8px" type="primary" icon="printer" @click="handlePrintBatch()">批量打印</a-button>
-          <a-button style="margin-left: 8px" v-if="$auth('sb-infos-generate-code-all')" :loading="confirmLoading" type="primary" @click="batchGenerate()">重新生成二维码</a-button>
+          <a-button style="margin-left: 8px" v-if="$auth('sb-infos-generate-code-all')" :loading="confirmLoading"
+            type="primary" @click="batchGenerate()">重新生成二维码</a-button>
           <a-dropdown v-action:edit v-if="selectedRowKeys.length > 0 && $auth('sqarepartmanage-spare-part-info-del')">
             <a-menu slot="overlay">
               <a-popconfirm title="是否要删除所选数据?" @confirm="batchDelete()">
@@ -132,19 +123,11 @@
           </a-dropdown>
         </div>
 
-        <s-table
-          ref="table"
-          size="default"
-          rowKey="id"
-          :columns="columns"
-          :data="loadData"
-          :scroll="{x: 1500, y: BaseTool.Constant.scrollY}"
-          :alert="options.alert"
-          :rowSelection="options.rowSelection"
-          showPagination="auto"
-        >
+        <s-table ref="table" size="default" rowKey="id" :columns="columns" :data="loadData"
+          :scroll="{ x: 1500, y: BaseTool.Constant.scrollY }" :alert="options.alert" :rowSelection="options.rowSelection"
+          showPagination="auto">
           <span slot="status" slot-scope="text, record">
-            <a @click="handleStore(record)">{{ text||"0" }}</a>
+            <a @click="handleStore(record)">{{ text || "0" }}</a>
           </span>
           <span slot="action" slot-scope="record">
             <template>
@@ -152,7 +135,8 @@
               <a-divider v-if="$auth('sqarepartmanage-spare-part-info-edit')" type="vertical" />
               <a v-if="$auth('sqarepartmanage-spare-part-info-edit')" @click="handleEdit(record)">修改</a>
               <a-divider v-if="$auth('sqarepartmanage-spare-part-info-del')" type="vertical" />
-              <a-popconfirm v-if="$auth('sqarepartmanage-spare-part-info-del')" title="是否要删除该条数据?" @confirm="batchDelete(record.id)">
+              <a-popconfirm v-if="$auth('sqarepartmanage-spare-part-info-del')" title="是否要删除该条数据?"
+                @confirm="batchDelete(record.id)">
                 <a>删除</a>
               </a-popconfirm>
               <a-divider type="vertical" />
@@ -164,17 +148,17 @@
         </s-table>
       </a-col>
     </a-row>
-    <base-form ref="baseModal" @ok="handleOk"/>
-    <detail ref="detailModal" @ok="handleOk"/>
-    <detail-bom ref="detailBomModal" @ok="handleOk"/>
-    <storeList ref="storeListModal"/>
-    <inStoreList ref="inStoreListModal"/>
-    <outStoreList ref="outStoreListModal"/>
-    <spare-part-used-select-modal ref="sparePartUsedSelectModal"/>
-    <spare-part-info-select-modal-for-adjust :type="'radio'" ref="spareSelectModal" @selected="handleSpareSelected"/>
-    <import-form-add ref="importModal" @ok="handleOk"/>
-    <import-form-update ref="importModalForUpdate" @ok="handleOk"/>
-    <print-in-spare-batch ref="printInSbInfoBatch" @ok="handleOk"/>
+    <base-form ref="baseModal" @ok="handleOk" />
+    <detail ref="detailModal" @ok="handleOk" />
+    <detail-bom ref="detailBomModal" @ok="handleOk" />
+    <storeList ref="storeListModal" />
+    <inStoreList ref="inStoreListModal" />
+    <outStoreList ref="outStoreListModal" />
+    <spare-part-used-select-modal ref="sparePartUsedSelectModal" />
+    <spare-part-info-select-modal-for-adjust :type="'radio'" ref="spareSelectModal" @selected="handleSpareSelected" />
+    <import-form-add ref="importModal" @ok="handleOk" />
+    <import-form-update ref="importModalForUpdate" @ok="handleOk" />
+    <print-in-spare-batch ref="printInSbInfoBatch" @ok="handleOk" />
   </a-card>
 </template>
 
@@ -222,7 +206,7 @@ export default {
     SparePartInfoSelectModalForAdjust,
     ImportFormUpdate
   },
-  data () {
+  data() {
     return {
       // 查询参数
       queryParam: {
@@ -246,12 +230,6 @@ export default {
           dataIndex: 'no'
         },
         {
-          title: '品牌',
-          width: '150px',
-          checked: true,
-          dataIndex: 'brand'
-        },
-        {
           title: '备件名称',
           width: '150px',
           checked: true,
@@ -347,6 +325,12 @@ export default {
           width: '150px'
         },
         {
+          title: '品牌',
+          width: '150px',
+          checked: true,
+          dataIndex: 'brand'
+        },
+        {
           title: '操作',
           checked: true,
           width: '250px',
@@ -393,7 +377,7 @@ export default {
       optionAlertShow: false
     }
   },
-  created () {
+  created() {
     // 下拉框map
     this.levelMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SPARE_PART_INFO_LEVEL)
     this.unitMap = this.DictCache.getLabelByValueMapByType(this.DictCache.TYPE.SBINFO_UNIT)
@@ -406,7 +390,7 @@ export default {
     })
   },
   methods: {
-    tableOption () {
+    tableOption() {
       if (!this.optionAlertShow) {
         this.options = {
           alert: { show: true, clear: () => { this.selectedRowKeys = [] } },
@@ -430,7 +414,7 @@ export default {
         this.optionAlertShow = false
       }
     },
-    batchDelete (id) {
+    batchDelete(id) {
       let ids = []
       if (this.BaseTool.String.isBlank(id)) {
         const length = this.selectedRows.length
@@ -448,19 +432,19 @@ export default {
         this.$refs.table.clearSelected()
       })
     },
-    handleEdit (record) {
+    handleEdit(record) {
       this.visible = false
       fetchSparePartInfo2({ id: record.id }).then(res => {
         const modal = this.$refs.baseModal
         modal.base(res.data)
       })
     },
-    handleDetailBom (record) {
+    handleDetailBom(record) {
       this.visible = false
       const modal = this.$refs.detailBomModal
       modal.base(record)
     },
-    handleCopy (record) {
+    handleCopy(record) {
       this.visible = false
       fetchSparePartInfo2({ id: record.id }).then(res => {
         const modal = this.$refs.baseModal
@@ -468,47 +452,47 @@ export default {
         modal.base(res.data)
       })
     },
-    handleStore (record) {
+    handleStore(record) {
       fetchStoreList({ id: record.id }).then(res => {
         const modal = this.$refs.storeListModal
         modal.base(res.data)
       })
     },
-    handleInStore (record) {
+    handleInStore(record) {
       fetchInStoreList({ id: record.id }).then(res => {
         const modal = this.$refs.inStoreListModal
         modal.base(res.data)
       })
     },
-    handleSparePartUsed (record) {
+    handleSparePartUsed(record) {
       this.$refs.sparePartUsedSelectModal.base({}, { spareId: record.id })
     },
-    handleOutStore (record) {
+    handleOutStore(record) {
       fetchOutStoreList({ id: record.id }).then(res => {
         const modal = this.$refs.outStoreListModal
         modal.base(res.data)
       })
     },
-    handleAdd (record) {
+    handleAdd(record) {
       this.visible = false
       this.$refs.baseModal.base()
     },
-    handleView (record) {
+    handleView(record) {
       this.visible = false
       fetchSparePartInfo2({ id: record.id }).then(res => {
         const modal = this.$refs.detailModal
         modal.base(res.data)
       })
     },
-    handleOk () {
+    handleOk() {
       this.visible = true
       this.$refs.table.refresh()
     },
-    onSelectChange (selectedRowKeys, selectedRows) {
+    onSelectChange(selectedRowKeys, selectedRows) {
       this.selectedRowKeys = selectedRowKeys
       this.selectedRows = selectedRows
     },
-    resetSearchForm () {
+    resetSearchForm() {
       this.queryParam = {
       }
       this.$refs.table.refresh(true)
@@ -518,11 +502,11 @@ export default {
       this.queryParam.typeId = selectedKeys.length > 0 ? selectedKeys[0] : ''
       this.$refs.table.refresh(true)
     },
-    onExpand (expandedKeys) {
+    onExpand(expandedKeys) {
       this.expandedKeys = expandedKeys
       this.autoExpandParent = false
     },
-    doExport () {
+    doExport() {
       this.$message.info('数据正在处理,耐心等待,请勿重复点击')
       const parameter = {
         ...this.queryParam
@@ -531,11 +515,11 @@ export default {
         this.BaseTool.UPLOAD.downLoadExportExcel(file)
       })
     },
-    searchTypeNull () {
+    searchTypeNull() {
       this.queryParam.searchType = true
       this.$refs.table.refresh(true)
     },
-    batchGenerate () {
+    batchGenerate() {
       this.confirmLoading = true
       this.$message.info('正在生成请稍后')
       generateSpareCodeAll().then(res => {
@@ -545,7 +529,7 @@ export default {
         this.$refs.table.clearSelected()
       })
     },
-    handlePrintBatch () {
+    handlePrintBatch() {
       this.visible = false
       let ids = []
       const length = this.selectedRows.length
@@ -559,18 +543,18 @@ export default {
         modal.base(res.data)
       })
     },
-    doImport () {
+    doImport() {
       this.$refs.importModal.base()
     },
-    doImportForUpdate () {
+    doImportForUpdate() {
       this.$refs.importModalForUpdate.base()
     },
-    doDownloadImportTemplate () {
+    doDownloadImportTemplate() {
       downloadSparePartInfoImportTemplate().then(file => {
         this.BaseTool.UPLOAD.downLoadExportExcel(file)
       })
     },
-    handleSpareSelect (id) {
+    handleSpareSelect(id) {
       const length = this.selectedRows.length
       if (length < 2) {
         this.$message.info('请至少选择2个备件')
@@ -578,7 +562,7 @@ export default {
       }
       this.$refs.spareSelectModal.base(this.selectedRows)
     },
-    handleSpareSelected (keys) {
+    handleSpareSelected(keys) {
       const spareId = keys[0]
       let ids = []
       ids = this.selectedRows.map(item => item.id).filter(id => id !== spareId)

+ 8 - 8
src/views/sqarepartmanage/sparepartinfo/SpareStoreTotal.vue

@@ -182,14 +182,6 @@ export default {
           dataIndex: 'no'
         },
         {
-          title: '品牌',
-          width: '150px',
-          align: 'center',
-          ellipsis: true,
-          checked: true,
-          dataIndex: 'brand'
-        },
-        {
           title: '备件名称',
           align: 'center',
           ellipsis: true,
@@ -325,6 +317,14 @@ export default {
            dataIndex: 'sbNo'
          },*/
         {
+          title: '品牌',
+          width: '150px',
+          align: 'center',
+          ellipsis: true,
+          checked: true,
+          dataIndex: 'brand'
+        },
+        {
           title: '备注',
           checked: true,
           align: 'center',