|
|
@ -10,24 +10,23 @@ |
|
|
|
flex-flow: column nowrap; |
|
|
|
flex-flow: column nowrap; |
|
|
|
gap: 20px; |
|
|
|
gap: 20px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.filed-container::before { |
|
|
|
.filed-container::before { |
|
|
|
content: ''; |
|
|
|
content: ""; |
|
|
|
position: absolute; |
|
|
|
position: absolute; |
|
|
|
top: 0; |
|
|
|
top: 0; |
|
|
|
left: 50%; |
|
|
|
left: 50%; |
|
|
|
width: 2px; |
|
|
|
width: 2px; |
|
|
|
height: 100%; |
|
|
|
height: 100%; |
|
|
|
background-image: linear-gradient( |
|
|
|
background-image: linear-gradient(to bottom, #e6f3ff, #fff7e6); |
|
|
|
to bottom, |
|
|
|
|
|
|
|
#e6f3ff, |
|
|
|
|
|
|
|
#fff7e6 |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
border-radius: 50%; |
|
|
|
border-radius: 50%; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-container { |
|
|
|
.info-container { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-item { |
|
|
|
.info-item { |
|
|
|
flex: 1; |
|
|
|
flex: 1; |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
@ -36,15 +35,18 @@ |
|
|
|
flex-flow: column; |
|
|
|
flex-flow: column; |
|
|
|
gap: 20px; |
|
|
|
gap: 20px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.footer { |
|
|
|
.footer { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
justify-content: space-between; |
|
|
|
justify-content: space-between; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.footer-item { |
|
|
|
.footer-item { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
|
gap: 10px; |
|
|
|
gap: 10px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-item-title { |
|
|
|
.info-item-title { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
@ -53,6 +55,7 @@ |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
gap: 10px; |
|
|
|
gap: 10px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-item-upload { |
|
|
|
.info-item-upload { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
@ -63,11 +66,13 @@ |
|
|
|
color: #419ff8; |
|
|
|
color: #419ff8; |
|
|
|
border-bottom: 1px solid #419ff8; |
|
|
|
border-bottom: 1px solid #419ff8; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-item-input-container { |
|
|
|
.info-item-input-container { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
|
gap: 5px; |
|
|
|
gap: 5px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-item-input { |
|
|
|
.info-item-input { |
|
|
|
width: 200px; |
|
|
|
width: 200px; |
|
|
|
height: 32px; |
|
|
|
height: 32px; |
|
|
@ -80,56 +85,66 @@ |
|
|
|
outline: none; |
|
|
|
outline: none; |
|
|
|
box-sizing: border-box; |
|
|
|
box-sizing: border-box; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-form-container { |
|
|
|
.info-form-container { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
flex-flow: row nowrap; |
|
|
|
flex-flow: row nowrap; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
|
gap: 10px; |
|
|
|
gap: 10px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table { |
|
|
|
.table { |
|
|
|
width: 100%; |
|
|
|
width: 100%; |
|
|
|
table-layout: fixed; |
|
|
|
table-layout: fixed; |
|
|
|
border-collapse: collapse; |
|
|
|
border-collapse: collapse; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th, |
|
|
|
.table th, |
|
|
|
.table td { |
|
|
|
.table td { |
|
|
|
overflow: hidden; |
|
|
|
overflow: hidden; |
|
|
|
text-overflow: ellipsis; |
|
|
|
text-overflow: ellipsis; |
|
|
|
white-space: nowrap; |
|
|
|
white-space: nowrap; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th:nth-child(1), |
|
|
|
.table th:nth-child(1), |
|
|
|
.table td:nth-child(1) { |
|
|
|
.table td:nth-child(1) { |
|
|
|
width: 70px; |
|
|
|
width: 70px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th:nth-child(2), |
|
|
|
.table th:nth-child(2), |
|
|
|
.table td:nth-child(2), |
|
|
|
.table td:nth-child(2), |
|
|
|
.table th:nth-child(6), |
|
|
|
.table th:nth-child(6), |
|
|
|
.table td:nth-child(6) { |
|
|
|
.table td:nth-child(6) { |
|
|
|
width: 125px; |
|
|
|
width: 125px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th:nth-child(3), |
|
|
|
.table th:nth-child(3), |
|
|
|
.table td:nth-child(3), |
|
|
|
.table td:nth-child(3), |
|
|
|
.table th:nth-child(7), |
|
|
|
.table th:nth-child(7), |
|
|
|
.table td:nth-child(7) { |
|
|
|
.table td:nth-child(7) { |
|
|
|
width: 120px; |
|
|
|
width: 120px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th:nth-child(4), |
|
|
|
.table th:nth-child(4), |
|
|
|
.table td:nth-child(4), |
|
|
|
.table td:nth-child(4), |
|
|
|
.table th:nth-child(8), |
|
|
|
.table th:nth-child(8), |
|
|
|
.table td:nth-child(8) { |
|
|
|
.table td:nth-child(8) { |
|
|
|
width: 100px; |
|
|
|
width: 100px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th:nth-child(5), |
|
|
|
.table th:nth-child(5), |
|
|
|
.table td:nth-child(5), |
|
|
|
.table td:nth-child(5), |
|
|
|
.table th:nth-child(9), |
|
|
|
.table th:nth-child(9), |
|
|
|
.table td:nth-child(9) { |
|
|
|
.table td:nth-child(9) { |
|
|
|
width: 100px; |
|
|
|
width: 100px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table th:nth-child(10), |
|
|
|
.table th:nth-child(10), |
|
|
|
.table td:nth-child(10) { |
|
|
|
.table td:nth-child(10) { |
|
|
|
width: 70px; |
|
|
|
width: 70px; |
|
|
|
text-align: center; |
|
|
|
text-align: center; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.footer-item-button { |
|
|
|
.footer-item-button { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
@ -143,12 +158,14 @@ |
|
|
|
color: #333; |
|
|
|
color: #333; |
|
|
|
gap: 5px; |
|
|
|
gap: 5px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table-row { |
|
|
|
.table-row { |
|
|
|
display: flex; |
|
|
|
display: flex; |
|
|
|
flex-flow: row nowrap; |
|
|
|
flex-flow: row nowrap; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
|
justify-content: center; |
|
|
|
justify-content: center; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.local-park, |
|
|
|
.local-park, |
|
|
|
.third-park { |
|
|
|
.third-park { |
|
|
|
width: 100%; |
|
|
|
width: 100%; |
|
|
@ -158,10 +175,12 @@ |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
|
justify-content: center; |
|
|
|
justify-content: center; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.local-park th, |
|
|
|
.local-park th, |
|
|
|
.third-park th { |
|
|
|
.third-park th { |
|
|
|
flex: 1; |
|
|
|
flex: 1; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table-item-input { |
|
|
|
.table-item-input { |
|
|
|
width: 100%; |
|
|
|
width: 100%; |
|
|
|
padding: 8px 12px; |
|
|
|
padding: 8px 12px; |
|
|
@ -185,6 +204,7 @@ |
|
|
|
color: #c0c4cc; |
|
|
|
color: #c0c4cc; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table-item-select { |
|
|
|
.table-item-select { |
|
|
|
width: 100%; |
|
|
|
width: 100%; |
|
|
|
padding: 8px 12px; |
|
|
|
padding: 8px 12px; |
|
|
@ -195,6 +215,7 @@ |
|
|
|
outline: none; |
|
|
|
outline: none; |
|
|
|
box-sizing: border-box; |
|
|
|
box-sizing: border-box; |
|
|
|
border: none; |
|
|
|
border: none; |
|
|
|
|
|
|
|
|
|
|
|
&:disabled { |
|
|
|
&:disabled { |
|
|
|
background-color: #f5f7fa; |
|
|
|
background-color: #f5f7fa; |
|
|
|
border-color: #e4e7ed; |
|
|
|
border-color: #e4e7ed; |
|
|
@ -206,6 +227,7 @@ |
|
|
|
color: #c0c4cc; |
|
|
|
color: #c0c4cc; |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.table-item-button { |
|
|
|
.table-item-button { |
|
|
|
display: inline-flex; |
|
|
|
display: inline-flex; |
|
|
|
align-items: center; |
|
|
|
align-items: center; |
|
|
@ -219,6 +241,7 @@ |
|
|
|
transition: all 0.2s ease; |
|
|
|
transition: all 0.2s ease; |
|
|
|
height: 32px; |
|
|
|
height: 32px; |
|
|
|
width: 32px; |
|
|
|
width: 32px; |
|
|
|
|
|
|
|
|
|
|
|
&:hover { |
|
|
|
&:hover { |
|
|
|
background-color: #f2f6fc; |
|
|
|
background-color: #f2f6fc; |
|
|
|
color: #409eff; |
|
|
|
color: #409eff; |
|
|
@ -232,7 +255,7 @@ |
|
|
|
font-size: 20px; |
|
|
|
font-size: 20px; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
&[title='保存'] { |
|
|
|
&[title="保存"] { |
|
|
|
color: #67c23a; |
|
|
|
color: #67c23a; |
|
|
|
|
|
|
|
|
|
|
|
&:hover { |
|
|
|
&:hover { |
|
|
@ -240,7 +263,7 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
&[title='取消'] { |
|
|
|
&[title="取消"] { |
|
|
|
color: #909399; |
|
|
|
color: #909399; |
|
|
|
|
|
|
|
|
|
|
|
&:hover { |
|
|
|
&:hover { |
|
|
@ -248,7 +271,7 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
&[title='删除'] { |
|
|
|
&[title="删除"] { |
|
|
|
color: #f56c6c; |
|
|
|
color: #f56c6c; |
|
|
|
|
|
|
|
|
|
|
|
&:hover { |
|
|
|
&:hover { |
|
|
@ -256,29 +279,21 @@ |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
.info-item-upload-name { |
|
|
|
.info-item-upload-name { |
|
|
|
color: #01c853; |
|
|
|
color: #01c853; |
|
|
|
} |
|
|
|
} |
|
|
|
</style> |
|
|
|
</style> |
|
|
|
<div |
|
|
|
<div id="apibox" class="card"> |
|
|
|
id="apibox" |
|
|
|
|
|
|
|
class="card" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<section class="filed-container"> |
|
|
|
<section class="filed-container"> |
|
|
|
<section class="info-container"> |
|
|
|
<section class="info-container"> |
|
|
|
<section class="info-item"> |
|
|
|
<section class="info-item"> |
|
|
|
<section class="info-item-title"> |
|
|
|
<section class="info-item-title"> |
|
|
|
本地表 |
|
|
|
本地表 |
|
|
|
<section |
|
|
|
<section class="info-item-upload-name" v-show="localJosnName"> |
|
|
|
class="info-item-upload-name" |
|
|
|
|
|
|
|
v-show="localJosnName" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
{{`(${localJosnName})`}} |
|
|
|
{{`(${localJosnName})`}} |
|
|
|
</section> |
|
|
|
</section> |
|
|
|
<section |
|
|
|
<section class="info-item-upload" @click="uploadLocalFile"> |
|
|
|
class="info-item-upload" |
|
|
|
|
|
|
|
@click="uploadLocalFile" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<input |
|
|
|
<input |
|
|
|
type="file" |
|
|
|
type="file" |
|
|
|
style="opacity: 0; display: none" |
|
|
|
style="opacity: 0; display: none" |
|
|
@ -311,16 +326,10 @@ |
|
|
|
<section class="info-item"> |
|
|
|
<section class="info-item"> |
|
|
|
<section class="info-item-title"> |
|
|
|
<section class="info-item-title"> |
|
|
|
三方表 |
|
|
|
三方表 |
|
|
|
<section |
|
|
|
<section class="info-item-upload-name" v-show="thirdJsonName"> |
|
|
|
class="info-item-upload-name" |
|
|
|
|
|
|
|
v-show="thirdJsonName" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
({{thirdJsonName}}) |
|
|
|
({{thirdJsonName}}) |
|
|
|
</section> |
|
|
|
</section> |
|
|
|
<section |
|
|
|
<section class="info-item-upload" @click="uploadThirdFile"> |
|
|
|
class="info-item-upload" |
|
|
|
|
|
|
|
@click="uploadThirdFile" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<input |
|
|
|
<input |
|
|
|
type="file" |
|
|
|
type="file" |
|
|
|
style="opacity: 0; display: none" |
|
|
|
style="opacity: 0; display: none" |
|
|
@ -356,63 +365,29 @@ |
|
|
|
<tr> |
|
|
|
<tr> |
|
|
|
<th>序号</th> |
|
|
|
<th>序号</th> |
|
|
|
<th style="background-color: #e6f3ff">字段名</th> |
|
|
|
<th style="background-color: #e6f3ff">字段名</th> |
|
|
|
<th style="background-color: #e6f3ff"> |
|
|
|
<th style="background-color: #e6f3ff">字段注释</th> |
|
|
|
字段注释 |
|
|
|
<th style="background-color: #e6f3ff">字段类型</th> |
|
|
|
</th> |
|
|
|
<th style="background-color: #e6f3ff">字典名称</th> |
|
|
|
<th style="background-color: #e6f3ff"> |
|
|
|
|
|
|
|
字段类型 |
|
|
|
|
|
|
|
</th> |
|
|
|
|
|
|
|
<th style="background-color: #e6f3ff"> |
|
|
|
|
|
|
|
字典名称 |
|
|
|
|
|
|
|
</th> |
|
|
|
|
|
|
|
<th style="background-color: #fff7e6">字段名</th> |
|
|
|
<th style="background-color: #fff7e6">字段名</th> |
|
|
|
<th style="background-color: #fff7e6"> |
|
|
|
<th style="background-color: #fff7e6">字段注释</th> |
|
|
|
字段注释 |
|
|
|
<th style="background-color: #fff7e6">字段类型</th> |
|
|
|
</th> |
|
|
|
<th style="background-color: #fff7e6">字典名称</th> |
|
|
|
<th style="background-color: #fff7e6"> |
|
|
|
|
|
|
|
字段类型 |
|
|
|
|
|
|
|
</th> |
|
|
|
|
|
|
|
<th style="background-color: #fff7e6"> |
|
|
|
|
|
|
|
字典名称 |
|
|
|
|
|
|
|
</th> |
|
|
|
|
|
|
|
<th>操作</th> |
|
|
|
<th>操作</th> |
|
|
|
</tr> |
|
|
|
</tr> |
|
|
|
</thead> |
|
|
|
</thead> |
|
|
|
<tbody> |
|
|
|
<tbody> |
|
|
|
<tr |
|
|
|
<tr v-for="(item, index) in data" :key="index"> |
|
|
|
v-for="(item, index) in data" |
|
|
|
|
|
|
|
:key="index" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<td style="width: 150px">{{index + 1}}</td> |
|
|
|
<td style="width: 150px">{{index + 1}}</td> |
|
|
|
<td |
|
|
|
<td style="background-color: #f5f9ff; position: relative"> |
|
|
|
style=" |
|
|
|
|
|
|
|
background-color: #f5f9ff; |
|
|
|
|
|
|
|
position: relative; |
|
|
|
|
|
|
|
" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
{{item.SYSTEM_FIELD}} |
|
|
|
{{item.SYSTEM_FIELD}} |
|
|
|
</td> |
|
|
|
</td> |
|
|
|
<td style="background-color: #f5f9ff"> |
|
|
|
<td style="background-color: #f5f9ff">{{item.SYSTEM_NAME}}</td> |
|
|
|
{{item.SYSTEM_NAME}} |
|
|
|
<td style="background-color: #f5f9ff">{{item.SYSTEM_FIELD_TYPE}}</td> |
|
|
|
</td> |
|
|
|
<td style="background-color: #f5f9ff">{{item.SYSTEM_DICT_NAME}}</td> |
|
|
|
<td style="background-color: #f5f9ff"> |
|
|
|
<td style="background-color: #fffbf2">{{item.INTERFACE_FIELD}}</td> |
|
|
|
{{item.SYSTEM_FIELD_TYPE}} |
|
|
|
<td style="background-color: #fffbf2">{{item.INTERFACE_NAME}}</td> |
|
|
|
</td> |
|
|
|
<td style="background-color: #fffbf2">{{item.OBJECT_FIELD_TYPE}}</td> |
|
|
|
<td style="background-color: #f5f9ff"> |
|
|
|
<td style="background-color: #fffbf2">{{item.OBJECT_DICT_NAME}}</td> |
|
|
|
{{item.SYSTEM_DICT_NAME}} |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
<td style="background-color: #fffbf2"> |
|
|
|
|
|
|
|
{{item.INTERFACE_FIELD}} |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
<td style="background-color: #fffbf2"> |
|
|
|
|
|
|
|
{{item.INTERFACE_NAME}} |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
<td style="background-color: #fffbf2"> |
|
|
|
|
|
|
|
{{item.OBJECT_FIELD_TYPE}} |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
<td style="background-color: #fffbf2"> |
|
|
|
|
|
|
|
{{item.OBJECT_DICT_NAME}} |
|
|
|
|
|
|
|
</td> |
|
|
|
|
|
|
|
<td> |
|
|
|
<td> |
|
|
|
<button |
|
|
|
<button |
|
|
|
@click="deleteField(index)" |
|
|
|
@click="deleteField(index)" |
|
|
@ -425,12 +400,7 @@ |
|
|
|
</tr> |
|
|
|
</tr> |
|
|
|
<tr v-show="isEditing"> |
|
|
|
<tr v-show="isEditing"> |
|
|
|
<td style="width: 150px">{{data.length + 1}}</td> |
|
|
|
<td style="width: 150px">{{data.length + 1}}</td> |
|
|
|
<td |
|
|
|
<td style="background-color: #f5f9ff; position: relative"> |
|
|
|
style=" |
|
|
|
|
|
|
|
background-color: #f5f9ff; |
|
|
|
|
|
|
|
position: relative; |
|
|
|
|
|
|
|
" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<input |
|
|
|
<input |
|
|
|
v-model="submitData.SYSTEM_FIELD" |
|
|
|
v-model="submitData.SYSTEM_FIELD" |
|
|
|
class="table-item-select" |
|
|
|
class="table-item-select" |
|
|
@ -498,12 +468,7 @@ |
|
|
|
:style="{display: submitData.SYSTEM_FIELD_TYPE == 'dict' ? 'block' : 'none'}" |
|
|
|
:style="{display: submitData.SYSTEM_FIELD_TYPE == 'dict' ? 'block' : 'none'}" |
|
|
|
/> |
|
|
|
/> |
|
|
|
</td> |
|
|
|
</td> |
|
|
|
<td |
|
|
|
<td style="background-color: #fffbf2; position: relative"> |
|
|
|
style=" |
|
|
|
|
|
|
|
background-color: #fffbf2; |
|
|
|
|
|
|
|
position: relative; |
|
|
|
|
|
|
|
" |
|
|
|
|
|
|
|
> |
|
|
|
|
|
|
|
<input |
|
|
|
<input |
|
|
|
v-model="submitData.INTERFACE_FIELD" |
|
|
|
v-model="submitData.INTERFACE_FIELD" |
|
|
|
class="table-item-select" |
|
|
|
class="table-item-select" |
|
|
@ -621,7 +586,7 @@ |
|
|
|
</div> |
|
|
|
</div> |
|
|
|
<script> |
|
|
|
<script> |
|
|
|
var vueObj = new Vue({ |
|
|
|
var vueObj = new Vue({ |
|
|
|
el: '#apibox', |
|
|
|
el: "#apibox", |
|
|
|
data() { |
|
|
|
data() { |
|
|
|
return { |
|
|
|
return { |
|
|
|
dict: { |
|
|
|
dict: { |
|
|
@ -630,167 +595,160 @@ |
|
|
|
isEditing: true, |
|
|
|
isEditing: true, |
|
|
|
data: [ |
|
|
|
data: [ |
|
|
|
{ |
|
|
|
{ |
|
|
|
SYSTEM_NAME: '测试1', |
|
|
|
SYSTEM_NAME: "测试1", |
|
|
|
SYSTEM_FIELD: 'test1', |
|
|
|
SYSTEM_FIELD: "test1", |
|
|
|
INTERFACE_NAME: '测试2', |
|
|
|
INTERFACE_NAME: "测试2", |
|
|
|
INTERFACE_FIELD: 'test2', |
|
|
|
INTERFACE_FIELD: "test2", |
|
|
|
SYSTEM_FIELD_TYPE: 'value', |
|
|
|
SYSTEM_FIELD_TYPE: "value", |
|
|
|
SYSTEM_DICT_NAME: '', |
|
|
|
SYSTEM_DICT_NAME: "", |
|
|
|
OBJECT_FIELD_TYPE: 'value', |
|
|
|
OBJECT_FIELD_TYPE: "value", |
|
|
|
OBJECT_DICT_NAME: '', |
|
|
|
OBJECT_DICT_NAME: "", |
|
|
|
}, |
|
|
|
}, |
|
|
|
{ |
|
|
|
{ |
|
|
|
SYSTEM_NAME: '测试2', |
|
|
|
SYSTEM_NAME: "测试2", |
|
|
|
SYSTEM_FIELD: 'test2', |
|
|
|
SYSTEM_FIELD: "test2", |
|
|
|
INTERFACE_NAME: '测试3', |
|
|
|
INTERFACE_NAME: "测试3", |
|
|
|
INTERFACE_FIELD: 'test3', |
|
|
|
INTERFACE_FIELD: "test3", |
|
|
|
SYSTEM_FIELD_TYPE: 'value', |
|
|
|
SYSTEM_FIELD_TYPE: "value", |
|
|
|
SYSTEM_DICT_NAME: '', |
|
|
|
SYSTEM_DICT_NAME: "", |
|
|
|
OBJECT_FIELD_TYPE: 'value', |
|
|
|
OBJECT_FIELD_TYPE: "value", |
|
|
|
OBJECT_DICT_NAME: '', |
|
|
|
OBJECT_DICT_NAME: "", |
|
|
|
}, |
|
|
|
}, |
|
|
|
], |
|
|
|
], |
|
|
|
localJsonData: {}, |
|
|
|
localJsonData: {}, |
|
|
|
localJosnName: '', |
|
|
|
localJosnName: "", |
|
|
|
thirdJsonData: {}, |
|
|
|
thirdJsonData: {}, |
|
|
|
thirdJsonName: '', |
|
|
|
thirdJsonName: "", |
|
|
|
submitData: { |
|
|
|
submitData: { |
|
|
|
SYSTEM_NAME: '', |
|
|
|
SYSTEM_NAME: "", |
|
|
|
SYSTEM_FIELD: '', |
|
|
|
SYSTEM_FIELD: "", |
|
|
|
INTERFACE_NAME: '', |
|
|
|
INTERFACE_NAME: "", |
|
|
|
INTERFACE_FIELD: '', |
|
|
|
INTERFACE_FIELD: "", |
|
|
|
SYSTEM_FIELD_TYPE: 'value', |
|
|
|
SYSTEM_FIELD_TYPE: "value", |
|
|
|
SYSTEM_DICT_NAME: '', |
|
|
|
SYSTEM_DICT_NAME: "", |
|
|
|
OBJECT_FIELD_TYPE: 'value', |
|
|
|
OBJECT_FIELD_TYPE: "value", |
|
|
|
OBJECT_DICT_NAME: '', |
|
|
|
OBJECT_DICT_NAME: "", |
|
|
|
}, |
|
|
|
}, |
|
|
|
cachesData: { |
|
|
|
cachesData: { |
|
|
|
ID: 0.0, |
|
|
|
|
|
|
|
OBJECT_TABLE_NAME: 'test2', |
|
|
|
OBJECT_TABLE_NAME: "test2", |
|
|
|
OBJECT_TABLE_CNNAME: '测试2', |
|
|
|
OBJECT_TABLE_CNNAME: "测试2", |
|
|
|
SYSTEM_TABLE_CNNAME: '测试1', |
|
|
|
SYSTEM_TABLE_CNNAME: "测试1", |
|
|
|
SYSTEM_TABLE_NAME: 'test1', |
|
|
|
SYSTEM_TABLE_NAME: "test1", |
|
|
|
}, |
|
|
|
}, |
|
|
|
} |
|
|
|
}; |
|
|
|
}, |
|
|
|
}, |
|
|
|
created() { |
|
|
|
created() { |
|
|
|
this.getDictOption() |
|
|
|
this.getDictOption(); |
|
|
|
}, |
|
|
|
}, |
|
|
|
mounted() {}, |
|
|
|
mounted() {}, |
|
|
|
methods: { |
|
|
|
methods: { |
|
|
|
getDictOption() { |
|
|
|
getDictOption() { |
|
|
|
axios |
|
|
|
axios |
|
|
|
.get( |
|
|
|
.get("/dict_data/simpleList?type=std_filed_type", jwHeader) |
|
|
|
'/dict_data/simpleList?type=std_filed_type', |
|
|
|
.then((res) => { |
|
|
|
jwHeader |
|
|
|
this.dict.filedType = res.data; |
|
|
|
) |
|
|
|
}); |
|
|
|
.then(res => { |
|
|
|
|
|
|
|
this.dict.filedType = res.data |
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
}, |
|
|
|
}, |
|
|
|
uploadLocalFile() { |
|
|
|
uploadLocalFile() { |
|
|
|
document.getElementById('localFile').click() |
|
|
|
document.getElementById("localFile").click(); |
|
|
|
document.getElementById('localFile').onchange = |
|
|
|
document.getElementById("localFile").onchange = () => { |
|
|
|
() => { |
|
|
|
const file = document.getElementById("localFile").files[0]; |
|
|
|
const file = |
|
|
|
this.localJosnName = file.name; |
|
|
|
document.getElementById('localFile').files[0] |
|
|
|
const reader = new FileReader(); |
|
|
|
this.localJosnName = file.name |
|
|
|
reader.readAsText(file); |
|
|
|
const reader = new FileReader() |
|
|
|
|
|
|
|
reader.readAsText(file) |
|
|
|
|
|
|
|
reader.onload = () => { |
|
|
|
reader.onload = () => { |
|
|
|
this.localJsonData = JSON.parse(reader.result) |
|
|
|
this.localJsonData = JSON.parse(reader.result); |
|
|
|
} |
|
|
|
}; |
|
|
|
} |
|
|
|
}; |
|
|
|
}, |
|
|
|
}, |
|
|
|
uploadThirdFile() { |
|
|
|
uploadThirdFile() { |
|
|
|
document.getElementById('thirdFile').click() |
|
|
|
document.getElementById("thirdFile").click(); |
|
|
|
document.getElementById('thirdFile').onchange = |
|
|
|
document.getElementById("thirdFile").onchange = () => { |
|
|
|
() => { |
|
|
|
const file = document.getElementById("thirdFile").files[0]; |
|
|
|
const file = |
|
|
|
this.thirdJsonName = file.name; |
|
|
|
document.getElementById('thirdFile').files[0] |
|
|
|
const reader = new FileReader(); |
|
|
|
this.thirdJsonName = file.name |
|
|
|
reader.readAsText(file); |
|
|
|
const reader = new FileReader() |
|
|
|
|
|
|
|
reader.readAsText(file) |
|
|
|
|
|
|
|
reader.onload = () => { |
|
|
|
reader.onload = () => { |
|
|
|
this.thirdJsonData = JSON.parse(reader.result) |
|
|
|
this.thirdJsonData = JSON.parse(reader.result); |
|
|
|
} |
|
|
|
}; |
|
|
|
} |
|
|
|
}; |
|
|
|
}, |
|
|
|
}, |
|
|
|
addNewField() { |
|
|
|
addNewField() { |
|
|
|
this.submitData = { |
|
|
|
this.submitData = { |
|
|
|
SYSTEM_NAME: '', |
|
|
|
SYSTEM_NAME: "", |
|
|
|
SYSTEM_FIELD: '', |
|
|
|
SYSTEM_FIELD: "", |
|
|
|
INTERFACE_NAME: '', |
|
|
|
INTERFACE_NAME: "", |
|
|
|
INTERFACE_FIELD: '', |
|
|
|
INTERFACE_FIELD: "", |
|
|
|
SYSTEM_FIELD_TYPE: 'value', |
|
|
|
SYSTEM_FIELD_TYPE: "value", |
|
|
|
SYSTEM_DICT_NAME: '', |
|
|
|
SYSTEM_DICT_NAME: "", |
|
|
|
OBJECT_FIELD_TYPE: 'value', |
|
|
|
OBJECT_FIELD_TYPE: "value", |
|
|
|
OBJECT_DICT_NAME: '', |
|
|
|
OBJECT_DICT_NAME: "", |
|
|
|
} |
|
|
|
}; |
|
|
|
this.isEditing = true |
|
|
|
this.isEditing = true; |
|
|
|
}, |
|
|
|
}, |
|
|
|
saveField(index) { |
|
|
|
saveField(index) { |
|
|
|
this.data.push(this.submitData) |
|
|
|
this.data.push(this.submitData); |
|
|
|
this.isEditing = false |
|
|
|
this.isEditing = false; |
|
|
|
}, |
|
|
|
}, |
|
|
|
cancelField(index) { |
|
|
|
cancelField(index) { |
|
|
|
this.submitData = { |
|
|
|
this.submitData = { |
|
|
|
SYSTEM_NAME: '', |
|
|
|
SYSTEM_NAME: "", |
|
|
|
SYSTEM_FIELD: '', |
|
|
|
SYSTEM_FIELD: "", |
|
|
|
INTERFACE_NAME: '', |
|
|
|
INTERFACE_NAME: "", |
|
|
|
INTERFACE_FIELD: '', |
|
|
|
INTERFACE_FIELD: "", |
|
|
|
SYSTEM_FIELD_TYPE: 'value', |
|
|
|
SYSTEM_FIELD_TYPE: "value", |
|
|
|
SYSTEM_DICT_NAME: '', |
|
|
|
SYSTEM_DICT_NAME: "", |
|
|
|
OBJECT_FIELD_TYPE: 'value', |
|
|
|
OBJECT_FIELD_TYPE: "value", |
|
|
|
OBJECT_DICT_NAME: '', |
|
|
|
OBJECT_DICT_NAME: "", |
|
|
|
} |
|
|
|
}; |
|
|
|
this.isEditing = false |
|
|
|
this.isEditing = false; |
|
|
|
}, |
|
|
|
}, |
|
|
|
deleteField(index) { |
|
|
|
deleteField(index) { |
|
|
|
this.data.splice(index, 1) |
|
|
|
this.data.splice(index, 1); |
|
|
|
}, |
|
|
|
}, |
|
|
|
thridChange(e) { |
|
|
|
thridChange(e) { |
|
|
|
this.submitData.INTERFACE_FIELD = e.target.value |
|
|
|
this.submitData.INTERFACE_FIELD = e.target.value; |
|
|
|
}, |
|
|
|
}, |
|
|
|
localChange(e) { |
|
|
|
localChange(e) { |
|
|
|
this.submitData.SYSTEM_FIELD = e.target.value |
|
|
|
this.submitData.SYSTEM_FIELD = e.target.value; |
|
|
|
}, |
|
|
|
}, |
|
|
|
saveAll() { |
|
|
|
saveAll() { |
|
|
|
if ( |
|
|
|
if ( |
|
|
|
this.cachesData.SYSTEM_TABLE_NAME === '' || |
|
|
|
this.cachesData.SYSTEM_TABLE_NAME === "" || |
|
|
|
this.cachesData.OBJECT_TABLE_NAME === '' |
|
|
|
this.cachesData.OBJECT_TABLE_NAME === "" |
|
|
|
) { |
|
|
|
) { |
|
|
|
tools.alert('请输入表名') |
|
|
|
tools.alert("请输入表名"); |
|
|
|
return |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
if (this.data.length === 0) { |
|
|
|
if (this.data.length === 0) { |
|
|
|
tools.alert('请输入字段') |
|
|
|
tools.alert("请输入字段"); |
|
|
|
return |
|
|
|
return; |
|
|
|
} |
|
|
|
} |
|
|
|
const data = this.data.map(i => { |
|
|
|
const data = this.data.map((i) => { |
|
|
|
return { |
|
|
|
return { |
|
|
|
...this.cachesData, |
|
|
|
...this.cachesData, |
|
|
|
...i, |
|
|
|
...i, |
|
|
|
} |
|
|
|
}; |
|
|
|
}) |
|
|
|
}); |
|
|
|
console.log(data) |
|
|
|
console.log(data); |
|
|
|
axios |
|
|
|
axios |
|
|
|
.post( |
|
|
|
.post( |
|
|
|
`/std_filed/createBatch`, |
|
|
|
`/api/200100/stdobjectmappingcontroller/insertlist`, |
|
|
|
{ Data: JSON.stringify(data) }, |
|
|
|
{ list: data }, |
|
|
|
jwHeader |
|
|
|
jwHeader |
|
|
|
) |
|
|
|
) |
|
|
|
.then(res => { |
|
|
|
.then((res) => { |
|
|
|
tools.highlightErrorFields(res.data) |
|
|
|
tools.highlightErrorFields(res.data); |
|
|
|
// window.location.href = './std_filed_map.html' |
|
|
|
// window.location.href = './std_filed_map.html' |
|
|
|
}) |
|
|
|
}) |
|
|
|
.catch(error => { |
|
|
|
.catch((error) => { |
|
|
|
tools.alert(error.message) |
|
|
|
tools.alert(error.message); |
|
|
|
}) |
|
|
|
}); |
|
|
|
}, |
|
|
|
}, |
|
|
|
cancelAll() { |
|
|
|
cancelAll() { |
|
|
|
window.location.href = './std_filed_map.html' |
|
|
|
window.location.href = "./std_filed_map.html"; |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}, |
|
|
|
}) |
|
|
|
}); |
|
|
|
</script> |
|
|
|
</script> |
|
|
|