Commit 69edd48a authored by 何远江's avatar 何远江

bug 修改

parent c223e890
......@@ -649,6 +649,7 @@ watch(connectVisible, (val) => {
)
if (index > -1) {
const beConnectFiledItem = beConnectFiled[index]
const connectFiledItem = connectFiled[index]
return {
title: item.title,
sheet: item.sheet,
......@@ -657,8 +658,8 @@ watch(connectVisible, (val) => {
numFlag: item.numFlag,
numTitle: item.numTitle,
only: item.only,
script: item.script,
scriptName: item.scriptName,
script: connectFiledItem.script,
scriptName: connectFiledItem.scriptName,
bescriptName: beConnectFiledItem.scriptName,
bescript: beConnectFiledItem.script,
betitle: beConnectFiledItem.title,
......
......@@ -150,7 +150,13 @@
</template>
</vxe-modal>
<vxe-modal v-model="connectVisible" width="1000" title="关联信息配置" show-footer>
<vxe-modal
v-model="connectVisible"
@hide="onHideSettingConnect"
width="1000"
title="关联信息配置"
show-footer
>
<p>关联区域信息:{{ currentConnectInfo.excelAreaNicname }}</p>
<p>被关联信息:{{ cachCurrentBeConnectInfo.excelAreaNicname }}</p>
......@@ -158,7 +164,6 @@
class="mt-2"
size="mini"
:data="connectConfigData"
@hide="onHideSettingConnect"
border
height="400"
ref="xTableConnect"
......@@ -649,7 +654,8 @@ watch(connectVisible, (val) => {
connectConfigData.value = titles.map((item: any) => {
// 全部列,并且匹配已经绑定的列
if (currentConnectInfo.excelAreaConnectId) {
if (currentConnectInfo.varAreaConnectId) {
console.log('zhixing -------')
// 按照顺序来赋值connectFiled -> beConnectFiled
const connectFiled = cachConnectEditInfo.value?.connectFiled || []
const beConnectFiled = cachConnectEditInfo.value?.beConnectFiled
......@@ -659,6 +665,7 @@ watch(connectVisible, (val) => {
)
if (index > -1) {
const beConnectFiledItem = beConnectFiled[index]
const connectFiledItem = connectFiled[index]
return {
title: item.title,
sheet: item.sheet,
......@@ -667,8 +674,8 @@ watch(connectVisible, (val) => {
numFlag: item.numFlag,
numTitle: item.numTitle,
only: item.only,
script: item.script,
scriptName: item.scriptName,
script: connectFiledItem.script,
scriptName: connectFiledItem.scriptName,
bescriptName: beConnectFiledItem.scriptName,
bescript: beConnectFiledItem.script,
betitle: beConnectFiledItem.title,
......@@ -704,6 +711,8 @@ watch(connectVisible, (val) => {
const onHideSettingConnect = () => {
// 清空
cachConnectEditInfo.value = {}
currentConnectInfo.varAreaConnectId = ''
console.log('清空----===')
}
const changeBeConnect = (v: string, row: any) => {
const option = beConnectSelectOptions.value.find((item: any) => item.title == v)
......@@ -751,8 +760,8 @@ const chooseConnectOnHide = () => {
const editConnect = async (row: any, index: number) => {
console.log(row)
currentConnectInfo.excelAreaConnectId = row.excelAreaConnectId
currentConnectInfo.excelAreaBeId = row.excelAreaBeId
currentConnectInfo.varAreaConnectId = row.varAreaConnectId
currentConnectInfo.varAreaBeId = row.varAreaBeId
currentConnectInfo.varAreaId = row.varAreaId
Object.assign(cachConnectEditInfo.value, unref(row))
......@@ -764,7 +773,7 @@ const editConnect = async (row: any, index: number) => {
// cachCurrentBeConnectInfo 保存被关联数据
Object.assign(
cachCurrentBeConnectInfo,
unref(areaList.value?.find((item) => item.varAreaId == row.excelAreaBeId))
unref(areaList.value?.find((item) => item.varAreaId == row.varAreaBeId))
)
connectVisible.value = true
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment