|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
|
<div class="setInput">
|
|
|
<div class="flexBetween">
|
|
|
- <el-select
|
|
|
+ <!-- <el-select
|
|
|
style="width:45%;"
|
|
|
v-model="from.value"
|
|
|
clearable
|
|
@@ -14,7 +14,12 @@
|
|
|
:value="item.tabId"
|
|
|
>
|
|
|
</el-option>
|
|
|
- </el-select>
|
|
|
+ </el-select> -->
|
|
|
+ <el-input
|
|
|
+ :disabled='true'
|
|
|
+ v-model="htmlData.name"
|
|
|
+ placeholder="请输入内容"
|
|
|
+ ></el-input>
|
|
|
<el-select
|
|
|
style="width:45%;"
|
|
|
v-model="from.type"
|
|
@@ -83,8 +88,7 @@
|
|
|
</div>
|
|
|
|
|
|
<el-button
|
|
|
- class="martop15"
|
|
|
- style="float:right;"
|
|
|
+ style="float:right;margin-top:15px;"
|
|
|
type="info"
|
|
|
size="mini"
|
|
|
@click="saveType()"
|
|
@@ -96,7 +100,7 @@
|
|
|
import { dictionary, saveInput, getColByTabId } from "@/api/manager/AdjustForm";
|
|
|
import { getExcelHtml } from '@/api/exctab/excelmodel'
|
|
|
export default {
|
|
|
- props: ['pkeyId'],
|
|
|
+ props: ['pkeyId', 'htmlData'],
|
|
|
data () {
|
|
|
return {
|
|
|
elementName: [],
|
|
@@ -119,7 +123,7 @@ export default {
|
|
|
saveType () {//保存设置按钮
|
|
|
this.disabled = true
|
|
|
|
|
|
- if (this.from.type && this.from.value) {
|
|
|
+ if (this.from.type && this.htmlData.name) {
|
|
|
let ks = false
|
|
|
if (this.from.type == 'select' | this.from.type == 'radio' | this.from.type == 'checkbox') {
|
|
|
if (this.setInputTable) {
|
|
@@ -137,7 +141,7 @@ export default {
|
|
|
this.disabled = false
|
|
|
} else {
|
|
|
this.saveInput({
|
|
|
- colId: this.from.value,
|
|
|
+ colId: this.htmlData.name,
|
|
|
nodeId: this.pkeyId,
|
|
|
textId: this.from.type,
|
|
|
textInfo: this.setInputTable
|
|
@@ -145,7 +149,7 @@ export default {
|
|
|
}
|
|
|
} else {
|
|
|
this.saveInput({
|
|
|
- colId: this.from.value,
|
|
|
+ colId: this.htmlData.name,
|
|
|
nodeId: this.pkeyId,
|
|
|
textId: this.from.type,
|
|
|
textInfo: []
|
|
@@ -170,18 +174,18 @@ export default {
|
|
|
this.getExcelHtml()
|
|
|
}
|
|
|
},
|
|
|
- async getColByTabId () {//获取字段信息
|
|
|
- const { data: res } = await getColByTabId({ tabId: this.pkeyId })
|
|
|
- console.log(res);
|
|
|
- if (res.code === 200) {
|
|
|
- this.elementName = res.data
|
|
|
- }
|
|
|
- },
|
|
|
+ // async getColByTabId () {//获取字段信息
|
|
|
+ // const { data: res } = await getColByTabId({ tabId: this.pkeyId })
|
|
|
+ // console.log(res);
|
|
|
+ // if (res.code === 200) {
|
|
|
+ // this.elementName = res.data
|
|
|
+ // }
|
|
|
+ // },
|
|
|
async getExcelHtml () {
|
|
|
const { data: res } = await getExcelHtml({ excelId: this.excelId })
|
|
|
console.log(res);
|
|
|
if (res.code === 200) {
|
|
|
- this.from.value = ''
|
|
|
+ this.htmlData.name = ''
|
|
|
this.from.type = ''
|
|
|
this.setInputTable = []
|
|
|
localStorage.setItem('excelHtml', res.data)
|
|
@@ -191,7 +195,7 @@ export default {
|
|
|
},
|
|
|
created () {
|
|
|
this.dictionary() //获取文本类型接口
|
|
|
- this.getColByTabId()
|
|
|
+ // this.getColByTabId()
|
|
|
},
|
|
|
}
|
|
|
</script>
|