|
|
@ -1,57 +1,29 @@
|
|
|
|
<template>
|
|
|
|
<template>
|
|
|
|
<el-dialog title="详情" :close-on-click-modal="false" append-to-body :visible.sync="visible"
|
|
|
|
<el-dialog title="子件详情" :close-on-click-modal="false" append-to-body :visible.sync="visible"
|
|
|
|
class="JNPF-dialog JNPF-dialog_center" lock-scroll width="600px">
|
|
|
|
class="JNPF-dialog JNPF-dialog_center" lock-scroll width="1200px">
|
|
|
|
<el-row :gutter="15" class="">
|
|
|
|
<JNPF-table v-loading="listLoading" :data="list" @sort-change='sortChange' :span-method="arraySpanMethod"
|
|
|
|
<el-form ref="formRef" :model="dataForm" size="small" label-width="100px" label-position="right">
|
|
|
|
border height="500px">
|
|
|
|
<template v-if="!loading">
|
|
|
|
<el-table-column prop="subsetId" label="子件编码" align="center">
|
|
|
|
<el-col :span="24">
|
|
|
|
</el-table-column>
|
|
|
|
<jnpf-form-tip-item label="母件编码" prop="pieceId">
|
|
|
|
<el-table-column prop="subsetName" label="子件名称" align="center">
|
|
|
|
<p>{{ dataForm.pieceId }}</p>
|
|
|
|
</el-table-column>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
<el-table-column prop="subsetModel" label="规格型号" align="center">
|
|
|
|
</el-col>
|
|
|
|
</el-table-column>
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-table-column prop="unit" label="计量单位" align="center">
|
|
|
|
<jnpf-form-tip-item label="母件名称" prop="pieceName">
|
|
|
|
</el-table-column>
|
|
|
|
<p>{{ dataForm.pieceName }}</p>
|
|
|
|
<el-table-column prop="baseUse" label="基本用量" align="center">
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
</el-table-column>
|
|
|
|
</el-col>
|
|
|
|
<el-table-column prop="baseNum" label="基础数量" align="center">
|
|
|
|
<el-col :span="24">
|
|
|
|
</el-table-column>
|
|
|
|
<jnpf-form-tip-item label="规格型号" prop="models">
|
|
|
|
<el-table-column prop="creatorTime" label="创建时间" align="center">
|
|
|
|
<p>{{ dataForm.models }}</p>
|
|
|
|
</el-table-column>
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
<el-table-column prop="status" label="单据状态" align="center">
|
|
|
|
</el-col>
|
|
|
|
<template slot-scope="scope">
|
|
|
|
<el-col :span="24">
|
|
|
|
<el-tag v-if="scope.row.status == '1'">未审核</el-tag>
|
|
|
|
<jnpf-form-tip-item label="计量单位" prop="unit">
|
|
|
|
<el-tag type="success" v-else-if="scope.row.status == '2'">已审核</el-tag>
|
|
|
|
<p>{{ dataForm.unit }}</p>
|
|
|
|
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
<el-col :span="24">
|
|
|
|
|
|
|
|
<jnpf-form-tip-item label="版本代号" prop="versionCode">
|
|
|
|
|
|
|
|
<p>{{ dataForm.versionCode }}</p>
|
|
|
|
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
<el-col :span="24">
|
|
|
|
|
|
|
|
<jnpf-form-tip-item label="版本说明" prop="versionIllustrate">
|
|
|
|
|
|
|
|
<p>{{ dataForm.versionIllustrate }}</p>
|
|
|
|
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
<el-col :span="24">
|
|
|
|
|
|
|
|
<jnpf-form-tip-item label="版本日期" prop="versionDate">
|
|
|
|
|
|
|
|
<p>{{ dataForm.versionDate }}</p>
|
|
|
|
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
<el-col :span="24">
|
|
|
|
|
|
|
|
<jnpf-form-tip-item label="创建时间" prop="creatorTime">
|
|
|
|
|
|
|
|
<p>{{ dataForm.creatorTime }}</p>
|
|
|
|
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
<el-col :span="24">
|
|
|
|
|
|
|
|
<jnpf-form-tip-item label="单据状态" prop="documentStatus">
|
|
|
|
|
|
|
|
<p>{{ dataForm.documentStatus }} </p>
|
|
|
|
|
|
|
|
</jnpf-form-tip-item>
|
|
|
|
|
|
|
|
</el-col>
|
|
|
|
|
|
|
|
</template>
|
|
|
|
</template>
|
|
|
|
</el-form>
|
|
|
|
</el-table-column>
|
|
|
|
</el-row>
|
|
|
|
</JNPF-table>
|
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
|
<el-button @click="visible = false"> 取 消</el-button>
|
|
|
|
<el-button @click="visible = false"> 取 消</el-button>
|
|
|
|
</span>
|
|
|
|
</span>
|
|
|
@ -73,7 +45,17 @@ export default {
|
|
|
|
visible: false,
|
|
|
|
visible: false,
|
|
|
|
detailVisible: false,
|
|
|
|
detailVisible: false,
|
|
|
|
loading: false,
|
|
|
|
loading: false,
|
|
|
|
|
|
|
|
mergeList: [],
|
|
|
|
|
|
|
|
list: [],
|
|
|
|
|
|
|
|
expandObj: {},
|
|
|
|
|
|
|
|
listLoading: true,
|
|
|
|
|
|
|
|
listQuery: {
|
|
|
|
|
|
|
|
superQueryJson: '',
|
|
|
|
|
|
|
|
currentPage: 1,
|
|
|
|
|
|
|
|
pageSize: 20,
|
|
|
|
|
|
|
|
sort: "desc",
|
|
|
|
|
|
|
|
sidx: "",
|
|
|
|
|
|
|
|
},
|
|
|
|
dataForm: {
|
|
|
|
dataForm: {
|
|
|
|
id: '',
|
|
|
|
id: '',
|
|
|
|
pieceId: '',
|
|
|
|
pieceId: '',
|
|
|
@ -115,20 +97,42 @@ export default {
|
|
|
|
this.dataForm = _dataAll
|
|
|
|
this.dataForm = _dataAll
|
|
|
|
},
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
sortChange({ column, prop, order }) {
|
|
|
|
|
|
|
|
this.listQuery.sort = order == 'ascending' ? 'asc' : 'desc'
|
|
|
|
|
|
|
|
this.listQuery.sidx = !order ? '' : prop
|
|
|
|
|
|
|
|
this.init()
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
arraySpanMethod({ column }) {
|
|
|
|
|
|
|
|
for (let i = 0; i < this.mergeList.length; i++) {
|
|
|
|
|
|
|
|
if (column.property == this.mergeList[i].prop) {
|
|
|
|
|
|
|
|
return [this.mergeList[i].rowspan, this.mergeList[i].colspan]
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
|
|
init(id) {
|
|
|
|
init(id) {
|
|
|
|
this.dataForm.id = id || 0;
|
|
|
|
|
|
|
|
this.visible = true;
|
|
|
|
this.visible = true;
|
|
|
|
|
|
|
|
this.listLoading = true;
|
|
|
|
|
|
|
|
let _query = {
|
|
|
|
|
|
|
|
...this.listQuery,
|
|
|
|
|
|
|
|
pieceId: id
|
|
|
|
|
|
|
|
};
|
|
|
|
this.$nextTick(() => {
|
|
|
|
this.$nextTick(() => {
|
|
|
|
if (this.dataForm.id) {
|
|
|
|
|
|
|
|
this.loading = true
|
|
|
|
this.loading = true
|
|
|
|
request({
|
|
|
|
request({
|
|
|
|
url: '/api/example/YysBillMaterial/detail/' + this.dataForm.id,
|
|
|
|
url: '/api/example/YysBillMaterial/queryByPieceId',
|
|
|
|
method: 'get'
|
|
|
|
method: 'POST',
|
|
|
|
|
|
|
|
data: _query
|
|
|
|
}).then(res => {
|
|
|
|
}).then(res => {
|
|
|
|
this.dataInfo(res.data)
|
|
|
|
var _list = res.data.list;
|
|
|
|
this.loading = false
|
|
|
|
this.list = _list.map(o => ({
|
|
|
|
|
|
|
|
...o,
|
|
|
|
|
|
|
|
...this.expandObj,
|
|
|
|
|
|
|
|
}))
|
|
|
|
|
|
|
|
this.total = res.data.pagination.total
|
|
|
|
|
|
|
|
this.listLoading = false
|
|
|
|
})
|
|
|
|
})
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
})
|
|
|
|
})
|
|
|
|
},
|
|
|
|
},
|
|
|
|