优化数据展示

This commit is contained in:
java110 2020-06-03 10:59:57 +08:00
parent 7ed9de2dc7
commit a3f9b4c715
2 changed files with 12 additions and 14 deletions

View File

@ -1,5 +1,5 @@
<div id="addJobModel" class="modal fade" tabindex="-1" role="dialog" aria-labelledby="exampleModalLabel"
aria-hidden="true">
aria-hidden="true">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-body">
@ -11,18 +11,16 @@
<label class="col-sm-2 col-form-label">任务名称</label>
<div class="col-sm-10">
<input v-model="addJobInfo.taskName" type="text" placeholder="必填,请填写任务名称"
class="form-control">
class="form-control">
</div>
</div>
<div class="form-group row">
<label class="col-sm-2 col-form-label">选择模板</label>
<div class="col-sm-10">
<select class="form-control form-control-sm"
v-model="addJobInfo.templateId"
@change="chooseTemplate(item)">
<option v-for="item in addJobInfo.templates"
:label="item.templateName"
:value="item.templateId">{{item.templateName}}
<select class="form-control form-control-sm" v-model="addJobInfo.templateId"
@change="chooseTemplate()" placeholder="必填,请选择模板">
<option v-for="item in addJobInfo.templates" :label="item.templateName"
:value="item.templateId">{{item.templateName}}
</option>
</select>
@ -32,14 +30,14 @@
<label class="col-sm-2 col-form-label">定时时间</label>
<div class="col-sm-10">
<input v-model="addJobInfo.taskCron" type="text" placeholder="选填,请填写定时时间"
class="form-control">
class="form-control">
</div>
</div>
<div class="form-group row" v-for="item in addJobInfo.templateSpecs">
<label class="col-sm-2 col-form-label">{{item.specName}}</label>
<div class="col-sm-10">
<input v-model="item.value" type="text" :placeholder="item.specDesc"
class="form-control">
class="form-control">
</div>
</div>
@ -48,7 +46,7 @@
class="fa fa-check"></i>&nbsp;保存
</button>
<button type="button" class="btn btn-warning float-right" style="margin-right:20px;"
data-dismiss="modal">取消
data-dismiss="modal">取消
</button>
</div>
</div>
@ -57,4 +55,4 @@
</div>
</div>
</div>
</div>
</div>

View File

@ -112,13 +112,13 @@
vc.toast("查询地区失败");
});
},
chooseTemplate: function (_template) {
chooseTemplate: function () {
//根据当前 template 查询属性 渲染页面
var _param = {
params: {
page: 1,
row: 30,
templateId: _template.templateId,
templateId: $that.addJobInfo.templateId,
isShow: 'T'
}
};