[update] 零部件名称修改
This commit is contained in:
@@ -31,13 +31,14 @@
|
||||
<div class="modal-content">
|
||||
<a-table
|
||||
:columns="columns"
|
||||
rowKey="itemValue"
|
||||
rowKey="code"
|
||||
bordered
|
||||
:scroll="{x: '100%'}"
|
||||
:data-source="dataSource"
|
||||
:pagination="ipagination"
|
||||
:row-selection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type: type }"
|
||||
:loading="confirmLoading"
|
||||
:childrenColumnName="['childPartNameList']"
|
||||
@change="handleTableChange">
|
||||
<template slot="text" slot-scope="text">
|
||||
<a-tooltip overlay-class-name="tooltip-style">
|
||||
@@ -49,7 +50,7 @@
|
||||
</div>
|
||||
<p class="modal-content-title">{{ $t('treeSelection.selectedData') }}</p>
|
||||
<div v-if="dataSourceRight && dataSourceRight.length > 0" class="name-content">
|
||||
<div v-for="(item, index) in dataSourceRight" :key="item.itemValue" class="name-div">
|
||||
<div v-for="(item, index) in dataSourceRight" :key="item.code" class="name-div">
|
||||
{{ item.itemText }}
|
||||
<a-icon type="close" @click="handleDelete(item, index)" />
|
||||
</div>
|
||||
@@ -117,7 +118,7 @@ export default {
|
||||
columns: [
|
||||
{
|
||||
title: this.$t('system.tag.name'),
|
||||
dataIndex: 'title'
|
||||
dataIndex: 'name'
|
||||
}
|
||||
],
|
||||
dataSource: [],
|
||||
@@ -186,7 +187,7 @@ export default {
|
||||
if (selectedRowKeys.length > this.dataSourceRight.length) {
|
||||
// 说明是增加了数据
|
||||
for (const rowIndex in selectedRows) {
|
||||
if (!this.dataSourceRight.find(item => item.itemValue === selectedRows[rowIndex].itemValue)) {
|
||||
if (!this.dataSourceRight.find(item => item.code === selectedRows[rowIndex].code)) {
|
||||
// 右侧不存在,追加到右侧表格
|
||||
this.dataSourceRight.push(selectedRows[rowIndex])
|
||||
}
|
||||
@@ -196,7 +197,7 @@ export default {
|
||||
if (selectedRowKeys && selectedRowKeys.length > 0) {
|
||||
// 没有选中数据,说明这一页没有选中数据了
|
||||
for (let i = 0; i < this.dataSourceRight.length; i++) {
|
||||
if (!selectedRowKeys.find(item => item === this.dataSourceRight[i].itemValue)) {
|
||||
if (!selectedRowKeys.find(item => item === this.dataSourceRight[i].code)) {
|
||||
// 表格选中中没有找到这一条数据,说明已经被删了
|
||||
this.dataSourceRight.splice(i, 1)
|
||||
i--
|
||||
@@ -217,7 +218,7 @@ export default {
|
||||
// 名字列表的删除
|
||||
handleDelete (record, index) {
|
||||
this.dataSourceRight.splice(index, 1)
|
||||
this.selectedRowKeys = this.selectedRowKeys.filter(item => item !== record.itemValue)
|
||||
this.selectedRowKeys = this.selectedRowKeys.filter(item => item !== record.code)
|
||||
},
|
||||
handleOk () {
|
||||
if (this.checkRequired && (!this.selectedRowKeys || this.selectedRowKeys.length === 0)) {
|
||||
|
||||
+1
-1
@@ -412,7 +412,7 @@
|
||||
filedName="componentName"
|
||||
type="checkbox"
|
||||
:nameStr="formInline.componentName_dictText"
|
||||
dict-id="1696007957666533377"
|
||||
options-href="/laws/standard/partName/"
|
||||
:disabled="disabled" />
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
|
||||
+1
-1
@@ -391,7 +391,7 @@
|
||||
filedName="componentName"
|
||||
type="checkbox"
|
||||
:nameStr="formInline.componentName_dictText"
|
||||
dict-id="1696007957666533377"
|
||||
options-href="/laws/standard/partName/"
|
||||
:disabled="disabled" />
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
|
||||
@@ -207,7 +207,7 @@
|
||||
filedName="partName"
|
||||
type="checkbox"
|
||||
:nameStr="formInline.partName_dictText"
|
||||
dict-id="1696007957666533377"
|
||||
options-href="/laws/standard/partName/"
|
||||
:disabled="disabled" />
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
|
||||
@@ -362,7 +362,7 @@
|
||||
filedName="componentName"
|
||||
type="checkbox"
|
||||
:nameStr="formInline.componentName_dictText"
|
||||
dict-id="1696007957666533377"
|
||||
options-href="/laws/standard/partName/"
|
||||
:disabled="disabled" />
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
|
||||
@@ -366,7 +366,7 @@
|
||||
filedName="componentName"
|
||||
type="checkbox"
|
||||
:nameStr="formInline.componentName_dictText"
|
||||
dict-id="1696007957666533377"
|
||||
options-href="/laws/standard/partName/"
|
||||
:disabled="disabled" />
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
|
||||
@@ -175,7 +175,7 @@
|
||||
:filedName="item.dbFieldName"
|
||||
type="checkbox"
|
||||
:nameStr="formInline[item.dbFieldName + '_dictText']"
|
||||
:dict-id="item.dictId"
|
||||
:options-href="item.fieldHref"
|
||||
:disabled="disabled || disabledFieldList.includes(item.dbFieldName)" />
|
||||
</a-form-model-item>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user