[fix uat124] 市场法规清单-新增、编辑页面 展示市场清单+市场清单编码的全部信息
This commit is contained in:
@@ -71,6 +71,7 @@ module.exports = {
|
|||||||
releaseTime: 'Published Date',
|
releaseTime: 'Published Date',
|
||||||
listState: 'Status',
|
listState: 'Status',
|
||||||
customName: 'Custom Name',
|
customName: 'Custom Name',
|
||||||
|
customNameLastText: '车型需满足标准法规清单',
|
||||||
securityClass: 'Confidential Level',
|
securityClass: 'Confidential Level',
|
||||||
listDeclaration: 'Manifest Declaration',
|
listDeclaration: 'Manifest Declaration',
|
||||||
templateName: 'Market regulation list import template',
|
templateName: 'Market regulation list import template',
|
||||||
|
|||||||
@@ -71,6 +71,7 @@ module.exports = {
|
|||||||
releaseTime: '发布时间',
|
releaseTime: '发布时间',
|
||||||
listState: '清单状态',
|
listState: '清单状态',
|
||||||
customName: '自定义名称',
|
customName: '自定义名称',
|
||||||
|
customNameLastText: '车型需满足标准法规清单',
|
||||||
securityClass: '密级',
|
securityClass: '密级',
|
||||||
listDeclaration: '清单说明',
|
listDeclaration: '清单说明',
|
||||||
templateName: '市场法规清单导入模板',
|
templateName: '市场法规清单导入模板',
|
||||||
|
|||||||
+65
-22
@@ -25,25 +25,32 @@
|
|||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
<!-- 清单编号英文缩写 -->
|
<!-- 清单编号英文缩写 -->
|
||||||
<a-col :span="12" v-if="isShowManifestNo">
|
<!--<template v-if="isShowManifestNo">-->
|
||||||
<a-form-item :label="$t('standardRegulationLibrary.marketRegulationsList.listNumberEnglishPart')"
|
<a-form-item class="block-form-item" :label="$t('standardRegulationLibrary.marketRegulationsList.listNumber')"
|
||||||
:labelCol="labelCol"
|
:labelCol="lineLabelCol"
|
||||||
:wrapperCol="wrapperCol">
|
:wrapperCol="lineWrapperCol">
|
||||||
<a-input :placeholder="$t('pleaseEnter') + $t('standardRegulationLibrary.marketRegulationsList.listNumberEnglishPart')"
|
<!--固定的编码-->
|
||||||
:maxLength="192"
|
<span>BZFG-</span>
|
||||||
v-decorator="['manifestNo', validatorRules.manifestNo]" />
|
<a-input :placeholder="$t('pleaseEnter') + $t('standardRegulationLibrary.marketRegulationsList.listNumberEnglishPart')"
|
||||||
</a-form-item>
|
:maxLength="192"
|
||||||
</a-col>
|
v-decorator="['manifestNo', validatorRules.manifestNo]" />
|
||||||
|
<!--后端生成的序号-->
|
||||||
|
<span>-{{model.columnNo}}</span>
|
||||||
|
</a-form-item>
|
||||||
|
<!--</template>-->
|
||||||
<!-- 自定义名称 -->
|
<!-- 自定义名称 -->
|
||||||
<a-col :span="12">
|
<!--<a-col :span="24">-->
|
||||||
<a-form-item :label="$t('standardRegulationLibrary.marketRegulationsList.customName')"
|
<a-form-item class="block-form-item" :label="$t('standardRegulationLibrary.marketRegulationsList.listName')"
|
||||||
:labelCol="labelCol"
|
:labelCol="lineLabelCol"
|
||||||
:wrapperCol="wrapperCol">
|
:wrapperCol="lineWrapperCol">
|
||||||
<a-input :placeholder="$t('pleaseEnter') + $t('standardRegulationLibrary.marketRegulationsList.customName')"
|
<!--国家地区-->
|
||||||
:maxLength="200"
|
<span>{{model.countryName}}</span>
|
||||||
v-decorator="['customColumnName', validatorRules.customColumnName]" />
|
<a-input :placeholder="$t('pleaseEnter') + $t('standardRegulationLibrary.marketRegulationsList.customName')"
|
||||||
</a-form-item>
|
:maxLength="200"
|
||||||
</a-col>
|
v-decorator="['customColumnName', validatorRules.customColumnName]" />
|
||||||
|
<span>{{ $t('standardRegulationLibrary.marketRegulationsList.customNameLastText') }}</span>
|
||||||
|
</a-form-item>
|
||||||
|
<!--</a-col>-->
|
||||||
<!-- 驾驶位置 -->
|
<!-- 驾驶位置 -->
|
||||||
<a-col :span="12">
|
<a-col :span="12">
|
||||||
<a-form-item :labelCol="labelCol"
|
<a-form-item :labelCol="labelCol"
|
||||||
@@ -256,7 +263,7 @@ export default {
|
|||||||
SecurityClass,
|
SecurityClass,
|
||||||
pageLoading: false,
|
pageLoading: false,
|
||||||
form: this.$form.createForm(this),
|
form: this.$form.createForm(this),
|
||||||
model: { manifest: {}, lists: [] },
|
model: { manifest: {}, lists: [], columnNo: 'XXX', countryName: '' },
|
||||||
queryParam: {},
|
queryParam: {},
|
||||||
countryOptions: [], // 国家下拉选择
|
countryOptions: [], // 国家下拉选择
|
||||||
labelCol: {
|
labelCol: {
|
||||||
@@ -512,17 +519,33 @@ export default {
|
|||||||
// const value = this.form.getFieldValue('country')
|
// const value = this.form.getFieldValue('country')
|
||||||
console.log('--------value', value)
|
console.log('--------value', value)
|
||||||
const param = {}
|
const param = {}
|
||||||
param.country = value && value.length > 0 ? value.map(item => item.value).join(',') : ''
|
if (value && value.length > 0) {
|
||||||
|
param.country = value.map(item => item.value).join(',')
|
||||||
|
this.model.countryName = value.map(item => item.label).join('')
|
||||||
|
} else {
|
||||||
|
param.country = ''
|
||||||
|
this.model.countryName = ''
|
||||||
|
}
|
||||||
|
|
||||||
marketRegulationGetListNumber(param).then(res => {
|
marketRegulationGetListNumber(param).then(res => {
|
||||||
if (res.success) {
|
if (res.success) {
|
||||||
|
const noText = res.message ? res.message.split(',')[0] : ''
|
||||||
const result = {
|
const result = {
|
||||||
manifestNo: res.message
|
manifestNo: noText
|
||||||
}
|
}
|
||||||
// 显示清单编号英文名称缩写
|
// 显示清单编号英文名称缩写
|
||||||
this.isShowManifestNo = true
|
this.isShowManifestNo = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.form.setFieldsValue(pick(result, 'manifestNo'))
|
this.form.setFieldsValue(pick(result, 'manifestNo'))
|
||||||
})
|
})
|
||||||
|
|
||||||
|
} else {
|
||||||
|
const result = {
|
||||||
|
manifestNo: ''
|
||||||
|
}
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.form.setFieldsValue(pick(result, 'manifestNo'))
|
||||||
|
})
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@@ -540,14 +563,22 @@ export default {
|
|||||||
this.model.country = this.model.country.split(',').map(item => {
|
this.model.country = this.model.country.split(',').map(item => {
|
||||||
return { value: item }
|
return { value: item }
|
||||||
})
|
})
|
||||||
|
// 清单名称
|
||||||
|
this.model.countryName = this.model.country_dictText.split(',').join('')
|
||||||
}
|
}
|
||||||
|
// 清单编号的转换
|
||||||
|
const manifestNoAll = this.model.manifestNo
|
||||||
// 从清单编号截取英文缩写
|
// 从清单编号截取英文缩写
|
||||||
this.model.manifestNo = this.model.manifestNo.split('-')[1]
|
this.model.manifestNo = manifestNoAll.split('-')[1]
|
||||||
|
// 清单标号 里面的序号
|
||||||
|
this.model.columnNo = manifestNoAll.split('-')[2]
|
||||||
|
|
||||||
// 显示清单编号英文名称缩写
|
// 显示清单编号英文名称缩写
|
||||||
this.isShowManifestNo = true
|
this.isShowManifestNo = true
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.form.setFieldsValue(pick(this.model, 'country', 'manifestNo', 'customColumnName', 'drivePosition', 'securityLevel', 'manifestDesc', 'file'))
|
this.form.setFieldsValue(pick(this.model, 'country', 'manifestNo', 'customColumnName', 'drivePosition', 'securityLevel', 'manifestDesc', 'file'))
|
||||||
})
|
})
|
||||||
|
this.$forceUpdate()
|
||||||
}
|
}
|
||||||
}).finally(() => {
|
}).finally(() => {
|
||||||
this.pageLoading = false
|
this.pageLoading = false
|
||||||
@@ -715,4 +746,16 @@ export default {
|
|||||||
z-index: 999;
|
z-index: 999;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/deep/.block-form-item{
|
||||||
|
clear: both;
|
||||||
|
.ant-form-item-children {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
input {
|
||||||
|
flex: 1;
|
||||||
|
margin: 0 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user