合并代码

This commit is contained in:
zyx.net
2022-12-28 16:12:31 +08:00
63 changed files with 3391 additions and 210 deletions
@@ -59,6 +59,13 @@
@click="urlClick(queryForm.ipdInfo)"
>{{queryForm.ipdInfo}}</span>
</div>
<div class="text-field">
<span class="text-field-left" :title="$t('brand')">{{$t('brand')}}</span>
<span class="text-field-right text-field-right-color"
:title="queryForm.brand"
@click="urlClick(queryForm.brand)"
>{{queryForm.brand}}</span>
</div>
</div>
<div class="content-text">
<div class="text-field">
@@ -109,6 +109,7 @@
:scroll="{x: true,y:'calc(100vh - 335px)'}"
:data-source="dataSource"
rowKey="id"
@change="tableOnChange"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:columns="columns"
>
@@ -255,12 +256,14 @@
align: 'center',
dataIndex: 'standard',
width: 202,
sorter:true,
scopedSlots: { customRender: 'standardInformation' }
},
{
title: this.$t('areaOfResponsibility'),
align: 'center',
width: 180,
sorter:true,
dataIndex: 'areaOfResponsibility',
scopedSlots: { customRender: 'areaOfResponsibility' }
},
@@ -268,6 +271,7 @@
title: this.$t('confirmationOfDesignConformity'),
align: 'center',
width: 240,
sorter:true,
dataIndex: 'confirmationOfDesignConformity',
scopedSlots: { customRender: 'confirmationOfDesignConformity' }
},
@@ -275,6 +279,7 @@
title: this.$t('PrehomoConfirmation'),
align: 'center',
width: 240,
sorter:true,
dataIndex: 'PrehomoConfirmation',
scopedSlots: { customRender: 'PrehomoConfirmation' }
},
@@ -282,6 +287,7 @@
title: this.$t('verificationAndConformityconfirmation'),
align: 'center',
width: 240,
sorter:true,
dataIndex: 'verificationAndConformityconfirmation',
scopedSlots: { customRender: 'verificationAndConformityconfirmation' }
},
@@ -289,6 +295,7 @@
title: this.$t('CertificationProgress'),
align: 'center',
width: 150,
sorter:true,
dataIndex: 'CertificationProgress',
scopedSlots: { customRender: 'CertificationProgress' }
},
@@ -296,11 +303,14 @@
title: this.$t('CurrentStatus'),
align: 'center',
width: 150,
sorter:true,
dataIndex: 'CurrentProjectStatusEvaluation',
scopedSlots: { customRender: 'CurrentProjectStatusEvaluation' }
}
],
selectedRowKeys: [],
orderBy: '1',
orderByField: '',
status: {
'NotDone': '待办',
@@ -536,7 +546,27 @@
CertificationDirectory() {
this.$refs.certificationDirectoryRef.addModel()
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if(sorter.columnKey == 'standard'){
this.orderByField = 'serialNumber'
} else if(sorter.columnKey == 'areaOfResponsibility') {
this.orderByField = 'dutyTerritory'
} else if(sorter.columnKey == 'confirmationOfDesignConformity') {
this.orderByField = 'designFlowTaskStatus'
} else if(sorter.columnKey == 'PrehomoConfirmation') {
this.orderByField = 'prehomoFlowTaskStatus'
} else if(sorter.columnKey == 'verificationAndConformityconfirmation') {
this.orderByField = 'verifyFlowTaskStatus'
} else if(sorter.columnKey == 'CertificationProgress') {
this.orderByField = 'certificationProgressName'
} else if(sorter.columnKey == 'CurrentProjectStatusEvaluation') {
this.orderByField = 'projectStatusAssess'
} else{
this.orderByField = sorter.columnKey
}
this.getList()
},
getList() {
let queryParam = JSON.parse(JSON.stringify(this.queryParam))
Object.keys(queryParam).forEach(val => {
@@ -549,6 +579,8 @@
}
let query = {
projectLibraryId: this.$route.query.id,
orderBy: this.orderBy,
orderByField: this.orderByField,
...queryParam
}
this.loading = true
@@ -163,6 +163,7 @@
align: 'center',
width: 80,
ellipsis: true,
sorter:true,
dataIndex: 'state'
},
{
@@ -177,6 +178,7 @@
align: 'center',
width: 120,
ellipsis: true,
sorter:true,
dataIndex: 'projectVersion'
},
{
@@ -185,6 +187,7 @@
dataIndex: 'finishTime',
width: 180,
ellipsis: true,
sorter:true,
scopedSlots: { customRender: 'collectionCompletionTime' }
},
{
@@ -192,6 +195,7 @@
align: 'center',
width: 80,
ellipsis: true,
sorter:true,
dataIndex: 'version'
},
{
@@ -206,6 +210,7 @@
align: 'center',
width: 160,
ellipsis: true,
sorter:true,
dataIndex: 'createTime'
},
{
@@ -219,6 +224,8 @@
token: Vue.ls.get(ACCESS_TOKEN),
selectedRowKeys: [],
queryParam: {},
orderBy: '1',
orderByField: '',
url: {
list: 'params/manifest/page',
add: 'params/manifest/add',
@@ -312,9 +319,6 @@
} else {
this.$message.warning(this.$t('thisbuttonCompleted'))
}
},
handleTableChange() {
},
// 历史版本
historicalVersion(historicalRow) {
@@ -431,11 +435,26 @@
this.pageSize = pageSize
this.getlist()
},
handleTableChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if(sorter.columnKey == 'projectVersion'){
this.orderByField = 'project_version'
} else if(sorter.columnKey == 'finishTime') {
this.orderByField = 'finish_time'
} else if(sorter.columnKey == 'createTime') {
this.orderByField = 'create_time'
} else{
this.orderByField = sorter.columnKey
}
this.getlist()
},
getlist() {
let query = {
projectId: this.$route.query.parentId ? this.$route.query.parentId : this.$route.query.id,
pageSize: this.pageSize,
pageNo: this.pageNo,
orderBy: this.orderBy,
orderByField: this.orderByField,
...this.queryParam
}
this.loading = true
@@ -224,6 +224,20 @@
</a-form-model-item>
</div>
</a-col>
<a-col :span="12">
<div class="box-title-text">
<div class="title-text">
<span class="title-text-text"
:title="$t('brand')">{{$t('brand')}}</span>
</div>
<a-form-model-item class="itemModel" :prop="'brand'">
<j-multi-select-tag v-model="formInline.brand"
:placeholder="$t('PleaseSelect')+$t('brand')"
:type="'select'"
:triggerChange="false" :dictCode="'brand'"/>
</a-form-model-item>
</div>
</a-col>
</a-row>
<a-row :gutter="24">
<a-col :span="24">
@@ -208,6 +208,7 @@
:scroll="{x: '100%',y:'calc(100vh - 356px)'}"
rowKey="id"
:data-source="dataSource"
@change="tableOnChange"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
:columns="columns"
>
@@ -300,7 +301,8 @@
<listAddModel :url="url" @addModelList="addModelList" ref="addModelRef"/>
<listEditModel :url="url" @editModelList="addModelList" ref="editModelRef"/>
<batSetting :url="url" @batSettingList="addModelList" ref="batSettingRef"/>
<transferList :url="url" @transferListForm="addModelList" ref="transferListRef"/>
<transferList :url="url" @transferListForm="transferListForm" ref="transferListRef"/>
<transferListvirtal :url="url" @transferListFormHomo="transferListFormHomo" ref="transferListvirtalRef"/>
<fixedPlate @fixedPlateForm="addModelList" ref="fixedPlateRef"/>
<a-modal
:title="listTitle"
@@ -456,6 +458,7 @@
import listEditModel from './listEditModel'
import batSetting from './batSetting'
import transferList from './transferList'
import transferListvirtal from './transferListvirtal'
import fixedPlate from './fixedPlateForm'
import resultReportedUpload from './resultReportedUpload'
import listOfRegulationsView from './listOfRegulationsView'
@@ -475,6 +478,7 @@
listEditModel,
batSetting,
transferList,
transferListvirtal,
globalAdvancedQuery,
fixedPlate,
resultReportedUpload,
@@ -485,6 +489,8 @@
return {
roleSwitchingList: [],
listTitle: '',
orderBy: '1',
orderByField: '',
columnsAll: [
{
title: this.$t('standard'),
@@ -492,6 +498,7 @@
dataIndex: 'serialNumber',
width: 180,
fixed: 'left',
sorter:true,
scopedSlots: { customRender: 'standard' }
},
{
@@ -514,11 +521,13 @@
align: 'center',
dataIndex: 'inventoryAffirmStatusName',
width: 240,
sorter:true,
ellipsis: true
},
{
title: this.$t('taskAffirmStatus'),
align: 'center',
sorter:true,
dataIndex: 'taskAffirmStatusName',
width: 240,
ellipsis: true
@@ -575,6 +584,7 @@
align: 'center',
dataIndex: 'attestationRank_dictText',
width: 180,
sorter:true,
ellipsis: true
},
{
@@ -589,12 +599,14 @@
align: 'center',
dataIndex: 'wvtaId',
width: 180,
sorter:true,
ellipsis: true
},
{
title: this.$t('areaOfResponsibility'),
align: 'center',
ellipsis: true,
sorter:true,
dataIndex: 'dutyTerritory_dictText',
width: 180
},
@@ -602,6 +614,7 @@
title: this.$t('regulatoryEngineer'),
align: 'center',
ellipsis: true,
sorter:true,
dataIndex: 'regulationOwnerName',
width: 180
},
@@ -609,6 +622,7 @@
title: this.$t('certifiedEngineer'),
align: 'center',
ellipsis: true,
sorter:true,
dataIndex: 'homologationEngineerName',
width: 180
},
@@ -616,6 +630,7 @@
title: this.$t('engineeringInterfacePerson'),
align: 'center',
ellipsis: true,
sorter:true,
dataIndex: 'engineeringInterfacePersonName',
width: 180
},
@@ -1477,6 +1492,13 @@
this.selectedRowKeys = []
this.getList()
},
transferListForm(id){
this.$refs.transferListvirtalRef.transferModel(id)
},
transferListFormHomo(){
this.$refs.transferListRef.handleCancel()
this.getList()
},
handleSuperQuery(params, matchType) {
let sqp = {}
if (!params || (params && params.length == 0)) {
@@ -1490,6 +1512,17 @@
this.queryParamQuery = sqp
this.getList()
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
if(sorter.columnKey == 'attestationRank_dictText'){
this.orderByField = 'attestationRank'
} else if(sorter.columnKey == 'dutyTerritory_dictText'){
this.orderByField = 'dutyTerritory'
} else{
this.orderByField = sorter.columnKey
}
this.getList()
},
getList() {
let roleCode
if (this.isDisplay) {
@@ -1515,6 +1548,8 @@
...this.queryParamQuery,
...queryParam,
projectLibraryId: this.$route.query.id,
orderBy: this.orderBy,
orderByField: this.orderByField,
roleCode: roleCode
}
this.loading = true
@@ -56,6 +56,7 @@
:pagination="false"
:scroll="{x: '100%'}"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange }"
@change="tableOnChange"
:data-source="dataSource"
:columns="columns"
>
@@ -91,6 +92,8 @@
return {
queryParam: {},
loading: false,
orderBy: '1',
orderByField: '',
dataSource: [],
selectedRowKeys: [],
columns: [
@@ -100,6 +103,7 @@
dataIndex: 'serialNumber',
scopedSlots: { customRender: 'standard' },
ellipsis: true,
sorter:true,
width: 180
},
{
@@ -115,6 +119,7 @@
align: 'center',
dataIndex: 'flowType',
ellipsis: true,
sorter:true,
width: 180
},
{
@@ -122,6 +127,7 @@
align: 'center',
dataIndex: 'dutyTerritory',
ellipsis: true,
sorter:true,
width: 180
},
{
@@ -129,6 +135,7 @@
align: 'center',
dataIndex: 'problemType',
ellipsis: true,
sorter:true,
width: 180
},
{
@@ -136,6 +143,7 @@
align: 'center',
dataIndex: 'initiator',
ellipsis: true,
sorter:true,
width: 140
},
{
@@ -143,6 +151,7 @@
align: 'center',
dataIndex: 'duty',
ellipsis: true,
sorter:true,
width: 140
}
],
@@ -218,11 +227,18 @@
}
downloadFilePost(this.url.exportData, this.$t('NonConformance') + '.xls', query, this.Deselect)
},
tableOnChange(pagination, filters, sorter) {
this.orderBy = sorter.order == 'ascend' ? '1' : '2'
this.orderByField = sorter.columnKey
this.getList()
},
getList() {
let query = {
pageNo: this.pageNo,
pageSize: this.pageSize,
projectLibraryId: this.$route.query.id,
orderBy: this.orderBy,
orderByField: this.orderByField,
...this.queryParam
}
this.loading = true
@@ -56,7 +56,7 @@
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('determine')}}</a-button>
</div>
</a-drawer>
</template>
@@ -166,27 +166,30 @@
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
postAction(this.url.addModel, {
dummyInventoryBaseId: selectedRowKeys.join(','),
projectLibraryId: this.$route.query.id,
flag: flag
}).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.selectedRowKeys = []
this.$emit('transferListForm')
} else {
if (res.message == '该虚拟清单的维护清单中没有数据,是否需要添加') {
this.confirmLoading = false
this.getAdd()
return
}
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
this.confirmLoading = false
this.$emit('transferListForm',selectedRowKeys.join(','))
this.selectedRowKeys = []
// postAction(this.url.addModel, {
// dummyInventoryBaseId: selectedRowKeys.join(','),
// projectLibraryId: this.$route.query.id,
// flag: flag
// }).then((res) => {
// if (res.success) {
// this.confirmLoading = false
// this.$message.success(this.$t('OperationSuccessful'))
// this.visible = false
// this.selectedRowKeys = []
// this.$emit('transferListForm')
// } else {
// if (res.message == '该虚拟清单的维护清单中没有数据,是否需要添加') {
// this.confirmLoading = false
// this.getAdd()
// return
// }
// this.$message.warning(this.$t('operationFailed'))
// this.confirmLoading = false
// }
// })
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
@@ -0,0 +1,255 @@
<template>
<a-drawer
:title="$t('Transfer')"
:maskClosable="false"
:width="1000"
placement="right"
:closable="true"
@close="handleCancel"
:visible="visible"
style="height: 100%;overflow: auto;padding-bottom: 53px;">
<div style="margin-bottom: 60px">
<div class="table-page-search-wrapper">
<a-form layout="inline" @keyup.enter.native="searchQuery">
<a-row :gutter="24">
<a-col :md="12" :sm="5">
<div class="box-title-text">
<div class="title-text" :title="$t('standard')">
<span>{{$t('standard')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('standard')"
v-model="queryParam.serialNumber"></j-input>
</div>
</a-col>
<a-col :md="12" :sm="5">
<div class="box-title-text">
<div class="title-text" :title="$t('title')">
<span>{{$t('title')}}</span>
</div>
<j-input class="box-input" :placeholder="$t('PleaseEnter')+$t('title')"
v-model="queryParam.title"></j-input>
</div>
</a-col>
<span style="float: right;overflow: hidden;margin-right: 11px" class="table-page-search-submitButtons">
<a-col :md="12" :sm="24">
<a-button class="box-button" type="primary" @click="searchQuery">{{$t('query')}}</a-button>
<a-button class="box-button" style="margin-left: 8px" @click="searchReset">{{$t('reset')}}</a-button>
</a-col>
</span>
</a-row>
</a-form>
</div>
<a-table
:columns="columns"
rowKey="id"
:scroll="{x: 800}"
:data-source="dataList"
:pagination="false"
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange,columnTitle:' ' }"
:loading="loading">
</a-table>
<!-- <div class="page" v-if="dataList.length > 0">-->
<!-- <a-pagination-->
<!-- :show-total="total => $t('total')+` ${total} `+$t('strip')"-->
<!-- show-quick-jumper-->
<!-- show-size-changer-->
<!-- :page-size.sync="pageSize"-->
<!-- :total="total"-->
<!-- :current="pageNo"-->
<!-- @change="onChange"-->
<!-- @showSizeChange="SizeChange"-->
<!-- />-->
<!-- </div>-->
</div>
<div class="drawer-bootom-button">
<a-button @click="handleCancel" style="margin-right: 16px">{{$t('cancel')}}</a-button>
<a-button @click="handleSubmit(undefined)" type="primary" :loading="confirmLoading">{{$t('submit')}}</a-button>
</div>
</a-drawer>
</template>
<script>
import { getAction, postAction } from '@/api/manage'
export default {
name: 'transferList',
components: {},
props: ['url'],
data() {
return {
visible: false,
queryParam: {},
confirmLoading: false,
selectedRowKeys: [],
columns: [
{
title: this.$t('standard'),
align: 'center',
dataIndex: 'serialNumber',
scopedSlots: { customRender: 'standard' }
},
{
title: this.$t('title'),
align: 'center',
dataIndex: 'title',
scopedSlots: { customRender: 'titleName' }
},
{
title: this.$t('subtitle'),
align: 'center',
dataIndex: 'subtitle',
ellipsis: true
},
{
title: this.$t('areaOfResponsibility'),
align: 'center',
ellipsis: true,
dataIndex: 'dutyTerritory_dictText'
},
],
dataList: [],
content: [],
loading: false,
dummyInventoryBaseId:'',
pageNo: 1,
pageSize: 10,
total: 0
}
},
mounted() {
},
methods: {
transferModel(id) {
this.visible = true
this.dummyInventoryBaseId = id
this.queryParam = {}
this.selectedRowKeys = []
this.replacePage()
},
searchQuery() {
this.pageNo = 1
this.replacePage()
},
searchReset() {
this.pageNo = 1
this.queryParam = {}
this.replacePage()
},
onChange(page, pageSize) {
this.pageNo = page
this.replacePage()
},
SizeChange(page, pageSize) {
this.pageNo = 1
this.pageSize = pageSize
this.replacePage()
},
replacePage() {
let query = {
// pageNo: this.pageNo,
// pageSize: this.pageSize,
...this.queryParam,
dummyInventoryBaseId: this.dummyInventoryBaseId
}
this.loading = true
getAction('/dummy/dummyInventoryInfoEO/list', query).then((res) => {
if (res.success) {
this.dataList = res.result || []
this.loading = false
} else {
this.loading = false
}
})
},
onSelectChange(value) {
this.selectedRowKeys = value
// if (this.selectedRowKeys.length > 1) {
// this.selectedRowKeys.shift()
// }
},
handleCancel() {
this.visible = false
},
handleSubmit(flag) {
if (this.selectedRowKeys && this.selectedRowKeys.length > 0) {
this.confirmLoading = true
let selectedRowKeys = JSON.parse(JSON.stringify(this.selectedRowKeys))
postAction('project/projectLawsInventoryEO/add', {
dummyInventoryBaseId: this.dummyInventoryBaseId,
projectLibraryId: this.$route.query.id,
dummyids: selectedRowKeys.join(','),
}).then((res) => {
if (res.success) {
this.confirmLoading = false
this.$message.success(this.$t('OperationSuccessful'))
this.visible = false
this.selectedRowKeys = []
this.$emit('transferListFormHomo')
} else {
this.$message.warning(this.$t('operationFailed'))
this.confirmLoading = false
}
})
} else {
this.$message.warning(this.$t('selectLeastOne'))
}
},
}
}
</script>
<style scoped>
.page {
text-align: right;
margin-top: 20px;
}
.drawer-bootom-button {
position: absolute;
bottom: 0;
z-index: 100;
width: 100%;
border-top: 1px solid #e8e8e8;
padding: 10px 16px;
text-align: right;
left: 0;
background: #fff;
border-radius: 0 0 2px 2px;
}
.box-title-text {
line-height: 1.4;
display: flex;
align-items: center;
margin-bottom: 10px;
}
.title-text {
width: 20%;
min-width: 110px;
color: #000F16;
display: inline-block;
font-weight: 500;
font-size: 14px;
margin-right: 16px;
margin-top: 3px;
text-align: right;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.box-input {
display: inline-block;
width: 70%;
height: 38px;
margin-top: 2px;
}
.box-button {
height: 38px;
}
</style>