|
@@ -4,9 +4,12 @@
|
|
|
<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="showSbFlag" style="margin-left: 16px" type="default" @ok="handleOk" @click="handleViewBom()">备件BOM</a-button>
|
|
|
+ <a-button v-if="showSbFlag" style="margin-left: 16px" type="default" @ok="handleOk" @click="handleViewCheck()">保养项目</a-button>
|
|
|
+
|
|
|
<a-button v-if="$auth('repair-application-forms-assign') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.NOT_ALLOCATED === model.status" type="primary" @click="handleAssign">派工</a-button>
|
|
|
<a-popconfirm v-if="$auth('repair-application-forms-deal') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.NOT_ALLOCATED === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.ALLOCATED === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status)" title="是否要接收?" @confirm="receive">
|
|
|
- <a-button>接收</a-button>
|
|
|
+ <a-button style="margin-left: 16px">接收</a-button>
|
|
|
</a-popconfirm>
|
|
|
<a-button v-if="$auth('repair-application-forms-out') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING >= model.status) && model.type != 2" style="margin-left: 8px" type="primary" @click="handleOut">委外</a-button>
|
|
|
<a-button v-if="$auth('repair-application-forms-dispatch') && (DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.ALLOCATED === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status)" style="margin-left: 8px" type="primary" @click="handleDispatch">转派</a-button>
|
|
@@ -81,26 +84,26 @@
|
|
|
</div>
|
|
|
</a-layout-sider>
|
|
|
</a-layout>
|
|
|
- <title-divider title="维修项目" width="90px"></title-divider>
|
|
|
- <div class="table-operator" v-if="$auth('repair-application-forms-finish') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status">
|
|
|
- <a-button type="primary" @click="handleRepairProjectSelect">
|
|
|
- <a-icon type="plus"/>
|
|
|
- 添加
|
|
|
- </a-button>
|
|
|
- </div>
|
|
|
- <a-table
|
|
|
- :data-source="data"
|
|
|
- :columns="columns"
|
|
|
- tableLayout="auto"
|
|
|
- rowKey="id">
|
|
|
- <span slot="action" slot-scope="record">
|
|
|
- <template>
|
|
|
- <a-popconfirm v-if="$auth('repair-application-forms-finish') && ( DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status)" title="是否要删除该条数据?" @confirm="batchDelete(record.relationId)">
|
|
|
- <a>删除</a>
|
|
|
- </a-popconfirm>
|
|
|
- </template>
|
|
|
- </span>
|
|
|
- </a-table>
|
|
|
+ <title-divider title="维修项目" width="90px"></title-divider>
|
|
|
+ <div class="table-operator" v-if="$auth('repair-application-forms-finish') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status">
|
|
|
+ <a-button type="primary" @click="handleRepairProjectSelect">
|
|
|
+ <a-icon type="plus"/>
|
|
|
+ 添加
|
|
|
+ </a-button>
|
|
|
+ </div>
|
|
|
+ <a-table
|
|
|
+ :data-source="data"
|
|
|
+ :columns="columns"
|
|
|
+ tableLayout="auto"
|
|
|
+ rowKey="id">
|
|
|
+ <span slot="action" slot-scope="record">
|
|
|
+ <template>
|
|
|
+ <a-popconfirm v-if="$auth('repair-application-forms-finish') && ( DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status)" title="是否要删除该条数据?" @confirm="batchDelete(record.relationId)">
|
|
|
+ <a>删除</a>
|
|
|
+ </a-popconfirm>
|
|
|
+ </template>
|
|
|
+ </span>
|
|
|
+ </a-table>
|
|
|
<title-divider title="备件清单" width="90px"></title-divider>
|
|
|
<div class="table-operator" v-if="$auth('repair-application-forms-finish') && DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status">
|
|
|
<a-button type="primary" @click="handleSpareStoreSelect">
|
|
@@ -124,14 +127,15 @@
|
|
|
</template>
|
|
|
</span>
|
|
|
</a-table>
|
|
|
- <title-divider title="费用清单" width="90px"></title-divider>
|
|
|
- <div class="table-operator" v-if="$auth('repair-application-forms-finish') && ( DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status)">
|
|
|
+ <title-divider title="费用清单" width="90px" v-if="model.type == 2"></title-divider>
|
|
|
+ <div class="table-operator" v-if="$auth('repair-application-forms-finish') && ( DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.PROCESSING === model.status || DictCache.VALUE.REPAIR_APPLICATION_FORM_STATUS.REBACK === model.status) && model.type === 2">
|
|
|
<a-button type="primary" @click="handleAddFee">
|
|
|
<a-icon type="plus"/>
|
|
|
添加
|
|
|
</a-button>
|
|
|
</div>
|
|
|
<a-table
|
|
|
+ v-if="model.type == 2"
|
|
|
:data-source="dataFee"
|
|
|
:columns="columnsFee"
|
|
|
tableLayout="auto"
|
|
@@ -161,7 +165,7 @@
|
|
|
<a-table
|
|
|
:data-source="dataReason"
|
|
|
:columns="columnsReason"
|
|
|
- tableLayout="fixed"
|
|
|
+ :scroll="{x: 1, y: BaseTool.Constant.scrollY }"
|
|
|
rowKey="id">
|
|
|
<span slot="action" slot-scope="record">
|
|
|
<template>
|
|
@@ -202,6 +206,8 @@
|
|
|
<fee-detail ref="feeDetail" @ok="handleOk" />
|
|
|
<reason-base-form ref="reasonForm" @ok="handleOk" />
|
|
|
<reason-detail ref="reasonDetail" @ok="handleOk" />
|
|
|
+ <detail-sb-bom ref="detailSbBomModal" @ok="handleOk"/>
|
|
|
+ <detail-sb-check ref="detailSbCheckModal" @ok="handleOk"/>
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
@@ -229,7 +235,9 @@ import { deleteRepairFees, fetchRepairFee, queryRepairFee } from '@/api/repair/f
|
|
|
import ReasonBaseForm from '@/views/repair/repair-reason/modules/BaseForm'
|
|
|
import ReasonDetail from '@/views/repair/repair-reason/modules/Detail'
|
|
|
import { deleteRepairReasons, fetchRepairReason, queryRepairReason } from '@/api/repair/repair-reason'
|
|
|
-
|
|
|
+import DetailSbBom from '@/views/sb/modelbom/modules/DetailSbBom'
|
|
|
+import DetailSbCheck from '@/views/check/checkstandard/modules/DetailSbCheck'
|
|
|
+import { fetchSbInfo } from '@/api/sb/info'
|
|
|
const DetailListItem = DetailList.Item
|
|
|
|
|
|
export default {
|
|
@@ -237,6 +245,8 @@ export default {
|
|
|
components: {
|
|
|
CheckForm,
|
|
|
DetailList,
|
|
|
+ DetailSbCheck,
|
|
|
+ DetailSbBom,
|
|
|
ReasonBaseForm,
|
|
|
ReasonDetail,
|
|
|
DetailListItem,
|
|
@@ -262,6 +272,8 @@ export default {
|
|
|
needStopMap: {},
|
|
|
dispatchList: [],
|
|
|
visible: false,
|
|
|
+ showSbFlag: false,
|
|
|
+ sbInfo: {},
|
|
|
// 下拉框map
|
|
|
sourceMap: {},
|
|
|
typeMap: {},
|
|
@@ -412,7 +424,7 @@ export default {
|
|
|
{
|
|
|
title: '序号',
|
|
|
dataIndex: 'index',
|
|
|
- width: '70',
|
|
|
+ width: '70px',
|
|
|
customRender: (text, record, index) => {
|
|
|
return `${index + 1}`
|
|
|
}
|
|
@@ -495,10 +507,19 @@ export default {
|
|
|
methods: {
|
|
|
base (record) {
|
|
|
this.visible = true
|
|
|
+ this.showSbFlag = false
|
|
|
this.modalTitle = '详情'
|
|
|
this.model = record
|
|
|
this.activeKey = 'a'
|
|
|
this.dispatchList = JSON.parse(record.repairDispatchList)
|
|
|
+ const sbId = record.sbId
|
|
|
+ if (sbId) {
|
|
|
+ fetchSbInfo({ id: sbId }).then(res => {
|
|
|
+ this.sbInfo = res.data
|
|
|
+ this.showSbFlag = true
|
|
|
+ })
|
|
|
+ }
|
|
|
+
|
|
|
this.init()
|
|
|
},
|
|
|
init () {
|
|
@@ -515,6 +536,16 @@ export default {
|
|
|
this.dataReason = res.data
|
|
|
})
|
|
|
},
|
|
|
+ handleViewBom (record) {
|
|
|
+ this.visible = false
|
|
|
+ const modal = this.$refs.detailSbBomModal
|
|
|
+ modal.base(this.sbInfo)
|
|
|
+ },
|
|
|
+ handleViewCheck (record) {
|
|
|
+ this.visible = false
|
|
|
+ const modal = this.$refs.detailSbCheckModal
|
|
|
+ modal.base(this.sbInfo)
|
|
|
+ },
|
|
|
handleCancel () {
|
|
|
this.visible = false
|
|
|
this.confirmLoading = false
|