提交: 场景控制 触发器中 cron 使用弹窗去掉右上角关闭,改为取消按钮。
This commit is contained in:
parent
f5548043d2
commit
57c5124828
|
@ -29,6 +29,7 @@ export default {
|
||||||
exeStartTime: "",
|
exeStartTime: "",
|
||||||
open: false,
|
open: false,
|
||||||
isAntiShake: false,
|
isAntiShake: false,
|
||||||
|
oldCronValue: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
@ -79,7 +80,7 @@ export default {
|
||||||
if (!this.dataItem['execScript']) {
|
if (!this.dataItem['execScript']) {
|
||||||
this.dataItem['execScript'] = '* * * * * ? *';
|
this.dataItem['execScript'] = '* * * * * ? *';
|
||||||
}
|
}
|
||||||
this.open = false
|
this.open = false;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
|
@ -159,14 +160,14 @@ export default {
|
||||||
dataItem.method === 'TIMER' ?
|
dataItem.method === 'TIMER' ?
|
||||||
<div>
|
<div>
|
||||||
<el-input placeholder="请输入内容" v-model={dataItem['execScript']}>
|
<el-input placeholder="请输入内容" v-model={dataItem['execScript']}>
|
||||||
<el-button slot="append" onClick={() => { this.open = true}} icon="el-icon-connection"></el-button>
|
<el-button slot="append" onClick={() => { this.open = true; this.oldCronValue = dataItem['execScript']}} icon="el-icon-connection"></el-button>
|
||||||
</el-input>
|
</el-input>
|
||||||
</div> : null
|
</div> : null
|
||||||
}
|
}
|
||||||
<el-dialog
|
<el-dialog
|
||||||
title="cron-表达式"
|
title="cron-表达式"
|
||||||
visible={this.open}
|
visible={this.open}
|
||||||
onClose={() => {this.open = false}}
|
show-close={false}
|
||||||
class="eldialog-wrap"
|
class="eldialog-wrap"
|
||||||
width="880px"
|
width="880px"
|
||||||
append-to-body
|
append-to-body
|
||||||
|
@ -183,7 +184,11 @@ export default {
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<div slot="footer" class="dialog-footer" style="padding-right: 10px;">
|
<div slot="footer" class="dialog-footer" style="padding-right: 10px;">
|
||||||
<el-button type="primary" size="mini" onClick={this.handleCronSubmit} >确 定</el-button>
|
<el-button type="primary" size="mini" style="margin-right: 10px;" onClick={this.handleCronSubmit} >确 定</el-button>
|
||||||
|
<el-button size="mini" onClick={() => {
|
||||||
|
dataItem['execScript'] = this.oldCronValue
|
||||||
|
this.open = false;
|
||||||
|
}} >取 消</el-button>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
|
|
Loading…
Reference in New Issue