merger master
This commit is contained in:
commit
4887585838
|
@ -155,3 +155,4 @@ quota_duration_excess_organization=The stress test duration exceeds the organiza
|
||||||
email_subject=Metersphere timing task result notification
|
email_subject=Metersphere timing task result notification
|
||||||
import_xmind_count_error=The number of use cases imported into the mind map cannot exceed 500
|
import_xmind_count_error=The number of use cases imported into the mind map cannot exceed 500
|
||||||
import_xmind_not_found=Test case not found
|
import_xmind_not_found=Test case not found
|
||||||
|
license_valid_license_error=Authorization authentication failed
|
||||||
|
|
|
@ -153,6 +153,7 @@ quota_duration_excess_workspace=压测时长超过工作空间限额
|
||||||
quota_duration_excess_organization=压测时长超过组织限额
|
quota_duration_excess_organization=压测时长超过组织限额
|
||||||
email_subject=MeterSphere定时任务结果通知
|
email_subject=MeterSphere定时任务结果通知
|
||||||
import_xmind_count_error=思维导图导入用例数量不能超过 500 条
|
import_xmind_count_error=思维导图导入用例数量不能超过 500 条
|
||||||
|
license_valid_license_error=授权认证失败
|
||||||
import_xmind_not_found=未找到测试用例
|
import_xmind_not_found=未找到测试用例
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -858,7 +858,7 @@ export class Controller extends BaseConfig {
|
||||||
super();
|
super();
|
||||||
this.type = type
|
this.type = type
|
||||||
options.id = options.id || uuid();
|
options.id = options.id || uuid();
|
||||||
options.enable = options.enable || true;
|
options.enable = options.enable === undefined ? true : options.enable;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -896,7 +896,7 @@ export class Timer extends BaseConfig {
|
||||||
super();
|
super();
|
||||||
this.type = type;
|
this.type = type;
|
||||||
options.id = options.id || uuid();
|
options.id = options.id || uuid();
|
||||||
options.enable = options.enable || true;
|
options.enable = options.enable === undefined ? true : options.enable;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -6,7 +6,8 @@
|
||||||
<span class="character">SCHEDULER</span>
|
<span class="character">SCHEDULER</span>
|
||||||
</span>
|
</span>
|
||||||
<el-switch :disabled="!schedule.value || isReadOnly" v-model="schedule.enable" @change="scheduleChange"/>
|
<el-switch :disabled="!schedule.value || isReadOnly" v-model="schedule.enable" @change="scheduleChange"/>
|
||||||
<ms-schedule-edit :is-read-only="isReadOnly" :schedule="schedule" :test-id="testId" :save="save" :custom-validate="customValidate"
|
<ms-schedule-edit :is-read-only="isReadOnly" :schedule="schedule" :test-id="testId" :save="save"
|
||||||
|
:custom-validate="customValidate"
|
||||||
ref="scheduleEdit"/>
|
ref="scheduleEdit"/>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
@ -22,23 +23,24 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import MsScheduleEdit from "./MsScheduleEdit";
|
import MsScheduleEdit from "./MsScheduleEdit";
|
||||||
import CrontabResult from "../cron/CrontabResult";
|
import CrontabResult from "../cron/CrontabResult";
|
||||||
|
|
||||||
function defaultCustomValidate() {
|
function defaultCustomValidate() {
|
||||||
return {pass: true};
|
return {pass: true};
|
||||||
}
|
}
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "MsScheduleConfig",
|
name: "MsScheduleConfig",
|
||||||
components: {CrontabResult, MsScheduleEdit},
|
components: {CrontabResult, MsScheduleEdit},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
recentList: [],
|
recentList: [],
|
||||||
|
refreshScheduler: null,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
props: {
|
props: {
|
||||||
testId:String,
|
testId: String,
|
||||||
save: Function,
|
save: Function,
|
||||||
schedule: {},
|
schedule: {},
|
||||||
checkOpen: {
|
checkOpen: {
|
||||||
|
@ -72,40 +74,57 @@ export default {
|
||||||
},
|
},
|
||||||
flashResultList() {
|
flashResultList() {
|
||||||
this.$refs.crontabResult.expressionChange();
|
this.$refs.crontabResult.expressionChange();
|
||||||
|
},
|
||||||
|
cancelRefresh() {
|
||||||
|
if (this.refreshScheduler) {
|
||||||
|
clearInterval(this.refreshScheduler);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
beforeDestroy() {
|
||||||
|
this.cancelRefresh();
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
schedule() {
|
||||||
|
if (this.schedule.enable) {
|
||||||
|
this.refreshScheduler = setInterval(this.flashResultList, 2000);
|
||||||
|
} else {
|
||||||
|
this.cancelRefresh();
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
|
|
||||||
.schedule-config {
|
.schedule-config {
|
||||||
float: right;
|
float: right;
|
||||||
width: 250px;
|
width: 250px;
|
||||||
height: 15px;
|
height: 15px;
|
||||||
line-height: 25px;
|
line-height: 25px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-icon-date {
|
.el-icon-date {
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
margin-left: 5px;
|
margin-left: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.character {
|
.character {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin: 0 5px;
|
margin: 0 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.disable-character {
|
.disable-character {
|
||||||
color: #cccccc;
|
color: #cccccc;
|
||||||
}
|
}
|
||||||
|
|
||||||
.el-switch {
|
.el-switch {
|
||||||
margin: 0 5px;
|
margin: 0 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cron-ico {
|
.cron-ico {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
}
|
}
|
||||||
|
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue