1、代码优化,重构逻辑,界面html
2、解决TplKit 因升级导致的模板文件找不到(退回原版本)
This commit is contained in:
@@ -1,21 +1,6 @@
|
||||
<style>
|
||||
.table td, .table th{
|
||||
padding: 6px;
|
||||
}
|
||||
.panel-body {
|
||||
padding: 0;
|
||||
}
|
||||
.tlist>li.active>a,
|
||||
.tlist>li.active>a:focus,
|
||||
.tlist>li.active>a:hover,
|
||||
.tlist>li>a:hover {
|
||||
background-color: #92b0cb;
|
||||
border-bottom: 2px solid #607d8b;
|
||||
color: #fff;
|
||||
}
|
||||
</style>
|
||||
|
||||
<row class="meta-service">
|
||||
<div class="col-md-12" style="padding-top: 10px;">
|
||||
<div class="col-md-12">
|
||||
<div class="info" style="padding-left: 10px">
|
||||
<a @click="showInfo()" href="javascript:;"><i class="icon icon-info"></i></a>
|
||||
</div>
|
||||
@@ -67,7 +52,7 @@
|
||||
<option v-for="item in services" :value="item.name"> {{item.name}} [{{item.comment}}]</option>
|
||||
</select>
|
||||
|
||||
<span class="input-group-btn pull-left" style="padding-left: 20px">
|
||||
<span class="input-group-btn pull-left" style="padding-left: 5px">
|
||||
<button @click="createService()" :class="['btn']" type="button"> 新建业务</button>
|
||||
</span>
|
||||
|
||||
@@ -79,7 +64,7 @@
|
||||
<button @click="status=6" :class="['btn',{'btn-primary':status==6}]" type="button"> 查询配置</button>
|
||||
</span>
|
||||
|
||||
<span class="input-group-btn" style="padding-left: 20px">
|
||||
<span class="input-group-btn" style="padding-left: 10px">
|
||||
<button @click="status=3" :class="['btn',{'btn-primary':status==3}]" type="button"> 导出配置</button>
|
||||
</span>
|
||||
<!--<span class="input-group-btn">
|
||||
@@ -89,106 +74,96 @@
|
||||
<button @click="tipShow()" :class="['btn',{'btn-primary':status==7}]" type="button"> 基本属性</button>
|
||||
</span>-->
|
||||
|
||||
<span class="input-group-btn" style="padding-left: 30px">
|
||||
<span class="input-group-btn" style="padding-left: 20px">
|
||||
<button @click="save()" :class="['btn',{'btn-primary':status!=0},{'disabled':status==0}]" type="button"> 保存</button>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="col-xs-1" style="padding-right: 0px">
|
||||
<ul class="nav nav-tabs nav-stacked tlist" style="height: 100%">
|
||||
<div class="col-md-2">
|
||||
<div style="padding-left: 10px;background-color: #ccc;width: 100%"> 业务相关表</div>
|
||||
<ul class="nav nav-tabs nav-stacked tlist">
|
||||
<li @click="sheet=item" :class="[{active: sheet==item }]" v-for="item in sheetArr" >
|
||||
<a href="javascript:;" data-target="#tab3Content1" data-toggle="tab" v-text="serviceDetail['tables'][item]['name']"></a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="col-xs-6" style="padding-left: 0px;">
|
||||
<div class="tab-content">
|
||||
<div class="tab-pane fade active in" id="">
|
||||
<table :class="[{'table':status!=2},'table-bordered', 'table-auto']" style="width: 100%">
|
||||
<tr style="background-color: #f1f1f1">
|
||||
<td v-show="status==3 || status==4 || status==5 || status==6"><input type="checkbox"></td>
|
||||
<th v-show="status==1"></th>
|
||||
<th>字段名</th>
|
||||
<th>中文名</th>
|
||||
<th>数据类型</th>
|
||||
<th>输入类型</th>
|
||||
<th>附加属性</th>
|
||||
<th>备注</th>
|
||||
</tr>
|
||||
<tr v-for="(item, index) in serviceDetail['tables'][sheet].items">
|
||||
<td v-show="status==3"><input type="checkbox" v-model="serviceInfo.exports" :value="sheet + '$' + item.name" class=""></td>
|
||||
<td v-show="status==4"><input type="checkbox" v-model="serviceInfo.imports" :value="sheet + '$' + item.name" class=""></td>
|
||||
<td v-show="status==5"><input type="checkbox" v-model="serviceInfo.shows" :value="sheet + '$' + item.name" class=""></td>
|
||||
<td v-show="status==6"><input type="checkbox" v-model="filterArr" :value="sheet + '$' + item.name" class=""></td>
|
||||
|
||||
<td v-show="status==1" class="icon icon-move"></td>
|
||||
<td v-show="status!=2" v-text="item.name" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-show="status!=2" v-text="item.label"></td>
|
||||
<td v-show="status!=2" v-text="item.type"></td>
|
||||
<td v-show="status!=2" v-text="item.inType"></td>
|
||||
<td v-show="status!=2" v-text="item.inExt"></td>
|
||||
<td v-show="status!=2" v-text="item.remark"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 实体字段信息 -->
|
||||
<div class="col-md-5" style="padding-left: 0px;">
|
||||
<div style="padding-left: 10px;background-color: #ccc;width: 100%"> 字段信息</div>
|
||||
<table class="table table-bordered">
|
||||
<tr>
|
||||
<td v-show="status==3 || status==4 || status==5 || status==6"><input type="checkbox"></td>
|
||||
<th v-show="status==1"></th>
|
||||
<th>字段名</th>
|
||||
<th>中文名</th>
|
||||
<th>数据类型</th>
|
||||
<!--<th>输入类型</th>
|
||||
<th>附加属性</th>
|
||||
<th>备注</th>-->
|
||||
</tr>
|
||||
<tr v-for="(item, index) in serviceDetail['tables'][sheet].items">
|
||||
<td v-show="status==3"><input type="checkbox" v-model="serviceInfo.exports" :value="sheet + '$' + item.name"></td>
|
||||
<td v-show="status==4"><input type="checkbox" v-model="serviceInfo.imports" :value="sheet + '$' + item.name"></td>
|
||||
<td v-show="status==5"><input type="checkbox" v-model="serviceInfo.shows" :value="sheet + '$' + item.name"></td>
|
||||
<td v-show="status==6"><input type="checkbox" v-model="filterArr" :value="sheet + '$' + item.name"></td>
|
||||
|
||||
<td v-text="item.name" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="item.label"></td>
|
||||
<td v-text="item.type"></td>
|
||||
<!--<td v-text="item.inType"></td>
|
||||
<td v-text="item.inExt"></td>
|
||||
<td v-text="item.remark"></td>-->
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
<div class="col-xs-5" style="padding-left: 0px;padding-right: 0px">
|
||||
|
||||
<div class="col-md-5" style="padding-left: 0px;padding-right: 0px;">
|
||||
<!-- shows -->
|
||||
<div class="panel" v-show="status==5">
|
||||
<div class="panel-heading">列表展示的属性</div>
|
||||
<div id="show" class="panel-body">
|
||||
<table class="table-bordered table-auto" style="width: 100%">
|
||||
<thead>
|
||||
<tr style="background-color: #f1f1f1">
|
||||
<th></th>
|
||||
<th>字段名</th>
|
||||
<th>中文名</th>
|
||||
<!--<th>支持排序</th>-->
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(item, index) in serviceInfo.shows">
|
||||
<td class="icon icon-move">
|
||||
<input name="name" :value="item" type="hidden">
|
||||
</td>
|
||||
<td v-text="item" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="">{{getFieldLabel(item)}}</td>
|
||||
<td v-show="false"><input v-model="item.label" style="width: 100px;"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div id="show" v-show="status==5">
|
||||
<div style="padding-left: 10px;background-color: #ccc;width: 100%"> 展示字段配置</div>
|
||||
<table class="table table-bordered table-auto" style="width: 100%;background-color: #fff;">
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>字段名</th>
|
||||
<th>中文名</th>
|
||||
<!--<th>支持排序</th>-->
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="(item, index) in serviceInfo.shows">
|
||||
<td class="icon icon-move">
|
||||
<input name="name" :value="item" type="hidden">
|
||||
</td>
|
||||
<td v-text="item" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="">{{getFieldLabel(item)}}</td>
|
||||
<td v-show="false"><input v-model="item.label" style="width: 100px;"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<!-- exports -->
|
||||
<div class="panel" v-show="status==3">
|
||||
<div class="panel-heading">导出的属性配置</div>
|
||||
<div id="export" class="panel-body">
|
||||
<table class="table-bordered table-auto" style="width: 100%">
|
||||
<thead>
|
||||
<tr style="background-color: #f1f1f1">
|
||||
<th></th>
|
||||
<th>字段名</th>
|
||||
<th>中文名</th>
|
||||
<!--<th>展示名</th>-->
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(item, index) in serviceInfo.exports">
|
||||
<td class="icon icon-move">
|
||||
<input name="name" :value="item" type="hidden">
|
||||
</td>
|
||||
<td v-text="item" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="">{{getFieldLabel(item)}}</td>
|
||||
<td v-show="false"><input v-model="item.label" style="width: 100px;"></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div id="export" v-show="status==3">
|
||||
<div style="padding-left: 10px;background-color: #ccc;width: 100%"> 查询配置</div>
|
||||
<table class="table table-bordered table-auto" style="width: 100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>字段名</th>
|
||||
<th>中文名</th>
|
||||
<!--<th>展示名</th>-->
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="(item, index) in serviceInfo.exports">
|
||||
<td class="icon icon-move">
|
||||
<input name="name" :value="item" type="hidden">
|
||||
</td>
|
||||
<td v-text="item" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="">{{getFieldLabel(item)}}</td>
|
||||
<td v-show="false"><input v-model="item.label" style="width: 100px;"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
<!-- imports -->
|
||||
@@ -221,45 +196,39 @@
|
||||
</div>
|
||||
|
||||
<!-- filters -->
|
||||
<div class="panel" v-show="status==6">
|
||||
<div class="panel-heading">查询配置</div>
|
||||
<div id="filter" class="panel-body" style="overflow:auto;">
|
||||
<table class="table-bordered table-auto" style="width: 100%">
|
||||
<thead>
|
||||
<tr style="background-color: #f1f1f1">
|
||||
<th></th>
|
||||
<th style="width: 30px">字段名</th>
|
||||
<th style="width: 30px">中文名</th>
|
||||
<th style="width: 30px">默认展示</th>
|
||||
<th>支持查询类型</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr v-for="(item, index) in filterArr">
|
||||
<td class="icon icon-move">
|
||||
<input name="name" :value="item" type="hidden">
|
||||
</td>
|
||||
<td v-text="item" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="">{{getFieldLabel(item)}}</td>
|
||||
<td>
|
||||
<label>
|
||||
<input type="checkbox" v-model="filterMap[item].checked" value="1"> 展示
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<label class="checkbox-inline" v-for="c in filterCate">
|
||||
<input type="checkbox" v-model="filterMap[item].filterType" :value="c"> {{c}}
|
||||
</label>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div id="filter" v-show="status==6">
|
||||
<div style="padding-left: 10px;background-color: #ccc;width: 100%"> 查询配置</div>
|
||||
<table class="table table-bordered table-auto" style="width: 100%">
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th style="width: 30px">字段名</th>
|
||||
<th style="width: 30px">中文名</th>
|
||||
<th style="width: 30px">默认展示</th>
|
||||
<th>支持查询类型</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tr v-for="(item, index) in filterArr">
|
||||
<td class="icon icon-move">
|
||||
<input name="name" :value="item" type="hidden">
|
||||
</td>
|
||||
<td v-text="item" style="background-color: rgb(235, 235, 228);"></td>
|
||||
<td v-text="">{{getFieldLabel(item)}}</td>
|
||||
<td>
|
||||
<label>
|
||||
<input type="checkbox" v-model="filterMap[item].checked" value="1"> 展示
|
||||
</label>
|
||||
</td>
|
||||
<td>
|
||||
<label class="checkbox-inline" v-for="c in filterCate">
|
||||
<input type="checkbox" v-model="filterMap[item].filterType" :value="c"> {{c}}
|
||||
</label>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="clearfix"></div>
|
||||
|
||||
|
||||
<!-- 新建业务 -->
|
||||
<div class="modal fade" id="createServiceDia">
|
||||
|
||||
Reference in New Issue
Block a user